X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/64e2e5110c566354322764918e05c4fbfeb778df..d8be5cc409de5b3bc34439599b1481201a5a1c2e:/sql/Pg-upgrade2-auth/rights_view_docs.sql

diff --git a/sql/Pg-upgrade2-auth/rights_view_docs.sql b/sql/Pg-upgrade2-auth/rights_view_docs.sql
index 9ddb85ecb..2591ada33 100644
--- a/sql/Pg-upgrade2-auth/rights_view_docs.sql
+++ b/sql/Pg-upgrade2-auth/rights_view_docs.sql
@@ -59,12 +59,22 @@ INSERT INTO auth.master_rights (position, name, description, category)
           FALSE);
 
 
+-- INSERT INTO auth.group_rights (group_id, "right", granted)
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_quotation_view',         true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_order_view',             true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_delivery_order_view',    true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_invoice_view',           true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'request_quotation_view',       true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'purchase_order_view',          true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'purchase_delivery_order_view', true UNION
+--    SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'purchase_invoice_view',        true;
+
 INSERT INTO auth.group_rights (group_id, "right", granted)
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_quotation_view',         true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_order_view',             true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_delivery_order_view',    true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'sales_invoice_view',           true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'request_quotation_view',       true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'purchase_order_view',          true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'purchase_delivery_order_view', true UNION
-   SELECT (SELECT id FROM auth.group WHERE name = 'Vollzugriff'), 'purchase_invoice_view',        true;
+   SELECT id, 'sales_quotation_view',         true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'sales_order_view',             true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'sales_delivery_order_view',    true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'sales_invoice_view',           true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'request_quotation_view',       true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'purchase_order_view',          true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'purchase_delivery_order_view', true FROM auth.group WHERE name = 'Vollzugriff' UNION
+   SELECT id, 'purchase_invoice_view',        true FROM auth.group WHERE name = 'Vollzugriff';
