@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | |
11 | 11 | $this->alterColumn('dds_storage', 'type', "enum('INTEGER_TINY','INTEGER_SHORT','INTEGER','INTEGER_LONG','FLOAT','DOUBLE','DATE','DATETIME','TEXT_SHORT','TEXT','TEXT_LONG','BINARY_SHORT','BINARY','BINARY_LONG','CHAR','TIME') COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the storage type'"); |
12 | 12 | |
13 | - $sql =<<<EOQ |
|
13 | + $sql = <<<EOQ |
|
14 | 14 | SET foreign_key_checks = 0; |
15 | 15 | REPLACE INTO {{%dds_storage}} (`storage_ref`, `label`, `type`, `description`) |
16 | 16 | VALUES |
@@ -21,7 +21,7 @@ discard block |
||
21 | 21 | $connection->createCommand($sql)->execute(); |
22 | 22 | |
23 | 23 | |
24 | - $sql =<<<EOQ |
|
24 | + $sql = <<<EOQ |
|
25 | 25 | SET foreign_key_checks = 0; |
26 | 26 | REPLACE INTO {{%dds_data_type}} (`data_type_ref`, `label`, `description`, `definition`, `storage_ref`, `deleted`) |
27 | 27 | VALUES |
@@ -25,7 +25,7 @@ discard block |
||
25 | 25 | // $connection->createCommand($sql)->execute(); |
26 | 26 | |
27 | 27 | // 1. add the choices datatype |
28 | -$sql =<<<EOQ |
|
28 | +$sql = <<<EOQ |
|
29 | 29 | SET foreign_key_checks = 0; |
30 | 30 | REPLACE INTO `dds_data_type` (`data_type_ref`, `label`, `description`, `definition`, `storage_ref`, `deleted`) |
31 | 31 | VALUES |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | { |
47 | 47 | $connection = neon()->db; |
48 | 48 | |
49 | -$sql =<<<EOQ |
|
49 | +$sql = <<<EOQ |
|
50 | 50 | SET foreign_key_checks = 0; |
51 | 51 | DELETE FROM {{%dds_data_type}} WHERE `data_type_ref`='choice' LIMIT 1; |
52 | 52 | SET foreign_key_checks = 1; |
@@ -6,7 +6,7 @@ discard block |
||
6 | 6 | { |
7 | 7 | public function safeUp() |
8 | 8 | { |
9 | - $sql =<<<EOQ |
|
9 | + $sql = <<<EOQ |
|
10 | 10 | SET foreign_key_checks = 0; |
11 | 11 | REPLACE INTO `dds_data_type` (`data_type_ref`, `label`, `description`, `definition`, `storage_ref`, `deleted`) |
12 | 12 | VALUES |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | |
20 | 20 | public function safeDown() |
21 | 21 | { |
22 | - $sql =<<<EOQ |
|
22 | + $sql = <<<EOQ |
|
23 | 23 | SET foreign_key_checks=0; |
24 | 24 | DELETE FROM `dds_data_type` WHERE `data_type_ref`='choice_multiple'; |
25 | 25 | SET foreign_key_checks=1; |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | public function safeUp() |
9 | 9 | { |
10 | 10 | // add a series of default types to the datatypes |
11 | - $sql =<<<EOQ |
|
11 | + $sql = <<<EOQ |
|
12 | 12 | INSERT INTO `dds_data_type` (`data_type_ref`, `label`, `description`, `definition`, `storage_ref`, `deleted`) |
13 | 13 | VALUES |
14 | 14 | ('binary','Normal Binary','For normal binaries such as images up to 16MB in size','','binary',0), |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | public function safeDown() |
46 | 46 | { |
47 | 47 | // delete the additional rows in the datatypes |
48 | - $sql =<<<EOQ |
|
48 | + $sql = <<<EOQ |
|
49 | 49 | DELETE FROM `dds_data_type` WHERE `data_type_ref` IN |
50 | 50 | ('binary', 'binarylong', 'binaryshort', 'date', 'datetime', 'float', 'floatdouble', |
51 | 51 | 'integer', 'integerlong', 'integershort', 'integertiny', 'text', 'textlong', 'textshort', |
@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | $connection = \Yii::$app->getDb(); |
16 | 16 | |
17 | 17 | // create the various tables for dds |
18 | - $sql=<<<EOQ |
|
18 | + $sql = <<<EOQ |
|
19 | 19 | -- -------------------------------------------------------- |
20 | 20 | |
21 | 21 | -- |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | $command = $connection->createCommand($sql); |
143 | 143 | $command->execute(); |
144 | 144 | |
145 | - $sql=<<<EOQ |
|
145 | + $sql = <<<EOQ |
|
146 | 146 | -- |
147 | 147 | -- Dumping data for table `dds_storage` |
148 | 148 | -- |
@@ -6,7 +6,7 @@ |
||
6 | 6 | { |
7 | 7 | public function safeUp() |
8 | 8 | { |
9 | - $this->addColumn('dds_class', 'definition', $this->text(10000) . " DEFAULT NULL COMMENT 'A definition for use by other modules, but not understood by DDS'"); |
|
9 | + $this->addColumn('dds_class', 'definition', $this->text(10000)." DEFAULT NULL COMMENT 'A definition for use by other modules, but not understood by DDS'"); |
|
10 | 10 | } |
11 | 11 | |
12 | 12 | public function safeDown() |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | * @param string $module which module this is for - e.g. dds or phoebe |
150 | 150 | * @return \neon\daedalus\interfaces\IDdsAppMigrator |
151 | 151 | */ |
152 | - public function getIDdsAppMigrator($module='dds') { |
|
152 | + public function getIDdsAppMigrator($module = 'dds') { |
|
153 | 153 | $factory = $this->get('DdsAppMigratorFactory'); |
154 | 154 | return $factory::createMigrator("@system/$module/migrations"); |
155 | 155 | } |
@@ -197,7 +197,7 @@ discard block |
||
197 | 197 | /** |
198 | 198 | * @inheritdoc |
199 | 199 | */ |
200 | - public function getDataMap($key, $query='', $filters = [], $fields = [], $start = 0, $length = 100) |
|
200 | + public function getDataMap($key, $query = '', $filters = [], $fields = [], $start = 0, $length = 100) |
|
201 | 201 | { |
202 | 202 | if (is_string($query)) { |
203 | 203 | $filters['_map_field_'] = $query; |
@@ -209,7 +209,7 @@ discard block |
||
209 | 209 | /** |
210 | 210 | * @inheritdoc |
211 | 211 | */ |
212 | - public function makeMapLookupRequest($key, $ids, $fields=[]) |
|
212 | + public function makeMapLookupRequest($key, $ids, $fields = []) |
|
213 | 213 | { |
214 | 214 | return $this->IDdsObjectMapManagement->makeMapLookupRequest($ids, $fields, $key); |
215 | 215 | } |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | * @param boolean $refresh whther to refresh the cache before fetching this setting defaults to false |
25 | 25 | * @return string |
26 | 26 | */ |
27 | - public function get($app, $key, $default=null, $refresh=false); |
|
27 | + public function get($app, $key, $default = null, $refresh = false); |
|
28 | 28 | |
29 | 29 | /** |
30 | 30 | * Set a setting value |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | * @param boolean $refresh if true forces reftech fo the the settings |
45 | 45 | * @return array in the format @see self::$_settings |
46 | 46 | */ |
47 | - public function getSettings($refresh=false); |
|
47 | + public function getSettings($refresh = false); |
|
48 | 48 | |
49 | 49 | /** |
50 | 50 | * Load the settings from the database and cache for the session |
@@ -52,6 +52,6 @@ discard block |
||
52 | 52 | * @param boolean $refresh if true forces refresh values from the database |
53 | 53 | * @return array in the format @see self::$_settings |
54 | 54 | */ |
55 | - public function getAll($refresh=false); |
|
55 | + public function getAll($refresh = false); |
|
56 | 56 | |
57 | 57 | } |
@@ -81,7 +81,7 @@ |
||
81 | 81 | public function loadFields() |
82 | 82 | { |
83 | 83 | $settings = neon()->settings->getAppSettings(); |
84 | - foreach($settings as $app => $config) { |
|
84 | + foreach ($settings as $app => $config) { |
|
85 | 85 | if (is_array($config)) { |
86 | 86 | $this->addSubForm($app)->setFields($config)->setLabel(neon($app)->name); |
87 | 87 | } |