additional prescription fields, improved display of clients and prescriptions
[confetti] / templates / view_prescription.sh
index c11bd9d..57ff0b6 100755 (executable)
@@ -38,9 +38,16 @@ cat <<END_HTML
 <br>
 <label for="addcontrib">$(l10n addcontrib)</label>
 <span id="addcontrib">${mpx[addcontrib]}</span>
-<label class="checkbox ${mpx[contribconfirm]:+checked}" for="contribconfirm">$(l10n contribconfirm)</label>
+<label for="contribconfirm">$(l10n contribconfirm)</label>
+<span id="contribconfirm">${mpx[contribconfirm]}</span>
+<label class="checkbox ${mpx[contribreceipt]:+checked}" for="contribreceipt">$(l10n contribreceipt)</label>
 </fieldset>
 
+<label class="checkbox ${mpx[prescreviewed]:+checked}" for="prescreviewed">
+  $([ -n "${mpx[prescreviewed]}" ] && printf %s "$(l10n prescreviewed)" \
+                                   || printf %s "$(l10n prescreview)" )
+</label>
+
 <fieldset class="catalogue">
 <h2>$(l10n prescription_by_catalogue)</h2>
 <label class="radio $(check "$mpx[prescno]" first)" for="prescfirst">$(l10n prescfirst)</label>
@@ -49,9 +56,9 @@ cat <<END_HTML
 <br>
 <label class="radio $(check "$mpx[prescno]" follow2)" for="prescfollow2">$(l10n prescfollow2)</label>
 <br>
-<label class="radio $(check "$mpx[prescno]" continual)" for="presccontinual">$(l10n presccontinual)</label>
-<br>
 <label class="radio $(check "$mpx[prescno]" other)" for="prescother">$(l10n prescother)</label>
+<br>
+<label class="radio $(check "$mpx[prescno]" continual)" for="presccontinual">$(l10n presccontinual)</label>
 
 <br>
 <label class="checkbox ${mpx[grouptherapy]:+checked}" for="grouptherapy">$(l10n grouptherapy)</label>
@@ -85,8 +92,6 @@ cat <<END_HTML
 <span id="icd10">${mpx[icd10]}</span>
 </fieldset>
 
-<label class="checkbox ${mpx[prescreviewed]:+checked}" for="prescreviewed">$(l10n prescreviewed)</label>
-
 <fieldset class="controls">
 <a class="button" href="?p=prescriptions&amp;edit=${mpx[prescription]}">$(l10n edit)</a>
 <a class="button" href="?p=therapy&amp;id=${mpx[prescription]%.mpx}.tpy">$(l10n therapy)</a>