| | |
| | | import ttable from '@/views/common/ztt-table.vue' |
| | | import * as fecha from 'element-ui/lib/utils/date' |
| | | import finishedProductInspectionAdd from './finishedProductInspectionAdd' |
| | | import finishedProductInspectionUp from './finishedProductInspectionUp' |
| | | import finishedProductInspectionLook from './finishedProductInspectionLook' |
| | | import { page } from '@/api/quality/finishedProduct' |
| | | import { page,deletePro } from '@/api/quality/finishedProduct' |
| | | export default { |
| | | components: { |
| | | finishedProductInspectionAdd, |
| | | finishedProductInspectionUp, |
| | | finishedProductInspectionLook, |
| | | ttable |
| | | }, |
| | | data() { |
| | |
| | | // this.getInspectionTableData() |
| | | }, |
| | | methods: { |
| | | deleteHandle(row){ |
| | | console.log(row.id) |
| | | this.$confirm('确认删除该数据吗?', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning', |
| | | }).then(()=>{ |
| | | deletePro(row.id).then(res=>{ |
| | | if(res.data.code == 0){ |
| | | this.$message.success("删除成功") |
| | | }else{ |
| | | this.$message.error("删除失败") |
| | | } |
| | | this.getData() |
| | | }) |
| | | }) |
| | | }, |
| | | // 新增 / 修改 |
| | | addOrUpdateHandle(row) { |
| | | this.$router.push({ |
| | |
| | | handleAddNew() { |
| | | this.showAdd = true |
| | | }, |
| | | // async getInspectionTableData() { |
| | | // const { |
| | | // data: { |
| | | // row, |
| | | // total |
| | | // } |
| | | // } = await this.$axios.get(this.$api.url.finishedInsListPage, { |
| | | // params: { |
| | | // ...this.pageParams, |
| | | // ...this.searchData |
| | | // } |
| | | // }) |
| | | // this.inspectionTable = row |
| | | // this.pageParams.total = total |
| | | // }, |
| | | getData() { |
| | | this.$refs.finishedProduct.getDataList() |
| | | }, |
| | | goToDetail(row) { |
| | | this.rowInfo = row |
| | | this.showLook = true |