ct.pl als Controller
[kivitendo-erp.git] / templates / webpages / customer_vendor / get_delivery.html
diff --git a/templates/webpages/customer_vendor/get_delivery.html b/templates/webpages/customer_vendor/get_delivery.html
new file mode 100644 (file)
index 0000000..7cfc76f
--- /dev/null
@@ -0,0 +1,48 @@
+[% USE T8 %]
+[% USE HTML %]
+[% USE LxERP %]
+<div id="delivery">
+  <table width="100%">
+    <tr>
+      <td>
+        <table width="100%">
+          <tr class="listheading">
+            <th class="listheading">[% 'Shipping Address' | $T8 %]</th>
+            <th class="listheading">[% 'Invoice' | $T8 %]</th>
+            <th class="listheading">[% 'Order' | $T8 %]</th>
+            <th class="listheading">[% 'Invdate' | $T8 %]</th>
+            <th class="listheading">[% 'Description' | $T8 %]</th>
+            <th class="listheading">[% 'Qty' | $T8 %]</th>
+            <th class="listheading">[% 'Unit' | $T8 %]</th>
+            [% IF ( SELF.is_customer() ) %]
+              <th class="listheading">[% 'Sell Price' | $T8 %]</th>
+            [% ELSE %]
+              <th class="listheading">[% 'Last Cost' | $T8 %]</th>
+            [%- END %]
+          </tr>
+
+
+          [% FOREACH row = SELF.delivery %]
+            [% row.script = SELF.is_vendor() ? ( row.invoice ? 'ir' : 'ap' ) : ( row.invoice ? 'is' : 'ar' ) %]
+            <tr class="listrow[% loop.count % 2 %]">
+              <td>[% HTML.escape(row.shiptoname) UNLESS loop.prev.shiptoname == row.shiptoname %]&nbsp;</td>
+              <td>[% IF row.id %]<a href='[% row.script %].pl?action=edit&id=[% HTML.escape(row.id) %]'>[% END %][% HTML.escape(row.invnumber)   || '&nbsp;' %][% IF row.id %]</a>[% END %]</td>
+              <td>[% IF row.oe_id %]<a href='oe.pl?action=edit&type=[% IF is_customer %]sales_order[% ELSE %]purchase_order[% END %]&vc=customer&id=[% HTML.escape(row.oe_id) %]'>[% END %][% HTML.escape(row.ordnumber)   || '&nbsp;' %][% IF row.oe_id %]</a>[% END %]</td>
+              <td>[% HTML.escape(row.transdate)   || '&nbsp;' %]</td>
+              <td>[% HTML.escape(row.description) || '&nbsp;' %]</td>
+              <td>[% HTML.escape(row.qty)         || '&nbsp;' %]</td>
+              <td>[% HTML.escape(row.unit)        || '&nbsp;' %]</td>
+              <td>[% LxERP.format_amount(row.sellprice, 2) || '&nbsp;' %]</td>
+            </tr>
+          [% END %]
+
+        </table>
+
+        [% IF DELIVERY.size == 15 %]
+          <p>[% 'This list is capped at 15 items to keep it fast. If you need a full list, please use reports.' | $T8 %]</p>
+        [% END %]
+
+      </td>
+    </tr>
+  </table>
+</div>