Commit f90ac9c6 authored by zhanglw's avatar zhanglw

ds

parent c2b9f592
......@@ -20,6 +20,15 @@ export const HttpReq = {
method: 'get'
})
},
updateIfUp: function(data) {
return request({
url: 'apps/updateIfUp',
method: 'post',
data: data
}).then((res) => {
return res
})
},
api: null
},
// web端接口列表
......
......@@ -25,8 +25,8 @@
</div>
<div class="toolbar">
<div>
<el-button type="danger" icon="el-icon-download" :disabled="!multipleSelection.length" @click="batchOperate(0, null)">下架</el-button>
<el-button type="success" icon="el-icon-finished" :disabled="!multipleSelection.length" @click="batchOperate(1, null)">上架</el-button>
<el-button type="danger" icon="el-icon-download" :disabled="!multipleSelection.length" @click="batchOperate(1, null)">下架</el-button>
<el-button type="success" icon="el-icon-finished" :disabled="!multipleSelection.length" @click="batchOperate(0, null)">上架</el-button>
</div>
<div style="text-align: right">
<el-button type="primary" icon="el-icon-upload2" @click="toAdd">上传app</el-button>
......@@ -52,8 +52,8 @@
<el-table-column prop="uploadtime" label="最后维护日期" align="center" width="180" />
<el-table-column label="操作" align="center" width="200">
<template slot-scope="scope">
<el-tooltip content="下架"><el-button round plain type="danger" icon="el-icon-download" @click="batchOperate(0, scope.row)" /></el-tooltip>
<el-tooltip content="上架"><el-button round plain type="success" icon="el-icon-finished" @click="batchOperate(1, scope.row)" /></el-tooltip>
<el-tooltip content="下架"><el-button round plain type="danger" icon="el-icon-download" @click="batchOperate(1, scope.row)" /></el-tooltip>
<el-tooltip content="上架"><el-button round plain type="success" icon="el-icon-finished" @click="batchOperate(0, scope.row)" /></el-tooltip>
</template>
</el-table-column>
</el-table>
......@@ -118,12 +118,12 @@ export default {
type: 'info'
})
}
HttpReq.backstageApi.batchReleaseAndRecovery({
ids: row ? [row.productId] : this.multipleSelection.map(item => { return item.productId }),
type: type
HttpReq.backstageApi.updateIfUp({
ids: row ? [row.id] : this.multipleSelection.map(item => { return item.id }),
ifUp: type
}).then((res) => {
this.$notify({
title: res.msg,
title: res.message,
type: res.code === 200 ? 'success' : 'error',
duration: 2500
})
......
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