From 1444c7c800fc042cd99213e901d6ad3722d0f03f Mon Sep 17 00:00:00 2001
From: jiangshuai <291802688@qq.com>
Date: 星期三, 27 九月 2023 16:13:53 +0800
Subject: [PATCH] 1.二期一部分代码

---
 router/router.go |   28 +++++++++++++++++++++++++++-
 1 files changed, 27 insertions(+), 1 deletions(-)

diff --git a/router/router.go b/router/router.go
index ac257be..bac5f16 100644
--- a/router/router.go
+++ b/router/router.go
@@ -77,11 +77,13 @@
 	operationController := new(controllers.OperationController)
 	operationAPI := r.Group(urlPrefix + "/operation")
 	{
-		operationAPI.GET("operation", operationController.List)
+		operationAPI.POST("list", operationController.List)
 		operationAPI.POST("operation", operationController.Add)
 		operationAPI.POST("update", operationController.Update)
 		operationAPI.DELETE("operation/:id", operationController.Delete)
 		operationAPI.PUT("finish/:id", operationController.Finish)
+		operationAPI.POST("listAll", operationController.ListAll)
+
 	}
 
 	//浜у搧
@@ -99,6 +101,30 @@
 		productAPI.GET("getProductCategoryDetails/:id", productController.GetProductCategoryDetails) //鑾峰彇浜у搧绫诲瀷璇︽儏
 		productAPI.POST("updateProductCategory", productController.UpdateProductCategory)            //淇敼浜у搧绫诲瀷
 		productAPI.DELETE("deleteProductCategory/:id", productController.DeleteProductCategory)      //鍒犻櫎浜у搧绫诲瀷
+
+		productAPI.POST("listOperaton", productController.ListOperation)   //鏌ョ湅浜у搧鐨勫巻鍙插嚭鍏ュ簱淇℃伅
+		productAPI.POST("addDisuse", productController.AddDisuse)          //娣诲姞鎶ュ簾淇℃伅
+		productAPI.POST("listDisuse", productController.ListDisuse)        //鏌ョ湅浜у搧鐨勫巻鍙插嚭鍏ュ簱淇℃伅
+		productAPI.PUT("finishDisuse/:id", productController.FinishDisuse) //鎶ュ簾楠岃瘉
+		productAPI.POST("updateDisuse", productController.UpdateDisuse)    //淇敼鎶ュ簾淇℃伅
+	}
+
+	// 涓婃灦瑙勫垯
+	locationProductController := new(controllers.LocationProductController)
+	locationProductAPI := r.Group(urlPrefix + "/locationProduct")
+	{
+		locationProductAPI.POST("list", locationProductController.List)           // 鑾峰彇涓婃灦瑙勫垯鍒楄〃
+		locationProductAPI.POST("add", locationProductController.Add)             // 鏂板涓婃灦瑙勫垯
+		locationProductAPI.POST("update", locationProductController.Update)       // 淇敼涓婃灦瑙勫垯
+		locationProductAPI.DELETE("delete/:id", locationProductController.Delete) // 鍒犻櫎涓婃灦瑙勫垯
+	}
+
+	//搴撳瓨鐩樼偣
+	locationProductAmountController := new(controllers.LocationProductAmountController)
+	locationProductAmountAPI := r.Group(urlPrefix + "/locationProductAmount")
+	{
+		locationProductAmountAPI.POST("add", locationProductAmountController.Add)   //娣诲姞搴撳瓨鐩樼偣淇℃伅
+		locationProductAmountAPI.POST("list", locationProductAmountController.List) //鏌ョ湅搴撳瓨鐩樼偣鍒楄〃
 	}
 
 	return r

--
Gitblit v1.8.0