Commit 19ee064f authored by hubaoshan's avatar hubaoshan

液体出入库

parent 7b8054c8
......@@ -4,7 +4,7 @@ import { getInfo } from '@/api/login'
import Layout from '@/layout/index'
// pathList: 是要隐藏菜单的集合 system元素:一级菜单的路径(path)
const pathList = ['/setup/index', '/setup/outku', '/setup/enterbound', '/setup/test', '/setup/enterboundTwo', '/setup/ApplicationTable', '/setup/inspectionRequestProcessing', '/setup/checkTheApplicationForExit',
'/setup/enterboundPd', '/setup/Warehousing']
'/setup/enterboundPd', '/setup/Warehousing', '/setup/storage', '/setup/dealWithStorage']
const permission = {
state: {
routes: [],
......
......@@ -142,6 +142,7 @@
<span v-else-if="scope.row.ptype === '3'">wd</span>
<span v-else-if="scope.row.ptype === '4'">sl</span>
<span v-else-if="scope.row.ptype === '5'">zd</span>
<span v-else-if="scope.row.ptype === '20'">jl</span>
<span v-else-if="scope.row.ptype === '30'">che</span>
<span v-else>-</span>
</template>
......@@ -250,6 +251,7 @@
<span v-else-if="singleDetails.ptype === '3'">wd</span>
<span v-else-if="singleDetails.ptype === '4'">sl</span>
<span v-else-if="singleDetails.ptype === '5'">zd</span>
<span v-else-if="singleDetails.ptype === '20'">jl</span>
<span v-else-if="singleDetails.ptype === '30'">che</span>
<span v-else>-</span>
<!-- <el-input v-model.trim="singleDetails.ptype" :readonly="true" />-->
......
......@@ -294,7 +294,7 @@
</el-col>
<el-col :span="12">
<el-form-item label="cj:" prop="cj">
<span>{{ getManufacturerLabel( singleDetails.cj)|| '-' }}</span>
<span>{{ getManufacturerLabel( singleDetails.cj) || '-' }}</span>
</el-form-item>
</el-col>
</el-row>
......
......@@ -149,9 +149,8 @@
<el-table-column label="wh_id" prop="whId" :show-overflow-tooltip="true">
<template slot-scope="scope">
<!-- 假设字典数据存储在 dataDict 中 -->
<span v-if="scope.row.whId &&getDataDictLabel(scope.row.whId) ">{{
getDataDictLabel(scope.row.whId)
}}</span>
<span v-if="scope.row.whId &&getDataDictLabel(scope.row.whId) ">
{{ getDataDictLabel(scope.row.whId) }}</span>
<span v-else>-</span>
</template>
</el-table-column>
......@@ -186,7 +185,8 @@
</el-table-column>
<el-table-column label="qty" prop="qty" :show-overflow-tooltip="true">
<template slot-scope="scope">
{{ scope.row.qty || '-' }}
<span v-if="scope.row.ptype === '1'"> {{ scope.row.qty|| '-' }}</span>
<span v-else> {{ scope.row.qty /1000 }}KG</span>
</template>
</el-table-column>
<el-table-column label="rank" prop="rank" :show-overflow-tooltip="true">
......@@ -317,7 +317,7 @@
@input="handleInputChange"
/>
</el-form-item>
<el-form-item label="lot" prop="lot">
<el-form-item label="lot" prop="lot" :rules="[{required: form.ptype === '1', message: '请输入lot的值', trigger: 'blur' }]">
<el-input
v-model.trim="form.lot"
show-word-limit
......@@ -463,7 +463,11 @@
</el-col>
<el-col :span="12">
<el-form-item label="qty:" prop="qty">
<span>{{ singleDetails.qty|| '-' }}</span>
<!-- <span>{{ singleDetails.qty|| '-' }}</span>-->
<template slot-scope="scope">
<span v-if="scope.row.ptype === '1'"> {{ singleDetails.qty|| '-' }}</span>
<span v-else> {{ singleDetails.qty /1000 }}KG</span>
</template>
</el-form-item>
</el-col>
</el-row>
......@@ -533,22 +537,23 @@
<script>
import {
listOutcomeWmsJbapplyTemp,
getOutcomeWmsJbapplyTemp,
delOutcomeWmsJbapplyTemp,
acquireOrderByCode,
addOutcomeWmsJbapplyTemp,
updateOutcomeWmsJbapplyTemp,
delOutcomeWmsJbapplyTemp,
exportOutcomeWmsJbapplyTemp,
findListOutTemp,
getDownloadTemplate,
getOutcomeWmsJbapplyTemp,
importJbapplyExcel,
listOutcomeWmsJbapplyTemp,
queryByPnAndPtypeAndLot,
acquireOrderByCode,
findListOutTemp
updateOutcomeWmsJbapplyTemp
} from '@/api/outcomeWmsJbapplyTemp'
import commonField from '@/utils/commonField'
import { getDicts } from '@/api/system/dict/data'
import { getToken } from '@/utils/auth'
import manufacturer from '@/data/cjlist'
export default {
name: 'OutcomeWmsJbapplyTemp',
data() {
......@@ -700,15 +705,16 @@ export default {
pn: [
{ required: true, message: '请输入pn的值', trigger: 'blur' }
],
lot: [
{ required: true, message: '请输入lot的值', trigger: 'blur' }
],
// lot: [
// { required: true, message: '请输入lot的值', trigger: 'blur' }
// ],
orderCode: [
{ required: true, message: '请输入code的值', trigger: 'blur' }
],
qty: [
{ required: true, message: '请输入qty的值', trigger: 'blur' },
{ pattern: /^(0|[1-9]\d*)$/, message: '输入值不符合格式要求,请重新输入', trigger: 'blur' }
// { pattern: /^(0|[1-9]\d*)$/, message: '输入值不符合格式要求,请重新输入', trigger: 'blur' }
{ pattern: /^(0|[1-9]\d*)(\.\d{0,1})?$/, message: '输入值不符合格式要求,请重新输入', trigger: 'blur' }
]
}
}
......@@ -909,6 +915,7 @@ export default {
}
})
this.singleDetails = row
console.log('12', this.singleDetails)
this.title = '详情信息'
this.openDetails = !this.openDetails
this.isShow = false
......@@ -1022,6 +1029,9 @@ export default {
getOutcomeWmsJbapplyTemp(id).then(response => {
this.ptype = response.data.ptype
this.form = response.data
if (this.ptype === '20') {
this.form.qty = response.data.qty / 1000
}
this.open = true
this.title = '修改检查申请'
this.queryQty()
......@@ -1050,17 +1060,41 @@ export default {
this.$refs['form'].validate(valid => {
if (valid) {
if (this.form.businessId !== undefined) {
updateOutcomeWmsJbapplyTemp(this.form).then(response => {
this.msgSuccess('修改成功')
this.open = false
this.getList()
})
if (this.form.ptype === '20') {
const obj = {
...this.form,
qty: this.form.qty * 1000
}
updateOutcomeWmsJbapplyTemp(obj).then(response => {
this.msgSuccess('修改成功')
this.open = false
this.getList()
})
} else {
updateOutcomeWmsJbapplyTemp(this.form).then(response => {
this.msgSuccess('修改成功')
this.open = false
this.getList()
})
}
} else {
addOutcomeWmsJbapplyTemp(this.form).then(response => {
this.msgSuccess('新增成功')
this.open = false
this.getList()
})
if (this.form.ptype === '20') {
const obj = {
...this.form,
qty: this.form.qty * 1000
}
addOutcomeWmsJbapplyTemp(obj).then(response => {
this.msgSuccess('新增成功')
this.open = false
this.getList()
})
} else {
addOutcomeWmsJbapplyTemp(this.form).then(response => {
this.msgSuccess('新增成功')
this.open = false
this.getList()
})
}
}
}
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment