Commit 971e1f30 by cpa

商品审核通过

parent 9f74555d
...@@ -161,9 +161,7 @@ ...@@ -161,9 +161,7 @@
this.$message.error('请选择项进行上架') this.$message.error('请选择项进行上架')
return return
} }
let a = d.map(r => { return r.stateName }).join(',') let a = d.map(r => { return r.stateName }).join(',')
if(a.search('平台下架') != -1){ if(a.search('平台下架') != -1){
this.$message.error('平台下架商品,无法操作') this.$message.error('平台下架商品,无法操作')
return; return;
...@@ -197,25 +195,36 @@ ...@@ -197,25 +195,36 @@
if(a.search('平台下架') != -1){ if(a.search('平台下架') != -1){
this.$message.error('只能下架,上架商品') this.$message.error('只能下架,上架商品')
return; return;
}else if(a.search('有效') != -1){ }else if(a.search('下架') != -1){
this.$message.error('只能下架,上架商品') this.$message.error('商品已经下架')
return;
}else if(a.search('') != -1){
this.$message.error('只能下架,上架商品')
return; return;
} else if(a.search('审核中') != -1){
let ids = d.map(r => { return r.id }).join(',')
this.$confirm('商品正在审核,是否确认下架', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'error'
}).then(function () {
return isNotUpon({ids: ids})
}).then(data => {
this.$message.success('下架成功')
this.getList(this.page)
})
}else {
let ids = d.map(r => { return r.id }).join(',')
this.$confirm('请确认是否下架已勾选的商品', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(function () {
return isNotUpon({ids: ids})
}).then(data => {
this.$message.success('下架成功')
this.getList(this.page)
})
} }
let ids = d.map(r => { return r.id }).join(',')
this.$confirm('请确认是否下架已勾选的商品', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(function () {
return isNotUpon({ids: ids})
}).then(data => {
this.$message.success('下架成功')
this.getList(this.page)
})
}, },
// 批量删除 // 批量删除
handleDelBatch() { handleDelBatch() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment