Passed
Push — master ( 655b2f...381d64 )
by Tõnis
02:02
created
AddressForm.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
 
81 81
         $countryList = [];
82 82
         foreach ($this->countries as $country) {
83
-            $countryList[$country->getIsoAlpha2()] = $country->getEmoji(). " " . $country->getName();
83
+            $countryList[$country->getIsoAlpha2()] = $country->getEmoji() . " " . $country->getName();
84 84
         }
85 85
         return $countryList;
86 86
     }
Please login to merge, or discard this patch.
views/_country-region-row.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
 use tonisormisson\addressform\AddressHelper;
10 10
 use yii\helpers\ArrayHelper;
11 11
 
12
-$country =$widget->getCountry();
12
+$country = $widget->getCountry();
13 13
 $countryDisabled = !is_null($country);
14 14
 ?>
15 15
 
@@ -27,11 +27,11 @@  discard block
 block discarded – undo
27 27
             'pluginOptions'=>[
28 28
                 'placeholder' => $widget->placeHolders['country'],
29 29
             ],
30
-        ]);?>
30
+        ]); ?>
31 31
     </div>
32 32
 
33 33
     <div class="col-sm-6">
34
-    <?php if(is_null($country)):?>
34
+    <?php if (is_null($country)):?>
35 35
         <?= $form->field($model, 'state')->widget(DepDrop::class, [
36 36
             'type'=>DepDrop::TYPE_SELECT2,
37 37
             'select2Options'=>['pluginOptions'=>['allowClear'=>true]],
@@ -42,14 +42,14 @@  discard block
 block discarded – undo
42 42
                 'loadingText' => Yii::t("addressform", "Loading") . "...",
43 43
                 'value' => !is_null($country) ? (new AddressHelper())->formatList($country->getDivisions()) : [],
44 44
             ],
45
-        ]);?>
45
+        ]); ?>
46 46
     <?php else:?>
47 47
         <?= $form->field($model, 'state')->widget(Select2::class, [
48
-            'data'=>  ArrayHelper::map((new AddressHelper())->formatList($country->getDivisions()),'id', 'name'),
48
+            'data'=>  ArrayHelper::map((new AddressHelper())->formatList($country->getDivisions()), 'id', 'name'),
49 49
             'options' => [
50 50
                 'placeholder' => $widget->placeHolders['state'],
51 51
             ],
52
-        ]);?>
53
-    <?php endif;?>
52
+        ]); ?>
53
+    <?php endif; ?>
54 54
     </div>
55 55
 </div>
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -43,13 +43,16 @@
 block discarded – undo
43 43
                 'value' => !is_null($country) ? (new AddressHelper())->formatList($country->getDivisions()) : [],
44 44
             ],
45 45
         ]);?>
46
-    <?php else:?>
46
+    <?php else {
47
+    :?>
47 48
         <?= $form->field($model, 'state')->widget(Select2::class, [
48 49
             'data'=>  ArrayHelper::map((new AddressHelper())->formatList($country->getDivisions()),'id', 'name'),
49 50
             'options' => [
50 51
                 'placeholder' => $widget->placeHolders['state'],
51 52
             ],
52
-        ]);?>
53
+        ]);
54
+}
55
+?>
53 56
     <?php endif;?>
54 57
     </div>
55 58
 </div>
Please login to merge, or discard this patch.
views/form.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@
 block discarded – undo
22 22
             <?= (in_array('postCode', $widget->disabledFields)) ? null: $form->field($model, 'postCode')->textInput(['placeholder'=>$widget->placeHolders['postCode']]) ?>
23 23
         </div>
24 24
     </div>
25
-    <?= empty($widget->form) ? Html::submitButton($widget->submitText,$widget->submitOptions) : null?>
25
+    <?= empty($widget->form) ? Html::submitButton($widget->submitText, $widget->submitOptions) : null?>
26 26
 
27 27
 <?php (empty($widget->form)) ? ActiveForm::end() : null?>
28 28
 <?= Html::endTag("div")?>
29 29
\ No newline at end of file
Please login to merge, or discard this patch.