feat(schema): rename manifestarticle customname to name, add pu, and use taxrate
This commit is contained in:
@@ -32,14 +32,15 @@ export const GET_DELIVERY_LINES = `
|
||||
SELECT
|
||||
ma.id,
|
||||
ma.sku,
|
||||
ma.customname,
|
||||
ma.name,
|
||||
ma.pu,
|
||||
ma.amount,
|
||||
ma.net,
|
||||
ma.rebate,
|
||||
t.rate AS tax,
|
||||
ma.taxrate AS tax,
|
||||
ma.taxrate,
|
||||
ma.comment
|
||||
FROM manifestarticle ma
|
||||
INNER JOIN tax t ON t.id = ma.tax_id
|
||||
WHERE ma.manifest_id = @manifestId
|
||||
ORDER BY ma.id
|
||||
`;
|
||||
@@ -78,22 +79,24 @@ export const CREATE_LINE = `
|
||||
INSERT INTO manifestarticle (
|
||||
manifest_id,
|
||||
sku,
|
||||
customname,
|
||||
name,
|
||||
pu,
|
||||
amount,
|
||||
net,
|
||||
comment,
|
||||
rebate,
|
||||
tax_id
|
||||
taxrate
|
||||
)
|
||||
OUTPUT INSERTED.id
|
||||
VALUES (
|
||||
@manifestId,
|
||||
@sku,
|
||||
@customname,
|
||||
@name,
|
||||
@pu,
|
||||
@amount,
|
||||
@net,
|
||||
@comment,
|
||||
@rebate,
|
||||
@taxId
|
||||
@taxrate
|
||||
)
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user