This commit is contained in:
seb
2026-07-31 15:36:48 +02:00
parent 818d799f63
commit 6cc6dbb9e8
13 changed files with 1096 additions and 998 deletions

View File

@@ -31,7 +31,7 @@ LEFT JOIN pic p ON p.id = first_pic.pic_id
ORDER BY t.sort, t.id
`;
export const GET_ROOT_CATEGORY_ARTICLES = `
export const GET_CATEGORY_ARTICLES = `
SELECT
a.id,
a.sku,
@@ -79,7 +79,7 @@ OUTER APPLY (
ORDER BY ap.sort ASC, ap.id ASC
) first_pic
LEFT JOIN pic ON pic.id = first_pic.pic_id
WHERE ca.category_id = @rootCategoryId
WHERE ca.category_id = @categoryId
ORDER BY a.id
`;
@@ -111,6 +111,7 @@ SELECT
r.rootCategoryId,
co.id AS companyId,
co.default_language_id AS languageId,
co.poscustomergroup_id AS posCustomerGroupId,
cu.id AS companyuserId
FROM category p
LEFT JOIN root r ON 1 = 1