From b23188df0c4343d51cbc777121d4a138c5a5a1f4 Mon Sep 17 00:00:00 2001
From: yangfeng <wanwan926_4@163.com>
Date: 星期三, 08 十一月 2023 09:49:29 +0800
Subject: [PATCH] 增加显示用户名及退出优化
---
src/views/productManage/product/AddProductDialog.vue | 58 +++++++++++++++++++++++++++++++++++++++++++++-------------
1 files changed, 45 insertions(+), 13 deletions(-)
diff --git a/src/views/productManage/product/AddProductDialog.vue b/src/views/productManage/product/AddProductDialog.vue
index e24ecd2..5c63af6 100644
--- a/src/views/productManage/product/AddProductDialog.vue
+++ b/src/views/productManage/product/AddProductDialog.vue
@@ -43,6 +43,8 @@
:show-procure="showProcure"
:countObject="statisticsMap"
:show-sale="showSale"
+ @listingRulesClick="listingRulesClick"
+ @reorderRulesClick="reorderRulesClick"
/>
<div class="bottom">
<el-tabs v-model="activeName" type="card">
@@ -558,22 +560,24 @@
/**
* 闈炲繀濉」鍚庣杩斿洖鐨勬槸鏁板瓧 0,琛ㄥ崟闇�瑕佺┖涓叉墠鑳借涓烘湭閫夋嫨鍥炴樉
*/
- setOptionalFieldsToEmpty(){
- ['productType','categoryId']
- .filter(filed => this.editConfig.infomation[filed] === 0)
- .forEach(filed => {
- this.editConfig.infomation[filed] = ''
- })
+ setOptionalFieldsToEmpty() {
+ let arr = ["productType", "categoryId"]
+ arr
+ .filter((filed) => this.editConfig.infomation[filed] === 0)
+ .forEach((filed) => {
+ this.editConfig.infomation[filed] = ""
+ })
},
/**
* 鍚庣鍙帴鍙楁暟瀛楀舰寮�, 淇濆瓨鏃惰繕寰楀啀杞洖鍘�
*/
- unsetFieldsToNumber(){
- ['productType','categoryId']
- .filter(filed => this.editConfig.infomation[filed] === '')
- .forEach(filed => {
- this.editConfig.infomation[filed] = 0
- })
+ unsetFieldsToNumber() {
+ let arr = ["productType", "categoryId"]
+ arr
+ .filter((filed) => this.editConfig.infomation[filed] === "")
+ .forEach((filed) => {
+ this.editConfig.infomation[filed] = 0
+ })
},
// 鑾峰彇浜у搧绫诲埆
async getProductCategoryList() {
@@ -645,7 +649,7 @@
this.$message.success("娣诲姞鎴愬姛")
this.$parent.getData()
}
- },console.error)
+ }, console.error)
}
})
},
@@ -779,6 +783,34 @@
})
}
},
+ // 涓婃灦瑙勫垯
+ listingRulesClick() {
+ this.$refs.form.validate((valid) => {
+ if (valid) {
+ this.$router.push({
+ path: "/warehouseManage/listingRules",
+ query: {
+ productName: this.editConfig.infomation.name,
+ productId: this.editConfig.title === "鏂板缓" ? "" : this.editConfig.infomation.id
+ }
+ })
+ }
+ })
+ },
+ // 閲嶈璐鍒�
+ reorderRulesClick() {
+ this.$refs.form.validate((valid) => {
+ if (valid) {
+ this.$router.push({
+ path: "/productManage/reorderRules",
+ query: {
+ productName: this.editConfig.infomation.name,
+ productId: this.editConfig.title === "鏂板缓" ? "" : this.editConfig.infomation.id
+ }
+ })
+ }
+ })
+ },
// 鍙攢鍞�/鍙噰璐�
checkboxChange(val, param) {
if (val === "閲囪喘") {
--
Gitblit v1.8.0