| | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <!-- <div style="width: 100%;height: 100%;">--> |
| | | <!-- <CustomsInspection :active="active"--> |
| | | <!-- :currentId="currentId"--> |
| | | <!-- :customsInspection="customsInspection" :orderType="orderType" />--> |
| | | <!-- </div>--> |
| | | <!-- <div style="width: 100%;height: 100%;">--> |
| | | <!-- <CopperOrder :active="active" :currentId="currentId"></CopperOrder>--> |
| | | <!-- </div>--> |
| | | <!-- 确认免检弹框 --> |
| | | <el-dialog :visible.sync="exemptionVisible" title="确认免检" width="42%"> |
| | | <div style="display: flex"> |
| | |
| | | import DownFileDialog from "@/views/business/materialOrderComponents/materialOrder/downFileDialog.vue"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import { |
| | | concessionRelease, |
| | | getIfsByAll, |
| | | getIfsByOver, |
| | | getIfsByQuarter, |
| | | getIfsByStateOne, |
| | | getPurchaseOrder |
| | | getPurchaseOrder, |
| | | rawAllExport, |
| | | rawOrderRelease, |
| | | repealEnterRawOrder, |
| | | repealQuarterRawOrder, |
| | | revokeInspectionReport, |
| | | updateEntrustCode |
| | | } from "@/api/business/rawMaterialOrder"; |
| | | import {getWarehouseSubmit} from "@/api/business/materialInspection"; |
| | | // import Inspection from "../do/b1-inspect-order-plan/Inspection.vue"; |
| | |
| | | dataType: 'action', |
| | | fixed: 'right', |
| | | label: '操作', |
| | | width: '300px', |
| | | width: '420px', |
| | | operation: [ |
| | | { |
| | | name: '季度检验', |
| | |
| | | cancelButtonText: '取消', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | this.$axios.post(this.$api.materialInspection.concessionRelease+'?ifsInventoryId='+row.id).then(res => { |
| | | concessionRelease({ifsInventoryId: row.id}).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | type: 'success', |
| | |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.$axios.post(this.$api.rawMaterialOrder.repealQuarterRawOrder + '?quarterOrderId=' + row.quarterOrderId).then(res => { |
| | | repealQuarterRawOrder({quarterOrderId: row.quarterOrderId}).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('撤销成功') |
| | | this.refreshTable('page') |
| | |
| | | // 提交免检信息 |
| | | submitExemption () { |
| | | this.exemptionLoading = true |
| | | this.$axios.post(this.$api.rawMaterialOrder.rawOrderRelease, { |
| | | rawOrderRelease({ |
| | | ifsInventoryId: this.exemptionInfo.id, |
| | | partDetail: this.exemptionInfo.partDetail |
| | | }, { |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | }, |
| | | noQs: true |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | this.exemptionVisible = false |
| | |
| | | }, |
| | | // 提交撤销报检申请 |
| | | submitDeclare () { |
| | | this.$axios.post(this.$api.rawMaterialOrder.revokeInspectionReport, { |
| | | id: this.insOrderRow.id |
| | | }).then(res => { |
| | | revokeInspectionReport({id: this.insOrderRow.id}).then(res => { |
| | | if (res.code === 200) { |
| | | this.declareDialogVisible = false |
| | | this.refreshTable('page') |
| | | this.refreshTable() |
| | | this.$message.success("撤销报检成功") |
| | | } |
| | | }).catch(err => { |
| | |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.$axios.post(this.$api.rawMaterialOrder.repealEnterRawOrder + '?enterOrderId=' + row.enterOrderId).then(res => { |
| | | repealEnterRawOrder({enterOrderId: row.enterOrderId}).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('撤销成功') |
| | | this.refreshTable('page') |
| | |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.$axios.post(this.$api.rawMaterialOrder.repealQuarterRawOrder + '?quarterOrderId=' + row.quarterOrderId).then(res => { |
| | | repealQuarterRawOrder({quarterOrderId: row.quarterOrderId}).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('撤销成功') |
| | | this.refreshTable('page') |
| | |
| | | this.insOrderRow = row |
| | | }, |
| | | cancelQuashOrder (type) { |
| | | const url = type === 'enterOrderId' ? this.$api.rawMaterialOrder.repealEnterRawOrder : this.$api.rawMaterialOrder.repealQuarterRawOrder |
| | | const name = type === 'enterOrderId' ? 'enterOrderId' : 'quarterOrderId' |
| | | const paramInfo = type === 'enterOrderId' ? this.insOrderRow.enterOrderId : this.insOrderRow.quarterOrderId |
| | | this.$confirm('是否撤销当前数据?', "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.$axios.post(url + `?${name}=` + paramInfo).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('撤销成功') |
| | | this.refreshTable('page') |
| | | } |
| | | }) |
| | | }).catch(() => {}) |
| | | if (type === 'enterOrderId') { |
| | | this.$confirm('是否撤销当前数据?', "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | repealEnterRawOrder({enterOrderId: this.insOrderRow.enterOrderId}).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('撤销成功') |
| | | this.refreshTable('page') |
| | | } |
| | | }) |
| | | }).catch(() => {}) |
| | | } else { |
| | | this.$confirm('是否撤销当前数据?', "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | repealQuarterRawOrder({quarterOrderId: this.insOrderRow.quarterOrderId}).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('撤销成功') |
| | | this.refreshTable('page') |
| | | } |
| | | }) |
| | | }).catch(() => {}) |
| | | } |
| | | }, |
| | | // 点击样品名称查看详情 |
| | | selectAllByOne(row) { |
| | |
| | | closeFilesLook () { |
| | | this.filesDialogVisible = false |
| | | }, |
| | | // 附件下载 |
| | | handleDown(row){ |
| | | this.$axios.post(this.$api.insOrderPlan.downFile, { |
| | | id: row.id, |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | let url = ''; |
| | | if(res.data.type==1){ |
| | | url = this.javaApi+'/img/'+res.data.fileUrl |
| | | file.downloadIamge(url,row.fileName) |
| | | }else{ |
| | | url = this.javaApi+'/word/'+res.data.fileUrl |
| | | const link = document.createElement('a'); |
| | | link.href = url; |
| | | link.download = row.fileName; |
| | | link.click(); |
| | | } |
| | | } |
| | | }).catch(error => { |
| | | |
| | | }) |
| | | }, |
| | | // 报告下载 |
| | | download(row) { |
| | | this.downFileDialogVisible = true |
| | |
| | | let entity = this.tabIndex === 3 ? {...this.entity, isInspect: 2} : {...this.entity,state: 2, orderState: 4,} |
| | | delete entity.orderBy |
| | | this.outLoading = true |
| | | this.$axios.post(this.$api.rawMaterialOrder.rawAllExport,{ |
| | | rawAllExport({ |
| | | entity:entity |
| | | },{ |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | } |
| | | ,responseType: "blob"}).then(res => { |
| | | },{responseType: "blob"}).then(res => { |
| | | this.outLoading = false |
| | | this.$message.success('导出成功') |
| | | const blob = new Blob([res],{ type: 'application/octet-stream' }); |
| | |
| | | link.click(); |
| | | }) |
| | | }, |
| | | // 提交修改委托编号信息 |
| | | submitCode () { |
| | | this.submitCodeLoading = true |
| | | try { |
| | | this.$axios.post(this.$api.insOrderPlan.updateEntrustCode, { |
| | | updateEntrustCode({ |
| | | id: this.entrustCodeInfo.id, |
| | | entrustCode: this.entrustCodeInfo.entrustCode, |
| | | }, { |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | } |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | this.entrustCodeVisible = false |