添加型材发货
This commit is contained in:
@@ -136,7 +136,7 @@ export default {
|
||||
},
|
||||
toPage2 (e) {
|
||||
let name = e.path.substr(2)
|
||||
if (name === 'ProcedureInspection' || name === 'SoftWasteBarrelPrint' || name === 'NewMaterInStoreGroup' || name === 'SoftWasteInStoreGroup' || name === 'FinishProdBarrelPrint' || name === 'ChengPinBarrelPrint' || name === 'BarrelBagUpdate' || name === 'ReworkBarrelPrint' || name === 'SoftWasteBagPrint' || name === 'ChaipanManage' || name === 'RawMaterCheck' || name === 'ProductInstore' || name === 'PeifenOutStore' || name === 'ReturnMaterOutStore' || name === 'OtherOutStore' || name === 'CheckOutStore' || name === 'SaleOutStore' || name === 'SoftWasteCleanOutStore' || name === 'CleaningGroupBarrel' || name === 'PeifenBarrelPrint' || name === 'AbnormalBarrelPrint' || name === 'SoftWasteCleanInStore' || name === 'ProcessMakePowder' || name === 'ProcessGrindBall' || name === 'ProcessSpray' || name === 'ProcessMix' || name === 'ProcessDry' || name === 'ProcessSeDry' || name === 'ProcessChuimo' || name === 'ProcessYatuan' || name === 'ProcessGranulation' || name === 'ProcessWipe' || name === 'MaintainExecution' || name === 'MaintainConfirm' || name === 'EquipRepair' || name === 'EquipRepairExecute' || name === 'EquipRepairConfirm' || name === 'SparePartInstore' || name === 'SparePartOutstore' || name === 'UseReturn' || name === 'RunLogFill') {
|
||||
if (name === 'ProcedureInspection' || name === 'SoftWasteBarrelPrint' || name === 'NewMaterInStoreGroup' || name === 'SoftWasteInStoreGroup' || name === 'FinishProdBarrelPrint' || name === 'ChengPinBarrelPrint' || name === 'BarrelBagUpdate' || name === 'ReworkBarrelPrint' || name === 'SoftWasteBagPrint' || name === 'ChaipanManage' || name === 'RawMaterCheck' || name === 'ProductInstore' || name === 'PeifenOutStore' || name === 'ReturnMaterOutStore' || name === 'OtherOutStore' || name === 'CheckOutStore' || name === 'SaleOutStore' || name === 'SoftWasteCleanOutStore' || name === 'CleaningGroupBarrel' || name === 'PeifenBarrelPrint' || name === 'AbnormalBarrelPrint' || name === 'SoftWasteCleanInStore' || name === 'ProcessMakePowder' || name === 'ProcessGrindBall' || name === 'ProcessSpray' || name === 'ProcessMix' || name === 'ProcessDry' || name === 'ProcessSeDry' || name === 'ProcessChuimo' || name === 'ProcessYatuan' || name === 'ProcessGranulation' || name === 'ProcessWipe' || name === 'MaintainExecution' || name === 'MaintainConfirm' || name === 'EquipRepair' || name === 'EquipRepairExecute' || name === 'EquipRepairConfirm' || name === 'SparePartInstore' || name === 'SparePartOutstore' || name === 'UseReturn' || name === 'RunLogFill' || name === 'XingcaiDeliver') {
|
||||
this.$store.dispatch('setKeepAlive', [name])
|
||||
}
|
||||
this.$router.push(e.path.substr(2))
|
||||
|
||||
128
src/pages/xinrui/production/SelectGongling.vue
Normal file
128
src/pages/xinrui/production/SelectGongling.vue
Normal file
@@ -0,0 +1,128 @@
|
||||
<template>
|
||||
<section>
|
||||
<nav-bar :inner="true" title="查找外协工令"></nav-bar>
|
||||
<section class="content mgt196" v-infinite-scroll="loadMore" infinite-scroll-disabled="busy" infinite-scroll-distance="0" infinite-scroll-immediate-check="false">
|
||||
<div class="grid-wraper">
|
||||
<div class="left_fixed">
|
||||
<table class="layout-t left_layout_t">
|
||||
<tr>
|
||||
<th>发货日期</th>
|
||||
</tr>
|
||||
<tr v-for="e in dataList" :key="e.material_code" @click="toCheck(e)" :class="{'checked': e.material_code === pkId}">
|
||||
<td>{{e.send_date}}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="slide">
|
||||
<table class="layout-t">
|
||||
<tr>
|
||||
<th>物料编码</th>
|
||||
<th>物料名称</th>
|
||||
<th>批次</th>
|
||||
<th>重量kg</th>
|
||||
<th>所属组织</th>
|
||||
<th>工令号</th>
|
||||
</tr>
|
||||
<tr v-for="e in dataList" :key="e.material_code" @click="toCheck(e)" :class="{'checked': e.material_code === pkId}">
|
||||
<td>{{e.material_code}}</td>
|
||||
<td>{{e.material_name}}</td>
|
||||
<td>{{e.pcsn}}</td>
|
||||
<td>{{e.workorder_qty | numeric(3)}}</td>
|
||||
<td>{{e.org_name}}</td>
|
||||
<td>{{e.workorder_code}}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="loading-tips">{{desc}}</div>
|
||||
</section>
|
||||
<section class="submit-bar">
|
||||
<button class="btn submit-button" @click="toSearch">查询</button>
|
||||
<button class="btn submit-button" :class="{'btn-disabled': pkId === ''}" @click="toSure">确认</button>
|
||||
</section>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import NavBar from '@components/NavBar.vue'
|
||||
import {xcoutqueryWorkorder} from '@config/getData2.js'
|
||||
export default {
|
||||
name: 'SearchSoftWasteBill',
|
||||
components: {
|
||||
NavBar
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
dataList: [],
|
||||
pkId: '',
|
||||
pkObj: {},
|
||||
page: 1,
|
||||
size: '10',
|
||||
busy: false,
|
||||
desc: ''
|
||||
}
|
||||
},
|
||||
created () {
|
||||
this._xcoutqueryWorkorder()
|
||||
},
|
||||
methods: {
|
||||
toCheck (e) {
|
||||
this.pkId = this.pkId === e.material_code ? '' : e.material_code
|
||||
this.pkObj = this.pkId === e.material_code ? e : {}
|
||||
},
|
||||
toSure () {
|
||||
if (this.pkId !== '') {
|
||||
this.$store.dispatch('materObj', this.pkObj)
|
||||
this.$router.back()
|
||||
}
|
||||
},
|
||||
async loadMore () {
|
||||
this.busy = true
|
||||
this.page++
|
||||
this.desc = '加载数据中...'
|
||||
let res = await xcoutqueryWorkorder(this.page + '', this.size)
|
||||
if (res.code === '1') {
|
||||
this.dataList = [...this.dataList, ...res.rows]
|
||||
if (res.rows.length < 10) {
|
||||
this.busy = true
|
||||
this.desc = '已加载全部数据'
|
||||
} else {
|
||||
this.busy = false
|
||||
}
|
||||
} else {
|
||||
this.Dialog(res.desc)
|
||||
this.desc = res.desc
|
||||
}
|
||||
},
|
||||
async _xcoutqueryWorkorder () {
|
||||
let res = await xcoutqueryWorkorder(this.page + '', this.size)
|
||||
if (res.code === '1') {
|
||||
this.dataList = [...res.rows]
|
||||
if (res.rows.length < 10) {
|
||||
this.busy = true
|
||||
this.desc = '已加载全部数据'
|
||||
}
|
||||
} else {
|
||||
this.Dialog(res.desc)
|
||||
this.desc = res.desc
|
||||
}
|
||||
},
|
||||
toSearch () {
|
||||
this.dataList = []
|
||||
this.pkId = ''
|
||||
this.pkObj = {}
|
||||
this.page = 1
|
||||
this.size = '10'
|
||||
this.busy = false
|
||||
this.desc = ''
|
||||
this._xcoutqueryWorkorder()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="stylus" scoped>
|
||||
>>>.content
|
||||
height calc(100% - 1.96rem)
|
||||
overflow-y auto
|
||||
</style>
|
||||
162
src/pages/xinrui/production/XingcaiDeliver.vue
Normal file
162
src/pages/xinrui/production/XingcaiDeliver.vue
Normal file
@@ -0,0 +1,162 @@
|
||||
<template>
|
||||
<section>
|
||||
<nav-bar title="型材发货"></nav-bar>
|
||||
<section class="content mgt186 mgb70">
|
||||
<div class="filter-wraper">
|
||||
<div class="bottom-filter-tip">
|
||||
<div class="filter-label txtjustify">选择工令</div>
|
||||
<div class="fxcol mgl20">
|
||||
<input type="text" class="filter-input filter-scan-input" v-model="val2" disabled>
|
||||
</div>
|
||||
<div class="mgl20">
|
||||
<button class="btn" :disabled="disabled2" :class="{'btn-disabled': disabled2 === true}" @click="selectgl">选择</button>
|
||||
</div>
|
||||
</div>
|
||||
<search-box
|
||||
label="载具码"
|
||||
:focused="true"
|
||||
v-model="val3"
|
||||
@handleChange="handleChange3"
|
||||
></search-box>
|
||||
</div>
|
||||
<div class="grid-wraper">
|
||||
<div class="left_fixed">
|
||||
<table class="layout-t left_layout_t">
|
||||
<tr>
|
||||
<th>桶码</th>
|
||||
</tr>
|
||||
<tr v-for="e in dataList" :key="e.bucketunique" @click="toCheck(e)" :class="{'checked': e.bucketunique === pkId}">
|
||||
<td>{{e.bucketunique}}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="slide">
|
||||
<table class="layout-t">
|
||||
<tr>
|
||||
<th>物料编码</th>
|
||||
<th>物料名称</th>
|
||||
<th>批次</th>
|
||||
<th>重量kg</th>
|
||||
</tr>
|
||||
<tr v-for="e in dataList" :key="e.bucketunique" @click="toCheck(e)" :class="{'checked': e.bucketunique === pkId}">
|
||||
<td>{{e.material_code}}</td>
|
||||
<td>{{e.material_name}}</td>
|
||||
<td>{{e.pcsn}}</td>
|
||||
<td>{{e.storage_qty | numeric(3)}}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="calc_value_wraper">
|
||||
<div class="bottom-filter-tip">
|
||||
<div class="filter-label txtjustify">总重量</div>
|
||||
<div class="fxcol mgl20">
|
||||
<input type="text" class="filter-input filter-scan-input" v-model="val4">
|
||||
</div>
|
||||
<div class="mgl20">KG</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="submit-bar">
|
||||
<button class="btn submit-button" :disabled="disabled1" :class="{'btn-disabled': dataList.length === 0}" @click="toSure">确认发货</button>
|
||||
</section>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import NavBar from '@components/NavBar.vue'
|
||||
import SearchBox from '@components/SearchBox.vue'
|
||||
// import {checkVehicle, checkBucket, confirmVehicle} from '@config/getData2.js'
|
||||
import {xcoutqueryStoragevehicle, xcoutconfirmoutstore} from '@config/getData2.js'
|
||||
import {accAdd} from '@config/mUtils.js'
|
||||
export default {
|
||||
name: 'SoftWasteInStoreGroup',
|
||||
components: {
|
||||
NavBar,
|
||||
SearchBox
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
vehicle: {},
|
||||
val2: '',
|
||||
val3: '',
|
||||
dataList: [],
|
||||
pkId: '',
|
||||
disabled1: false,
|
||||
disabled2: false
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
val4 () {
|
||||
let cur = '0.000'
|
||||
this.dataList.map(el => {
|
||||
cur = accAdd(cur, el.storage_qty)
|
||||
})
|
||||
cur = Number(cur).toFixed(3) + ''
|
||||
return cur
|
||||
}
|
||||
},
|
||||
beforeRouteLeave (to, from, next) {
|
||||
if (to.path === '/home' || to.path === '/login') {
|
||||
this.$store.dispatch('setKeepAlive', [])
|
||||
}
|
||||
next()
|
||||
},
|
||||
activated () {
|
||||
if (this.$store.getters.materObj !== '') this.val2 = this.$store.getters.materObj.workorder_code
|
||||
},
|
||||
methods: {
|
||||
handleChange3 (e, type) {
|
||||
if (type) {
|
||||
this._xcoutqueryStoragevehicle(e)
|
||||
}
|
||||
},
|
||||
toCheck (e) {
|
||||
this.pkId = this.pkId === e.bucketunique ? '' : e.bucketunique
|
||||
this.pkObj = this.pkId === e.bucketunique ? e : {}
|
||||
},
|
||||
/** 选择工令 */
|
||||
selectgl () {
|
||||
// this.$router.push('/SearchSoftWasteBill')
|
||||
this.$router.push('/SelectGongling')
|
||||
},
|
||||
/** 确认发货--------- */
|
||||
toSure () {
|
||||
this.disabled1 = true
|
||||
this._xcoutconfirmoutstore()
|
||||
},
|
||||
/** 1.2扫载具查询桶明细 */
|
||||
async _xcoutqueryStoragevehicle (e) {
|
||||
let res = await xcoutqueryStoragevehicle(e)
|
||||
if (res.code === '1') {
|
||||
this.dataList = [...res.content]
|
||||
} else {
|
||||
this.Dialog(res.desc)
|
||||
}
|
||||
},
|
||||
async _xcoutconfirmoutstore () {
|
||||
try {
|
||||
let res = await xcoutconfirmoutstore(this.val2, this.val3, this.dataList)
|
||||
if (res.code === '1') {
|
||||
this.toast(res.desc)
|
||||
Object.assign(this.$data, this.$options.data())
|
||||
} else {
|
||||
this.Dialog(res.desc)
|
||||
}
|
||||
this.disabled1 = false
|
||||
} catch (e) {
|
||||
this.disabled1 = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="stylus" scoped>
|
||||
.pad
|
||||
padding-top 0
|
||||
.btn1
|
||||
max-width auto
|
||||
font-size .2rem
|
||||
padding 0 .1rem
|
||||
</style>
|
||||
Reference in New Issue
Block a user