| Total Complexity | 5 |
| Total Lines | 65 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 7 | class Import extends Model |
||
| 8 | { |
||
| 9 | protected $fillable = ['file', 'file_rows', 'db_cols', 'row_processed']; |
||
| 10 | |||
| 11 | |||
| 12 | /** |
||
| 13 | * Relationship with import export log model |
||
| 14 | * |
||
| 15 | * @return void |
||
| 16 | */ |
||
| 17 | public function importLogs() |
||
| 20 | } |
||
| 21 | |||
| 22 | |||
| 23 | /** |
||
| 24 | * Model Map accessor |
||
| 25 | * |
||
| 26 | * Unserialize model map while retriving. |
||
| 27 | * @param $value |
||
| 28 | * @return string |
||
| 29 | */ |
||
| 30 | public function getModelMapAttribute($value) |
||
| 31 | { |
||
| 32 | return unserialize( $value ); |
||
| 33 | } |
||
| 34 | |||
| 35 | |||
| 36 | /** |
||
| 37 | * Model Map mulator |
||
| 38 | * |
||
| 39 | * Serialize model map while storing. |
||
| 40 | * @param $value |
||
| 41 | * @return void |
||
| 42 | */ |
||
| 43 | public function setModelMapAttribute($value) |
||
| 46 | } |
||
| 47 | |||
| 48 | |||
| 49 | /** |
||
| 50 | * DB cols accessor |
||
| 51 | * |
||
| 52 | * Unserialize model map while retriving. |
||
| 53 | * @param $value |
||
| 54 | * @return string |
||
| 55 | */ |
||
| 56 | public function getDbColsAttribute($value) |
||
| 59 | } |
||
| 60 | |||
| 61 | |||
| 62 | /** |
||
| 63 | * Model Map mulator |
||
| 64 | * |
||
| 65 | * Serialize model map while storing. |
||
| 66 | * @param $value |
||
| 67 | * @return void |
||
| 68 | */ |
||
| 69 | public function setDbColsAttribute($value) |
||
| 74 |