| Total Complexity | 2 |
| Total Lines | 34 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 8 | class Sms_event extends Model |
||
| 9 | { |
||
| 10 | protected $table = 'mst_sms_events'; |
||
| 11 | |||
| 12 | protected $fillable = [ |
||
| 13 | 'name', |
||
| 14 | 'date', |
||
| 15 | 'message', |
||
| 16 | 'description', |
||
| 17 | 'status', |
||
| 18 | 'send_to', |
||
| 19 | 'created_by', |
||
| 20 | 'updated_by' |
||
| 21 | ]; |
||
| 22 | |||
| 23 | protected $dates = ['created_at', 'updated_at', 'date']; |
||
| 24 | |||
| 25 | //Eloquence Search mapping |
||
| 26 | use Eloquence; |
||
| 27 | |||
| 28 | protected $searchableColumns = [ |
||
| 29 | 'name' => 20, |
||
| 30 | 'date' => 10, |
||
| 31 | 'message' => 5, |
||
| 32 | ]; |
||
| 33 | |||
| 34 | public function createdBy() |
||
| 35 | { |
||
| 36 | return $this->belongsTo('App\User','created_by'); |
||
| 37 | } |
||
| 38 | |||
| 39 | public function updatedBy() |
||
| 42 | } |
||
| 43 | } |
||
| 44 |