Blame view

app/Models/Common/Recurring.php 557 Bytes
b7c7a5f6   Alexey Boroda   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
  <?php
  
  namespace App\Models\Common;
  
  use App\Models\Model;
  use App\Traits\Recurring as RecurringTrait;
  
  class Recurring extends Model
  {
      use RecurringTrait;
  
      protected $table = 'recurring';
  
      /**
       * Attributes that should be mass-assignable.
       *
       * @var array
       */
      protected $fillable = ['company_id', 'recurable_id', 'recurable_type', 'frequency', 'interval', 'started_at', 'count'];
  
  
      /**
       * Get all of the owning recurable models.
       */
      public function recurable()
      {
          return $this->morphTo();
      }
  }