Gives dashback a single store call that atomically replaces all price rows for the article’s poscustomergroup.
12 lines
338 B
JavaScript
12 lines
338 B
JavaScript
export const DELETE_BY_ARTICLE_AND_CUSTOMERGROUP = `
|
|
DELETE FROM price
|
|
WHERE article_id = @articleId
|
|
AND customergroup_id = @customerGroupId
|
|
`;
|
|
|
|
export const CREATE = `
|
|
INSERT INTO price (tax_id, article_id, minmultiplier, customergroup_id, net)
|
|
OUTPUT INSERTED.id
|
|
VALUES (@taxId, @articleId, @minmultiplier, @customerGroupId, @net)
|
|
`;
|