From c0f8f8d3a74dbdab4f6ab4926fc664d818fb50f2 Mon Sep 17 00:00:00 2001
From: liujiandao <274878379@qq.com>
Date: 星期四, 25 四月 2024 16:59:22 +0800
Subject: [PATCH] 获取供应商产品

---
 api/v1/test/supplier.go |   31 +++++++++++++++++++++++++++++++
 1 files changed, 31 insertions(+), 0 deletions(-)

diff --git a/api/v1/test/supplier.go b/api/v1/test/supplier.go
index 674d309..6a2b489 100644
--- a/api/v1/test/supplier.go
+++ b/api/v1/test/supplier.go
@@ -226,3 +226,34 @@
 		response.OkWithMessage("淇敼鎴愬姛", c)
 	}
 }
+
+// GetSupplierProductList 鑾峰彇渚涘簲鍟嗘彁渚涗骇鍝佸垪琛�
+// @Tags Supplier
+// @Summary 鑾峰彇渚涘簲鍟嗘彁渚涗骇鍝佸垪琛�
+// @Security ApiKeyAuth
+// @accept application/json
+// @Produce application/json
+// @Param data query testReq.SupplierProduct true "鑾峰彇渚涘簲鍟嗘彁渚涗骇鍝佸垪琛�"
+// @Param Authorization	header string true "token"
+// @Success 200 {string} string "{"success":true,"data":{},"msg":"鑾峰彇鎴愬姛"}"
+// @Router /s/getSupplierProductList [get]
+func (sApi *SupplierApi) GetSupplierProductList(c *gin.Context) {
+	var params testReq.SupplierProduct
+	err := c.ShouldBindQuery(&params)
+	if err != nil {
+		response.FailWithMessage(err.Error(), c)
+		return
+	}
+	list, total, err := sService.GetSupplierProduct(params)
+	if err != nil {
+		global.GVA_LOG.Error("鑾峰彇澶辫触!", zap.Error(err))
+		response.FailWithMessage("鑾峰彇澶辫触", c)
+		return
+	}
+	response.OkWithDetailed(response.PageResult{
+		List:     list,
+		Total:    total,
+		Page:     params.Page,
+		PageSize: params.PageSize,
+	}, "鑾峰彇鎴愬姛", c)
+}

--
Gitblit v1.8.0