Merge branch 'dev_衡阳_鹏创电子' of http://114.132.189.42:9002/r/product-inventory-management into dev_衡阳_鹏创电子
| | |
| | | data: query, |
| | | }); |
| | | } |
| | | |
| | | // 取消隔离 |
| | | export function liftTheQuarantineQualityUnqualified(query) { |
| | | return request({ |
| | | url: "/quality/qualityUnqualified/liftTheQuarantine", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | |
| | | width: 280, |
| | | operation: [ |
| | | { |
| | | name: "查看", |
| | | name: "绑定生产记录", |
| | | type: "text", |
| | | clickFun: row => { |
| | | showProcessParamModal(row); |
| | |
| | | clickFun: row => { |
| | | showReportDialog(row); |
| | | }, |
| | | disabled: row => row.planQuantity <= 0, |
| | | disabled: row => !row.isCanReport || row.planQuantity <= 0, |
| | | }, |
| | | ], |
| | | }, |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="数量:" prop="quantity"> |
| | | <el-input-number :step="0.01" :min="0" style="width: 100%" v-model="form.quantity" placeholder="请输入" clearable :precision="2" :disabled="quantityDisabled"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row :gutter="30"> |
| | | <el-col :span="12"> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="数量:" prop="quantity"> |
| | | <el-input-number :step="0.01" :min="0" style="width: 100%" v-model="form.quantity" placeholder="请输入" clearable :precision="2" :disabled="quantityDisabled"/> |
| | | <el-form-item label="不良原因:" prop="defectiveReason"> |
| | | <el-select v-model="form.defectiveReason" placeholder="请选择" clearable style="width: 100%"> |
| | | <el-option :label="item.label" :value="item.value" v-for="(item,index) in defective_reason" :key="index" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | productModelId: "", |
| | | model: "", |
| | | testStandardId: "", |
| | | defectiveReason: undefined, |
| | | unit: "", |
| | | quantity: "", |
| | | checkCompany: "", |
| | |
| | | }); |
| | | const supplierList = ref([]); |
| | | const productOptions = ref([]); |
| | | const { defective_reason } = proxy.useDict("defective_reason"); |
| | | const tableColumn = ref([ |
| | | { |
| | | label: "指标", |
| | |
| | | > |
| | | </div> |
| | | <div> |
| | | <el-button type="primary" @click="openForm('add')">新增</el-button> |
| | | <!-- <el-button type="primary" @click="openForm('add')">新增</el-button>--> |
| | | <el-button @click="handleOut">导出</el-button> |
| | | <el-button type="danger" plain @click="handleDelete">删除</el-button> |
| | | </div> |
| | |
| | | width: 100 |
| | | }, |
| | | { |
| | | label: "不良数量", |
| | | prop: "defectiveQuantity", |
| | | width: 100 |
| | | }, |
| | | { |
| | | label: "不良原因", |
| | | prop: "defectiveReason", |
| | | width: 100 |
| | | }, |
| | | { |
| | | label: "检测单位", |
| | | prop: "checkCompany", |
| | | width: 120 |
| | |
| | | </el-form-item> |
| | | <el-form-item label="类别" prop="inspectType"> |
| | | <el-select v-model="form.inspectType" placeholder="请选择类别" style="width: 100%"> |
| | | <el-option label="原材料检验" value="0" /> |
| | | <!-- <el-option label="原材料检验" value="0" />--> |
| | | <el-option label="过程检验" value="1" /> |
| | | <el-option label="出厂检验" value="2" /> |
| | | <el-option label="成品检验" value="2" /> |
| | | <el-option label="巡检" value="3" /> |
| | | </el-select> |
| | | </el-form-item> |
| | |
| | | const map = { |
| | | 0: '原材料检验', |
| | | 1: '过程检验', |
| | | 2: '出厂检验' |
| | | 2: '成品检验' |
| | | } |
| | | return map[val] || val |
| | | } |
| | |
| | | <el-select v-model="form.inspectType" disabled> |
| | | <el-option label="原材料检验" :value="0" /> |
| | | <el-option label="过程检验" :value="1" /> |
| | | <el-option label="出厂检验" :value="2" /> |
| | | <el-option label="成品检验" :value="2" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-col :span="12"> |
| | | <el-form-item label="处理结果:" prop="dealResult"> |
| | | <el-select v-model="form.dealResult" placeholder="请选择" clearable> |
| | | <el-option :label="item.label" :value="item.value" v-for="item in filteredRejectionHandling" :key="item.value" /> |
| | | <el-option :label="item.label" :value="item.value" v-for="item in filteredRejectionHandling" :key="item.value" :disabled="form.process === '印铜' && item.value !== '报废'" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row :gutter="30" v-if="form.dealResult === '隔离'"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="备注:" prop="remark"> |
| | | <el-input type="textarea" v-model="form.remark" :rows="3" placeholder="请输入"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | <template #footer> |
| | | <div class="dialog-footer"> |
| | |
| | | </template> |
| | | |
| | | <script setup> |
| | | import {ref, reactive, toRefs, computed} from "vue"; |
| | | import {ref, reactive, toRefs, computed, watch} from "vue"; |
| | | import {productTreeList} from "@/api/basicData/product.js"; |
| | | import { |
| | | getQualityUnqualifiedInfo, |
| | |
| | | dealResult: '', |
| | | dealName: '', |
| | | dealTime: '', |
| | | method: undefined |
| | | method: undefined, |
| | | remark: undefined |
| | | }, |
| | | rules: { |
| | | checkTime: [{ required: false, message: "请输入", trigger: "blur" },], |
| | |
| | | return data |
| | | }) |
| | | |
| | | watch(() => form.value.dealResult, (newVal) => { |
| | | if (newVal !== '隔离') { |
| | | form.value.remark = undefined; |
| | | } |
| | | }); |
| | | |
| | | // 打开弹框 |
| | | const openDialog = async (type, row) => { |
| | |
| | | import {onMounted, ref, reactive, toRefs, nextTick, getCurrentInstance} from "vue"; |
| | | import FormDia from "@/views/qualityManagement/nonconformingManagement/components/formDia.vue"; |
| | | import {ElMessageBox} from "element-plus"; |
| | | import {qualityUnqualifiedDel, qualityUnqualifiedListPage} from "@/api/qualityManagement/nonconformingManagement.js"; |
| | | import {qualityUnqualifiedDel, qualityUnqualifiedListPage, liftTheQuarantineQualityUnqualified} from "@/api/qualityManagement/nonconformingManagement.js"; |
| | | import InspectionFormDia from "@/views/qualityManagement/nonconformingManagement/components/inspectionFormDia.vue"; |
| | | import dayjs from "dayjs"; |
| | | |
| | |
| | | width: 100, |
| | | operation: [ |
| | | { |
| | | name: "取消隔离", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | liftTheQuarantine(row); |
| | | }, |
| | | showHide: (row) => row.dealResult === '隔离' && !row.quarantineLifted |
| | | }, |
| | | { |
| | | name: "处理", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | |
| | | }) |
| | | }; |
| | | |
| | | const liftTheQuarantine = (row) => { |
| | | proxy.$modal.confirm("是否确认取消隔离?").then(function () { |
| | | return liftTheQuarantineQualityUnqualified(row) |
| | | }).then(() => { |
| | | proxy.$modal.msgSuccess("取消隔离成功"); |
| | | getList(); |
| | | }).catch(() => {}) |
| | | } |
| | | // 删除 |
| | | const handleDelete = () => { |
| | | let ids = []; |