Rechte zum Bearbeiten von Preisen in Belgen getrennt nach VK/EK anwenden
[kivitendo-erp.git] / templates / webpages / order / tabs / _price_sources_dialog.html
index be05c62..772d9d5 100644 (file)
@@ -4,7 +4,13 @@
 [%- USE LxERP %]
 [% SET best_price = price_source.best_price %]
 [% SET best_discount = price_source.best_discount %]
-[% SET price_editable = AUTH.assert('edit_prices', 1) %]
+[% SET price_editable = 0 %]
+[% IF (FORM.type == "sales_order" || FORM.type == "sales_quotation") %]
+  [% SET price_editable = AUTH.assert('sales_edit_prices', 1) %]
+[% END %]
+[% IF (FORM.type == "purchase_order" || FORM.type == "request_quotation") %]
+  [% SET price_editable = AUTH.assert('purchase_edit_prices', 1) %]
+[% END %]
   <h2>[% 'Prices' | $T8 %]</h2>
 
   <table>