Skip to content

Commit

Permalink
Make the var invoice_id global
Browse files Browse the repository at this point in the history
  • Loading branch information
gogdzl committed Jan 19, 2025
1 parent ecf570b commit ae99436
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion projects/plugins/crm/js/ZeroBSCRM.admin.invoicebuilder.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jQuery( function () {
// but DAL3.0 should return the next available ID and reserve it?
// WH - how do we handle the case where YOU and I make a new invoice (same time)
// we fill it in, and the ID is the same - won't we have a race condition here?
const invoice_id = jQuery( '.zbs_invoice_html_canvas' ).data( 'invid' );
window.invoice_id = jQuery( '.zbs_invoice_html_canvas' ).data( 'invid' );

//draw the invoice HTML UI (v2.98) start by drawing the data from the DB (drawing / getting)
zbscrm_JS_retrieve_invoice_data( invoice_id );
Expand Down

0 comments on commit ae99436

Please sign in to comment.