fix:半成品添加两个不合格体原因(颜色青和杂志)添加备注
This commit is contained in:
parent
bb7b2817e0
commit
29de95414a
|
|
@ -45,70 +45,165 @@
|
|||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="不合格数" prop="count_notok">
|
||||
<el-input-number v-model="form.count_notok" :min="0" style="width:100%" disabled controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_notok"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
disabled
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="炸纹">
|
||||
<el-input-number v-model="form.count_n_zw" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_zw"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="条纹">
|
||||
<el-input-number v-model="form.count_n_tw" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_tw"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="气泡">
|
||||
<el-input-number v-model="form.count_n_qp" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_qp"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="弯曲">
|
||||
<el-input-number v-model="form.count_n_wq" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_wq"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="断裂">
|
||||
<el-input-number v-model="form.count_n_dl" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_dl"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="偏壁">
|
||||
<el-input-number v-model="form.count_n_pb" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_pb"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="大小头">
|
||||
<el-input-number v-model="form.count_n_dxt" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_dxt"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="结石">
|
||||
<el-input-number v-model="form.count_n_js" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_js"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="气线">
|
||||
<el-input-number v-model="form.count_n_qx" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_qx"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="杂质">
|
||||
<el-input-number
|
||||
v-model="form.count_n_zz"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="颜色青">
|
||||
<el-input-number
|
||||
v-model="form.count_n_ysq"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="其他">
|
||||
<el-input-number v-model="form.count_n_qt" @change="countNotOkSun" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_n_qt"
|
||||
@change="countNotOkSun"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="备注">
|
||||
<el-input v-model="form.note"> </el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<!-- 成品 -->
|
||||
<el-row v-if="type == 'do_in' && cate == 'good'">
|
||||
|
|
@ -134,11 +229,21 @@
|
|||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="抽检数">
|
||||
<el-input-number v-model="form.count" :min="0" style="width:100%" @change="countChange" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
@change="countChange"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!-- 预制棒 -->
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="备注">
|
||||
<el-input v-model="form.note"> </el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<sc-form-table
|
||||
v-model="form.ftestitems"
|
||||
:addTemplate="addTemplate"
|
||||
|
|
@ -146,55 +251,116 @@
|
|||
>
|
||||
<el-table-column prop="val" label="抽检编号">
|
||||
<template #default="scope">
|
||||
<span v-if="scope.row.id">{{scope.row.name}}</span>
|
||||
<el-input v-else v-model="scope.row.name" placeholder="名称"></el-input>
|
||||
<span v-if="scope.row.id">{{
|
||||
scope.row.name
|
||||
}}</span>
|
||||
<el-input
|
||||
v-else
|
||||
v-model="scope.row.name"
|
||||
placeholder="名称"
|
||||
></el-input>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="检验记录" align="center">
|
||||
<el-table-column prop="test_val" label="长度/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="长度/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="直径/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="直径/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="椭圆度/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="椭圆度/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="锥度/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="锥度/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="结石、沙石、黑点">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="结石、沙石、黑点"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="条纹">
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="气泡">
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="合格判定" min-width="120" align="center">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="合格判定"
|
||||
min-width="120"
|
||||
align="center"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-select
|
||||
v-model="scope.row.is_ok"
|
||||
|
|
@ -207,7 +373,12 @@
|
|||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_user" label="检验人" min-width="120" align="center">
|
||||
<el-table-column
|
||||
prop="test_user"
|
||||
label="检验人"
|
||||
min-width="120"
|
||||
align="center"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-select
|
||||
v-model="scope.row.test_user"
|
||||
|
|
@ -224,14 +395,20 @@
|
|||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="open" label="操作" width="80" align="center">
|
||||
<el-table-column
|
||||
prop="open"
|
||||
label="操作"
|
||||
width="80"
|
||||
align="center"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
text
|
||||
type="danger"
|
||||
size="small"
|
||||
@click="userPostDel(scope.row.id)"
|
||||
>删除</el-button>
|
||||
>删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</sc-form-table>
|
||||
|
|
@ -243,79 +420,169 @@
|
|||
>
|
||||
<el-table-column prop="val" label="抽检编号">
|
||||
<template #default="scope">
|
||||
<span v-if="scope.row.id">{{scope.row.name}}</span>
|
||||
<el-input v-else v-model="scope.row.name" placeholder="名称"></el-input>
|
||||
<span v-if="scope.row.id">{{
|
||||
scope.row.name
|
||||
}}</span>
|
||||
<el-input
|
||||
v-else
|
||||
v-model="scope.row.name"
|
||||
placeholder="名称"
|
||||
></el-input>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="检验记录" align="center">
|
||||
<el-table-column prop="test_val" label="长度/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="长度/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="内径/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="内径/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="椭圆度/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="椭圆度/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="壁厚/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="壁厚/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="壁厚偏差/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="壁厚偏差/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="锥度/mm">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="锥度/mm"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="气泡(线)">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="气泡(线)"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="结石、杂志">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="结石、杂志"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="条纹">
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="划伤">
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="水雾">
|
||||
<template #default="scope">
|
||||
<el-input-number v-model="scope.row.test_val" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="scope.row.test_val"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_val" label="合格判定" min-width="120" align="center">
|
||||
<el-table-column
|
||||
prop="test_val"
|
||||
label="合格判定"
|
||||
min-width="120"
|
||||
align="center"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-select
|
||||
v-model="scope.row.is_ok"
|
||||
|
|
@ -328,7 +595,12 @@
|
|||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="test_user" label="检验人" min-width="120" align="center">
|
||||
<el-table-column
|
||||
prop="test_user"
|
||||
label="检验人"
|
||||
min-width="120"
|
||||
align="center"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-select
|
||||
v-model="scope.row.test_user"
|
||||
|
|
@ -345,14 +617,20 @@
|
|||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="open" label="操作" width="80" align="center">
|
||||
<el-table-column
|
||||
prop="open"
|
||||
label="操作"
|
||||
width="80"
|
||||
align="center"
|
||||
>
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
text
|
||||
type="danger"
|
||||
size="small"
|
||||
@click="userPostDel(scope.row.id)"
|
||||
>删除</el-button>
|
||||
>删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</sc-form-table>
|
||||
|
|
@ -371,13 +649,22 @@
|
|||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="总袋(桶)数:">
|
||||
<el-input-number v-model="form.count_bag" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_bag"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="抽样数量">
|
||||
<el-input v-model="form.weight_kgs_count" disabled placeholder="抽样数量"/>
|
||||
<el-input
|
||||
v-model="form.weight_kgs_count"
|
||||
disabled
|
||||
placeholder="抽样数量"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
|
|
@ -423,21 +710,48 @@
|
|||
</el-col>
|
||||
<el-col :md="12" :sm="24">
|
||||
<el-form-item label="抽样计算总重量/Kg">
|
||||
<el-input-number v-model="form.count_bag_weight_all" :min="0" style="width:100%" controls-position="right">
|
||||
<el-input-number
|
||||
v-model="form.count_bag_weight_all"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
controls-position="right"
|
||||
>
|
||||
</el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col>
|
||||
<el-form-item label="称重记录/Kg">
|
||||
<el-button type="primary" icon="el-icon-plus" @click="addWeight"></el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
@click="addWeight"
|
||||
></el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :md="12" :sm="24" v-for="(item,ind) in weight_kgs" :key="item" style="position:relative">
|
||||
<el-col
|
||||
:md="12"
|
||||
:sm="24"
|
||||
v-for="(item, ind) in weight_kgs"
|
||||
:key="item"
|
||||
style="position: relative"
|
||||
>
|
||||
<el-form-item :label-width="50">
|
||||
<el-input-number v-model="item.value" :min="0" style="width:90%" controls-position="right" @change="countSun"/>
|
||||
<el-input-number
|
||||
v-model="item.value"
|
||||
:min="0"
|
||||
style="width: 90%"
|
||||
controls-position="right"
|
||||
@change="countSun"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-button @click="delWeight(ind)" type="danger" icon="el-icon-delete" circle style="position:absolute;right:-10px;top:0"/>
|
||||
<el-button
|
||||
@click="delWeight(ind)"
|
||||
type="danger"
|
||||
icon="el-icon-delete"
|
||||
circle
|
||||
style="position: absolute; right: -10px; top: 0"
|
||||
/>
|
||||
</el-col>
|
||||
<!-- <el-col :md="12" :sm="24">
|
||||
<el-form-item label="合同采购量/Kg">
|
||||
|
|
@ -462,7 +776,9 @@
|
|||
</el-form>
|
||||
</el-main>
|
||||
<el-footer v-if="mode == 'add'">
|
||||
<el-button type="primary" :loading="isSaveing" @click="submit">保存</el-button>
|
||||
<el-button type="primary" :loading="isSaveing" @click="submit"
|
||||
>保存</el-button
|
||||
>
|
||||
<el-button @click="visible = false">取消</el-button>
|
||||
</el-footer>
|
||||
</el-container>
|
||||
|
|
@ -492,9 +808,27 @@ export default {
|
|||
ftestitems: [],
|
||||
},
|
||||
rules: {
|
||||
test_date: [{required: true, message: "请选择检验日期", trigger: "blur"}],
|
||||
test_user: [{required: true, message: "请选择检验人", trigger: "blur"}],
|
||||
count_notok: [{required: true, message: "请填写不合格数", trigger: "blur"}],
|
||||
test_date: [
|
||||
{
|
||||
required: true,
|
||||
message: "请选择检验日期",
|
||||
trigger: "blur",
|
||||
},
|
||||
],
|
||||
test_user: [
|
||||
{
|
||||
required: true,
|
||||
message: "请选择检验人",
|
||||
trigger: "blur",
|
||||
},
|
||||
],
|
||||
count_notok: [
|
||||
{
|
||||
required: true,
|
||||
message: "请填写不合格数",
|
||||
trigger: "blur",
|
||||
},
|
||||
],
|
||||
},
|
||||
mioItem: {},
|
||||
weight_kgs: [{ value: 0 }],
|
||||
|
|
@ -512,13 +846,13 @@ export default {
|
|||
mounted() {
|
||||
this.getUserList();
|
||||
let that = this;
|
||||
if(that.type=='pur_in'){
|
||||
console.log('objitem',that.objitem)
|
||||
if (that.type == "pur_in") {
|
||||
console.log("objitem", that.objitem);
|
||||
that.form.material_name = that.objitem.material_name;
|
||||
that.form.batch = that.objitem.batch;
|
||||
that.form.count_bag = that.objitem.count_bag;
|
||||
}
|
||||
if(that.type=='do_in'&&that.cate=='halfgood'){
|
||||
if (that.type == "do_in" && that.cate == "halfgood") {
|
||||
this.form.count_notok = 0;
|
||||
this.form.count_n_zw = 0;
|
||||
this.form.count_n_tw = 0;
|
||||
|
|
@ -529,8 +863,33 @@ export default {
|
|||
this.form.count_n_dxt = 0;
|
||||
this.form.count_n_js = 0;
|
||||
this.form.count_n_qx = 0;
|
||||
this.form.count_n_ysq = 0;
|
||||
this.form.count_n_zz = 0;
|
||||
this.form.count_n_qt = 0;
|
||||
}
|
||||
// if (that.type == "do_in" && that.cate == "good") {
|
||||
// this.form.count_notok = 0;
|
||||
// this.form.count_n_hs = 0;
|
||||
// this.form.count_n_zs = 0;
|
||||
// this.form.count_n_zz = 0;
|
||||
// this.form.count_n_tw = 0;
|
||||
// this.form.count_n_d = 0;
|
||||
// this.form.count_n_zdd = 0;
|
||||
// //棒
|
||||
// this.form.count_n_qp = 0;
|
||||
// this.form.count_n_bl = 0;
|
||||
// this.form.count_n_hw = 0;
|
||||
// this.form.count_n_yp = 0;
|
||||
// this.form.count_n_bp = 0;
|
||||
// this.form.count_n_sc = 0;
|
||||
// //管
|
||||
// this.form.count_n_qx = 0;
|
||||
// this.form.count_n_js = 0;
|
||||
// this.form.count_n_tydu = 0;
|
||||
// this.form.count_n_sw = 0;
|
||||
// this.form.count_n_bhpcd = 0;
|
||||
// this.form.count_n_w = 0;
|
||||
// }
|
||||
},
|
||||
methods: {
|
||||
//显示
|
||||
|
|
@ -542,8 +901,10 @@ export default {
|
|||
//获取员工
|
||||
getUserList() {
|
||||
let that = this;
|
||||
this.$API.system.user.list.req({page_size:20,page:1}).then(res=>{
|
||||
that.userList = res.results;
|
||||
this.$API.system.user.list
|
||||
.req({ page: 0, belong_dept__name: "检验管理部" })
|
||||
.then((res) => {
|
||||
that.userList = res;
|
||||
});
|
||||
},
|
||||
addWeight() {
|
||||
|
|
@ -557,15 +918,14 @@ export default {
|
|||
countSun() {
|
||||
let that = this;
|
||||
let sum = 0;
|
||||
console.log('change')
|
||||
that.weight_kgs.forEach(item=>{
|
||||
console.log("change");
|
||||
that.weight_kgs.forEach((item) => {
|
||||
sum = sum + item.value;
|
||||
})
|
||||
that.form.count_bag_weight_all = sum/that.weight_kgs.length*that.form.count_bag;
|
||||
},
|
||||
countChange(){
|
||||
|
||||
});
|
||||
that.form.count_bag_weight_all =
|
||||
(sum / that.weight_kgs.length) * that.form.count_bag;
|
||||
},
|
||||
countChange() {},
|
||||
countNotOkSun() {
|
||||
this.form.count_notok =
|
||||
this.form.count_n_zw +
|
||||
|
|
@ -586,34 +946,37 @@ export default {
|
|||
if (valid) {
|
||||
that.isSaveing = true;
|
||||
try {
|
||||
if(that.type=='pur_in'){
|
||||
if (that.type == "pur_in") {
|
||||
console.log(that.form);
|
||||
let arr = [];
|
||||
that.weight_kgs.forEach(item=>{
|
||||
that.weight_kgs.forEach((item) => {
|
||||
arr.push(item.value);
|
||||
})
|
||||
});
|
||||
let obj = {};
|
||||
obj.test_date = that.form.test_date;
|
||||
obj.test_user = that.form.test_user;
|
||||
obj.count_bag = that.objitem.count_bag;
|
||||
obj.weight_kgs = arr;
|
||||
obj.is_testok = that.form.is_testok;
|
||||
console.log(obj)
|
||||
that.$API.inm.mioitem.testpurin.req(that.mioitemId,obj).then(res=>{
|
||||
console.log(obj);
|
||||
that.$API.inm.mioitem.testpurin
|
||||
.req(that.mioitemId, obj)
|
||||
.then((res) => {
|
||||
that.isSaveing = false;
|
||||
that.$emit("success");
|
||||
that.visible = false;
|
||||
that.$message.success("操作成功");
|
||||
})
|
||||
});
|
||||
} else {
|
||||
that.$API.inm.mioitem.test.req(that.mioitemId,that.form).then(res=>{
|
||||
that.$API.inm.mioitem.test
|
||||
.req(that.mioitemId, that.form)
|
||||
.then((res) => {
|
||||
that.isSaveing = false;
|
||||
that.$emit("success");
|
||||
that.visible = false;
|
||||
that.$message.success("操作成功");
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
} catch (err) {
|
||||
//可以处理校验错误
|
||||
this.isSaveing = false;
|
||||
|
|
@ -628,8 +991,8 @@ export default {
|
|||
Object.assign(that.form, data);
|
||||
// that.form.test_group = that.form.split(',');
|
||||
that.weight_kgs = [];
|
||||
console.log(data.count_bag)
|
||||
console.log(data.weight_kgs)
|
||||
console.log(data.count_bag);
|
||||
console.log(data.weight_kgs);
|
||||
if (data.weight_kgs.length > 0) {
|
||||
that.form.weight_kgs_count = data.weight_kgs.length;
|
||||
let sum = 0;
|
||||
|
|
@ -637,11 +1000,11 @@ export default {
|
|||
sum = sum + item;
|
||||
let obj = {};
|
||||
obj.value = item;
|
||||
that.weight_kgs.push(obj)
|
||||
})
|
||||
that.form.count_bag_weight_all =sum/data.weight_kgs.length*data.count_bag;
|
||||
that.weight_kgs.push(obj);
|
||||
});
|
||||
that.form.count_bag_weight_all =
|
||||
(sum / data.weight_kgs.length) * data.count_bag;
|
||||
}
|
||||
|
||||
},
|
||||
//设置过滤项
|
||||
setFilters(filters) {
|
||||
|
|
@ -652,5 +1015,4 @@ export default {
|
|||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
<style></style>
|
||||
|
|
|
|||
Loading…
Reference in New Issue