|
|
@ -88,7 +88,7 @@ |
|
|
|
<!-- <a-divider type="vertical"/>--> |
|
|
|
<!-- <a-divider type="vertical"/>--> |
|
|
|
<!-- <a @click="handleDetail(record)">详情</a>--> |
|
|
|
<!-- <a @click="handleDetail(record)">详情</a>--> |
|
|
|
<a-divider type="vertical"/> |
|
|
|
<a-divider type="vertical"/> |
|
|
|
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)"> |
|
|
|
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete2(record.id)"> |
|
|
|
<a>删除</a> |
|
|
|
<a>删除</a> |
|
|
|
</a-popconfirm> |
|
|
|
</a-popconfirm> |
|
|
|
</span> |
|
|
|
</span> |
|
|
@ -106,6 +106,7 @@ import '@/assets/less/TableExpand.less' |
|
|
|
import {mixinDevice} from '@/utils/mixin' |
|
|
|
import {mixinDevice} from '@/utils/mixin' |
|
|
|
import StationModal from './modules/StationModal' |
|
|
|
import StationModal from './modules/StationModal' |
|
|
|
import {JeecgListMixin} from '@/mixins/JeecgListMixin' |
|
|
|
import {JeecgListMixin} from '@/mixins/JeecgListMixin' |
|
|
|
|
|
|
|
import {deleteAction, getAction} from "@api/manage"; |
|
|
|
|
|
|
|
|
|
|
|
export default { |
|
|
|
export default { |
|
|
|
name: "StationList", |
|
|
|
name: "StationList", |
|
|
@ -171,6 +172,7 @@ export default { |
|
|
|
], |
|
|
|
], |
|
|
|
url: { |
|
|
|
url: { |
|
|
|
list: "/team/station/list", |
|
|
|
list: "/team/station/list", |
|
|
|
|
|
|
|
queryIsCanDelete: "/team/station/queryIsCanDelete", |
|
|
|
delete: "/team/station/delete", |
|
|
|
delete: "/team/station/delete", |
|
|
|
deleteBatch: "/team/station/deleteBatch", |
|
|
|
deleteBatch: "/team/station/deleteBatch", |
|
|
|
exportXlsUrl: "/team/station/exportXls", |
|
|
|
exportXlsUrl: "/team/station/exportXls", |
|
|
@ -203,6 +205,37 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
handleDelete2: function (id) { |
|
|
|
|
|
|
|
if (!this.url.queryIsCanDelete) { |
|
|
|
|
|
|
|
this.$message.error("请设置url.delete属性!") |
|
|
|
|
|
|
|
return |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// let dataTotal = 0; |
|
|
|
|
|
|
|
let param = { |
|
|
|
|
|
|
|
id: id |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
getAction(this.url.queryIsCanDelete, param).then((res) => { |
|
|
|
|
|
|
|
console.log("queryIsCanDelete res:" + JSON.stringify(res)); |
|
|
|
|
|
|
|
if (res.success) { |
|
|
|
|
|
|
|
if (res.result > 0) { |
|
|
|
|
|
|
|
this.$message.warning("暂不可删除,子模块正在使用!"); |
|
|
|
|
|
|
|
return; |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
var that = this; |
|
|
|
|
|
|
|
deleteAction(that.url.delete, param).then((res) => { |
|
|
|
|
|
|
|
if (res.success) { |
|
|
|
|
|
|
|
//重新计算分页问题 |
|
|
|
|
|
|
|
that.reCalculatePage(1) |
|
|
|
|
|
|
|
that.$message.success(res.message); |
|
|
|
|
|
|
|
that.loadData(); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
that.$message.warning(res.message); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
}, |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
</script> |
|
|
|
</script> |
|
|
|