X-Git-Url: https://git.plutz.net/?p=confetti;a=blobdiff_plain;f=templates%2Fprescriptions.html.sh;h=a3db3a7d879157a24982c309ca357f5f2d58a76e;hp=9a0dd480912145e0cf6e5f7f79b77c52c3fc2187;hb=fdfc261b61998249782240ecb0d40a10d44936a9;hpb=18ecf2c0b034e25c418a83ecb1adefb9f3f04cd8 diff --git a/templates/prescriptions.html.sh b/templates/prescriptions.html.sh index 9a0dd48..a3db3a7 100755 --- a/templates/prescriptions.html.sh +++ b/templates/prescriptions.html.sh @@ -15,18 +15,17 @@ # You should have received a copy of the GNU Affero General Public License # along with Confetti. If not, see . -edit="${_GET[edit]}" client="${_GET[client]}" -[ -z "$client" ] && client="${edit%.*.mpx}.vcf" +edit="${_GET[edit]}" +[ -n "$edit" ] && client="${edit%.*.mpx}.vcf" cat <$(view_card "$client") -

$(l10n prescriptions_current)

+ ${edit:+$(edit_prescription "$edit")} -
@@ -36,11 +35,11 @@ ${edit:+$(edit_prescription "$edit")} $(list_prescriptions "$client" \ |while read pre; do - view_prescription "$pre" + [ "$pre" = "$edit" ] || view_prescription "$pre" done ) -

$(l10n prescriptions_past)

+ EOF