+
-
-
-
- handleChange(event, 0)"
- :on-exceed="Exceed_ProductImg"
- limit="1" >
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- loadForm(event, 0)">
-
-
-
-
-
-
- loadForm(event, 1)">
-
-
-
-
-
-
-
-
-
-
- 上架
-
-
- 重置
-
-
+
+
+
+
+
+ handleChange(event, 0)" :on-exceed="Exceed_ProductImg"
+ limit="7">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ loadForm(event)" :disabled="typeSelect">
+
+
+
+
+
+
+
+
+
+
+
+ 添加
+
+
+
+
+
+
+ 保存
+
+
+ 重置
+
+
+
+
\ No newline at end of file
+const rules = reactive
>({ //表单校验规则
+ name: [{ validator: validateName, trigger: 'blur' }],
+ intro: [{ validator: validateIntro, trigger: 'blur' }],
+ introDetail: [{ validator: validateDetail, trigger: 'blur' }]
+})
+const addLabel = () => { //添加商品标签按钮的方法
+ if (labelList.value[labelList.value.length - 1] === '') {
+ WarnInfo('请填写完')
+ return;
+ }
+ if (labelList.value.length < 4) {
+ labelList.value.push('')
+ }
+}
+const addLabelList = () => { //格式化商品标签
+ var string = ''
+ if (!labelList.value.some((item: any) => item === '')) {
+ string = labelList.value.join(';')
+ } else return;
+ form.value.label = string
+}
+const customTag = (e:any)=>{ //点击定制
+ if(e) {
+ form.value.inventory = 1
+ invInput.value = true
+ typeSelect.value = true
+ form.value.type = '定制'
+ } else {
+ form.value.inventory = 0
+ invInput.value = false
+ typeSelect.value = false
+ form.value.type = ''
+ }
+}
+
+
+
\ No newline at end of file
diff --git a/src/views/Commodity/MerchandiseCenter.vue b/src/views/Commodity/MerchandiseCenter.vue
index 8ed2a3b..38c5a30 100644
--- a/src/views/Commodity/MerchandiseCenter.vue
+++ b/src/views/Commodity/MerchandiseCenter.vue
@@ -2,20 +2,16 @@
-
-
- searchByType(event)" placeholder="请选择">
-
-
-
-
- searchByState(event)">
+ 搜索
+ searchByType(event)" placeholder="商品类别" style="width: 240px; margin-right: 10px;">
+
+
+ searchByState(event)" style="width: 240px; margin-right: 10px;">
-
- 搜索
重置
@@ -41,12 +37,18 @@
-
![]()
+
-
+
+
+
+ {{ scope.row.price }} 元
+
+
+
@@ -95,10 +97,8 @@
-
-
![商品图标]()
-
handleChange(event, 0)"
:on-exceed="Exceed_ProductImg"
- limit="1" >
+ limit="7" >
@@ -116,8 +116,9 @@
-
-
+
+
+ 元
loadForm(event, 1)">
@@ -175,9 +176,11 @@