选择物料
This commit is contained in:
@@ -40,26 +40,26 @@ export const authority = () => {
|
|||||||
},
|
},
|
||||||
{menu_id: '5',
|
{menu_id: '5',
|
||||||
path: 'RF05',
|
path: 'RF05',
|
||||||
name: '专机管理',
|
|
||||||
sonTree: [
|
|
||||||
// {menu_id: '1', name: '专机管理', path: '/operation'}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{menu_id: '6',
|
|
||||||
path: 'RF06',
|
|
||||||
name: '暂存区管理',
|
|
||||||
sonTree: [
|
|
||||||
// {menu_id: '1', name: '暂存区管理', path: '/operation'}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{menu_id: '7',
|
|
||||||
path: 'RF04',
|
|
||||||
name: '清洗管理',
|
name: '清洗管理',
|
||||||
sonTree: [
|
sonTree: [
|
||||||
{menu_id: '1', name: '清洗上料', path: '/cleaningloading'},
|
{menu_id: '1', name: '清洗上料', path: '/cleaningloading'},
|
||||||
{menu_id: '2', name: '清洗下料', path: '/cleaningcutting'},
|
{menu_id: '2', name: '清洗下料', path: '/cleaningcutting'},
|
||||||
{menu_id: '3', name: '人工倒料', path: '/manpour'}
|
{menu_id: '3', name: '人工倒料', path: '/manpour'}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{menu_id: '6',
|
||||||
|
path: 'RF06',
|
||||||
|
name: '专机管理',
|
||||||
|
sonTree: [
|
||||||
|
// {menu_id: '1', name: '专机管理', path: '/operation'}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{menu_id: '7',
|
||||||
|
path: 'RF07',
|
||||||
|
name: '暂存区管理',
|
||||||
|
sonTree: [
|
||||||
|
// {menu_id: '1', name: '暂存区管理', path: '/operation'}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<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">
|
||||||
<el-select v-model="value1" filterable clearable placeholder="请选择">
|
<el-select v-model="value1" filterable clearable placeholder="请选择" @change="changeValue">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in options1"
|
v-for="item in options1"
|
||||||
:key="item.value"
|
:key="item.value"
|
||||||
@@ -18,12 +18,12 @@
|
|||||||
<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">
|
||||||
<el-select v-model="value2" filterable clearable placeholder="请选择">
|
<el-select v-model="value2" filterable clearable placeholder="请选择" @change="changeValue">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in options2"
|
v-for="item in options2"
|
||||||
:key="item.value"
|
:key="item.device_code"
|
||||||
:label="item.label"
|
:label="item.device_name"
|
||||||
:value="item.value">
|
:value="item.device_code">
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</div>
|
</div>
|
||||||
@@ -72,8 +72,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {dictall, washdevicelist, washquery, washweighing, washweighingFinish} from '@config/getData2.js'
|
import {dictall, washdevicelist, washquery, washweighing, washweighingFinish} from '@config/getData1.js'
|
||||||
import {accDiv} from '@config/utils.js'
|
|
||||||
export default {
|
export default {
|
||||||
name: 'manpour',
|
name: 'manpour',
|
||||||
data () {
|
data () {
|
||||||
@@ -127,16 +126,32 @@ export default {
|
|||||||
this.toast(res.msg)
|
this.toast(res.msg)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
changeValue () {
|
||||||
|
if (this.value1 && this.value2) {
|
||||||
|
this._washquery()
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 1.2根据设备列表获取物料信息
|
||||||
|
async _washquery () {
|
||||||
|
let res = await washquery(this.value1, this.value2)
|
||||||
|
if (res.code === 200) {
|
||||||
|
this.material_spec = res.content[0].material_spec
|
||||||
|
this.material_code = res.content[0].material_code
|
||||||
|
this.material_name = res.content[0].material_name
|
||||||
|
} else {
|
||||||
|
this.toast(res.msg)
|
||||||
|
}
|
||||||
|
},
|
||||||
// 称重
|
// 称重
|
||||||
async _washweighing () {
|
async _washweighing () {
|
||||||
this.disabled1 = true
|
this.disabled1 = true
|
||||||
let list = []
|
let list = []
|
||||||
list.push(this.value2)
|
list.push(this.value2)
|
||||||
try {
|
try {
|
||||||
// let res = await washweighing(['A1_SKQX_05'])
|
|
||||||
let res = await washweighing(list)
|
let res = await washweighing(list)
|
||||||
this.toast(res.msg)
|
if (res.code === 200) {
|
||||||
this.deviceinstor_weight = res.content[0].deviceinstor_weight
|
this.deviceinstor_weight = res.content[0].deviceinstor_weight
|
||||||
|
}
|
||||||
this.disabled1 = false
|
this.disabled1 = false
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
this.disabled1 = false
|
this.disabled1 = false
|
||||||
@@ -151,14 +166,16 @@ export default {
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
let res = await washweighingFinish(this.value1, this.value2, this.material_spec, this.material_code, this.material_name)
|
let res = await washweighingFinish(this.value1, this.value2, this.material_spec, this.material_code, this.material_name)
|
||||||
this.toast(res.msg)
|
if (res.code === 200) {
|
||||||
this.value1 = ''
|
this.toast(res.msg)
|
||||||
this.value2 = ''
|
this.value1 = ''
|
||||||
this.material_spec = ''
|
this.value2 = ''
|
||||||
this.material_code = ''
|
this.material_spec = ''
|
||||||
this.material_name = ''
|
this.material_code = ''
|
||||||
|
this.material_name = ''
|
||||||
|
this.$store.dispatch('setMaterObj', '')
|
||||||
|
}
|
||||||
this.disabled2 = false
|
this.disabled2 = false
|
||||||
this.$store.dispatch('setMaterObj', '')
|
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
this.disabled2 = false
|
this.disabled2 = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,8 +45,6 @@ import {washsearchlist} from '@config/getData1.js'
|
|||||||
export default {
|
export default {
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
options1: [],
|
|
||||||
value1: '',
|
|
||||||
val1: '',
|
val1: '',
|
||||||
dataList: [],
|
dataList: [],
|
||||||
pkId: '',
|
pkId: '',
|
||||||
|
|||||||
Reference in New Issue
Block a user