# You should have received a copy of the GNU Affero General Public License
# along with Confetti. If not, see <http://www.gnu.org/licenses/>.
-edit="${_GET[edit]}"
client="${_GET[client]}"
-[ -z "$client" ] && client="${edit%.*.mpx}.vcf"
+edit="${_GET[edit]}"
+[ -n "$edit" ] && client="${edit%.*.mpx}.vcf"
cat <<EOF
<div id="${card}" class="card">$(view_card "$client")</div>
-<h1>$(l10n prescriptions_current)</h1>
+<!--h1>$(l10n prescriptions_current)</h1-->
${edit:+$(edit_prescription "$edit")}
-
<div class="newprescription">
<form action="?action=new_prescription" method="POST">
<input type="hidden" name="client" value="$client">
$(list_prescriptions "$client" \
|while read pre; do
- view_prescription "$pre"
+ [ "$pre" = "$edit" ] || view_prescription "$pre"
done
)
-<h1>$(l10n prescriptions_past)</h1>
+<!--h1>$(l10n prescriptions_past)</h1-->
EOF