diff --git a/hsarback/database/data.sql b/hsarback/database/data.sql index 87008c1..dad7f9e 100644 --- a/hsarback/database/data.sql +++ b/hsarback/database/data.sql @@ -90,8 +90,9 @@ INSERT INTO contact (bp_id, salut, first_name, last_name, firma, email) -- table: bank_account -- INSERT INTO bank_account (bp_id, autodebit_ga, autodebit_ar, autodebit_op, - bank_customer, bank_account, bank_code, bank_name) - SELECT bp_id, false, false, false, '', '', '', '' FROM business_partner WHERE member_id=10000; + bank_customer, bank_account, bank_code, bank_name, mandat_ref, mandat_signed, mandat_since) + SELECT bp_id, false, false, false, '', '', '', '', member_id, current_date, current_date + FROM business_partner WHERE member_id=10000; -- -- Table: inet_addr diff --git a/hsarback/database/schema.sql b/hsarback/database/schema.sql index 3f0a4f5..b4a4d19 100644 --- a/hsarback/database/schema.sql +++ b/hsarback/database/schema.sql @@ -14,7 +14,11 @@ CREATE TABLE bank_account ( bank_name character varying(50), bank_iban character varying(30), bank_bic character varying(15), - mandat_ref character varying(10) + mandat_ref character varying(10) NOT NULL, + mandat_signed date, + mandat_since date, + mandat_until date, + mandat_used date ); @@ -169,6 +173,8 @@ CREATE TABLE contact ( phone_mobile character varying(30), fax character varying(30), email character varying(100) NOT NULL, + business_contact boolean DEFAULT TRUE, + technical_contact boolean DEFAULT TRUE, CONSTRAINT ckc_email_contact CHECK (((email)::text ~~ '%@%.%'::text)) );