Revision 44ee7293
Von Cem Aydin vor etwa 3 Jahren hinzugefügt
SL/DB/MetaSetup/BankAccount.pm | ||
---|---|---|
11 | 11 |
__PACKAGE__->meta->columns( |
12 | 12 |
account_number => { type => 'varchar', length => 100 }, |
13 | 13 |
bank => { type => 'text' }, |
14 |
bank_account_id => { type => 'varchar' }, |
|
14 | 15 |
bank_code => { type => 'varchar', length => 100 }, |
15 | 16 |
bic => { type => 'varchar', length => 100 }, |
16 | 17 |
chart_id => { type => 'integer', not_null => 1 }, |
... | ... | |
21 | 22 |
reconciliation_starting_balance => { type => 'numeric', precision => 15, scale => 5 }, |
22 | 23 |
reconciliation_starting_date => { type => 'date' }, |
23 | 24 |
sortkey => { type => 'integer', not_null => 1 }, |
25 |
use_for_qrbill => { type => 'boolean', default => 'false', not_null => 1 }, |
|
24 | 26 |
use_for_zugferd => { type => 'boolean', default => 'false', not_null => 1 }, |
25 | 27 |
); |
26 | 28 |
|
sql/Pg-upgrade2/bank_account_informations_for_swiss_qrbill.sql | ||
---|---|---|
1 |
-- @tag: bank_account_information_for_swiss_qrbill |
|
2 |
-- @description: Bankkonto Informationen für Swiss QR-Bill hinzufügen |
|
3 |
-- @depends: release_3_5_6_1 |
|
4 |
ALTER TABLE bank_accounts ADD COLUMN use_for_qrbill BOOLEAN; |
|
5 |
ALTER TABLE bank_accounts ADD COLUMN bank_account_id VARCHAR; |
|
6 |
|
|
7 |
UPDATE bank_accounts SET use_for_qrbill = ( |
|
8 |
SELECT COUNT(*) |
|
9 |
FROM bank_accounts |
|
10 |
) = 1; |
|
11 |
|
|
12 |
ALTER TABLE bank_accounts |
|
13 |
ALTER COLUMN use_for_qrbill SET DEFAULT FALSE, |
|
14 |
ALTER COLUMN use_for_qrbill SET NOT NULL; |
Auch abrufbar als: Unified diff
Swiss QR-Bill: Datenbankupgrade BankAccount
- Felder bank_account_id und use_for_qrbill hinzugefügt