]> wagnertech.de Git - mfinanz.git/blobdiff - templates/mobile_webpages/image_upload/form.html
ImageUpload: erste Version
[mfinanz.git] / templates / mobile_webpages / image_upload / form.html
diff --git a/templates/mobile_webpages/image_upload/form.html b/templates/mobile_webpages/image_upload/form.html
new file mode 100644 (file)
index 0000000..428f6b9
--- /dev/null
@@ -0,0 +1,31 @@
+[% USE HTML %]
+[% USE T8 %]
+[% USE P %]
+[% USE LxERP %]
+
+<h1>[% title | html %]</h1>
+
+<form action="controller.pl">
+
+[% IF !SELF.object.id %]
+
+  <p>[% 'Input delivery order number (picker NYI)' | $T8 %]</p>
+
+  [% P.M.input_tag("object_number", "", label=LxERP.t8("Number")) %]
+  [% P.M.submit_tag("submit", LxERP.t8("Update")) %]
+[% ELSE %]
+  <h2>[% SELF.object.displayable_name | html %]</h2>
+
+  [% P.hidden_tag("object_id", SELF.object.id) %]
+[% END %]
+
+[% P.hidden_tag("object_type", SELF.object_type) %]
+[% P.hidden_tag("action", "ImageUpload/upload_image") %]
+</form>
+
+[%# IF SELF.object.id %]
+  <div id="image_list_[% SELF.object_type | html %]"></div>
+  <script>
+    $(function() { $.get('controller.pl', { action: "File/list", "file_type": "image", "object_type": "[% SELF.object_type %]", "object_id": "[% SELF.object.id %]", "json": "1"}, kivi.eval_json_result) });
+  </script>
+[%# END %]