From a8219a1c955a9bb84300a52944ab886c604a4512 Mon Sep 17 00:00:00 2001
From: Administrator <15274802129@163.com>
Date: Sun, 14 Jun 2026 16:54:52 +0800
Subject: [PATCH] fix(security): 修复CORS配置中的安全漏洞
---
src/main/resources/templates/febs/views/modules/goods/goodsAddNew.html | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/main/resources/templates/febs/views/modules/goods/goodsAddNew.html b/src/main/resources/templates/febs/views/modules/goods/goodsAddNew.html
index a258d79..9183f84 100644
--- a/src/main/resources/templates/febs/views/modules/goods/goodsAddNew.html
+++ b/src/main/resources/templates/febs/views/modules/goods/goodsAddNew.html
@@ -789,8 +789,8 @@
form.on('submit(goods-add-form-submit)', function (data) {
data.field.goodsType = 1;
- let couponRuleList = couponRule.getValue();
- if (couponRuleList.length > 0) {
+ let couponRuleList = couponRule.getValue ? couponRule.getValue() : [];
+ if (couponRuleList && couponRuleList.length > 0) {
var couponIds = [];
layui.each(couponRuleList, function (key, item) {
couponIds.push(item.id)
@@ -799,7 +799,8 @@
}
data.field.addMallGoodsSkuDtos = tableSkuData;
data.field.categoryId = category.getValue('valueStr');
- data.field.carriageRuleId = carriageRule.getValue('valueStr');
+ var carriageRuleId = carriageRule.getValue ? carriageRule.getValue('valueStr') : '';
+ data.field.carriageRuleId = carriageRuleId;
// let content = layedit.getContent();
// alert(content);
// data.field.goodsDetails = content;
--
Gitblit v1.9.1