@@ -7,13 +7,13 @@ |
||
7 | 7 | public $timezone = 'America/Los_Angeles'; |
8 | 8 | public $password; |
9 | 9 | |
10 | - public static function findIdentity($id) {} |
|
11 | - public static function findIdentityByAccessToken($token, $type = null) {} |
|
12 | - public function getId() {} |
|
13 | - public function getAuthKey() {} |
|
14 | - public function validateAuthKey($authKey) {} |
|
15 | - public function validatePassword($password) {} |
|
16 | - public function setPassword($password) {} |
|
10 | + public static function findIdentity($id) {} |
|
11 | + public static function findIdentityByAccessToken($token, $type = null) {} |
|
12 | + public function getId() {} |
|
13 | + public function getAuthKey() {} |
|
14 | + public function validateAuthKey($authKey) {} |
|
15 | + public function validatePassword($password) {} |
|
16 | + public function setPassword($password) {} |
|
17 | 17 | |
18 | 18 | public static function primaryKey() {} |
19 | 19 | public function attributes() {} |
@@ -20,7 +20,7 @@ |
||
20 | 20 | { |
21 | 21 | use _generated\FunctionalTesterActions; |
22 | 22 | |
23 | - /** |
|
24 | - * Define custom actions here |
|
25 | - */ |
|
23 | + /** |
|
24 | + * Define custom actions here |
|
25 | + */ |
|
26 | 26 | } |
@@ -14,7 +14,7 @@ |
||
14 | 14 | public static function isPrimaryKey($keys) {} |
15 | 15 | public static function find() {} |
16 | 16 | public static function findOne($condition) {} |
17 | - public static function findAll($condition) {return [];} |
|
17 | + public static function findAll($condition) {return []; } |
|
18 | 18 | public static function updateAll($attributes, $condition = null) {} |
19 | 19 | public static function deleteAll($condition = null) {} |
20 | 20 | public function save($runValidation = true, $attributeNames = null) {} |
@@ -36,7 +36,7 @@ |
||
36 | 36 | } |
37 | 37 | |
38 | 38 | if (!empty($this->json)) { |
39 | - foreach($this->json[self::POS_READY] as $json_name => $json_value) { |
|
39 | + foreach ($this->json[self::POS_READY] as $json_name => $json_value) { |
|
40 | 40 | $lines[] = Html::script($json_value, ['type' => 'application/json', 'id' => $json_name]); |
41 | 41 | } |
42 | 42 | } |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | use \yii\helpers\Html; |
3 | 3 | |
4 | -foreach($posts as $file) { |
|
4 | +foreach ($posts as $file) { |
|
5 | 5 | $yaml = $file['yaml']; |
6 | 6 | $content = $file['content']; |
7 | 7 | $short_name = Html::encode($file['date']['name']); |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | $this->title = "The Faster Scale App | $name"; |
14 | 14 | $code = $exception->statusCode; |
15 | 15 | |
16 | -if($code === 404): |
|
16 | +if ($code === 404): |
|
17 | 17 | $this->title = "The Faster Scale App | Page Not Found"; |
18 | 18 | ?> |
19 | 19 | |
@@ -23,7 +23,7 @@ discard block |
||
23 | 23 | <p>Otherwise, please ensure your attempted url is correct.</p> |
24 | 24 | |
25 | 25 | <?php |
26 | -elseif($code >= 500 && $code < 600): |
|
26 | +elseif ($code >= 500 && $code < 600): |
|
27 | 27 | $this->title = "The Faster Scale App | Oops"; |
28 | 28 | ?> |
29 | 29 | <h1>It's not you. It's us.</h1> |
@@ -30,7 +30,8 @@ discard block |
||
30 | 30 | <div class="alert alert-danger"><?= nl2br(Html::encode($name)) ?></div> |
31 | 31 | <p>Well this is embarrassing...we're having an error on our side. So sorry for the annoyance. If you'd like to help, please send us a message on our <a href='<?=Url::to(['site/contact'])?>'>contact form</a>.</p> |
32 | 32 | |
33 | -<?php else: ?> |
|
33 | +<?php else { |
|
34 | + : ?> |
|
34 | 35 | |
35 | 36 | <div class="site-error"> |
36 | 37 | <h1><?= Html::encode($name) ?></h1> |
@@ -38,4 +39,6 @@ discard block |
||
38 | 39 | <p>The above error occurred while the Web server was processing your request.</p> |
39 | 40 | <p>Please contact us if you think this is a server error. Thank you.</p> |
40 | 41 | </div> |
41 | -<?php endif; ?> |
|
42 | +<?php endif; |
|
43 | +} |
|
44 | +?> |
@@ -13,8 +13,8 @@ |
||
13 | 13 | */ |
14 | 14 | site\assets\AppAsset::register($this); |
15 | 15 | |
16 | -if($hash = Utility::getRevHash()) { |
|
17 | - $rev_link = '<a href="'.Utility::getGithubRevUrl().'">'.Utility::getRevHash().'</a>'; |
|
16 | +if ($hash = Utility::getRevHash()) { |
|
17 | + $rev_link = '<a href="' . Utility::getGithubRevUrl() . '">' . Utility::getRevHash() . '</a>'; |
|
18 | 18 | } else $rev_link = 'DEVELOPMENT'; |
19 | 19 | |
20 | 20 | ?> |
@@ -15,7 +15,9 @@ |
||
15 | 15 | |
16 | 16 | if($hash = Utility::getRevHash()) { |
17 | 17 | $rev_link = '<a href="'.Utility::getGithubRevUrl().'">'.Utility::getRevHash().'</a>'; |
18 | -} else $rev_link = 'DEVELOPMENT'; |
|
18 | +} else { |
|
19 | + $rev_link = 'DEVELOPMENT'; |
|
20 | +} |
|
19 | 21 | |
20 | 22 | ?> |
21 | 23 | <?php $this->beginPage() ?> |
@@ -40,7 +40,7 @@ |
||
40 | 40 | print $form |
41 | 41 | ->field($model, "behaviors{$category['id']}") |
42 | 42 | ->checkboxList($behaviors, |
43 | - ['data-toggle' => 'buttons', 'item' => "checkboxItemTemplate"]); |
|
43 | + ['data-toggle' => 'buttons', 'item' => "checkboxItemTemplate"]); |
|
44 | 44 | } |
45 | 45 | print Html::submitButton('Submit', ['class' => 'btn btn-success']); |
46 | 46 | ActiveForm::end(); |
@@ -10,8 +10,7 @@ discard block |
||
10 | 10 | $this->title = "The Faster Scale App | Check-in"; |
11 | 11 | |
12 | 12 | function checkboxItemTemplate($index, $label, $name, $checked, $value) { |
13 | - return Html::checkbox |
|
14 | - ( |
|
13 | + return Html::checkbox( |
|
15 | 14 | $name, |
16 | 15 | $checked, |
17 | 16 | [ |
@@ -35,7 +34,7 @@ discard block |
||
35 | 34 | 'options' => ['class' => 'form-horizontal'], |
36 | 35 | ]); |
37 | 36 | |
38 | -foreach($categories as $category) { |
|
37 | +foreach ($categories as $category) { |
|
39 | 38 | $behaviors = AH::map($behaviorsList[$category['id']], 'id', 'name'); |
40 | 39 | print $form |
41 | 40 | ->field($model, "behaviors{$category['id']}") |
@@ -92,7 +92,7 @@ |
||
92 | 92 | print $form |
93 | 93 | ->field($model, "behaviors{$category['id']}") |
94 | 94 | ->checkboxList($behaviors, |
95 | - ['item' => "checkboxItemTemplate"]); |
|
95 | + ['item' => "checkboxItemTemplate"]); |
|
96 | 96 | } |
97 | 97 | ActiveForm::end(); |
98 | 98 |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | $plus_week = $time->alterLocalDate($actual_date, "+1 week"); |
28 | 28 | |
29 | 29 | $pie_data = []; |
30 | -if($answer_pie) { |
|
30 | +if ($answer_pie) { |
|
31 | 31 | $values = array_map('intval', array_column($answer_pie, "count")); |
32 | 32 | $labels = array_column($answer_pie, "name"); |
33 | 33 | $colors = array_column($answer_pie, "color"); |
@@ -68,15 +68,15 @@ discard block |
||
68 | 68 | </div> |
69 | 69 | </div> |
70 | 70 | |
71 | - <?php if($questions) { |
|
72 | - foreach($questions as $behavior_id => $behavior_questions) { |
|
71 | + <?php if ($questions) { |
|
72 | + foreach ($questions as $behavior_id => $behavior_questions) { |
|
73 | 73 | print "<div class='well well-sm'>"; |
74 | 74 | print "<button type='button' class='btn btn-primary' disabled='disabled'>{$behavior_questions['question']['title']}</button>"; |
75 | 75 | print "<div class='row'>"; |
76 | - foreach($behavior_questions['answers'] as $question) { |
|
76 | + foreach ($behavior_questions['answers'] as $question) { |
|
77 | 77 | print "<div class='col-md-4'>"; |
78 | 78 | print "<p><strong>{$question['title']}</strong></p>"; |
79 | - print "<p>".Html::encode($question['answer'])."</p>"; |
|
79 | + print "<p>" . Html::encode($question['answer']) . "</p>"; |
|
80 | 80 | print "</div>"; |
81 | 81 | } |
82 | 82 | print "</div></div>"; |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | 'options' => ['class' => 'form-horizontal'], |
89 | 89 | ]); |
90 | 90 | |
91 | - foreach($categories as $category) { |
|
91 | + foreach ($categories as $category) { |
|
92 | 92 | $behaviors = AH::map($behaviorsList[$category['id']], 'id', 'name'); |
93 | 93 | print $form |
94 | 94 | ->field($model, "behaviors{$category['id']}") |