| | |
| | | <div> |
| | | <el-button type="primary" @click="handleAdd">新增</el-button> |
| | | <el-button type="primary" @click="exportFile" :loading="exportLoading">导出</el-button> |
| | | <el-button type="danger" :disabled="!selectedIds.length" @click="handleDelete()">删除</el-button> |
| | | <!-- <el-button type="danger" :disabled="!selectedIds.length" @click="handleDelete()">删除</el-button>--> |
| | | </div> |
| | | <el-table v-loading="loading" :data="list" @selection-change="handleSelectionChange"> |
| | | <el-table-column type="selection" width="55" /> |
| | |
| | | <el-link @click="handleView(row)" type="primary">查看</el-link> |
| | | <el-link @click="handleEdit(row)" type="warning">编辑</el-link> |
| | | <el-link @click="outbound(row)" type="warning">出库</el-link> |
| | | <el-link @click="handleDelete(row)" type="danger">删除</el-link> |
| | | <el-link @click="scrap(row)" type="warning" v-if="row.status !== 3">报废</el-link> |
| | | <!-- <el-link @click="handleDelete(row)" type="danger">删除</el-link>--> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | |
| | | <FormDiaLog ref="dialogRef" @success="getList" /> |
| | | <DeviceTrackDiaLog ref="outboundDialogRef" @success="getList" /> |
| | | <DeviceScrapDiaLog ref="scrapDialogRef" @success="getList" /> |
| | | </basic-container> |
| | | </template> |
| | | |
| | |
| | | import { blobDownload, dateRangeFormat, getDictLabel } from '@ztzf/utils' |
| | | import { DEVICE_STATUS } from '@ztzf/constants' |
| | | import DeviceTrackDiaLog from '@/views/basicManage/deviceStock/DeviceTrackDiaLog.vue' |
| | | import DeviceScrapDiaLog from '@/views/basicManage/deviceStock/DeviceScrapDiaLog.vue' |
| | | |
| | | const initSearchParams = () => ({ |
| | | deviceName: '', // 设备名称 |
| | |
| | | const queryParamsRef = ref(null) // 查询表单实例 |
| | | const dialogRef = ref(null) // 弹框实例 |
| | | const outboundDialogRef = ref(null) // 弹框实例 |
| | | const scrapDialogRef = ref(null) // 弹框实例 |
| | | const dictObj = ref({ |
| | | deviceType: [], //设备类型 |
| | | deviceAtt: [], //设备属性 |
| | |
| | | } |
| | | |
| | | function outbound(row) { |
| | | outboundDialogRef.value?.open({ mode: 'add', row: { ...row } }) |
| | | outboundDialogRef.value?.open({ mode: 'edit', row: { ...row } }) |
| | | } |
| | | |
| | | function scrap(row) { |
| | | scrapDialogRef.value?.open({ mode: 'edit', row: { ...row } }) |
| | | } |
| | | |
| | | // 删除 |