PriceRule: Kontextinfo in Kunden
[kivitendo-erp.git] / templates / webpages / customer_vendor / tabs / price_rules.html
diff --git a/templates/webpages/customer_vendor/tabs/price_rules.html b/templates/webpages/customer_vendor/tabs/price_rules.html
new file mode 100644 (file)
index 0000000..dc87a68
--- /dev/null
@@ -0,0 +1,21 @@
+[%- USE T8 %]
+[%- USE LxERP %]
+[%- USE L %]
+<div id="price_rules">
+  <div id='price_rules_customer_report'></div>
+  <div id='price_rules_vendor_report'></div>
+
+  <script type='text/javascript'>
+    $(function() {
+      window.setTimeout(function(){
+[%- IF SELF.is_customer %]
+        kivi.CustomerVendor.inline_report('#price_rules_customer_report', 'controller.pl', { action: 'PriceRule/list', 'filter.item_type_matches[].customer': [% SELF.cv.id %], type: 'customer', inline: 1 });
+[%- END %]
+[%- IF SELF.is_vendor %]
+        kivi.CustomerVendor.inline_report('#price_rules_vendor_report', 'controller.pl', { action: 'PriceRule/list', 'filter.item_type_matches[].vendor': [% SELF.cv.id %], type: 'vendor', inline: 1 });
+[%- END %]
+      }, 200);
+    })
+  </script>
+</div>
+