They are mostly the same as invoices, but the contact and payment method are optional, thus, like other optionals fields, i created relations to link these that have payment method or contact, to avoid NULL columns in quote. Still missing functions to add and edit quotations, and views to compute their tax and total amount.
22 lines
489 B
PL/PgSQL
22 lines
489 B
PL/PgSQL
-- Deploy numerus:quote_status_i18n to pg
|
|
-- requires: roles
|
|
-- requires: schema_numerus
|
|
-- requires: quote_status
|
|
-- requires: language
|
|
|
|
begin;
|
|
|
|
set search_path to numerus, public;
|
|
|
|
create table quote_status_i18n (
|
|
quote_status text not null references quote_status,
|
|
lang_tag text not null references language,
|
|
name text not null,
|
|
primary key (quote_status, lang_tag)
|
|
);
|
|
|
|
grant select on table quote_status_i18n to invoicer;
|
|
grant select on table quote_status_i18n to admin;
|
|
|
|
commit;
|