Acq: When creating invoices, let the user know if they're repeating an ID collab/senator/create-inv-ident-warning
authorLebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Mon, 1 Oct 2012 17:53:27 +0000 (13:53 -0400)
committerLebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Mon, 1 Oct 2012 17:53:27 +0000 (13:53 -0400)
commitad4eca3f04cad3f53a9872e194c7813771476ee3
treefd2fdc323fa442bc2564971f6de5666318128544
parent2506f44116762d102e02bc190b55d7e82d56c6da
Acq: When creating invoices, let the user know if they're repeating an ID

Invoices have a field for Vendor Invoice ID, which is required to be
unique for invoices associated with a given provider (vendor).  In
practice users may mistakenly try to create an invoice more than once, so
this gives them an indication that a given Vnedor Invoice ID has already
been used before they fill out the whole invoice.

Users do have to have the fields labeled "Vendor Invoice ID",
"Provider", and "Receiver" filled out before validation can occur (the
last field is needed because of how permissions are checked when
searching for invoices).

It is still possible to see a database error at save time if another
invoice is created between the time you started yours and the time
somebody else saved theirs.

Also, while we're at it, this commit gets rid of acq/invoice/common.js
and moves its last function into acq/invoice/view.js, since both are
actually used only by the one interface.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Open-ILS/src/templates/acq/invoice/view.tt2
Open-ILS/web/js/dojo/openils/acq/nls/acq.js
Open-ILS/web/js/dojo/openils/widget/EditPane.js
Open-ILS/web/js/ui/default/acq/invoice/common.js [deleted file]
Open-ILS/web/js/ui/default/acq/invoice/view.js