液压机出库
This commit is contained in:
@@ -68,3 +68,13 @@ export const querySectCode = () => post('api/pda/check/querySectCode', {})
|
||||
export const queryStructCode = (uuid) => post('api/pda/check/queryStructCode', {
|
||||
sect_uuid: uuid
|
||||
})
|
||||
|
||||
/** 液压机出库 */
|
||||
// 1.1查询点位
|
||||
export const queryPoint = () => post('api/pda/pressure/queryPoint', {})
|
||||
// 1.5查询仓位
|
||||
export const pressureConfirm = (id, code, pname) => post('api/pda/pressure/confirm', {
|
||||
point_id: id,
|
||||
point_code: code,
|
||||
point_name: pname
|
||||
})
|
||||
|
||||
104
src/pages/proj/MechineOutstore.vue
Normal file
104
src/pages/proj/MechineOutstore.vue
Normal file
@@ -0,0 +1,104 @@
|
||||
<template>
|
||||
<section>
|
||||
<nav-bar title="液压机出库"></nav-bar>
|
||||
<section class="content mgt186">
|
||||
<div class="filter-wraper">
|
||||
<div class="bottom-filter-tip">
|
||||
<div class="filter-label txtjustify">点位</div>
|
||||
<div class="fxcol mgl20 visible" >
|
||||
<dropdown-menu
|
||||
:option="option1"
|
||||
:active="active1"
|
||||
:open="open1"
|
||||
@toggleItem="toggleItem1"
|
||||
@dropdownMenu="dropdownMenu1">
|
||||
</dropdown-menu>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="submit-bar">
|
||||
<button class="btn submit-button" :class="{'btn-disabled' : active1 === ''}" :disabled="disabled" @click="_pressureConfirm">确定</button>
|
||||
<button class="btn submit-button" @click="toCancle">取消</button>
|
||||
</section>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import NavBar from '@components/NavBar.vue'
|
||||
import DropdownMenu from '@components/DropdownMenu.vue'
|
||||
import {queryPoint, pressureConfirm} from '@config/getData2'
|
||||
export default {
|
||||
name: 'MechineOutstore',
|
||||
components: {
|
||||
NavBar,
|
||||
DropdownMenu
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
option1: [],
|
||||
active1: '',
|
||||
open1: false,
|
||||
disabled: false
|
||||
}
|
||||
},
|
||||
created () {
|
||||
this._queryPoint()
|
||||
},
|
||||
methods: {
|
||||
/** 1.1查询点位 */
|
||||
async _queryPoint () {
|
||||
let res = await queryPoint()
|
||||
if (res.code === '1') {
|
||||
this.option1 = [...res.result]
|
||||
this.option1.map(el => {
|
||||
this.$set(el, 'value', el.point_code)
|
||||
this.$set(el, 'label', el.point_name)
|
||||
})
|
||||
} else {
|
||||
this.Dialog(res.desc)
|
||||
}
|
||||
},
|
||||
/** 确定 */
|
||||
async _pressureConfirm () {
|
||||
this.disabled = true
|
||||
if (this.active1 === '') {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await pressureConfirm(this.option1[this.active1].point_id, this.option1[this.active1].point_code, this.option1[this.active1].point_name)
|
||||
if (res.code === '1') {
|
||||
this.toast(res.desc)
|
||||
this.toCancle()
|
||||
} else {
|
||||
this.Dialog(res.desc)
|
||||
}
|
||||
this.disabled = false
|
||||
} catch (e) {
|
||||
this.disabled = false
|
||||
}
|
||||
},
|
||||
/** 取消 */
|
||||
toCancle () {
|
||||
this.active1 = ''
|
||||
this.disabled = false
|
||||
},
|
||||
toggleItem1 () {
|
||||
if (!this.open1) {
|
||||
this.open1 = true
|
||||
} else {
|
||||
this.open1 = false
|
||||
}
|
||||
},
|
||||
dropdownMenu1 (i) {
|
||||
this.active1 = i + ''
|
||||
this.open1 = false
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="stylus" scoped>
|
||||
|
||||
</style>
|
||||
@@ -17,6 +17,7 @@ const CallEmptyPallet = r => require.ensure([], () => r(require('../pages/proj/C
|
||||
const BindPalletPoint = r => require.ensure([], () => r(require('../pages/proj/BindPalletPoint')), 'BindPalletPoint')
|
||||
const CheckManage = r => require.ensure([], () => r(require('../pages/proj/CheckManage')), 'CheckManage')
|
||||
const SearchMater = r => require.ensure([], () => r(require('../pages/proj/SearchMater')), 'SearchMater')
|
||||
const MechineOutstore = r => require.ensure([], () => r(require('../pages/proj/MechineOutstore')), 'MechineOutstore')
|
||||
|
||||
Vue.use(Router)
|
||||
|
||||
@@ -88,6 +89,10 @@ export default new Router({
|
||||
{
|
||||
path: '/SearchMater', // 查找物料
|
||||
component: SearchMater
|
||||
},
|
||||
{
|
||||
path: '/MechineOutstore', // 液压机出库
|
||||
component: MechineOutstore
|
||||
}
|
||||
],
|
||||
scrollBehavior (to, from, savedPosition) {
|
||||
|
||||
Reference in New Issue
Block a user