From 7d9e94796fb4e4b76ae739088dc15c858272a90a Mon Sep 17 00:00:00 2001 From: einhverfr Date: Fri, 9 May 2008 17:49:14 +0000 Subject: Correcting issues saving/retriving tax id for vendors/customers, and retrieving the cash id. git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@2130 4979c152-3d1c-0410-bac9-87ea11338e46 --- sql/modules/Company.sql | 3 ++- sql/modules/Roles.sql | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'sql') diff --git a/sql/modules/Company.sql b/sql/modules/Company.sql index faffe92e..d935317d 100644 --- a/sql/modules/Company.sql +++ b/sql/modules/Company.sql @@ -144,6 +144,7 @@ CREATE TYPE entity_credit_search_return AS ( enddate date, ar_ap_account_id int, cash_account_id int, + tax_id text, threshold numeric ); @@ -161,7 +162,7 @@ BEGIN ec.taxincluded, ec.creditlimit, ec.terms, ec.meta_number, ec.business_id, ec.language_code, ec.pricegroup_id, ec.curr::char(3), ec.startdate, ec.enddate, ec.ar_ap_account_id, - ec.cash_account_id, ec.threshold + ec.cash_account_id, c.tax_id, ec.threshold INTO out_row FROM company c JOIN entity e ON (c.entity_id = e.id) diff --git a/sql/modules/Roles.sql b/sql/modules/Roles.sql index e8ae3bb4..b91298f1 100644 --- a/sql/modules/Roles.sql +++ b/sql/modules/Roles.sql @@ -577,6 +577,7 @@ IN ROLE "lsmb___list_ap_transactions"; GRANT INSERT ON acc_trans TO "lsmb___process_payment"; GRANT ALL ON acc_trans_entry_id_seq TO "lsmb___process_payment"; +GRANT UPDATE ON ap TO "lsmb___process_payment"; INSERT INTO menu_acl (node_id, acl_type, role_name) @@ -591,6 +592,7 @@ IN ROLE "lsmb___list_ar_transactions"; GRANT INSERT ON acc_trans TO "lsmb___process_receipt"; GRANT ALL ON acc_trans_entry_id_seq TO "lsmb___process_receipt"; +GRANT UPDATE ON ar TO "lsmb___process_receipt"; INSERT INTO menu_acl (node_id, acl_type, role_name) values (35, 'allow', 'lsmb___process_receipt'); -- cgit v1.2.3