From d4bf53dd19a45ef09a367babcf7a2ac04ae1d08f Mon Sep 17 00:00:00 2001
From: liujiandao <274878379@qq.com>
Date: 星期二, 17 十月 2023 14:31:31 +0800
Subject: [PATCH] bug修改

---
 api/v1/salesReturn.go |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/api/v1/salesReturn.go b/api/v1/salesReturn.go
index f53260f..bf1fdbd 100644
--- a/api/v1/salesReturn.go
+++ b/api/v1/salesReturn.go
@@ -37,6 +37,13 @@
 		return
 	}
 
+	if salesReturn.MemberId == 0 {
+		userInfo := utils.GetUserInfo(c)
+		if userInfo.UserType == constvar.UserTypeSub {
+			salesReturn.MemberId = userInfo.CrmUserId
+		}
+	}
+
 	errCode = salesReturnService.AddSalesReturn(&salesReturn)
 	if errCode != ecode.OK {
 		ctx.Fail(errCode)

--
Gitblit v1.8.0