配料任务
This commit is contained in:
66
pages.json
66
pages.json
@@ -19,71 +19,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
,{
|
,{
|
||||||
"path" : "pages/manage/empty-tray-back",
|
"path" : "pages/manage/mix-task",
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/mater-in-storage",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/area-lock",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/fill-tray",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/empty-material-racks-back",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/material-transfer",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/modify-process",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/route-lock",
|
|
||||||
"style" :
|
|
||||||
{
|
|
||||||
"navigationStyle": "custom"
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
,{
|
|
||||||
"path" : "pages/manage/call-mater",
|
|
||||||
"style" :
|
"style" :
|
||||||
{
|
{
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
|
|||||||
@@ -32,15 +32,7 @@
|
|||||||
return {
|
return {
|
||||||
userName: '',
|
userName: '',
|
||||||
menuList: [
|
menuList: [
|
||||||
{title: '物料入库', icon: 'RF03', path: '/pages/manage/mater-in-storage'},
|
{title: '配料任务', icon: 'RF07', path: '/pages/manage/mix-task'}
|
||||||
{title: '笼框补仓', icon: 'RF04', path: '/pages/manage/empty-tray-back'},
|
|
||||||
// {title: '外协区空料架送回', icon: 'RF05', path: '/pages/manage/empty-material-racks-back'},
|
|
||||||
// {title: '物料转运', icon: 'RF02', path: '/pages/manage/material-transfer'},
|
|
||||||
{title: '区域锁定', icon: 'RF08', path: '/pages/manage/area-lock'},
|
|
||||||
{title: '路线锁定', icon: 'RF06', path: '/pages/manage/route-lock'},
|
|
||||||
{title: '呼叫空框', icon: 'RF01', path: '/pages/manage/fill-tray'},
|
|
||||||
{title: '修改订单工序', icon: 'RF07', path: '/pages/manage/modify-process'},
|
|
||||||
{title: '呼叫物料', icon: 'RF09', path: '/pages/manage/call-mater'}
|
|
||||||
],
|
],
|
||||||
show: false,
|
show: false,
|
||||||
secM: []
|
secM: []
|
||||||
|
|||||||
@@ -7,14 +7,6 @@
|
|||||||
<view class="setup-label">服务器地址</view>
|
<view class="setup-label">服务器地址</view>
|
||||||
<input type="text" class="setup-input" placeholder="请输入服务器地址" v-model="addrip">
|
<input type="text" class="setup-input" placeholder="请输入服务器地址" v-model="addrip">
|
||||||
</view>
|
</view>
|
||||||
<view class="setup-item">
|
|
||||||
<view class="setup-label">ACS地址</view>
|
|
||||||
<input type="text" class="setup-input" placeholder="请输入ACS地址" v-model="acsip">
|
|
||||||
</view>
|
|
||||||
<view class="setup-item">
|
|
||||||
<view class="setup-label">打印地址</view>
|
|
||||||
<input type="text" class="setup-input" placeholder="请输入打印地址" v-model="printip">
|
|
||||||
</view>
|
|
||||||
<!-- <view class="setup-item">
|
<!-- <view class="setup-item">
|
||||||
<view class="setup-label">刷新时间(s)</view>
|
<view class="setup-label">刷新时间(s)</view>
|
||||||
<input type="text" class="setup-input" placeholder="请输入刷新时间" v-model="setTime">
|
<input type="text" class="setup-input" placeholder="请输入刷新时间" v-model="setTime">
|
||||||
@@ -36,8 +28,6 @@
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
addrip: this.$store.getters.baseUrl,
|
addrip: this.$store.getters.baseUrl,
|
||||||
acsip: this.$store.getters.acsUrl,
|
|
||||||
printip: this.$store.getters.printUrl,
|
|
||||||
setTime: this.$store.getters.setTime / 1000
|
setTime: this.$store.getters.setTime / 1000
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
@@ -55,20 +45,6 @@
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (this.acsip === '') {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写ACS地址',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (this.printip === '') {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写打印地址',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
// if (this.setTime === '') {
|
// if (this.setTime === '') {
|
||||||
// uni.showToast({
|
// uni.showToast({
|
||||||
// title: '请填写刷新时间',
|
// title: '请填写刷新时间',
|
||||||
@@ -77,7 +53,7 @@
|
|||||||
// return
|
// return
|
||||||
// }
|
// }
|
||||||
// 存值
|
// 存值
|
||||||
this.$store.dispatch('setConfig',{baseUrl: this.addrip, acsUrl: this.acsip, printUrl: this.printip,setTime: this.setTime * 1000})
|
this.$store.dispatch('setConfig',{baseUrl: this.addrip, setTime: this.setTime * 1000})
|
||||||
uni.redirectTo({
|
uni.redirectTo({
|
||||||
url: '/pages/login/login'
|
url: '/pages/login/login'
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -1,143 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">区域</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19 filter_select">
|
|
||||||
<!-- <zxz-uni-data-select
|
|
||||||
v-model="index"
|
|
||||||
:localdata="options"
|
|
||||||
:multiple="true"
|
|
||||||
:collapseTags="true"
|
|
||||||
/> -->
|
|
||||||
<uni-data-select v-model="index" :localdata="options" @change="selectChange"></uni-data-select>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- <view v-show="dataList.length > 0" class="zd_wrapper grid-wraper">
|
|
||||||
<view class="slide_new">
|
|
||||||
<table>
|
|
||||||
<tbody>
|
|
||||||
<tr v-for="(e, i) in dataList" :key="i" @click="toCheck(e)">
|
|
||||||
<td><uni-icons :type="e.checked ? 'checkbox-filled' : 'circle'" size="26" color="#4e6ef2"></uni-icons></td>
|
|
||||||
<td>{{e.point_name}}</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</view>
|
|
||||||
</view> -->
|
|
||||||
<view v-show="dataList.length > 0" class="zd_wrapper grid-wraper">
|
|
||||||
<view class="zd-row point-wraper">
|
|
||||||
<view class="zd-row point-item" v-for="(e, i) in dataList" :key="i" @click="toCheck(e)" :class="{'point-item_n5': index === 'QTJGSLZCQ', 'cgreen': e.point_status === '0', 'cyellow': e.point_status === '1'}">
|
|
||||||
<text>{{e.point_name}}</text>
|
|
||||||
<uni-icons class="item-checked" type="checkbox-filled" size="22" :color="e.checked ? '#4e6ef2' : 'transparent'"></uni-icons>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<view class="zd-col-4 zd-row flexcol" @tap="allCheck">
|
|
||||||
<uni-icons :type="allChecked ? 'checkbox-filled' : 'circle'" size="26" color="#4e6ef2"></uni-icons>
|
|
||||||
<view class="checkbox-text">全选</view>
|
|
||||||
</view>
|
|
||||||
<button class="zd-col-5 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-7 button-primary" :class="{'button-info': !index}" :disabled="disabled" @tap="_handheldLock('1')">锁定</button>
|
|
||||||
<button class="zd-col-7 button-primary" :class="{'button-info': !index}" :disabled="disabled" @tap="_handheldLock('0')">释放</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
// import {selectPointByRegion} from '@/utils/mork2.js'
|
|
||||||
import {selectPointByRegion, handheldLock} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
options: [{value: 'NBJGZCQ', text: '内部加工暂存区'}, {value: '111-22', text: '其他加工送料暂存区'}, {value: 'WXJGZCQ', text: '外协加工暂存区'}],
|
|
||||||
index: '',
|
|
||||||
multiple: true,
|
|
||||||
disabled: false,
|
|
||||||
dataList: [],
|
|
||||||
pkId: '',
|
|
||||||
pkObj: {},
|
|
||||||
allChecked: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
selectChange (e) {
|
|
||||||
if (e) {
|
|
||||||
this._selectPointByRegion(e)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async _selectPointByRegion (e) {
|
|
||||||
let res = await selectPointByRegion(e)
|
|
||||||
this.dataList = [...res]
|
|
||||||
this.dataList.map(el => {
|
|
||||||
this.$set(el, 'checked', false)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
toCheck (e) {
|
|
||||||
e.checked = !e.checked
|
|
||||||
let arr = this.dataList.filter(el => el.checked === true)
|
|
||||||
if (arr.length === this.dataList.length) {
|
|
||||||
this.allChecked = true
|
|
||||||
} else {
|
|
||||||
this.allChecked = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
allCheck () {
|
|
||||||
if (!this.dataList.length) return
|
|
||||||
this.allChecked = !this.allChecked
|
|
||||||
this.dataList.map(el => {
|
|
||||||
el.checked = this.allChecked
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async _handheldLock (type) {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.index) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let arr = null
|
|
||||||
if (type === '0') {
|
|
||||||
arr = this.dataList.filter(el => el.checked === true)
|
|
||||||
}
|
|
||||||
let res = await handheldLock(this.index, type, arr)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.index = ''
|
|
||||||
this.disabled = false
|
|
||||||
this.dataList = []
|
|
||||||
this.pkId = ''
|
|
||||||
this.pkObj = {}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
@import '../../common/style/mixin.styl';
|
|
||||||
</style>
|
|
||||||
@@ -1,171 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">点位</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">工序</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19 filter_select">
|
|
||||||
<uni-data-select v-model="index" :localdata="options"></uni-data-select>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd_wrapper grid-wraper">
|
|
||||||
<view class="slide_new">
|
|
||||||
<table>
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th>载具号</th>
|
|
||||||
<th>订单号</th>
|
|
||||||
<th>工序</th>
|
|
||||||
<th>物料数量</th>
|
|
||||||
<th>交期时间</th>
|
|
||||||
<th>优先级</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr v-for="(e, i) in dataList" :key="i" @click="toCheck(e)" :class="{'checked': e.vehicle_code === pkId}">
|
|
||||||
<td>{{e.vehicle_code}}</td>
|
|
||||||
<td>{{e.order_code}}</td>
|
|
||||||
<td>{{e.region_code}}</td>
|
|
||||||
<td>{{e.material_qty}}</td>
|
|
||||||
<td>{{e.due_date}}</td>
|
|
||||||
<td>{{e.priority}}</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-11 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-11 button-primary" @tap="_selectOrderByRegion">查询</button>
|
|
||||||
</view>
|
|
||||||
<view class="msg_wrapper" :class="show ? 'popshow' : 'pophide'">
|
|
||||||
<view class="pop_content">
|
|
||||||
<view class="zd_wrapper grid-wraper">
|
|
||||||
<view class="slide_new">
|
|
||||||
<table>
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th>订单号</th>
|
|
||||||
<th>交期时间</th>
|
|
||||||
<th>物料数量</th>
|
|
||||||
<th>工序</th>
|
|
||||||
<th>优先级</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr v-for="(e, i) in popList" :key="i">
|
|
||||||
<td>{{e.order_code}}</td>
|
|
||||||
<td>{{e.due_date}}</td>
|
|
||||||
<td>{{e.material_qty}}</td>
|
|
||||||
<td>{{e.region_code}}</td>
|
|
||||||
<td>{{e.priority}}</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-11 button-default" @tap="pkId = '', show = false, popList = []">取消</button>
|
|
||||||
<button class="zd-col-11 button-primary" :class="{'button-info': !popList.length}" :disabled="disabled" @tap="_callMater">叫料</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-show="show" class="msg_mask"></view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
// import {regionList, selectOrderByRegion, fabMaterial} from '@/utils/mork2.js'
|
|
||||||
import {regionList, selectOrderByRegion, fabMaterial, callMater} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
options: [],
|
|
||||||
index: '',
|
|
||||||
disabled: false,
|
|
||||||
dataList: [],
|
|
||||||
pkId: '',
|
|
||||||
show: false,
|
|
||||||
popList: []
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
this._regionList()
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async _regionList () {
|
|
||||||
let res = await regionList()
|
|
||||||
this.options = [...res.content]
|
|
||||||
this.options.map(el => {
|
|
||||||
this.$set(el, 'text', el.label)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.val1 = ''
|
|
||||||
this.index = ''
|
|
||||||
this.dataList = []
|
|
||||||
this.disabled = false
|
|
||||||
this.pkId = ''
|
|
||||||
this.show = false
|
|
||||||
this.popList = []
|
|
||||||
},
|
|
||||||
async _selectOrderByRegion () {
|
|
||||||
let res = await selectOrderByRegion(this.index, this.val1)
|
|
||||||
this.dataList = [...res.content]
|
|
||||||
},
|
|
||||||
toCheck (e) {
|
|
||||||
this.pkId = e.vehicle_code
|
|
||||||
this._fabMaterial(this.pkId)
|
|
||||||
this.show = true
|
|
||||||
},
|
|
||||||
async _fabMaterial (e) {
|
|
||||||
let res = await fabMaterial(e)
|
|
||||||
this.popList = [...res]
|
|
||||||
},
|
|
||||||
async _callMater () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.popList.length) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await callMater(this.popList, this.val1, this.pkId)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.msg,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
</style>
|
|
||||||
@@ -1,84 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">当前点位</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">载具号</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val2"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-7 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2}" :disabled="disabled" @tap="_handheldRack">确认</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
import {handheldRack} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
val2: '',
|
|
||||||
disabled: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async _handheldRack () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.val1 || !this.val2) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await handheldRack(this.val1, this.val2)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.val1 = ''
|
|
||||||
this.val2 = ''
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
</style>
|
|
||||||
@@ -1,98 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">当前点位</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">载具号</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<link-scan ref="scanChild" @getScanlist="getScanlist"/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">目的地</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19 filter_select">
|
|
||||||
<uni-data-select v-model="index" :localdata="options"></uni-data-select>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-8 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2 || !index}" :disabled="disabled" @tap="_handheldCageFrame">送回确认</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
import LinkScan from '@/components/LinkScan.vue'
|
|
||||||
import {handheldCageFrame} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox,
|
|
||||||
LinkScan
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
val2: '',
|
|
||||||
options: [{ value: '1', text: '人工折弯区' }, { value: '2', text: '半自动折弯区' }, { value: '3', text: '内部加工区' }, { value: '4', text: '货架' }],
|
|
||||||
index: '',
|
|
||||||
disabled: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
getScanlist (e) {
|
|
||||||
this.val2 = e.join()
|
|
||||||
},
|
|
||||||
async _handheldCageFrame () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.val1 || !this.val2 || !this.index) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await handheldCageFrame(this.index, this.val1, this.val2)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.val1 = ''
|
|
||||||
this.val2 = ''
|
|
||||||
this.index = ''
|
|
||||||
this.$refs.scanChild.toDel()
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
</style>
|
|
||||||
@@ -1,97 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">当前点位</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">载具类型</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-17 filter_picker">
|
|
||||||
<picker @change="pickerChange" :value="index1" :range="options1" range-key="text">
|
|
||||||
<view class="uni-input">{{index1 !== '' ? options1[index1].text : ''}}</view>
|
|
||||||
</picker>
|
|
||||||
</view>
|
|
||||||
<uni-icons type="right" size="14" color="#999"></uni-icons>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-7 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || index1 === ''}" :disabled="disabled" @tap="_handheldStorehouse">确认</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
import {vehicleType, handheldStorehouse} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
options1: [],
|
|
||||||
index1: '',
|
|
||||||
disabled: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
this._vehicleType()
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
/** 载具类型下拉框 */
|
|
||||||
async _vehicleType () {
|
|
||||||
let res = await vehicleType()
|
|
||||||
this.options1 = [...res.content]
|
|
||||||
this.options1.map(el => {
|
|
||||||
this.$set(el, 'text', el.label)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
pickerChange (e) {
|
|
||||||
this.index1 = e.detail.value
|
|
||||||
},
|
|
||||||
async _handheldStorehouse () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.val1 || this.index1 === '') {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await handheldStorehouse(this.val1, this.options1[this.index1].value)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.index1 = ''
|
|
||||||
this.val1 = ''
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
</style>
|
|
||||||
@@ -1,152 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">当前点位</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">载具号</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val2"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">目的地</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19 filter_select">
|
|
||||||
<uni-data-select v-model="index" :localdata="options" @change="selectChange"></uni-data-select>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd_wrapper grid-wraper">
|
|
||||||
<view class="slide_new">
|
|
||||||
<table>
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th>操作</th>
|
|
||||||
<th>订单号</th>
|
|
||||||
<th>物料号</th>
|
|
||||||
<th>物料数量</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr v-for="(e, i) in dataList" :key="i">
|
|
||||||
<td @tap="addRow"><uni-icons type="plus-filled" size="30" color="#4e6ef2"></uni-icons></td>
|
|
||||||
<td><input type="text" class="td_input" v-model="e.order_code"></td>
|
|
||||||
<td><input type="text" class="td_input" v-model="e.material_code"></td>
|
|
||||||
<td><input type="number" class="td_input" v-model="e.material_qty"></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-show="dataList.length > 0 && dataList[0].order_code.indexOf('OR') !== -1" class="zd_wrapper">
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-7">
|
|
||||||
<span class="filter_label">下一道工序</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-17 filter_select">
|
|
||||||
<uni-data-select v-model="index1" :localdata="options1"></uni-data-select>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-8 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2}" :disabled="disabled" @tap="_handheldBlanking">入库确认</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
import {regionList, handheldBlanking} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
val2: '',
|
|
||||||
options: [{ value: '1', text: '货架' }, { value: '2', text: '内部' }, { value: '3', text: '外协' }],
|
|
||||||
index: '',
|
|
||||||
options1: [],
|
|
||||||
index1: '',
|
|
||||||
disabled: false,
|
|
||||||
dataList: [{order_code: '', material_code: '', material_qty: 0}]
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
this._regionList()
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
selectChange (e) {
|
|
||||||
this.dataList = [{order_code: '', material_code: '', material_qty: 0}]
|
|
||||||
this.index1 = ''
|
|
||||||
},
|
|
||||||
async _regionList () {
|
|
||||||
let res = await regionList()
|
|
||||||
this.options1 = [...res.content]
|
|
||||||
this.options1.map(el => {
|
|
||||||
this.$set(el, 'text', el.label)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
addRow () {
|
|
||||||
this.dataList.push({order_code: '', material_code: '', material_qty: 0})
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.val1 = ''
|
|
||||||
this.val2 = ''
|
|
||||||
this.index = ''
|
|
||||||
this.dataList = [{order_code: '', material_code: '', material_qty: 0}]
|
|
||||||
this.index1 = ''
|
|
||||||
this.disabled = false
|
|
||||||
},
|
|
||||||
async _handheldBlanking () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.val1 || !this.val2) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
let arr = []
|
|
||||||
this.dataList.map(el => {
|
|
||||||
if (el.order_code !== '' && el.material_qty !== '') {
|
|
||||||
arr.push(el)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
try {
|
|
||||||
let res = await handheldBlanking(this.index, this.val1, this.index1, this.val2, arr)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
</style>
|
|
||||||
@@ -1,84 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">当前点位</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">载具号</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val2"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-7 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2}" :disabled="disabled" @tap="_handheldTranshipment">确认</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
import {handheldTranshipment} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
val2: '',
|
|
||||||
disabled: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async _handheldTranshipment () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.val1 || !this.val2) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await handheldTranshipment(this.val1, this.val2)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.val1 = ''
|
|
||||||
this.val2 = ''
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
</style>
|
|
||||||
104
pages/manage/mix-task.vue
Normal file
104
pages/manage/mix-task.vue
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
<template>
|
||||||
|
<view class="zd_container">
|
||||||
|
<nav-bar :title="title"></nav-bar>
|
||||||
|
<view class="zd_content">
|
||||||
|
<view class="zd_wrapper grid-wraper">
|
||||||
|
<view class="slide_new">
|
||||||
|
<table>
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>工单编码</th>
|
||||||
|
<th>序号</th>
|
||||||
|
<th>物料编码</th>
|
||||||
|
<th>物料名称</th>
|
||||||
|
<th>产线</th>
|
||||||
|
<th>站点编码</th>
|
||||||
|
<th>配料桶数</th>
|
||||||
|
<th>剩余桶数</th>
|
||||||
|
<th>物料重量</th>
|
||||||
|
<th>状态</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr v-for="(e, i) in dataList" :key="i" @click="toCheck(e)" :class="{'checked': e.work_code === pkId}">
|
||||||
|
<td>{{ e.mfg_order_name }}</td>
|
||||||
|
<td>{{ e.seq_no }}</td>
|
||||||
|
<td>{{ e.material_code }}</td>
|
||||||
|
<td>{{ e.material_name }}</td>
|
||||||
|
<td>{{ e.resource_name }}</td>
|
||||||
|
<td>{{ e.point_code }}</td>
|
||||||
|
<td>{{ e.require_num }}</td>
|
||||||
|
<td>{{ e.remain_num }}</td>
|
||||||
|
<td>{{ e.qty }}</td>
|
||||||
|
<td>{{ e.status }}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="zd-row submit-bar">
|
||||||
|
<button class="zd-col-11 button-default" @tap="clearUp">清空</button>
|
||||||
|
<button class="zd-col-11 button-primary" :disabled="disabled" :class="{'button-info': !pkId}" @tap="_handConfirm">确认</button>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import SearchBox from '@/components/SearchBox.vue'
|
||||||
|
import {queryWorks, handConfirm} from '@/utils/mork2.js'
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
NavBar,
|
||||||
|
SearchBox
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
title: '',
|
||||||
|
disabled: false,
|
||||||
|
dataList: [],
|
||||||
|
pkId: ''
|
||||||
|
};
|
||||||
|
},
|
||||||
|
onLoad (options) {
|
||||||
|
this.title = options.title
|
||||||
|
this._queryWorks()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async _queryWorks () {
|
||||||
|
let res = await queryWorks()
|
||||||
|
this.dataList = [...res]
|
||||||
|
},
|
||||||
|
clearUp () {
|
||||||
|
this.dataList = []
|
||||||
|
this.disabled = false
|
||||||
|
this.pkId = ''
|
||||||
|
},
|
||||||
|
toCheck (e) {
|
||||||
|
this.pkId = this.pkId === e.work_code ? '' : e.work_code
|
||||||
|
},
|
||||||
|
async _handConfirm () {
|
||||||
|
this.disabled = true
|
||||||
|
if (!this.pkId) {
|
||||||
|
this.disabled = false
|
||||||
|
return
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
let res = await handConfirm()
|
||||||
|
this.clearUp()
|
||||||
|
this._queryWorks()
|
||||||
|
uni.showToast({
|
||||||
|
title: res.message,
|
||||||
|
icon: 'none'
|
||||||
|
})
|
||||||
|
} catch (e) {
|
||||||
|
this.disabled = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="stylus">
|
||||||
|
</style>
|
||||||
@@ -1,131 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row border-bottom">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">载具号</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19">
|
|
||||||
<search-box
|
|
||||||
v-model="val1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd_wrapper grid-wraper">
|
|
||||||
<view class="slide_new">
|
|
||||||
<table>
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th>订单号</th>
|
|
||||||
<th>下一道工序</th>
|
|
||||||
<th>交期时间</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr v-for="(e, i) in dataList" :key="i">
|
|
||||||
<td>{{e.order_code}}</td>
|
|
||||||
<td>
|
|
||||||
<view class="td_select">
|
|
||||||
<uni-data-select v-model="e.region_code" :localdata="options" @change="selectChange"></uni-data-select>
|
|
||||||
</view>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<uni-datetime-picker
|
|
||||||
type="datetime"
|
|
||||||
v-model="e.due_date"
|
|
||||||
@change="changeLog"
|
|
||||||
/>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-7 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-8 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_fabOrders">查询</button>
|
|
||||||
<button class="zd-col-8 button-primary" :class="{'button-info': !dataList.length}" :disabled="disabled" @tap="_updateOrder">入库确认</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
// import {regionList, fabOrders} from '@/utils/mork2.js'
|
|
||||||
import {regionList, fabOrders, updateOrder} from '@/utils/getData2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
val1: '',
|
|
||||||
options: [],
|
|
||||||
index: '',
|
|
||||||
disabled: false,
|
|
||||||
dataList: [],
|
|
||||||
show: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
this._regionList()
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async _regionList () {
|
|
||||||
let res = await regionList()
|
|
||||||
this.options = [...res.content]
|
|
||||||
this.options.map(el => {
|
|
||||||
this.$set(el, 'text', el.label)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async _fabOrders () {
|
|
||||||
let res = await fabOrders(this.val1)
|
|
||||||
this.dataList = [...res]
|
|
||||||
},
|
|
||||||
selectChange (val) {
|
|
||||||
},
|
|
||||||
changeLog (e) {
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.dataList = []
|
|
||||||
this.disabled = false
|
|
||||||
},
|
|
||||||
async _updateOrder () {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.dataList.length) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await updateOrder(this.dataList)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus" scoped>
|
|
||||||
.zd_content
|
|
||||||
height: calc(100% - var(--status-bar-height) - 212rpx);
|
|
||||||
padding: 20rpx 14rpx 0 14rpx;
|
|
||||||
.grid-wraper
|
|
||||||
height: 100%;
|
|
||||||
overflow: auto;
|
|
||||||
.slide_new table td, .slide_new table th
|
|
||||||
overflow: visible;
|
|
||||||
</style>
|
|
||||||
@@ -1,104 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="zd_container">
|
|
||||||
<nav-bar :title="title"></nav-bar>
|
|
||||||
<view class="zd_content">
|
|
||||||
<view class="zd_wrapper">
|
|
||||||
<view class="zd-row">
|
|
||||||
<view class="zd-col-5">
|
|
||||||
<span class="filter_label">类型</span>
|
|
||||||
</view>
|
|
||||||
<view class="zd-col-19 filter_select">
|
|
||||||
<zxz-uni-data-select
|
|
||||||
v-model="index1"
|
|
||||||
:localdata="options1"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="zd-row submit-bar">
|
|
||||||
<button class="zd-col-5 button-default" @tap="clearUp">清空</button>
|
|
||||||
<button class="zd-col-8 button-primary" :class="{'button-info': !index1}" :disabled="disabled" @tap="toSure('1')">锁定</button>
|
|
||||||
<button class="zd-col-8 button-primary" :class="{'button-info': !index1}" :disabled="disabled" @tap="_updateRouteStatus('0')">释放</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
|
||||||
import {updateRouteStatus} from '@/utils/getData2.js'
|
|
||||||
// import {updateRouteStatus} from '@/utils/mork2.js'
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
NavBar,
|
|
||||||
SearchBox
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
title: '',
|
|
||||||
options1: [{value: '1', text: '外协到冲床一'}, {value: '2', text: '外协到冲床二'}, {value: '3', text: '外协到冲床三'}, {value: '4', text: '外协到激光'}],
|
|
||||||
index1: '',
|
|
||||||
disabled: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
onLoad (options) {
|
|
||||||
this.title = options.title
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
toSure (type) {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.index1) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
uni.showModal({
|
|
||||||
title: '提示',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
content: '请确认当前锁定路线不存在AGV',
|
|
||||||
success: (res) => {
|
|
||||||
if (res.confirm) {
|
|
||||||
this._updateRouteStatus(type)
|
|
||||||
} else if (res.cancel) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async _updateRouteStatus (type) {
|
|
||||||
this.disabled = true
|
|
||||||
if (!this.index1) {
|
|
||||||
this.disabled = false
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let res = await updateRouteStatus(this.index1, type)
|
|
||||||
this.clearUp()
|
|
||||||
uni.showToast({
|
|
||||||
title: res.message,
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
this.$globalData.stopTimer()
|
|
||||||
if (type === '1') {
|
|
||||||
this.$store.dispatch('setRouteStatus', true)
|
|
||||||
this.$globalData.startTimer()
|
|
||||||
} else {
|
|
||||||
this.$store.dispatch('delRouteStatus', false)
|
|
||||||
this.$globalData.stopTimer()
|
|
||||||
}
|
|
||||||
} catch (e) {
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearUp () {
|
|
||||||
this.index1 = ''
|
|
||||||
this.disabled = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="stylus">
|
|
||||||
@import '../../common/style/mixin.styl';
|
|
||||||
</style>
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
import request from './request.js'
|
|
||||||
@@ -20,78 +20,13 @@ export const handLogin = (user, password) => request({
|
|||||||
password: password
|
password: password
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
// 区域
|
// 配料作业查询
|
||||||
export const regionList = () => request({
|
export const queryWorks = () => request({
|
||||||
url:'api/fab/regionList',
|
url:'api/hand/queryWorks',
|
||||||
method: 'GET'
|
|
||||||
})
|
|
||||||
// 区域锁定
|
|
||||||
export const handheldLock = (code, status, data) => request({
|
|
||||||
url:'api/handheld/lock',
|
|
||||||
data: {region_code: code, status: status, pointCodes: data}
|
|
||||||
})
|
|
||||||
// 外协区空料架送回
|
|
||||||
export const handheldRack = (code, vcode) => request({
|
|
||||||
url:'api/handheld/rack',
|
|
||||||
data: {device_code: code, vehicle_code: vcode}
|
|
||||||
})
|
|
||||||
// 外协区空笼框送回
|
|
||||||
export const handheldCageFrame = (type, code, list) => request({
|
|
||||||
url:'api/handheld/cageFrame',
|
|
||||||
data: {type: type, device_code: code, vehicle_list: list}
|
|
||||||
})
|
|
||||||
// 物料转运
|
|
||||||
export const handheldTranshipment = (code, vcode) => request({
|
|
||||||
url:'api/handheld/transhipment',
|
|
||||||
data: {device_code: code, vehicle_code: vcode}
|
|
||||||
})
|
|
||||||
// 载具类型列表
|
|
||||||
export const vehicleType = () => request({
|
|
||||||
url:'api/fab/vehicleType',
|
|
||||||
data: {}
|
data: {}
|
||||||
})
|
})
|
||||||
// 补空框
|
// 确认配料作业
|
||||||
export const handheldStorehouse = (code, type) => request({
|
export const handConfirm = () => request({
|
||||||
url:'api/handheld/storehouse',
|
url:'api/hand/confirm',
|
||||||
data: {device_code: code, vehicle_type: type}
|
data: {work_code: code}
|
||||||
})
|
|
||||||
// 工序下料
|
|
||||||
// export const handheldGetRegionCode = (code) => request({
|
|
||||||
// url:'api/handheld/getRegionCode',
|
|
||||||
// data: {orderCode: code}
|
|
||||||
// })
|
|
||||||
export const handheldBlanking = (type, code, rcode, vcode, material) => request({
|
|
||||||
url:'api/handheld/blanking',
|
|
||||||
data: {type: type, device_code: code, region_code: rcode, vehicle_code: vcode, material: material}
|
|
||||||
})
|
|
||||||
// 修改订单工序
|
|
||||||
export const fabOrders = (code) => request({
|
|
||||||
url:'api/fab/orders',
|
|
||||||
data: {vehicle_code: code}
|
|
||||||
})
|
|
||||||
export const updateOrder = (data) => request({
|
|
||||||
url:'api/handheld/updateOrder',
|
|
||||||
data: data
|
|
||||||
})
|
|
||||||
// 路线锁定
|
|
||||||
export const updateRouteStatus = (type, status) => request({
|
|
||||||
url:'api/handheld/updateRouteStatus',
|
|
||||||
data: {type: type, status: status}
|
|
||||||
})
|
|
||||||
// 呼叫物料
|
|
||||||
export const selectOrderByRegion = (code, code1) => request({
|
|
||||||
url:'api/fab/selectOrderByRegion?regionCode=' + code + '&deviceCode=' + code1,
|
|
||||||
method: 'GET'
|
|
||||||
})
|
|
||||||
export const fabMaterial = (code) => request({
|
|
||||||
url:'api/fab/material',
|
|
||||||
data: {vehicle_code: code}
|
|
||||||
})
|
|
||||||
export const callMater = (mater, code, vcode) => request({
|
|
||||||
url:'api/fab/callMater',
|
|
||||||
data: {mater: mater, device_code: code, vehicle_code: vcode}
|
|
||||||
})
|
|
||||||
export const selectPointByRegion = (code) => request({
|
|
||||||
url:'api/handheld/selectPointByRegion?regionCode=' + code,
|
|
||||||
method: 'GET'
|
|
||||||
})
|
})
|
||||||
@@ -7,36 +7,50 @@ export const handLogin = (user, password) => {
|
|||||||
}
|
}
|
||||||
return res
|
return res
|
||||||
}
|
}
|
||||||
export const regionList = () => {
|
export const queryWorks = () => {
|
||||||
let res = {
|
|
||||||
content: [{value: '1', label: 'A0000001'}, {value: '2', label: 'A0000002'}, {value: '3', label: 'A0000003'}, {value: '4', label: 'A0000004'}, {value: '5', label: 'A0000005'}, {value: '6', label: 'A0000006'}]
|
|
||||||
}
|
|
||||||
return res
|
|
||||||
}
|
|
||||||
|
|
||||||
export const fabOrders = (data) => {
|
|
||||||
let res = [
|
let res = [
|
||||||
{order_code: '111'}
|
{
|
||||||
|
"seq_no": 1,
|
||||||
|
"work_code": "000032",
|
||||||
|
"mfg_order_name": "20240110-2514",
|
||||||
|
"material_code": "10305020",
|
||||||
|
"material_name": "菜籽油",
|
||||||
|
"qty": 415.0,
|
||||||
|
"resource_name": "1",
|
||||||
|
"require_num": 21,
|
||||||
|
"remain_num": 21,
|
||||||
|
"status": "执行中"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"seq_no": 3,
|
||||||
|
"work_code": "000034",
|
||||||
|
"mfg_order_name": "20240110-2514",
|
||||||
|
"material_code": "10305092",
|
||||||
|
"material_name": "橄榄油",
|
||||||
|
"qty": 500.0,
|
||||||
|
"resource_name": "1",
|
||||||
|
"require_num": 25,
|
||||||
|
"remain_num": 25,
|
||||||
|
"status": "就绪"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"seq_no": 4,
|
||||||
|
"work_code": "000035",
|
||||||
|
"mfg_order_name": "20240110-2514",
|
||||||
|
"material_code": "10305093",
|
||||||
|
"material_name": "花生油",
|
||||||
|
"qty": 370.0,
|
||||||
|
"resource_name": "1",
|
||||||
|
"require_num": 19,
|
||||||
|
"remain_num": 19,
|
||||||
|
"status": "就绪"
|
||||||
|
}
|
||||||
]
|
]
|
||||||
return res
|
return res
|
||||||
}
|
}
|
||||||
export const updateRouteStatus = (data) => {
|
export const handConfirm = () => {
|
||||||
let res = {
|
let res = {
|
||||||
message: 'ok'
|
message: 'ok'
|
||||||
}
|
}
|
||||||
return res
|
return res
|
||||||
}
|
|
||||||
export const selectOrderByRegion = (code, code1) => {
|
|
||||||
let res = {
|
|
||||||
content: [{ vehicle_code: '123', order_code: '800034202869', region_code: '111-07', material_id: 'A7E0019008760_00', material_type: 'S39_SA01', custom: 'BBC支撑板后上', material_qty: '120', plan_date: '2024/8/11' }]
|
|
||||||
}
|
|
||||||
return res
|
|
||||||
}
|
|
||||||
export const fabMaterial = (code, code1) => {
|
|
||||||
let res = [{ vehicle_code: '123', order_code: '800034202869', region_code: '111-07', material_id: 'A7E0019008760_00', material_type: 'S39_SA01', custom: 'BBC支撑板后上', material_qty: '120', plan_date: '2024/8/11' }, { vehicle_code: '123', order_code: '800034202869', region_code: '111-07', material_id: 'A7E0019008760_00', material_type: 'S39_SA01', custom: 'BBC支撑板后上', material_qty: '120', plan_date: '2024/8/11' }, { vehicle_code: '123', order_code: '800034202869', region_code: '111-07', material_id: 'A7E0019008760_00', material_type: 'S39_SA01', custom: 'BBC支撑板后上', material_qty: '120', plan_date: '2024/8/11' }, { vehicle_code: '123', order_code: '800034202869', region_code: '111-07', material_id: 'A7E0019008760_00', material_type: 'S39_SA01', custom: 'BBC支撑板后上', material_qty: '120', plan_date: '2024/8/11' }]
|
|
||||||
return res
|
|
||||||
}
|
|
||||||
export const selectPointByRegion = (code) => {
|
|
||||||
let res = [{point_code: '1', point_name: 'Amada 80T冲床07-01-06-01'}, {point_code: '2', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '3', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '4', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '5', point_name: 'Amada 80T冲床07-01-06-01', point_status: '1'}, {point_code: '1', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '2', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '3', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '4', point_name: 'Amada 80T冲床07-01-06-01', point_status: '0'}, {point_code: '5', point_name: 'Amada 80T冲床07-01-06-01', point_status: '1'}]
|
|
||||||
return res
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user