|
|
@ -1,19 +1,8 @@
|
|
|
|
<template>
|
|
|
|
<template>
|
|
|
|
<div class="app-container">
|
|
|
|
<div class="app-container">
|
|
|
|
<el-form
|
|
|
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">
|
|
|
|
:model="queryParams"
|
|
|
|
|
|
|
|
ref="queryForm"
|
|
|
|
|
|
|
|
size="small"
|
|
|
|
|
|
|
|
:inline="true"
|
|
|
|
|
|
|
|
v-show="showSearch"
|
|
|
|
|
|
|
|
label-width="80px"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-form-item label="检验节点" prop="checkType">
|
|
|
|
<el-form-item label="检验节点" prop="checkType">
|
|
|
|
<el-select
|
|
|
|
<el-select v-model="queryParams.checkType" clearable placeholder="请选择检验节点">
|
|
|
|
v-model="queryParams.checkType"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
placeholder="请选择检验节点"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-option
|
|
|
|
<el-option
|
|
|
|
v-for="dict in checkTypes"
|
|
|
|
v-for="dict in checkTypes"
|
|
|
|
:key="dict.id"
|
|
|
|
:key="dict.id"
|
|
|
@ -63,6 +52,7 @@
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<el-form-item label="生产时间" prop="incomeTimeArray">
|
|
|
|
<el-form-item label="生产时间" prop="incomeTimeArray">
|
|
|
|
<el-date-picker
|
|
|
|
<el-date-picker
|
|
|
|
v-model="queryParams.incomeTimeArray"
|
|
|
|
v-model="queryParams.incomeTimeArray"
|
|
|
@ -70,8 +60,7 @@
|
|
|
|
type="datetimerange"
|
|
|
|
type="datetimerange"
|
|
|
|
range-separator="至"
|
|
|
|
range-separator="至"
|
|
|
|
start-placeholder="开始日期"
|
|
|
|
start-placeholder="开始日期"
|
|
|
|
end-placeholder="结束日期"
|
|
|
|
end-placeholder="结束日期">
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-date-picker>
|
|
|
|
</el-date-picker>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
|
|
|
@ -99,8 +88,7 @@
|
|
|
|
type="datetimerange"
|
|
|
|
type="datetimerange"
|
|
|
|
range-separator="至"
|
|
|
|
range-separator="至"
|
|
|
|
start-placeholder="开始日期"
|
|
|
|
start-placeholder="开始日期"
|
|
|
|
end-placeholder="结束日期"
|
|
|
|
end-placeholder="结束日期">
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-date-picker>
|
|
|
|
</el-date-picker>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
<el-form-item label="检验结果" prop="checkResult">
|
|
|
|
<el-form-item label="检验结果" prop="checkResult">
|
|
|
@ -118,16 +106,8 @@
|
|
|
|
</el-select>
|
|
|
|
</el-select>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
<el-form-item>
|
|
|
|
<el-form-item>
|
|
|
|
<el-button
|
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
|
type="primary"
|
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
|
|
icon="el-icon-search"
|
|
|
|
|
|
|
|
size="mini"
|
|
|
|
|
|
|
|
@click="handleQuery"
|
|
|
|
|
|
|
|
>搜索</el-button
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
|
|
|
|
|
|
|
|
>重置</el-button
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form>
|
|
|
|
</el-form>
|
|
|
|
|
|
|
|
|
|
|
@ -140,8 +120,7 @@
|
|
|
|
size="mini"
|
|
|
|
size="mini"
|
|
|
|
@click="handleAdd"
|
|
|
|
@click="handleAdd"
|
|
|
|
v-hasPermi="['quality:qcProduce:add']"
|
|
|
|
v-hasPermi="['quality:qcProduce:add']"
|
|
|
|
>新增</el-button
|
|
|
|
>新增</el-button>
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="1.5">
|
|
|
|
<el-col :span="1.5">
|
|
|
@ -153,8 +132,7 @@
|
|
|
|
:disabled="single"
|
|
|
|
:disabled="single"
|
|
|
|
@click="handleUpdate"
|
|
|
|
@click="handleUpdate"
|
|
|
|
v-hasPermi="['quality:qcProduce:edit']"
|
|
|
|
v-hasPermi="['quality:qcProduce:edit']"
|
|
|
|
>修改</el-button
|
|
|
|
>修改</el-button>
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<!--
|
|
|
|
<!--
|
|
|
|
<el-col :span="1.5">
|
|
|
|
<el-col :span="1.5">
|
|
|
@ -176,103 +154,38 @@
|
|
|
|
size="mini"
|
|
|
|
size="mini"
|
|
|
|
@click="handleExport"
|
|
|
|
@click="handleExport"
|
|
|
|
v-hasPermi="['quality:qcProduce:export']"
|
|
|
|
v-hasPermi="['quality:qcProduce:export']"
|
|
|
|
>导出</el-button
|
|
|
|
>导出</el-button>
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<right-toolbar
|
|
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
|
|
:showSearch.sync="showSearch"
|
|
|
|
|
|
|
|
@queryTable="getList"
|
|
|
|
|
|
|
|
></right-toolbar>
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
|
|
<el-table
|
|
|
|
<el-table v-loading="loading" :data="qcProduceList" @selection-change="handleSelectionChange">
|
|
|
|
v-loading="loading"
|
|
|
|
|
|
|
|
:data="qcProduceList"
|
|
|
|
|
|
|
|
@selection-change="handleSelectionChange"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
|
<el-table-column label="id" align="center" prop="recordId" v-if="false"/>
|
|
|
|
<el-table-column label="id" align="center" prop="recordId" v-if="false"/>
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="checkType" align="center" prop="checkType" v-if="false"/>
|
|
|
|
label="checkType"
|
|
|
|
<el-table-column label="任务编号" align="center" prop="checkNo" width="120">
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="checkType"
|
|
|
|
|
|
|
|
v-if="false"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="任务编号"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="checkNo"
|
|
|
|
|
|
|
|
width="120"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<el-button type="text" @click="handleView(scope.row)">{{
|
|
|
|
<el-button type="text" @click="handleView(scope.row)">{{
|
|
|
|
scope.row.checkNo
|
|
|
|
scope.row.checkNo
|
|
|
|
}}</el-button>
|
|
|
|
}}</el-button>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="批次号" align="center" prop="incomeBatchNo" width="200" :show-overflow-tooltip="true" />
|
|
|
|
label="批次号"
|
|
|
|
<el-table-column label="订单号" align="center" prop="orderNo" width="130"/>
|
|
|
|
align="center"
|
|
|
|
<el-table-column label="物料号" align="center" prop="materialCode" width="170"/>
|
|
|
|
prop="incomeBatchNo"
|
|
|
|
<el-table-column label="物料名称" align="center" prop="materialName" width="250" :show-overflow-tooltip="true" />
|
|
|
|
width="200"
|
|
|
|
|
|
|
|
:show-overflow-tooltip="true"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="订单号"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="orderNo"
|
|
|
|
|
|
|
|
width="130"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="物料号"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="materialCode"
|
|
|
|
|
|
|
|
width="170"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="物料名称"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="materialName"
|
|
|
|
|
|
|
|
width="250"
|
|
|
|
|
|
|
|
:show-overflow-tooltip="true"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column label="数量" align="center" prop="quality" />
|
|
|
|
<el-table-column label="数量" align="center" prop="quality" />
|
|
|
|
<el-table-column label="抽样数量" align="center" prop="sampleQuality" />
|
|
|
|
<el-table-column label="抽样数量" align="center" prop="sampleQuality" />
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="不合格数量" align="center" prop="noOkQuality" width="120"/>
|
|
|
|
label="不合格数量"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="noOkQuality"
|
|
|
|
|
|
|
|
width="120"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column label="单位" align="center" prop="unit" />
|
|
|
|
<el-table-column label="单位" align="center" prop="unit" />
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="车间编码" align="center" prop="supplierCode" width="120"/>
|
|
|
|
label="车间编码"
|
|
|
|
<el-table-column label="车间名称" align="center" prop="supplierName" width="170"/>
|
|
|
|
align="center"
|
|
|
|
<el-table-column label="生产时间" align="center" prop="incomeTime" width="150">
|
|
|
|
prop="supplierCode"
|
|
|
|
|
|
|
|
width="120"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="车间名称"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="supplierName"
|
|
|
|
|
|
|
|
width="170"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="生产时间"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="incomeTime"
|
|
|
|
|
|
|
|
width="150"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<span>{{ parseTime(scope.row.incomeTime, "{y}-{m}-{d}") }}</span>
|
|
|
|
<span>{{ parseTime(scope.row.incomeTime, '{y}-{m}-{d}') }}</span>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="检测地点" align="center" prop="checkLoc" width="120"/>
|
|
|
|
label="检测地点"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="checkLoc"
|
|
|
|
|
|
|
|
width="120"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column label="检测状态" align="center" prop="checkStatus" >
|
|
|
|
<el-table-column label="检测状态" align="center" prop="checkStatus" >
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<dict-tag
|
|
|
|
<dict-tag
|
|
|
@ -281,41 +194,17 @@
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="检测人工号" align="center" prop="checkManCode" width="100" />
|
|
|
|
label="检测人工号"
|
|
|
|
<el-table-column label="检测人姓名" align="center" prop="checkManName" width="100"/>
|
|
|
|
align="center"
|
|
|
|
<el-table-column label="检验时间" align="center" prop="checkTime" width="180">
|
|
|
|
prop="checkManCode"
|
|
|
|
|
|
|
|
width="100"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="检测人姓名"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="checkManName"
|
|
|
|
|
|
|
|
width="100"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<el-table-column
|
|
|
|
|
|
|
|
label="检验时间"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="checkTime"
|
|
|
|
|
|
|
|
width="180"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<span>{{
|
|
|
|
<span>{{ parseTime(scope.row.checkTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
|
|
|
parseTime(scope.row.checkTime, "{y}-{m}-{d} {h}:{i}:{s}")
|
|
|
|
|
|
|
|
}}</span>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column label="检验节点" align="center" prop="checkName" />
|
|
|
|
<el-table-column label="检验节点" align="center" prop="checkName" />
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
|
|
|
|
label="创建时间"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
prop="createTime"
|
|
|
|
|
|
|
|
width="180"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<span>{{
|
|
|
|
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
|
|
|
parseTime(scope.row.createTime, "{y}-{m}-{d} {h}:{i}:{s}")
|
|
|
|
|
|
|
|
}}</span>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column label="检验结果" align="center" prop="checkResult" />
|
|
|
|
<el-table-column label="检验结果" align="center" prop="checkResult" />
|
|
|
@ -329,11 +218,7 @@
|
|
|
|
></el-switch>
|
|
|
|
></el-switch>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column
|
|
|
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
|
label="操作"
|
|
|
|
|
|
|
|
align="center"
|
|
|
|
|
|
|
|
class-name="small-padding fixed-width"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<el-button
|
|
|
|
<el-button
|
|
|
|
size="mini"
|
|
|
|
size="mini"
|
|
|
@ -341,8 +226,7 @@
|
|
|
|
icon="el-icon-edit"
|
|
|
|
icon="el-icon-edit"
|
|
|
|
@click="handleCheckProject(scope.row)"
|
|
|
|
@click="handleCheckProject(scope.row)"
|
|
|
|
v-hasPermi="['quality:qcProduce:edit']"
|
|
|
|
v-hasPermi="['quality:qcProduce:edit']"
|
|
|
|
>检验</el-button
|
|
|
|
>检验</el-button>
|
|
|
|
>
|
|
|
|
|
|
|
|
<!--检验项目弹窗-->
|
|
|
|
<!--检验项目弹窗-->
|
|
|
|
<ItemSelectProject
|
|
|
|
<ItemSelectProject
|
|
|
|
ref="itemSelectProject"
|
|
|
|
ref="itemSelectProject"
|
|
|
@ -370,30 +254,17 @@
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 添加或修改生产过程检验任务对话框 -->
|
|
|
|
<!-- 添加或修改生产过程检验任务对话框 -->
|
|
|
|
<el-dialog
|
|
|
|
<el-dialog :title="title" :visible.sync="open" width="1000px" append-to-body>
|
|
|
|
:title="title"
|
|
|
|
|
|
|
|
:visible.sync="open"
|
|
|
|
|
|
|
|
width="1000px"
|
|
|
|
|
|
|
|
append-to-body
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
|
|
|
<el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="检验任务编号" prop="checkNo">
|
|
|
|
<el-form-item label="检验任务编号" prop="checkNo">
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.checkNo" placeholder="请输入检验任务编号" disabled/>
|
|
|
|
v-model="form.checkNo"
|
|
|
|
|
|
|
|
placeholder="请输入检验任务编号"
|
|
|
|
|
|
|
|
disabled
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="检验类型" prop="checkType" >
|
|
|
|
<el-form-item label="检验类型" prop="checkType" >
|
|
|
|
<el-select
|
|
|
|
<el-select v-model="form.checkType" placeholder="请选择检验类型" style="width: 100%;">
|
|
|
|
v-model="form.checkType"
|
|
|
|
|
|
|
|
placeholder="请选择检验类型"
|
|
|
|
|
|
|
|
style="width: 100%"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-option
|
|
|
|
<el-option
|
|
|
|
v-for="dict in checkTypes"
|
|
|
|
v-for="dict in checkTypes"
|
|
|
|
:key="dict.id"
|
|
|
|
:key="dict.id"
|
|
|
@ -406,11 +277,7 @@
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="订单号" prop="orderNo">
|
|
|
|
<el-form-item label="订单号" prop="orderNo">
|
|
|
|
<el-input v-model="form.orderNo" placeholder="请选择订单号" >
|
|
|
|
<el-input v-model="form.orderNo" placeholder="请选择订单号" >
|
|
|
|
<el-button
|
|
|
|
<el-button slot="append" @click="handleSelectWorkOrder" icon="el-icon-search"></el-button>
|
|
|
|
slot="append"
|
|
|
|
|
|
|
|
@click="handleSelectWorkOrder"
|
|
|
|
|
|
|
|
icon="el-icon-search"
|
|
|
|
|
|
|
|
></el-button>
|
|
|
|
|
|
|
|
</el-input>
|
|
|
|
</el-input>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
@ -418,54 +285,37 @@
|
|
|
|
<el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="物料名称" prop="materialName">
|
|
|
|
<el-form-item label="物料名称" prop="materialName">
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.materialName" placeholder="请选择物料名称"/>
|
|
|
|
v-model="form.materialName"
|
|
|
|
|
|
|
|
placeholder="请选择物料名称"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="物料号" prop="materialCode">
|
|
|
|
<el-form-item label="物料号" prop="materialCode">
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.materialCode" placeholder="请输入物料号"/>
|
|
|
|
v-model="form.materialCode"
|
|
|
|
|
|
|
|
placeholder="请输入物料号"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="生产数量" prop="quality">
|
|
|
|
<el-form-item label="生产数量" prop="quality">
|
|
|
|
<el-input
|
|
|
|
<el-input type="number" v-model="form.quality" placeholder="请输入生产数量" disabled/>
|
|
|
|
type="number"
|
|
|
|
|
|
|
|
v-model="form.quality"
|
|
|
|
|
|
|
|
placeholder="请输入生产数量"
|
|
|
|
|
|
|
|
disabled
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
</el-row>
|
|
|
|
</el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="生产时间" prop="incomeTime">
|
|
|
|
<el-form-item label="生产时间" prop="incomeTime">
|
|
|
|
<el-date-picker
|
|
|
|
<el-date-picker clearable
|
|
|
|
clearable
|
|
|
|
|
|
|
|
v-model="form.incomeTime"
|
|
|
|
v-model="form.incomeTime"
|
|
|
|
type="datetime"
|
|
|
|
type="datetime"
|
|
|
|
value-format="yyyy-MM-dd HH:mm:ss"
|
|
|
|
value-format="yyyy-MM-dd HH:mm:ss"
|
|
|
|
placeholder="请选择生产时间"
|
|
|
|
placeholder="请选择生产时间">
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-date-picker>
|
|
|
|
</el-date-picker>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="单位" prop="unit" >
|
|
|
|
<el-form-item label="单位" prop="unit" >
|
|
|
|
<el-select
|
|
|
|
<el-select v-model="form.unit" placeholder="请选择单位" style="width: 100%;">
|
|
|
|
v-model="form.unit"
|
|
|
|
|
|
|
|
placeholder="请选择单位"
|
|
|
|
|
|
|
|
style="width: 100%"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-option
|
|
|
|
<el-option
|
|
|
|
v-for="dict in dict.type.unit"
|
|
|
|
v-for="dict in dict.type.unit"
|
|
|
|
:key="dict.value"
|
|
|
|
:key="dict.value"
|
|
|
@ -478,18 +328,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="批次号" prop="incomeBatchNo">
|
|
|
|
<el-form-item label="批次号" prop="incomeBatchNo">
|
|
|
|
<el-select
|
|
|
|
<el-select v-model="form.incomeBatchNo" class="selectItem" placeholder="请选择批次" clearable>
|
|
|
|
v-model="form.incomeBatchNo"
|
|
|
|
<el-option v-for="(item,index) in batchList"
|
|
|
|
class="selectItem"
|
|
|
|
|
|
|
|
placeholder="请选择批次"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-option
|
|
|
|
|
|
|
|
v-for="(item, index) in batchList"
|
|
|
|
|
|
|
|
:key="index"
|
|
|
|
:key="index"
|
|
|
|
:label="item.batchCode"
|
|
|
|
:label="item.batchCode"
|
|
|
|
:value="item.batchCode"
|
|
|
|
:value="item.batchCode">
|
|
|
|
>
|
|
|
|
|
|
|
|
</el-option>
|
|
|
|
</el-option>
|
|
|
|
</el-select>
|
|
|
|
</el-select>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
@ -498,79 +341,45 @@
|
|
|
|
<el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="6">
|
|
|
|
<el-col :span="6">
|
|
|
|
<el-form-item label="抽样数量" prop="sampleQuality">
|
|
|
|
<el-form-item label="抽样数量" prop="sampleQuality">
|
|
|
|
<el-input
|
|
|
|
<el-input type="number" v-model="form.sampleQuality" placeholder="请输入抽样数量" />
|
|
|
|
type="number"
|
|
|
|
|
|
|
|
v-model="form.sampleQuality"
|
|
|
|
|
|
|
|
placeholder="请输入抽样数量"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="6" v-for="(item,index) in form.defects" :key="index">
|
|
|
|
<el-col :span="6" v-for="(item,index) in form.defects" :key="index">
|
|
|
|
<el-form-item :label="item.defectSubclass" prop="">
|
|
|
|
<el-form-item :label="item.defectSubclass" prop="">
|
|
|
|
<el-input
|
|
|
|
<el-input type="number" v-model="item.noOkQuality" placeholder="请输入不合格数量" />
|
|
|
|
type="number"
|
|
|
|
|
|
|
|
v-model="item.noOkQuality"
|
|
|
|
|
|
|
|
placeholder="请输入不合格数量"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
</el-row>
|
|
|
|
</el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="车间名称" prop="supplierName">
|
|
|
|
<el-form-item label="车间名称" prop="supplierName">
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.supplierName" placeholder="请输入所属车间名称" >
|
|
|
|
v-model="form.supplierName"
|
|
|
|
<el-button slot="append" @click="handleSelectWorkCenter" icon="el-icon-search"></el-button>
|
|
|
|
placeholder="请输入所属车间名称"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-button
|
|
|
|
|
|
|
|
slot="append"
|
|
|
|
|
|
|
|
@click="handleSelectWorkCenter"
|
|
|
|
|
|
|
|
icon="el-icon-search"
|
|
|
|
|
|
|
|
></el-button>
|
|
|
|
|
|
|
|
</el-input>
|
|
|
|
</el-input>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="车间编码" prop="supplierCode">
|
|
|
|
<el-form-item label="车间编码" prop="supplierCode">
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.supplierCode" placeholder="请输入所属车间编码" disabled/>
|
|
|
|
v-model="form.supplierCode"
|
|
|
|
|
|
|
|
placeholder="请输入所属车间编码"
|
|
|
|
|
|
|
|
disabled
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="抽样数量" prop="sampleQuality">
|
|
|
|
<el-form-item label="抽样数量" prop="sampleQuality">
|
|
|
|
<el-input
|
|
|
|
<el-input type="number" v-model="form.sampleQuality" placeholder="请输入抽样数量" />
|
|
|
|
type="number"
|
|
|
|
|
|
|
|
v-model="form.sampleQuality"
|
|
|
|
|
|
|
|
placeholder="请输入抽样数量"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
</el-row>
|
|
|
|
</el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-row>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="检测人姓名" prop="checkManName">
|
|
|
|
<el-form-item label="检测人姓名" prop="checkManName">
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.checkManName" placeholder="请选择检测人姓名">
|
|
|
|
v-model="form.checkManName"
|
|
|
|
<el-button slot="append" @click="handleSelectUser" icon="el-icon-search"></el-button>
|
|
|
|
placeholder="请选择检测人姓名"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-button
|
|
|
|
|
|
|
|
slot="append"
|
|
|
|
|
|
|
|
@click="handleSelectUser"
|
|
|
|
|
|
|
|
icon="el-icon-search"
|
|
|
|
|
|
|
|
></el-button>
|
|
|
|
|
|
|
|
</el-input>
|
|
|
|
</el-input>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-form-item label="检测人工号" prop="checkManCode" >
|
|
|
|
<el-form-item label="检测人工号" prop="checkManCode" >
|
|
|
|
<el-input
|
|
|
|
<el-input v-model="form.checkManCode" placeholder="请输入检测人工号" disabled/>
|
|
|
|
v-model="form.checkManCode"
|
|
|
|
|
|
|
|
placeholder="请输入检测人工号"
|
|
|
|
|
|
|
|
disabled
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="8">
|
|
|
|
<el-col :span="8">
|
|
|
@ -604,17 +413,10 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
import {
|
|
|
|
import { listQcProduce, getQcProduce, delQcProduce, addQcProduce, updateQcProduce,
|
|
|
|
listQcProduce,
|
|
|
|
getCheckTypes,changeProduceStatus,getBatchList
|
|
|
|
getQcProduce,
|
|
|
|
|
|
|
|
delQcProduce,
|
|
|
|
|
|
|
|
addQcProduce,
|
|
|
|
|
|
|
|
updateQcProduce,
|
|
|
|
|
|
|
|
getCheckTypes,
|
|
|
|
|
|
|
|
changeProduceStatus,
|
|
|
|
|
|
|
|
getBatchList,
|
|
|
|
|
|
|
|
} from "@/api/quality/qcProduce";
|
|
|
|
} from "@/api/quality/qcProduce";
|
|
|
|
import moment from "moment";
|
|
|
|
import moment from 'moment';
|
|
|
|
import ItemSelectWorkOrder from "./selectWorkOrder.vue";
|
|
|
|
import ItemSelectWorkOrder from "./selectWorkOrder.vue";
|
|
|
|
import ItemSelectWorkCenter from "./selectWorkCenter.vue";
|
|
|
|
import ItemSelectWorkCenter from "./selectWorkCenter.vue";
|
|
|
|
import ItemSelectUser from "../qcIncome/selectUser.vue";
|
|
|
|
import ItemSelectUser from "../qcIncome/selectUser.vue";
|
|
|
@ -622,12 +424,7 @@ import ItemSelectProject from "../qcIncome/checkProjectType.vue";
|
|
|
|
import { getDefectTypeListByDefectType } from "@/api/quality/defectType.js";
|
|
|
|
import { getDefectTypeListByDefectType } from "@/api/quality/defectType.js";
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
name: "QcProduce",
|
|
|
|
name: "QcProduce",
|
|
|
|
components: {
|
|
|
|
components: { ItemSelectWorkCenter,ItemSelectUser,ItemSelectProject,ItemSelectWorkOrder},
|
|
|
|
ItemSelectWorkCenter,
|
|
|
|
|
|
|
|
ItemSelectUser,
|
|
|
|
|
|
|
|
ItemSelectProject,
|
|
|
|
|
|
|
|
ItemSelectWorkOrder,
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
dicts: ["unit","check_status","check_result"],
|
|
|
|
dicts: ["unit","check_status","check_result"],
|
|
|
|
data() {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
@ -688,32 +485,36 @@ export default {
|
|
|
|
// 表单校验
|
|
|
|
// 表单校验
|
|
|
|
rules: {
|
|
|
|
rules: {
|
|
|
|
incomeBatchNo: [
|
|
|
|
incomeBatchNo: [
|
|
|
|
{ required: true, message: "批次号不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "批次号不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
orderNo: [
|
|
|
|
orderNo: [
|
|
|
|
{ required: true, message: "订单号不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "订单号不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
materialName: [
|
|
|
|
materialName: [
|
|
|
|
{ required: true, message: "物料号不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "物料号不能为空", trigger: "blur" }
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
quality: [
|
|
|
|
|
|
|
|
{ required: true, message: "数量不能为空", trigger: "blur" }
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
unit: [
|
|
|
|
|
|
|
|
{ required: true, message: "单位不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
quality: [{ required: true, message: "数量不能为空", trigger: "blur" }],
|
|
|
|
|
|
|
|
unit: [{ required: true, message: "单位不能为空", trigger: "blur" }],
|
|
|
|
|
|
|
|
supplierName: [
|
|
|
|
supplierName: [
|
|
|
|
{ required: true, message: "车间不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "车间不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
incomeTime: [
|
|
|
|
incomeTime: [
|
|
|
|
{ required: true, message: "生产时间不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "生产时间不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
checkManName: [
|
|
|
|
checkManName: [
|
|
|
|
{ required: true, message: "检测人不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "检测人不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
checkLoc: [
|
|
|
|
checkLoc: [
|
|
|
|
{ required: true, message: "检测地点不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "检测地点不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
],
|
|
|
|
checkType: [
|
|
|
|
checkType: [
|
|
|
|
{ required: true, message: "检测类型不能为空", trigger: "blur" },
|
|
|
|
{ required: true, message: "检测类型不能为空", trigger: "blur" }
|
|
|
|
],
|
|
|
|
]
|
|
|
|
},
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
},
|
|
|
|
},
|
|
|
|
created() {
|
|
|
|
created() {
|
|
|
@ -726,15 +527,15 @@ export default {
|
|
|
|
/****/
|
|
|
|
/****/
|
|
|
|
//获取检验节点
|
|
|
|
//获取检验节点
|
|
|
|
getCheckTypes() {
|
|
|
|
getCheckTypes() {
|
|
|
|
getCheckTypes("produce").then((response) => {
|
|
|
|
getCheckTypes('produce').then(response => {
|
|
|
|
this.checkTypes = response;
|
|
|
|
this.checkTypes = response;
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
/**获取默认查询时间段**/
|
|
|
|
/**获取默认查询时间段**/
|
|
|
|
getDate() {
|
|
|
|
getDate() {
|
|
|
|
let start = this.Fungetdate(0);
|
|
|
|
let start = this.Fungetdate (0)
|
|
|
|
let end = this.Fungetdate(1);
|
|
|
|
let end = this.Fungetdate (1)
|
|
|
|
this.queryParams.incomeTimeArray.push(start, end);
|
|
|
|
this.queryParams.incomeTimeArray.push(start,end)
|
|
|
|
//this.queryParams.checkTimeArray.push(start,end)
|
|
|
|
//this.queryParams.checkTimeArray.push(start,end)
|
|
|
|
},
|
|
|
|
},
|
|
|
|
Fungetdate (num) {
|
|
|
|
Fungetdate (num) {
|
|
|
@ -751,24 +552,16 @@ export default {
|
|
|
|
this.loading = true;
|
|
|
|
this.loading = true;
|
|
|
|
|
|
|
|
|
|
|
|
if(this.queryParams.incomeTimeArray.length>0){
|
|
|
|
if(this.queryParams.incomeTimeArray.length>0){
|
|
|
|
this.queryParams.incomeTimeStart = moment(
|
|
|
|
this.queryParams.incomeTimeStart = moment(this.queryParams.incomeTimeArray[0]).format('YYYY-MM-DD HH:mm:ss');
|
|
|
|
this.queryParams.incomeTimeArray[0]
|
|
|
|
this.queryParams.incomeTimeEnd = moment(this.queryParams.incomeTimeArray[1]).format('YYYY-MM-DD HH:mm:ss');
|
|
|
|
).format("YYYY-MM-DD HH:mm:ss");
|
|
|
|
|
|
|
|
this.queryParams.incomeTimeEnd = moment(
|
|
|
|
|
|
|
|
this.queryParams.incomeTimeArray[1]
|
|
|
|
|
|
|
|
).format("YYYY-MM-DD HH:mm:ss");
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if(this.queryParams.checkTimeArray.length>0){
|
|
|
|
if(this.queryParams.checkTimeArray.length>0){
|
|
|
|
this.queryParams.checkTimeStart = moment(
|
|
|
|
this.queryParams.checkTimeStart = moment(this.queryParams.checkTimeArray[0]).format('YYYY-MM-DD HH:mm:ss');
|
|
|
|
this.queryParams.checkTimeArray[0]
|
|
|
|
this.queryParams.checkTimeEnd = moment(this.queryParams.checkTimeArray[1]).format('YYYY-MM-DD HH:mm:ss');
|
|
|
|
).format("YYYY-MM-DD HH:mm:ss");
|
|
|
|
|
|
|
|
this.queryParams.checkTimeEnd = moment(
|
|
|
|
|
|
|
|
this.queryParams.checkTimeArray[1]
|
|
|
|
|
|
|
|
).format("YYYY-MM-DD HH:mm:ss");
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
listQcProduce(this.queryParams).then((response) => {
|
|
|
|
listQcProduce(this.queryParams).then(response => {
|
|
|
|
this.qcProduceList = response.rows;
|
|
|
|
this.qcProduceList = response.rows;
|
|
|
|
this.total = response.total;
|
|
|
|
this.total = response.total;
|
|
|
|
this.loading = false;
|
|
|
|
this.loading = false;
|
|
|
@ -810,7 +603,7 @@ export default {
|
|
|
|
updateTime: null,
|
|
|
|
updateTime: null,
|
|
|
|
factoryCode: null,
|
|
|
|
factoryCode: null,
|
|
|
|
delFlag: null,
|
|
|
|
delFlag: null,
|
|
|
|
defects: [],
|
|
|
|
defects: []
|
|
|
|
};
|
|
|
|
};
|
|
|
|
this.resetForm("form");
|
|
|
|
this.resetForm("form");
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -826,9 +619,9 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// 多选框选中数据
|
|
|
|
// 多选框选中数据
|
|
|
|
handleSelectionChange(selection) {
|
|
|
|
handleSelectionChange(selection) {
|
|
|
|
this.ids = selection.map((item) => item.recordId);
|
|
|
|
this.ids = selection.map(item => item.recordId)
|
|
|
|
this.single = selection.length !== 1;
|
|
|
|
this.single = selection.length!==1
|
|
|
|
this.multiple = !selection.length;
|
|
|
|
this.multiple = !selection.length
|
|
|
|
},
|
|
|
|
},
|
|
|
|
/** 新增按钮操作 */
|
|
|
|
/** 新增按钮操作 */
|
|
|
|
handleAdd() {
|
|
|
|
handleAdd() {
|
|
|
@ -836,36 +629,34 @@ export default {
|
|
|
|
this.form.defects = this.defectTypeList;
|
|
|
|
this.form.defects = this.defectTypeList;
|
|
|
|
this.open = true;
|
|
|
|
this.open = true;
|
|
|
|
this.title = "添加生产过程检验任务";
|
|
|
|
this.title = "添加生产过程检验任务";
|
|
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
/** 修改按钮操作 */
|
|
|
|
/** 修改按钮操作 */
|
|
|
|
handleUpdate(row) {
|
|
|
|
handleUpdate(row) {
|
|
|
|
this.reset();
|
|
|
|
this.reset();
|
|
|
|
const recordId = row.recordId || this.ids;
|
|
|
|
const recordId = row.recordId || this.ids
|
|
|
|
getQcProduce(recordId).then((response) => {
|
|
|
|
getQcProduce(recordId).then(response => {
|
|
|
|
this.form = response.data;
|
|
|
|
this.form = response.data;
|
|
|
|
if (this.form.defects == null) {
|
|
|
|
|
|
|
|
this.form.defects = this.defectTypeList;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
this.open = true;
|
|
|
|
this.open = true;
|
|
|
|
this.title = "修改生产过程检验任务";
|
|
|
|
this.title = "修改生产过程检验任务";
|
|
|
|
|
|
|
|
|
|
|
|
getBatchList(response.data.orderNo).then((response) => {
|
|
|
|
getBatchList(response.data.orderNo).then(response => {
|
|
|
|
this.batchList = response;
|
|
|
|
this.batchList = response;
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
/** 提交按钮 */
|
|
|
|
/** 提交按钮 */
|
|
|
|
submitForm() {
|
|
|
|
submitForm() {
|
|
|
|
this.$refs["form"].validate((valid) => {
|
|
|
|
this.$refs["form"].validate(valid => {
|
|
|
|
if (valid) {
|
|
|
|
if (valid) {
|
|
|
|
if (this.form.recordId != null) {
|
|
|
|
if (this.form.recordId != null) {
|
|
|
|
updateQcProduce(this.form).then((response) => {
|
|
|
|
updateQcProduce(this.form).then(response => {
|
|
|
|
this.$modal.msgSuccess("修改成功");
|
|
|
|
this.$modal.msgSuccess("修改成功");
|
|
|
|
this.open = false;
|
|
|
|
this.open = false;
|
|
|
|
this.getList();
|
|
|
|
this.getList();
|
|
|
|
});
|
|
|
|
});
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
addQcProduce(this.form).then((response) => {
|
|
|
|
addQcProduce(this.form).then(response => {
|
|
|
|
this.open = false;
|
|
|
|
this.open = false;
|
|
|
|
this.getList();
|
|
|
|
this.getList();
|
|
|
|
});
|
|
|
|
});
|
|
|
@ -876,41 +667,27 @@ export default {
|
|
|
|
/** 删除按钮操作 */
|
|
|
|
/** 删除按钮操作 */
|
|
|
|
handleDelete(row) {
|
|
|
|
handleDelete(row) {
|
|
|
|
const recordIds = row.recordId || this.ids;
|
|
|
|
const recordIds = row.recordId || this.ids;
|
|
|
|
this.$modal
|
|
|
|
this.$modal.confirm('是否确认删除生产过程检验任务编号为"' + recordIds + '"的数据项?').then(function() {
|
|
|
|
.confirm(
|
|
|
|
|
|
|
|
'是否确认删除生产过程检验任务编号为"' + recordIds + '"的数据项?'
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
.then(function () {
|
|
|
|
|
|
|
|
return delQcProduce(recordIds);
|
|
|
|
return delQcProduce(recordIds);
|
|
|
|
})
|
|
|
|
}).then(() => {
|
|
|
|
.then(() => {
|
|
|
|
|
|
|
|
this.getList();
|
|
|
|
this.getList();
|
|
|
|
this.$modal.msgSuccess("删除成功");
|
|
|
|
this.$modal.msgSuccess("删除成功");
|
|
|
|
})
|
|
|
|
}).catch(() => {});
|
|
|
|
.catch(() => {});
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
/** 导出按钮操作 */
|
|
|
|
/** 导出按钮操作 */
|
|
|
|
handleExport() {
|
|
|
|
handleExport() {
|
|
|
|
this.download(
|
|
|
|
this.download('quality/qcProduce/export', {
|
|
|
|
"quality/qcProduce/export",
|
|
|
|
...this.queryParams
|
|
|
|
{
|
|
|
|
}, `qcProduce_${new Date().getTime()}.xlsx`)
|
|
|
|
...this.queryParams,
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
`qcProduce_${new Date().getTime()}.xlsx`
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// 数据状态修改
|
|
|
|
// 数据状态修改
|
|
|
|
handleStatusChange(row) {
|
|
|
|
handleStatusChange(row) {
|
|
|
|
let text = row.status === "0" ? "停用" : "启用";
|
|
|
|
let text = row.status === "0" ? "停用" : "启用";
|
|
|
|
this.$modal
|
|
|
|
this.$modal.confirm('确认要"' + text + '""' + row.checkNo + '"吗?').then(function() {
|
|
|
|
.confirm('确认要"' + text + '""' + row.checkNo + '"吗?')
|
|
|
|
|
|
|
|
.then(function () {
|
|
|
|
|
|
|
|
return changeProduceStatus(row.recordId, row.status);
|
|
|
|
return changeProduceStatus(row.recordId, row.status);
|
|
|
|
})
|
|
|
|
}).then(() => {
|
|
|
|
.then(() => {
|
|
|
|
|
|
|
|
this.$modal.msgSuccess(text + "成功");
|
|
|
|
this.$modal.msgSuccess(text + "成功");
|
|
|
|
})
|
|
|
|
}).catch(function() {
|
|
|
|
.catch(function () {
|
|
|
|
|
|
|
|
row.status = row.status === "0" ? "1" : "0";
|
|
|
|
row.status = row.status === "0" ? "1" : "0";
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -927,7 +704,7 @@ export default {
|
|
|
|
this.form.quality = obj.quality;
|
|
|
|
this.form.quality = obj.quality;
|
|
|
|
this.form.unit = obj.unit;
|
|
|
|
this.form.unit = obj.unit;
|
|
|
|
this.form.incomeTime = obj.incomeTime;
|
|
|
|
this.form.incomeTime = obj.incomeTime;
|
|
|
|
getBatchList(obj.workorderCode).then((response) => {
|
|
|
|
getBatchList(obj.workorderCode).then(response => {
|
|
|
|
this.batchList = response;
|
|
|
|
this.batchList = response;
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -953,29 +730,29 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
//检验项目弹窗
|
|
|
|
//检验项目弹窗
|
|
|
|
handleCheckProject(row){
|
|
|
|
handleCheckProject(row){
|
|
|
|
if (row.checkStatus != "0") {
|
|
|
|
if(row.checkStatus != '0'){
|
|
|
|
this.$modal.msgSuccess("已经完成检验");
|
|
|
|
this.$modal.msgSuccess("已经完成检验");
|
|
|
|
return;
|
|
|
|
return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
this.$refs.itemSelectProject.showFlag = true;
|
|
|
|
this.$refs.itemSelectProject.showFlag = true;
|
|
|
|
this.$refs.itemSelectProject.init(row, "produce");
|
|
|
|
this.$refs.itemSelectProject.init(row,'produce');
|
|
|
|
},
|
|
|
|
},
|
|
|
|
//查看检验项目弹窗
|
|
|
|
//查看检验项目弹窗
|
|
|
|
handleView(row){
|
|
|
|
handleView(row){
|
|
|
|
this.$refs.itemSelectProject.showFlag = true;
|
|
|
|
this.$refs.itemSelectProject.showFlag = true;
|
|
|
|
this.$refs.itemSelectProject.init(row, "produce");
|
|
|
|
this.$refs.itemSelectProject.init(row,'produce');
|
|
|
|
},
|
|
|
|
},
|
|
|
|
//提交检测结果
|
|
|
|
//提交检测结果
|
|
|
|
saveCheck(){
|
|
|
|
saveCheck(){
|
|
|
|
this.getList();
|
|
|
|
this.getList();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
handleDefectType() {
|
|
|
|
handleDefectType() {
|
|
|
|
const defectType = "produce";
|
|
|
|
const defectType = "produce"
|
|
|
|
getDefectTypeListByDefectType(defectType).then((response) => {
|
|
|
|
getDefectTypeListByDefectType(defectType).then(response => {
|
|
|
|
this.defectTypeList = response.rows;
|
|
|
|
this.defectTypeList = response.rows;
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
}
|
|
|
|
},
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
</script>
|
|
|
|