半成品出库
This commit is contained in:
@@ -15,7 +15,10 @@ export const authority = () => {
|
|||||||
path: 'RF02',
|
path: 'RF02',
|
||||||
name: '半成品管理',
|
name: '半成品管理',
|
||||||
sonTree: [
|
sonTree: [
|
||||||
{menu_id: '1', name: '半成品入库', path: '/semifinishedinstore'}
|
{menu_id: '1', name: '半成品入库', path: '/semifinishedinstore'},
|
||||||
|
{menu_id: '2', name: '半成品出库', path: '/semifinishedoutstore'},
|
||||||
|
{menu_id: '3', name: '半成品盘点', path: '/semifinishedcheck'},
|
||||||
|
{menu_id: '4', name: '半成品拼盘', path: '/semifinishedcomposesearch'}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{menu_id: '3',
|
{menu_id: '3',
|
||||||
|
|||||||
@@ -2,19 +2,6 @@
|
|||||||
<div class="order-wraper">
|
<div class="order-wraper">
|
||||||
<div class="search-confirm-wrap">
|
<div class="search-confirm-wrap">
|
||||||
<div class="search-wrap">
|
<div class="search-wrap">
|
||||||
<!-- <div class="search-item">
|
|
||||||
<div class="search-label">类别</div>
|
|
||||||
<div class="filter_input_wraper">
|
|
||||||
<el-select v-model="value1" filterable clearable placeholder="请选择">
|
|
||||||
<el-option
|
|
||||||
v-for="item in options1"
|
|
||||||
:key="item.stor_id"
|
|
||||||
:label="item.stor_name"
|
|
||||||
:value="item.stor_id">
|
|
||||||
</el-option>
|
|
||||||
</el-select>
|
|
||||||
</div>
|
|
||||||
</div> -->
|
|
||||||
<div class="search-item">
|
<div class="search-item">
|
||||||
<div class="search-label">货位</div>
|
<div class="search-label">货位</div>
|
||||||
<div class="filter_input_wraper">
|
<div class="filter_input_wraper">
|
||||||
|
|||||||
@@ -15,12 +15,12 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="search-item">
|
<div class="search-item search-item_2">
|
||||||
<div class="search-label search-label_1">日期</div>
|
<div class="search-label">日期</div>
|
||||||
<div class="filter_input_wraper filter_input_wraper_1">
|
<div class="filter_input_wraper">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="date"
|
v-model="date"
|
||||||
type="daterange"
|
type="datetimerange"
|
||||||
range-separator="-"
|
range-separator="-"
|
||||||
start-placeholder="开始日期"
|
start-placeholder="开始日期"
|
||||||
end-placeholder="结束日期">
|
end-placeholder="结束日期">
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
<input type="text" class="filter-input">
|
<input type="text" class="filter-input">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="search-item flexend">
|
<div class="search-item flexend" style="width: 100%">
|
||||||
<button class="button button--primary" @click="_getAll">查询</button>
|
<button class="button button--primary" @click="_getAll">查询</button>
|
||||||
<button class="button button--primary" :disabled="disabled1" :class="{'button--defalut': pkId === ''}" @click="toSure">强制确认</button>
|
<button class="button button--primary" :disabled="disabled1" :class="{'button--defalut': pkId === ''}" @click="toSure">强制确认</button>
|
||||||
</div>
|
</div>
|
||||||
@@ -106,6 +106,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {getBcpStor, getBillType, getAll, bcpInConfirm} from '@config/getData2.js'
|
import {getBcpStor, getBillType, getAll, bcpInConfirm} from '@config/getData2.js'
|
||||||
|
import {dateFtt} from '@config/utils.js'
|
||||||
export default {
|
export default {
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@@ -140,7 +141,7 @@ export default {
|
|||||||
},
|
},
|
||||||
// grid
|
// grid
|
||||||
async _getAll () {
|
async _getAll () {
|
||||||
let res = await getAll(this.value1, this.date[0], this.date[1], this.material_code, this.storagevehicle_code, this.value2)
|
let res = await getAll(this.value1, this.date !== null ? dateFtt(this.date[0]) : '', this.date !== null ? dateFtt(this.date[1]) : '', this.material_code, this.storagevehicle_code, this.value2)
|
||||||
this.dataList = [...res.data]
|
this.dataList = [...res.data]
|
||||||
},
|
},
|
||||||
toRadio (e) {
|
toRadio (e) {
|
||||||
@@ -168,8 +169,15 @@ export default {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="stylus" scoped>
|
<style lang="stylus" scoped>
|
||||||
|
.search-item
|
||||||
|
&:nth-child(2), &:nth-child(5)
|
||||||
|
margin-right 0
|
||||||
|
&:nth-child(4)
|
||||||
|
margin-left 2%
|
||||||
|
.search-item_2
|
||||||
|
width 66%
|
||||||
.grid_wraper
|
.grid_wraper
|
||||||
height calc(100% - 95px)
|
height calc(100% - 135px)
|
||||||
.filter_input_wraper_1
|
.filter_input_wraper_1
|
||||||
width calc(100% - 45px)
|
width calc(100% - 45px)
|
||||||
.search-label_1
|
.search-label_1
|
||||||
|
|||||||
@@ -226,8 +226,7 @@ export default {
|
|||||||
this.$router.push('/matersearch')
|
this.$router.push('/matersearch')
|
||||||
},
|
},
|
||||||
toJumpSearch () {
|
toJumpSearch () {
|
||||||
console.log(this.unit_weight)
|
this.$router.push('/semifinishedinstoresearch')
|
||||||
// this.$router.push('/semifinishedinstoresearch')
|
|
||||||
},
|
},
|
||||||
handleBlur ($event) {
|
handleBlur ($event) {
|
||||||
$event.target.value = Number($event.target.value).toFixed(3)
|
$event.target.value = Number($event.target.value).toFixed(3)
|
||||||
|
|||||||
@@ -40,18 +40,6 @@
|
|||||||
<input type="text" class="filter-input" v-model="material_spec" disabled>
|
<input type="text" class="filter-input" v-model="material_spec" disabled>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="search-item">
|
|
||||||
<div class="search-label">重量(kg)</div>
|
|
||||||
<div class="filter_input_wraper">
|
|
||||||
<input type="number" class="filter-input" v-model="total_qty">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="search-item">
|
|
||||||
<div class="search-label">单重(g)</div>
|
|
||||||
<div class="filter_input_wraper">
|
|
||||||
<input type="number" class="filter-input" v-model="unit_weight">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="search-item">
|
<div class="search-item">
|
||||||
<div class="search-label">数量</div>
|
<div class="search-label">数量</div>
|
||||||
<div class="filter_input_wraper">
|
<div class="filter_input_wraper">
|
||||||
@@ -59,9 +47,33 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="search-item">
|
<div class="search-item">
|
||||||
<div class="search-label">入库点</div>
|
<div class="search-label">单重(g)</div>
|
||||||
<div class="filter_input_wraper">
|
<div class="filter_input_wraper">
|
||||||
<el-select v-model="value3" filterable clearable placeholder="请选择">
|
<input type="number" class="filter-input" v-model="unit_weight" disabled>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-label">重量(kg)</div>
|
||||||
|
<div class="filter_input_wraper">
|
||||||
|
<input type="number" class="filter-input" v-model="total_qty" disabled>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-label">货位</div>
|
||||||
|
<div class="filter_input_wraper">
|
||||||
|
<input type="text" class="filter-input" v-model="struct_code" disabled>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-label">载具号</div>
|
||||||
|
<div class="filter_input_wraper">
|
||||||
|
<input type="text" class="filter-input" v-model="storagevehicle_code" disabled>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-label">出库点</div>
|
||||||
|
<div class="filter_input_wraper">
|
||||||
|
<el-select v-model="value3" filterable clearable placeholder="请选择" disabled>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in options3"
|
v-for="item in options3"
|
||||||
:key="item.point_code"
|
:key="item.point_code"
|
||||||
@@ -71,15 +83,6 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="search-item">
|
|
||||||
<div class="search-label">载具号</div>
|
|
||||||
<div class="filter_input_wraper filter_input_wraper_1">
|
|
||||||
<input type="text" class="filter-input" v-model="storagevehicle_code">
|
|
||||||
</div>
|
|
||||||
<div class="filter_button">
|
|
||||||
<button class="button button--primary" :disabled="disabled1" @click="_callVehicle">呼叫空载具</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="search-item">
|
<div class="search-item">
|
||||||
<div class="search-label">备注</div>
|
<div class="search-label">备注</div>
|
||||||
<div class="filter_input_wraper">
|
<div class="filter_input_wraper">
|
||||||
@@ -87,7 +90,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="search-item_2">
|
<div class="search-item_2">
|
||||||
<button class="button button--primary" :disabled="disabled2" :class="{'button--defalut': value1 === '' || value2 === '' || value3 === '' || material_code === '' || total_qty === '' || unit_weight === '' || storagevehicle_code === ''}" @click="toSure">确认入库</button>
|
<button class="button button--primary" :disabled="disabled2" :class="{'button--defalut': value1 === '' || value2 === '' || value3 === ''}" @click="toSure">确认出库</button>
|
||||||
<button class="button button--primary" @click="toJumpSearch">作业查询</button>
|
<button class="button button--primary" @click="toJumpSearch">作业查询</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -96,7 +99,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {outgetBcpStor, outgetBillType, getPoint, callVehicle, createIn} from '@config/getData2.js'
|
import {outgetBcpStor, outgetBillType, outgetPoint, outcreateIn} from '@config/getData2.js'
|
||||||
import {accMul, accDiv} from '@config/utils.js'
|
import {accMul, accDiv} from '@config/utils.js'
|
||||||
export default {
|
export default {
|
||||||
name: 'semifinishedoutstore',
|
name: 'semifinishedoutstore',
|
||||||
@@ -111,8 +114,9 @@ export default {
|
|||||||
material_id: '',
|
material_id: '',
|
||||||
material_code: '',
|
material_code: '',
|
||||||
material_spec: '',
|
material_spec: '',
|
||||||
total_qty: '',
|
|
||||||
unit_weight: '',
|
unit_weight: '',
|
||||||
|
qty: '',
|
||||||
|
struct_code: '',
|
||||||
storagevehicle_code: '',
|
storagevehicle_code: '',
|
||||||
remark: '',
|
remark: '',
|
||||||
disabled1: false,
|
disabled1: false,
|
||||||
@@ -120,10 +124,13 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
qty () {
|
total_qty () {
|
||||||
let res = ''
|
let res = ''
|
||||||
let res1 = accMul(this.total_qty, 1000)
|
if (this.unit_weight !== '') {
|
||||||
res = accDiv(res1, this.unit_weight)
|
let res1 = accMul(this.unit_weight, this.qty)
|
||||||
|
res = accDiv(res1, 1000)
|
||||||
|
res = Number(res).toFixed(3)
|
||||||
|
}
|
||||||
return res
|
return res
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -138,12 +145,16 @@ export default {
|
|||||||
this.material_id = JSON.parse(this.$store.getters.materObj).material_id
|
this.material_id = JSON.parse(this.$store.getters.materObj).material_id
|
||||||
this.material_code = JSON.parse(this.$store.getters.materObj).material_code
|
this.material_code = JSON.parse(this.$store.getters.materObj).material_code
|
||||||
this.material_spec = JSON.parse(this.$store.getters.materObj).material_spec
|
this.material_spec = JSON.parse(this.$store.getters.materObj).material_spec
|
||||||
this.unit_weight = JSON.parse(this.$store.getters.materObj).net_weight
|
this.unit_weight = Number(JSON.parse(this.$store.getters.materObj).net_weight).toFixed(3)
|
||||||
|
this.qty = Number(JSON.parse(this.$store.getters.materObj).canuse_qty).toFixed(3)
|
||||||
|
this.struct_code = JSON.parse(this.$store.getters.materObj).struct_name
|
||||||
|
this.storagevehicle_code = JSON.parse(this.$store.getters.materObj).storagevehicle_code
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
this._outgetBcpStor()
|
this._outgetBcpStor()
|
||||||
this._outgetBillType()
|
this._outgetBillType()
|
||||||
|
this._outgetPoint()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 仓库下拉框
|
// 仓库下拉框
|
||||||
@@ -156,26 +167,15 @@ export default {
|
|||||||
let res = await outgetBillType()
|
let res = await outgetBillType()
|
||||||
this.options2 = [...res.data]
|
this.options2 = [...res.data]
|
||||||
},
|
},
|
||||||
// 入库点下拉框
|
// 出库点下拉框
|
||||||
async _getPoint () {
|
async _outgetPoint () {
|
||||||
let res = await getPoint()
|
let res = await outgetPoint()
|
||||||
this.options3 = [...res.data]
|
this.options3 = [...res.data]
|
||||||
},
|
},
|
||||||
// 呼叫空载具
|
// 确认出库
|
||||||
async _callVehicle () {
|
|
||||||
this.disabled1 = true
|
|
||||||
try {
|
|
||||||
let res = await callVehicle()
|
|
||||||
this.toast(res.message)
|
|
||||||
this.disabled1 = false
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled1 = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 确认入库
|
|
||||||
async toSure () {
|
async toSure () {
|
||||||
this.disabled2 = true
|
this.disabled2 = true
|
||||||
if (this.value1 === '' || this.value2 === '' || this.value3 === '' || this.material_code === '' || this.total_qty === '' || this.unit_weight === '' || this.storagevehicle_code === '') {
|
if (this.value1 === '' || this.value2 === '' || this.value3 === '') {
|
||||||
this.disabled2 = false
|
this.disabled2 = false
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@@ -190,10 +190,11 @@ export default {
|
|||||||
unit_weight: this.unit_weight,
|
unit_weight: this.unit_weight,
|
||||||
qty: this.qty,
|
qty: this.qty,
|
||||||
point_code: this.value3,
|
point_code: this.value3,
|
||||||
|
struct_code: this.struct_code,
|
||||||
storagevehicle_code: this.storagevehicle_code,
|
storagevehicle_code: this.storagevehicle_code,
|
||||||
remark: this.remark
|
remark: this.remark
|
||||||
}
|
}
|
||||||
let res = await createIn(from)
|
let res = await outcreateIn(from)
|
||||||
this.toast(res.message)
|
this.toast(res.message)
|
||||||
this.value1 = ''
|
this.value1 = ''
|
||||||
this.value2 = ''
|
this.value2 = ''
|
||||||
@@ -203,6 +204,7 @@ export default {
|
|||||||
this.material_spec = ''
|
this.material_spec = ''
|
||||||
this.total_qty = ''
|
this.total_qty = ''
|
||||||
this.unit_weight = ''
|
this.unit_weight = ''
|
||||||
|
this.struct_code = ''
|
||||||
this.storagevehicle_code = ''
|
this.storagevehicle_code = ''
|
||||||
this.remark = ''
|
this.remark = ''
|
||||||
this.disabled2 = false
|
this.disabled2 = false
|
||||||
@@ -216,7 +218,7 @@ export default {
|
|||||||
this.$router.push('/outmatersearch')
|
this.$router.push('/outmatersearch')
|
||||||
},
|
},
|
||||||
toJumpSearch () {
|
toJumpSearch () {
|
||||||
this.$router.push('/semifinishedinstoresearch')
|
this.$router.push('/semifinishedoutstoresearch')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user