From 29237e8dd94c4d3cdfb0eb48bca0de7dc68d768e Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期四, 05 十一月 2026 11:27:55 +0800
Subject: [PATCH] feat(mes): 出货检验单客户改为选填,未关联客户的单据不受客户数据权限限制
---
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/imports/MesQcImportHelper.java | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/imports/MesQcImportHelper.java b/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/imports/MesQcImportHelper.java
index c73f087..1b1396a 100644
--- a/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/imports/MesQcImportHelper.java
+++ b/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/imports/MesQcImportHelper.java
@@ -174,11 +174,11 @@
}
/**
- * 瑙f瀽瀹㈡埛缂栧彿锛屽熀浜庡鎴峰悕绉�
+ * 瑙f瀽瀹㈡埛缂栧彿锛屽熀浜庡鎴峰悕绉帮紙閫夊~锛氬鎴峰悕绉扮暀绌烘椂杩斿洖 null锛岃〃绀鸿妫�楠屽崟涓嶅叧鑱斿鎴凤級
*/
public Long resolveClientId(String clientName) {
if (StrUtil.isBlank(clientName)) {
- throw new IllegalArgumentException("瀹㈡埛鍚嶇О涓嶈兘涓虹┖锛氳濉啓妯℃澘涓琛岀殑銆屽鎴峰悕绉般�嶅垪");
+ return null;
}
if (customerNameMap == null) {
customerNameMap = new HashMap<>();
@@ -205,6 +205,10 @@
* 鍑鸿揣妫�楠屽崟鍒楄〃鎸夊鎴锋暟鎹潈闄愯繃婊わ紝鏉冮檺澶栫殑瀹㈡埛瀵煎叆鍚庢湰浜哄湪鍒楄〃涓湅涓嶅埌璇ュ崟鎹紝鍥犳鎻愬墠鎷︽埅銆�
*/
public void validateClientPermission(Long clientId, String clientName) {
+ // 瀹㈡埛閫夊~锛氭湭濉啓瀹㈡埛鐨勬楠屽崟涓嶅睘浜庝换浣曞鎴凤紝涓嶅彈瀹㈡埛鏁版嵁鏉冮檺闄愬埗
+ if (clientId == null) {
+ return;
+ }
if (!clientPermissionLoaded) {
List<Long> permittedIds = crmCustomerApi.getPermittedCustomerIds();
permittedClientIds = permittedIds == null ? null : new HashSet<>(permittedIds);
--
Gitblit v1.9.3