Commit ada48f20 authored by denghr's avatar denghr

删除的el-popover改成$confirm

parent 3864ff2e
......@@ -72,18 +72,7 @@
<template scope="scope">
<el-button size="small" type="primary" @click="compileAppUpload(scope.row)">编辑
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteApp(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" size="small" @click="deleteApp(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -419,7 +408,12 @@
},
deleteApp(row){
console.log(JSON.stringify(row))
removeAppVersion(row.id).then(res=>{
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
removeAppVersion(row.id).then(res=>{
if (res.rel) {
this.$notify.success({
title: '删除成功',
......@@ -433,6 +427,7 @@
}
this.getList()
})
})
},
handleRemove(file, fileList) {
console.log(file, fileList);
......
......@@ -55,18 +55,7 @@
<el-button size="small" type="primary" @click="handleUpdate(scope.row)">编辑</el-button>
<el-button size="small" type="success" @click="handleDown(scope.row)" style="margin-left:0px" v-show="scope.row.status==1">下架</el-button>
<el-button size="small" type="success" @click="handleUp(scope.row)" style="margin-left:0px" v-show="scope.row.status==2">上架</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5 v-show="scope.row.status==2">删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)" style="margin-left:0px" v-show="scope.row.status==2">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -538,24 +527,30 @@
* 操作-删除
* */
deleteHandler(row) {
delObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
}
}
......
......@@ -55,18 +55,7 @@
<el-button size="small" type="primary" @click="handleUpdate(scope.row)">编辑</el-button>
<el-button size="small" type="success" @click="handleDown(scope.row)" style="margin-left:0px" v-show="scope.row.status==1">下架</el-button>
<el-button size="small" type="success" @click="handleUp(scope.row)" style="margin-left:0px" v-show="scope.row.status==2">上架</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5 v-show="scope.row.status==2">删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)" style="margin-left:0px" v-show="scope.row.status==2">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -508,24 +497,31 @@
* 操作-删除
* */
deleteHandler(row) {
delObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
}
}
......
......@@ -41,18 +41,7 @@
<template scope="scope">
<el-button size="small" type="success" @click="handleUpdate(scope.row)">编辑
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -377,24 +366,30 @@
* 操作-删除
* */
deleteHandler(row) {
delBanner(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delBanner(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
getUrl(drivingLicensePath) {
return process.env.BASE_API +
......
......@@ -25,19 +25,7 @@
<template scope="scope">
<el-button size="small" type="success" @click="handleUpdate(scope.row)">编辑
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" v-if="scope.row.type!=88" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" v-if="scope.row.type!=88" size="small" @click="deleteHandler(scope.row)">删除</el-button>
<!--<el-button size="small" type="danger" @click="deleteHandler(scope.row)">删除-->
<!--</el-button>-->
</template>
......@@ -291,24 +279,30 @@
* 操作-删除
* */
deleteHandler(row) {
delGeneral(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delGeneral(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
}
});
})
},
/**
......
......@@ -32,18 +32,7 @@
<template scope="scope">
<el-button size="small" type="success" @click="handleUpdate(scope.row)">编辑
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -299,24 +288,30 @@
* 删除
* */
deleteHandler(row) {
delCampsiteTag(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delCampsiteTag(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
}
});
})
},
/**
* 编辑营地类别
......
......@@ -70,18 +70,7 @@
</el-button>
<el-button size="small" type="warn" v-if="scope.row.saleState==1 && campsiteshop_btn_update_salestatus" @click="upStatus(scope.row)">下架
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5 v-if="campsiteshop_btn_del">删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)" v-if="campsiteshop_btn_del">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -195,25 +184,31 @@ import {
* 操作-删除
* */
deleteHandler(row) {
delCampsiteShop(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.oneCampsiteDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delCampsiteShop(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.oneCampsiteDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
/**
* 上架、下架 参数 id status 1-上架;2-下架 post
......
......@@ -81,18 +81,7 @@
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel">取 消</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler()">确定</el-button>
</div>
</el-popover>
<el-button v-if="form.showTitle == '途径地编辑'" type="danger" v-popover:popover5>删除</el-button>
<el-button v-if="form.showTitle == '途径地编辑'" type="danger" @click="deleteHandler()">删除</el-button>
<el-button type="primary" @click="okHandler('form')">确 定</el-button>
</div>
</el-dialog>
......@@ -268,8 +257,14 @@
* */
deleteHandler(formName) {
// 删除
this.form.method = 'delete';
this.$emit(this.form.eventName, this.form);
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.form.method = 'delete';
this.$emit(this.form.eventName, this.form);
})
},
querySearch(queryString, cb) {
let selectArry = [];
......
......@@ -64,18 +64,7 @@
<el-table-column align="center" label="操作" fixed="right">
<template scope="scope">
<el-button size="small" type="primary" @click="handleUpdate(scope.row)">编辑</el-button>
<el-popover
ref="popover1"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover1>删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -501,17 +490,23 @@
that.editDialogVisible = true;
},
deleteHandler(row){
delObj(row.id).then(() => {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delObj(row.id).then(() => {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
row.visible2 = false;
const index = this.list.indexOf(row);
this.list.splice(index, 1);
});
row.visible2 = false;
const index = this.list.indexOf(row);
this.list.splice(index, 1);
});
})
},
/**
* 创建
......
......@@ -66,11 +66,13 @@
<div style="margin: 20px 0;"><span style="font-size: 18px;font-weight: bold;">出游人信息 成人{{form.orderTourDetail.adultNum}}人 儿童{{form.orderTourDetail.childNum}}</span></div>
<table class="orderDetail">
<tr><th>姓名</th><th>电话</th><th>身份证号</th></tr>
<tr v-for="(item,index) in form.orderTourDetail.userVoList " :key="index">
<td>{{item.realname}}</td>
<td>{{item.username}}</td>
<td>{{item.idNumber}}</td>
</tr>
<template v-if="form.orderTourDetail.userVoList.length>0">
<tr v-for="(item,index) in form.orderTourDetail.userVoList " :key="index">
<td>{{item.realname}}</td>
<td>{{item.username}}</td>
<td>{{item.idNumber}}</td>
</tr>
</template>
</table>
</div>
</el-form>
......@@ -201,7 +203,8 @@
this.costDetail = JSON.parse(a.orderTourDetail.costDetail)
var cost = '';
this.costDetail.children.forEach(function(a1) {
cost += a1.key + ":" +a1.detail+" "
var detail = a1.detail==undefined?'':a1.detail
cost += a1.key + ":" +detail+" "
})
if (this.form.status == 2) {
this.form.ststusName = '取消';
......
......@@ -426,7 +426,8 @@
this.costDetail = JSON.parse(this.form.orderRentVehicleDetail.costDetail)
var cost = '';
this.costDetail.children.forEach(function(a) {
cost += a.key + ":" +a.detail+" "
var detail = a.detail==undefined?'':a.detail
cost += a.key + ":" +detail+" "
})
this.tourCostDetail = cost
if(this.form.orderRentVehicleDetail.driverType==1) {
......
......@@ -63,18 +63,7 @@
</el-button>
<el-button size="small" type="warn" v-if="scope.row.status==1" @click="upStatus(scope.row)">下架
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -500,25 +489,31 @@
* 操作-删除
* */
deleteHandler(row) {
goodDel(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.oneTourDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
goodDel(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.oneTourDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
/**
* 上架、下架 参数 id status 1-上架;2-下架 post
......
......@@ -91,18 +91,7 @@
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel">取 消</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler()">确定</el-button>
</div>
</el-popover>
<el-button v-if="form.showTitle == '途径地编辑'" type="danger" v-popover:popover5>删除</el-button>
<el-button v-if="form.showTitle == '途径地编辑'" type="danger" @click="deleteHandler()">删除</el-button>
<el-button type="primary" @click="okHandler('form')">确 定</el-button>
</div>
</el-dialog>
......@@ -278,8 +267,14 @@
* */
deleteHandler(formName) {
// 删除
this.form.method = 'delete';
this.$emit(this.form.eventName, this.form);
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.form.method = 'delete';
this.$emit(this.form.eventName, this.form);
})
},
querySearch(queryString, cb) {
let selectArry = [];
......
......@@ -49,18 +49,7 @@
<template scope="scope">
<el-button size="small" type="success" @click="handleUpdate(scope.row)">编辑
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -315,24 +304,30 @@
* 删除
* */
deleteHandler(row) {
deleteTourTag(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteTourTag(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
/**
* 操作-编辑
......
......@@ -83,18 +83,7 @@
</el-table-column>
<el-table-column align="center" label="操作" width="100" fixed="right">
<template scope="scope">
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5 v-if="memberEnter_btn_del">删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)" v-if="memberEnter_btn_del">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -356,24 +345,30 @@
* 删除
* */
deleteHandler(row) {
delMemberObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message:response.message?response.message: '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delMemberObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message:response.message?response.message: '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
//excel上传
handleRemove(file, fileList) {
......
......@@ -139,19 +139,7 @@
</el-button>
<el-button v-if="scope.row.status==1&&userList_btn_unmute" size="small" type="danger" @click="available(scope.row)">取消禁用
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteUser(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-if="userList_btn_del" v-popover:popover5>删除</el-button>
<el-button type="danger" size="small" v-if="userList_btn_del" @click="deleteUser(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -1149,21 +1137,27 @@
this.$forceUpdate()
},
deleteUser(row){
deleteUser(row.userId).then(
res=>{
if (res.rel) {
this.$notify.success({
title: '删除成功',
message: `success`
})
} else {
this.$notify.warning({
title: '删除失败',
message: `failed`
})
}
this.getList()
})
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteUser(row.userId).then(
res=>{
if (res.rel) {
this.$notify.success({
title: '删除成功',
message: `success`
})
} else {
this.$notify.warning({
title: '删除失败',
message: `failed`
})
}
this.getList()
})
})
}
}
}
......
......@@ -338,18 +338,7 @@
</el-button>
<el-button size="small" class="el-button el-button--text el-button--small" @click="handleBookInfo(scope.row)">预订信息</el-button>
<el-button size="small" class="el-button el-button--text el-button--small" @click="handleDepartureLog(scope.row)">出车记录</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5 v-if="vehicleInfo_btn_ret">删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)" v-if="vehicleInfo_btn_ret">删除</el-button>
</template>
</el-table-column>
......@@ -1952,25 +1941,31 @@
* 删除
* */
deleteHandler(row) {
delObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.bannerDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delObj(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.bannerDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
resetTemp() {
this.form = {
......
......@@ -78,18 +78,7 @@
<template scope="scope">
<el-button size="small" type="success" @click="handleUpdate(scope.row)">{{vehicleTypeList_btn_edit?'编辑':'查看'}}
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" size="small" v-popover:popover5 v-if="vehicleTypeList_btn_del">删除</el-button>
<el-button type="danger" size="small" @click="deleteHandler(scope.row)" v-if="vehicleTypeList_btn_del">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -213,25 +202,31 @@
* 删除
* */
deleteHandler(row) {
delVehicleModel(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.bannerDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delVehicleModel(row.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.bannerDialogVisible = false;
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
/**
* 编辑
......
......@@ -51,18 +51,7 @@
<template scope="scope">
<el-button size="small" type="success" @click="handleUpdate(scope.row)">{{vehicleTypeLabel_btn_save?'编辑':'查看'}}
</el-button>
<el-popover
ref="popover5"
placement="top"
width="160"
v-model="scope.row.parent.visible2">
<p>确定删除吗?</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="scope.row.parent.visible2 = false">取消</el-button>
<el-button type="primary" size="mini" @click="deleteHandler(scope.row)">确定</el-button>
</div>
</el-popover>
<el-button type="danger" v-if="scope.row.parent.id != 1 && scope.row.parent.id!= 14&&vehicleTypeLabel_btn_del" size="small" v-popover:popover5>删除</el-button>
<el-button type="danger" v-if="scope.row.parent.id != 1 && scope.row.parent.id!= 14&&vehicleTypeLabel_btn_del" size="small" @click="deleteHandler(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
......@@ -342,24 +331,30 @@
* 删除一个标签
* */
deleteHandler(row) {
deleteVehicleType(row.parent.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
this.$confirm('确定删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteVehicleType(row.parent.id).then(response => {
if (response.status === 200) {
this.$notify({
title: '成功',
message: '删除成功',
type: 'success',
duration: 2000
});
this.getList();
} else {
this.$notify({
title: '删除失败',
message: rsCode.msg[response.code] ? rsCode.msg[response.code] : '操作失败!',
type: 'error',
duration: 2000
});
}
});
})
},
/**
* 操作-编辑
......
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