net 14
This commit is contained in:
@@ -424,7 +424,7 @@
|
||||
</div>
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-gray-700 mb-1">Terms</label>
|
||||
<input type="text" id="invoice-terms" value="Net 30" required
|
||||
<input type="text" id="invoice-terms" value="Net 14" required
|
||||
class="w-full px-4 py-2 border border-gray-300 rounded-md focus:ring-blue-500 focus:border-blue-500">
|
||||
</div>
|
||||
<div class="flex items-center gap-6 pt-6 w-max">
|
||||
|
||||
@@ -223,7 +223,7 @@ function prepareNewInvoice() {
|
||||
document.getElementById('invoice-modal-title').textContent = 'New Invoice';
|
||||
document.getElementById('invoice-form').reset();
|
||||
document.getElementById('invoice-items').innerHTML = '';
|
||||
document.getElementById('invoice-terms').value = 'Net 30';
|
||||
document.getElementById('invoice-terms').value = 'Net 14';
|
||||
document.getElementById('invoice-number').value = '';
|
||||
document.getElementById('invoice-send-date').value = '';
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@ CREATE TABLE public.invoices (
|
||||
invoice_number character varying(50) DEFAULT NULL::character varying,
|
||||
customer_id integer,
|
||||
invoice_date date NOT NULL,
|
||||
terms character varying(100) DEFAULT 'Net 30'::character varying,
|
||||
terms character varying(100) DEFAULT 'Net 14'::character varying,
|
||||
auth_code character varying(255),
|
||||
tax_exempt boolean DEFAULT false,
|
||||
tax_rate numeric(5,2) DEFAULT 8.25,
|
||||
|
||||
@@ -201,7 +201,7 @@ router.post('/import-unpaid', async (req, res) => {
|
||||
const txnDate = qboInv.TxnDate || new Date().toISOString().split('T')[0];
|
||||
const syncToken = qboInv.SyncToken || '';
|
||||
|
||||
let terms = 'Net 30';
|
||||
let terms = 'Net 14';
|
||||
if (qboInv.SalesTermRef?.name) {
|
||||
terms = qboInv.SalesTermRef.name;
|
||||
}
|
||||
|
||||
@@ -343,7 +343,7 @@ router.post('/:id/convert-to-invoice', async (req, res) => {
|
||||
const invoiceResult = await client.query(
|
||||
`INSERT INTO invoices (invoice_number, customer_id, invoice_date, terms, auth_code, tax_exempt, tax_rate, subtotal, tax_amount, total, created_from_quote_id)
|
||||
VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11) RETURNING *`,
|
||||
[invoice_number, quote.customer_id, invoiceDate, 'Net 30', '', quote.tax_exempt, quote.tax_rate, quote.subtotal, quote.tax_amount, quote.total, id]
|
||||
[invoice_number, quote.customer_id, invoiceDate, 'Net 14', '', quote.tax_exempt, quote.tax_rate, quote.subtotal, quote.tax_amount, quote.total, id]
|
||||
);
|
||||
|
||||
const invoiceId = invoiceResult.rows[0].id;
|
||||
|
||||
Reference in New Issue
Block a user