Просмотр исходного кода

Med center - show prev freq and exp in moe

Vijayakrishnan 3 лет назад
Родитель
Сommit
66a73ea705

+ 2 - 2
resources/views/app/patient/segment-templates/_child_review/medication/edit-review-in-place-optimized.php

@@ -9,14 +9,14 @@
                 <label class="text-sm mb-0 font-weight-bold text-secondary">Frequency</label>
                 <input type="text"
                        data-name="value"
-                       value="<?= @($currentChildReview->data->value) ? trim(strip_tags($currentChildReview->data->value)) : '' ?>"
+                       value="<?= @($currentChildReview->data->value) ? trim(strip_tags($currentChildReview->data->value)) : (@($previousChildReview->data->value) ? trim(strip_tags($previousChildReview->data->value)) : '') ?>"
                        class="form-control form-control-sm min-width-unset">
             </div>
             <div class="mb-2">
                 <label class="text-sm mb-0 font-weight-bold text-secondary">Experience</label>
                 <input type="text"
                        data-name="experience"
-                       value="<?= @($currentChildReview->data->experience) ?>"
+                       value="<?= @($currentChildReview->data->experience) ? trim(strip_tags($currentChildReview->data->experience)) : (@($previousChildReview->data->experience) ? trim(strip_tags($previousChildReview->data->experience)) : '') ?>"
                        class="form-control form-control-sm min-width-unset">
             </div>
 

+ 2 - 2
resources/views/app/patient/segment-templates/_child_review/medication/edit-review-optimized.php

@@ -13,14 +13,14 @@
             <label class="text-sm mb-0 font-weight-bold text-secondary">Frequency</label>
             <input type="text"
                    data-name="value"
-                   value="<?= @($currentChildReview->data->value) ? trim(strip_tags($currentChildReview->data->value)) : '' ?>"
+                   value="<?= @($currentChildReview->data->value) ? trim(strip_tags($currentChildReview->data->value)) : (@($previousChildReview->data->value) ? trim(strip_tags($previousChildReview->data->value)) : '') ?>"
                    class="form-control form-control-sm min-width-unset">
         </div>
         <div class="mb-2">
             <label class="text-sm mb-0 font-weight-bold text-secondary">Experience</label>
             <input type="text"
                    data-name="experience"
-                   value="<?= @($currentChildReview->data->experience) ?>"
+                   value="<?= @($currentChildReview->data->experience) ? trim(strip_tags($currentChildReview->data->experience)) : (@($previousChildReview->data->experience) ? trim(strip_tags($previousChildReview->data->experience)) : '') ?>"
                    class="form-control form-control-sm min-width-unset">
         </div>