| Total Complexity | 2 |
| Total Lines | 70 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 8 | class AppsSettings extends AbstractModel |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * Default number of settings for an app. |
||
| 12 | */ |
||
| 13 | const APP_DEFAULT_SETTINGS_NUMBER = 16; |
||
| 14 | /** |
||
| 15 | * |
||
| 16 | * @var integer |
||
| 17 | */ |
||
| 18 | public $apps_id; |
||
| 19 | |||
| 20 | /** |
||
| 21 | * |
||
| 22 | * @var string |
||
| 23 | */ |
||
| 24 | public $name; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * |
||
| 28 | * @var string |
||
| 29 | */ |
||
| 30 | public $value; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * |
||
| 34 | * @var string |
||
| 35 | */ |
||
| 36 | public $created_at; |
||
| 37 | |||
| 38 | /** |
||
| 39 | * |
||
| 40 | * @var string |
||
| 41 | */ |
||
| 42 | public $updated_at; |
||
| 43 | |||
| 44 | /** |
||
| 45 | * |
||
| 46 | * @var integer |
||
| 47 | */ |
||
| 48 | public $is_deleted; |
||
| 49 | |||
| 50 | /** |
||
| 51 | * Sub based app key word. |
||
| 52 | */ |
||
| 53 | const SUBSCRIPTION_BASED = 'subscription_based'; |
||
| 54 | |||
| 55 | /** |
||
| 56 | * Initialize method for model. |
||
| 57 | */ |
||
| 58 | public function initialize() |
||
| 59 | { |
||
| 60 | $this->setSource('apps_settings'); |
||
| 61 | |||
| 62 | $this->belongsTo( |
||
| 63 | 'apps_id', |
||
| 64 | 'Canvas\Models\Apps', |
||
| 65 | 'id', |
||
| 66 | ['alias' => 'app'] |
||
| 67 | ); |
||
| 68 | } |
||
| 69 | |||
| 70 | /** |
||
| 71 | * Returns table name mapped in the model. |
||
| 72 | * |
||
| 73 | * @return string |
||
| 74 | */ |
||
| 75 | public function getSource() : string |
||
| 78 | } |
||
| 79 | } |
||
| 80 |