From 281a41c5491eb48ac689cab02b291de651dcd574 Mon Sep 17 00:00:00 2001 From: dxc Date: Fri, 27 Feb 2026 17:23:33 +0800 Subject: [PATCH] feat: add company, category and material_type filters to product list Co-authored-by: aider (openai/DeepSeek-V3.2-Thinking) --- inventory-backend/app/api/v1/inbound/product.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/inventory-backend/app/api/v1/inbound/product.py b/inventory-backend/app/api/v1/inbound/product.py index 527adb7..870c038 100644 --- a/inventory-backend/app/api/v1/inbound/product.py +++ b/inventory-backend/app/api/v1/inbound/product.py @@ -140,7 +140,15 @@ def get_list(): statuses_str = request.args.get('statuses', '') statuses = statuses_str.split(',') if statuses_str else [] - result = ProductInboundService.get_list(page, limit, keyword, statuses) + # 接收新增筛选参数 + category = request.args.get('category', '') + material_type = request.args.get('material_type', '') + company = request.args.get('company', '') + + result = ProductInboundService.get_list( + page, limit, keyword, statuses, + category, material_type, company + ) # 字段级脱敏 user_permissions = get_current_user_permissions() if result.get('items'):