| | |
| | | <template> |
| | | <div class="system-user-container"> |
| | | <el-card shadow="hover"> |
| | | <div class="button_Line"> |
| | | <div class="button_Line mb15"> |
| | | <div class="button_Left"> |
| | | <el-button size="default" type="primary" @click="onOpenAdd"> |
| | | <el-icon> |
| | |
| | | </el-button> |
| | | </div> |
| | | <div class="button_Right"> |
| | | <el-button @click="upButton"> |
| | | <el-icon> |
| | | <Upload /> |
| | | </el-icon> |
| | | </el-button> |
| | | <el-button> |
| | | <el-icon> |
| | | <Download /> |
| | | </el-icon> |
| | | </el-button> |
| | | <el-button> |
| | | <el-icon> |
| | | <Refresh /> |
| | | </el-icon> |
| | | </el-button> |
| | | <!-- <el-button @click="upButton">--> |
| | | <!-- <el-icon>--> |
| | | <!-- <Upload />--> |
| | | <!-- </el-icon>--> |
| | | <!-- </el-button>--> |
| | | <!-- <el-button>--> |
| | | <!-- <el-icon>--> |
| | | <!-- <Download />--> |
| | | <!-- </el-icon>--> |
| | | <!-- </el-button>--> |
| | | <!-- <el-button>--> |
| | | <!-- <el-icon>--> |
| | | <!-- <Refresh />--> |
| | | <!-- </el-icon>--> |
| | | <!-- </el-button>--> |
| | | </div> |
| | | </div> |
| | | <el-table |
| | |
| | | type="selection" |
| | | width="55" |
| | | /> |
| | | <el-table-column prop="drillPlanId" label="演练名称" show-overflow-tooltip sortable></el-table-column> |
| | | <el-table-column prop="emergencyPlanName" label="演练名称" show-overflow-tooltip sortable></el-table-column> |
| | | <el-table-column prop="drillAddress" label="演练地点" show-overflow-tooltip sortable></el-table-column> |
| | | <el-table-column prop="drillWay" label="演练方式" show-overflow-tooltip sortable></el-table-column> |
| | | <el-table-column prop="drillLevel" label="演练级别" show-overflow-tooltip sortable></el-table-column> |
| | |
| | | </div> |
| | | </el-card> |
| | | <OpenAdd ref="addRef" @myAdd="onMyAdd"/> |
| | | <upData ref="upShow"></upData> |
| | | <!-- <upData ref="upShow"></upData>--> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | import { Plus, |
| | | // Edit, |
| | | Delete, |
| | | Upload, |
| | | Download, |
| | | // Upload, |
| | | // Download, |
| | | View, |
| | | Refresh, |
| | | VideoPause, |
| | |
| | | // Edit, |
| | | Delete, |
| | | View, |
| | | Upload, |
| | | Download, |
| | | // Upload, |
| | | // Download, |
| | | Refresh, |
| | | VideoPause, |
| | | UpData |
| | |
| | | }; |
| | | |
| | | // 上传 |
| | | const upShow=ref() |
| | | const upButton=()=>{ |
| | | upShow.value.openDialog() |
| | | } |
| | | // const upShow=ref() |
| | | // const upButton=()=>{ |
| | | // upShow.value.openDialog() |
| | | // } |
| | | // 打开新增用户弹窗 |
| | | const addRef = ref(); |
| | | const onOpenAdd = () => { |
| | |
| | | } |
| | | }; |
| | | // 删除用户 |
| | | const onRowDel = (data: any) => { |
| | | const onRowDel = (id: number) => { |
| | | let arr = []; |
| | | arr.push(id) |
| | | console.log(arr) |
| | | ElMessageBox.confirm('确定删除所选项吗?', '提示',{ |
| | | confirmButtonText: '确认', |
| | | cancelButtonText: '取消', |
| | | type: 'warning', |
| | | }).then(() => { |
| | | emergencyDrillExecuteApi() |
| | | .deleteEmergencyDrillExecute(data) |
| | | .deleteEmergencyDrillExecute(arr) |
| | | .then((res) => { |
| | | if (res.data.code == 200) { |
| | | ElMessage({ |
| | |
| | | }); |
| | | }) |
| | | .catch(() => {}); |
| | | }; |
| | | const danger = ref(true); |
| | | const deletAll = ref(); |
| | | const handleSelectionChange = (val: any) => { |
| | | let valId = JSON.parse(JSON.stringify(val)); |
| | | let arr = []; |
| | | for (let i = 0; i < valId.length; i++) { |
| | | arr.push(valId[i].id); |
| | | } |
| | | deletAll.value = arr; |
| | | if (val.length == 1) { |
| | | danger.value = false; |
| | | } else if (val.length == 0) { |
| | | danger.value = true; |
| | | } else { |
| | | danger.value = false; |
| | | } |
| | | }; |
| | | // 多选删除 |
| | | const onDeleteAll = () => { |
| | |
| | | listQuery.pageIndex = val; |
| | | listApi(); |
| | | }; |
| | | const danger = ref(true); |
| | | const deletAll = ref(); |
| | | const handleSelectionChange = (val: any) => { |
| | | let valId = JSON.parse(JSON.stringify(val)); |
| | | let arr = []; |
| | | for (let i = 0; i < valId.length; i++) { |
| | | arr.push(valId[i].id); |
| | | } |
| | | deletAll.value = arr.toString(); |
| | | // console.log(deletAll.value); |
| | | if (val.length == 1) { |
| | | danger.value = false; |
| | | } else if (val.length == 0) { |
| | | danger.value = true; |
| | | } else { |
| | | danger.value = false; |
| | | } |
| | | }; |
| | | |
| | | onMounted(() => { |
| | | listApi(); |
| | | }); |
| | | return { |
| | | upButton, |
| | | upShow, |
| | | // upButton, |
| | | // upShow, |
| | | tableData, |
| | | onOpenAdd, //新增 |
| | | addRef, |
| | |
| | | handleSelectionChange, |
| | | danger, |
| | | deletAll, |
| | | onEdit, |
| | | }; |
| | | }, |
| | | }); |
| | |
| | | flex-direction: row; |
| | | justify-content: space-between; |
| | | } |
| | | //表头 |
| | | ::v-deep .el-table th.el-table__cell { |
| | | background-color: #f6f7fa; |
| | | font-weight: 400; |
| | | color: #909399; |
| | | } |
| | | .el-table .sort-caret.ascending{ |
| | | border-bottom-color: #c0c4cc; |
| | | } |
| | | //分页开始 |
| | | .pages{ |
| | | display: flex; |