| Conditions | 2 |
| Paths | 2 |
| Total Lines | 19 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 6 | public function up() |
||
| 7 | { |
||
| 8 | // Don't do anything if the "settings" table already exists |
||
| 9 | if (Yii::app()->db->schema->getTable('settings') !== null) |
||
| 10 | return; |
||
| 11 | |||
| 12 | // Create the "settings" table |
||
| 13 | $this->createTable('settings', array( |
||
| 14 | 'name'=>'VARCHAR PRIMARY KEY NOT NULL', |
||
| 15 | 'value'=>'VARCHAR NULL')); |
||
| 16 | |||
| 17 | // Add default values |
||
| 18 | $this->insert('settings', array( |
||
| 19 | 'name'=>'applicationName', |
||
| 20 | 'value'=>'XBMC Video Server')); |
||
| 21 | |||
| 22 | $this->insert('settings', array( |
||
| 23 | 'name'=>'singleFilePlaylist', |
||
| 24 | 'value'=>'0')); |
||
| 25 | } |
||
| 32 | } |