From 1572f45e72cc0fa15c029f9ee2a08474104435e6 Mon Sep 17 00:00:00 2001
From: selfcheer <selfcheer@gmail.com>
Date: 星期五, 19 七月 2024 00:48:43 +0800
Subject: [PATCH] 采购单产品列表去掉过滤重复产品的逻辑

---
 api/v1/test/industry.go |   17 ++++++++---------
 1 files changed, 8 insertions(+), 9 deletions(-)

diff --git a/api/v1/test/industry.go b/api/v1/test/industry.go
index 871e889..47caef3 100644
--- a/api/v1/test/industry.go
+++ b/api/v1/test/industry.go
@@ -1,14 +1,14 @@
 package test
 
 import (
-	"github.com/flipped-aurora/gin-vue-admin/server/global"
-	"github.com/flipped-aurora/gin-vue-admin/server/model/common/request"
-	"github.com/flipped-aurora/gin-vue-admin/server/model/common/response"
-	"github.com/flipped-aurora/gin-vue-admin/server/model/test"
-	testReq "github.com/flipped-aurora/gin-vue-admin/server/model/test/request"
-	"github.com/flipped-aurora/gin-vue-admin/server/service"
 	"github.com/gin-gonic/gin"
 	"go.uber.org/zap"
+	"srm/global"
+	"srm/model/common/request"
+	"srm/model/common/response"
+	"srm/model/test"
+	testReq "srm/model/test/request"
+	"srm/service"
 )
 
 type IndustryApi struct {
@@ -116,12 +116,11 @@
 		if err := iService.CreateIndustry(&industry); err != nil {
 			global.GVA_LOG.Error("鏇存柊澶辫触!", zap.Error(err))
 			response.FailWithMessage("淇濆瓨澶辫触", c)
+			return
 		}
 	}
 
-	if err == nil {
-		response.OkWithMessage("鏇存柊鎴愬姛", c)
-	}
+	response.OkWithMessage("鏇存柊鎴愬姛", c)
 }
 
 // FindIndustry 鐢╥d鏌ヨIndustry

--
Gitblit v1.8.0