指令
This commit is contained in:
@@ -4,15 +4,21 @@
|
|||||||
<view class="search-confirm-wrap">
|
<view class="search-confirm-wrap">
|
||||||
<view class="search-wrap">
|
<view class="search-wrap">
|
||||||
<view class="search-item">
|
<view class="search-item">
|
||||||
<label class="search-label">缓存线</label>
|
<label class="search-label">生产区域</label>
|
||||||
<view class="filter_input_wraper">
|
<view class="filter_input_wraper">
|
||||||
<uni-data-select v-model="index1" :localdata="options1" @change="selectChange1"></uni-data-select>
|
<uni-data-select v-model="index1" :localdata="options1" @change="selectChange1"></uni-data-select>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="search-item">
|
||||||
|
<label class="search-label">缓存线</label>
|
||||||
|
<view class="filter_input_wraper">
|
||||||
|
<uni-data-select v-model="index2" :localdata="options2" @change="selectChange2"></uni-data-select>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="confirm-button-wrap">
|
<view class="confirm-button-wrap">
|
||||||
<button class="confirm-button" :disabled="disabled" @tap="toSure()">暂停</button>
|
<button class="confirm-button" :disabled="disabled" @tap="toSure('1')">暂停</button>
|
||||||
<button class="confirm-button" :disabled="disabled" @tap="toSure()">启动</button>
|
<button class="confirm-button" :disabled="disabled" @tap="toSure('2')">启动</button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -21,7 +27,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
import SearchBox from '@/components/SearchBox.vue'
|
||||||
import {cacheLineExcepOpt} from '@/utils/getData1.js'
|
import {getCacheLine, cacheLineExcepOpt} from '@/utils/getData1.js'
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
NavBar,
|
NavBar,
|
||||||
@@ -29,35 +35,52 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
options1: [],
|
options1: [{text: 'A1', value: 'A1'}, {text: 'A2', value: 'A2'}],
|
||||||
index1: '',
|
index1: 'A1',
|
||||||
|
options2: [],
|
||||||
|
index2: '',
|
||||||
disabled: false
|
disabled: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
this._getCacheLine('A1')
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
/** 选择器1 */
|
/** 选择器1 */
|
||||||
selectChange1(e) {
|
selectChange1(e) {
|
||||||
this.index1 = e
|
this.index1 = e
|
||||||
|
if (this.index1) {
|
||||||
|
this._getCacheLine(e)
|
||||||
|
}
|
||||||
|
this.index2 = ''
|
||||||
|
},
|
||||||
|
/** 选择器2 */
|
||||||
|
selectChange2(e) {
|
||||||
|
this.index2 = e
|
||||||
|
},
|
||||||
|
async _getCacheLine (id) {
|
||||||
|
let res = await getCacheLine(id)
|
||||||
|
this.options2 = [...res]
|
||||||
},
|
},
|
||||||
async toSure (type) {
|
async toSure (type) {
|
||||||
this.disabled = true
|
this.disabled = true
|
||||||
if (!this.index1) {
|
if (!this.index2) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '请选择',
|
title: '请选择',
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
})
|
})
|
||||||
this.disabled = false
|
this.disabled = false
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
let res = await _cacheLineExcepOpt()
|
let res = await cacheLineExcepOpt(this.index2, type)
|
||||||
this.disabled = false
|
this.disabled = false
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: res.message,
|
title: res.message,
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
})
|
})
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
this.disabled = false
|
this.disabled = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,17 +4,31 @@
|
|||||||
<view class="search-confirm-wrap">
|
<view class="search-confirm-wrap">
|
||||||
<view class="search-wrap">
|
<view class="search-wrap">
|
||||||
<view class="search-item">
|
<view class="search-item">
|
||||||
<label class="search-label">缓存线</label>
|
<label class="search-label">生产区域</label>
|
||||||
<view class="filter_input_wraper">
|
<view class="filter_input_wraper">
|
||||||
<uni-data-select v-model="index1" :localdata="options1" @change="selectChange1"></uni-data-select>
|
<uni-data-select v-model="index1" :localdata="options1" @change="selectChange1"></uni-data-select>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="search-item">
|
<view class="search-item">
|
||||||
<label class="search-label">车号</label>
|
<label class="search-label">缓存线</label>
|
||||||
|
<view class="filter_input_wraper">
|
||||||
|
<uni-data-select v-model="index2" :localdata="options2" @change="selectChange2"></uni-data-select>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="search-item">
|
||||||
|
<label class="search-label">缓存线位置</label>
|
||||||
<view class="filter_input_wraper">
|
<view class="filter_input_wraper">
|
||||||
<input type="text" class="search-input-l" v-model="val1">
|
<input type="text" class="search-input-l" v-model="val1">
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="search-item">
|
||||||
|
<label class="search-label">料箱码</label>
|
||||||
|
<view class="filter_input_wraper">
|
||||||
|
<search-box
|
||||||
|
v-model="val2"
|
||||||
|
/>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="confirm-button-wrap">
|
<view class="confirm-button-wrap">
|
||||||
<button class="confirm-button" @tap="toSearch()">查询</button>
|
<button class="confirm-button" @tap="toSearch()">查询</button>
|
||||||
@@ -28,6 +42,7 @@
|
|||||||
<th>选择</th>
|
<th>选择</th>
|
||||||
<th>指令编号</th>
|
<th>指令编号</th>
|
||||||
<th>设备编号</th>
|
<th>设备编号</th>
|
||||||
|
<th>条码</th>
|
||||||
<th>起点</th>
|
<th>起点</th>
|
||||||
<th>目的</th>
|
<th>目的</th>
|
||||||
<th>目的2</th>
|
<th>目的2</th>
|
||||||
@@ -40,6 +55,7 @@
|
|||||||
</td>
|
</td>
|
||||||
<td>{{e.instructorder_no}}</td>
|
<td>{{e.instructorder_no}}</td>
|
||||||
<td>{{e.wcsdevice_code}}</td>
|
<td>{{e.wcsdevice_code}}</td>
|
||||||
|
<td>{{e.vehicle_code}}</td>
|
||||||
<td>{{e.startpoint_code}}</td>
|
<td>{{e.startpoint_code}}</td>
|
||||||
<td>{{e.nextpoint_code}}</td>
|
<td>{{e.nextpoint_code}}</td>
|
||||||
<td>{{e.nextpoint_code2}}</td>
|
<td>{{e.nextpoint_code2}}</td>
|
||||||
@@ -53,7 +69,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import SearchBox from '@/components/SearchBox.vue'
|
import SearchBox from '@/components/SearchBox.vue'
|
||||||
import {queryInstraction, instOperation} from '@/utils/getData2.js'
|
import {getCacheLine, cacheLineOutBoxExceptionQuery, cacheLineOutBoxExceptionConfirm} from '@/utils/getData1.js'
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
NavBar,
|
NavBar,
|
||||||
@@ -61,28 +77,47 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
options1: [],
|
options1: [{text: 'A1', value: 'A1'}, {text: 'A2', value: 'A2'}],
|
||||||
index1: '',
|
index1: 'A1',
|
||||||
|
options2: [],
|
||||||
|
index2: '',
|
||||||
val1: '',
|
val1: '',
|
||||||
|
val2: '',
|
||||||
dataList: [],
|
dataList: [],
|
||||||
pkId: '',
|
pkId: '',
|
||||||
disabled: false
|
disabled: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
this._getCacheLine('A1')
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
/** 选择器1 */
|
/** 选择器1 */
|
||||||
selectChange1(e) {
|
selectChange1(e) {
|
||||||
this.index1 = e
|
this.index1 = e
|
||||||
|
if (this.index1) {
|
||||||
|
this._getCacheLine(e)
|
||||||
|
}
|
||||||
|
this.index2 = ''
|
||||||
|
},
|
||||||
|
/** 选择器2 */
|
||||||
|
selectChange2(e) {
|
||||||
|
this.index2 = e
|
||||||
},
|
},
|
||||||
toSearch () {
|
toSearch () {
|
||||||
this.dataList = []
|
this.dataList = []
|
||||||
this._queryInstraction()
|
this.pkId = ''
|
||||||
|
this._cacheLineOutBoxExceptionQuery()
|
||||||
},
|
},
|
||||||
async _queryInstraction () {
|
async _getCacheLine (id) {
|
||||||
let res = await queryInstraction()
|
let res = await getCacheLine(id)
|
||||||
this.dataList = [...res.data]
|
this.options2 = [...res]
|
||||||
},
|
},
|
||||||
toSure () {
|
async _cacheLineOutBoxExceptionQuery () {
|
||||||
|
let res = await cacheLineOutBoxExceptionQuery(this.index2, this.val1)
|
||||||
|
this.dataList = [...res]
|
||||||
|
},
|
||||||
|
async toSure () {
|
||||||
this.disabled = true
|
this.disabled = true
|
||||||
if (!this.pkId) {
|
if (!this.pkId) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -92,11 +127,17 @@
|
|||||||
this.disabled = false
|
this.disabled = false
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this._instOperation()
|
try {
|
||||||
},
|
let res = await cacheLineOutBoxExceptionConfirm(this.index2,this.pkId, '2', this.val2, this.index1, this.val1)
|
||||||
async _instOperation () {
|
this.disabled = false
|
||||||
let res = await instOperation()
|
this.toSearch()
|
||||||
this.dataList = [...res.data]
|
uni.showToast({
|
||||||
|
title: res.message,
|
||||||
|
icon: 'none'
|
||||||
|
})
|
||||||
|
} catch (e) {
|
||||||
|
this.disabled = false
|
||||||
|
}
|
||||||
},
|
},
|
||||||
toRadio (e) {
|
toRadio (e) {
|
||||||
this.pkId = this.pkId === e.instruct_uuid ? '' : e.instruct_uuid
|
this.pkId = this.pkId === e.instruct_uuid ? '' : e.instruct_uuid
|
||||||
|
|||||||
@@ -57,9 +57,9 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="confirm-button-wrap">
|
<view class="confirm-button-wrap">
|
||||||
<button class="confirm-button" @tap="toSearch()">查询</button>
|
<button class="confirm-button" @tap="toSearch()">查询</button>
|
||||||
<button class="confirm-button" :disabled="disabled" @tap="toSure('1')">取消</button>
|
<button class="confirm-button" :disabled="disabled" @tap="toSure('8')">取消</button>
|
||||||
<button class="confirm-button" :disabled="disabled" @tap="toSure('2')">完成</button>
|
<button class="confirm-button" :disabled="disabled" @tap="toSure('7')">完成</button>
|
||||||
<button class="confirm-button" :disabled="disabled" @tap="toSure('3')">重发</button>
|
<button class="confirm-button" :disabled="disabled" @tap="toSure('5')">重发</button>
|
||||||
<button class="confirm-button" :disabled="disabled" @tap="toSure('4')">WCS取消</button>
|
<button class="confirm-button" :disabled="disabled" @tap="toSure('4')">WCS取消</button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -86,8 +86,8 @@
|
|||||||
</td>
|
</td>
|
||||||
<td>{{e.instructoperate_num}}</td>
|
<td>{{e.instructoperate_num}}</td>
|
||||||
<td>{{e.mes_no}}</td>
|
<td>{{e.mes_no}}</td>
|
||||||
<td>{{e.startwcsdevice_code}}</td>
|
<td>{{e.startpoint_code}}</td>
|
||||||
<td>{{e.nextwcsdevice_code}}</td>
|
<td>{{e.nextpoint_code}}</td>
|
||||||
<td>{{e.invehicle_code}}</td>
|
<td>{{e.invehicle_code}}</td>
|
||||||
<td>{{e.outvehicle_code}}</td>
|
<td>{{e.outvehicle_code}}</td>
|
||||||
<td>{{e.status_name}}</td>
|
<td>{{e.status_name}}</td>
|
||||||
@@ -182,7 +182,7 @@
|
|||||||
},
|
},
|
||||||
async _instStatusQuery (id) {
|
async _instStatusQuery (id) {
|
||||||
let res = await instStatusQuery(id)
|
let res = await instStatusQuery(id)
|
||||||
this.options1 = [...res.result]
|
this.options1 = [...res]
|
||||||
},
|
},
|
||||||
toSearch () {
|
toSearch () {
|
||||||
this.dataList = []
|
this.dataList = []
|
||||||
@@ -204,9 +204,9 @@
|
|||||||
end_date: this.endDate || ''
|
end_date: this.endDate || ''
|
||||||
}
|
}
|
||||||
let res = await instPageQuery(form)
|
let res = await instPageQuery(form)
|
||||||
this.totalCount = res.size
|
this.totalCount = res.totalElements
|
||||||
if (res.size > 0) {
|
if (res.totalElements > 0) {
|
||||||
const dataMap = res.data
|
const dataMap = res.content
|
||||||
this.dataList = this.reload ? dataMap : this.dataList.concat(dataMap)
|
this.dataList = this.reload ? dataMap : this.dataList.concat(dataMap)
|
||||||
this.reload = false
|
this.reload = false
|
||||||
} else {
|
} else {
|
||||||
@@ -243,7 +243,7 @@
|
|||||||
},
|
},
|
||||||
async _instOperation (type) {
|
async _instOperation (type) {
|
||||||
let res = await instOperation(type)
|
let res = await instOperation(type)
|
||||||
this.dataList = [...res.data]
|
this.dataList = [...res]
|
||||||
},
|
},
|
||||||
toRadio (e) {
|
toRadio (e) {
|
||||||
this.pkId = this.pkId === e.instruct_uuid ? '' : e.instruct_uuid
|
this.pkId = this.pkId === e.instruct_uuid ? '' : e.instruct_uuid
|
||||||
@@ -255,5 +255,5 @@
|
|||||||
<style lang="stylus" scoped>
|
<style lang="stylus" scoped>
|
||||||
@import '../../common/style/mixin.styl';
|
@import '../../common/style/mixin.styl';
|
||||||
.grid-wrap
|
.grid-wrap
|
||||||
height calc(100% - 526rpx)
|
height: calc(100% - 337px); /** 42+ 15*8+ 35*5 */
|
||||||
</style>
|
</style>
|
||||||
@@ -12,9 +12,7 @@ export const getCacheLine = (area) => request({
|
|||||||
export const instStatusQuery = (searchbar) => request({
|
export const instStatusQuery = (searchbar) => request({
|
||||||
url:'/api/cacheLineHand/instStatusQuery',
|
url:'/api/cacheLineHand/instStatusQuery',
|
||||||
data: {
|
data: {
|
||||||
form: {
|
search_bar: searchbar
|
||||||
search_bar: searchbar
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -23,10 +21,8 @@ export const instStatusQuery = (searchbar) => request({
|
|||||||
export const cacheLineExcepOpt = (wcode, opttype) => request({
|
export const cacheLineExcepOpt = (wcode, opttype) => request({
|
||||||
url:'/api/cacheLineHand/cacheLineExcepOpt',
|
url:'/api/cacheLineHand/cacheLineExcepOpt',
|
||||||
data: {
|
data: {
|
||||||
form: {
|
wcsdevice_code: wcode,
|
||||||
wcsdevice_code: wcode,
|
opt_type: opttype
|
||||||
opt_type: opttype
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -35,43 +31,35 @@ export const cacheLineExcepOpt = (wcode, opttype) => request({
|
|||||||
export const cacheLineOutBoxExceptionQuery = (wcode, pcode) => request({
|
export const cacheLineOutBoxExceptionQuery = (wcode, pcode) => request({
|
||||||
url:'/api/cacheLineHand/cacheLineOutBoxExceptionQuery',
|
url:'/api/cacheLineHand/cacheLineOutBoxExceptionQuery',
|
||||||
data: {
|
data: {
|
||||||
form: {
|
wcsdevice_code: wcode,
|
||||||
wcsdevice_code: wcode,
|
position_code: pcode
|
||||||
position_code: pcode
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
// 1.2缓存线出箱异常-确认:
|
// 1.2缓存线出箱异常-确认:
|
||||||
export const cacheLineOutBoxExceptionConfirm = (wcode, uuid, itype, vcode, parea, pcode) => request({
|
export const cacheLineOutBoxExceptionConfirm = (wcode, uuid, itype, vcode, parea, pcode) => request({
|
||||||
url:'/api/cacheLineHand/cacheLineOutBoxExceptionConfirm',
|
url:'/api/cacheLineHand/cacheLineOutBoxExceptionConfirm',
|
||||||
data: {
|
data: {
|
||||||
form: {
|
wcsdevice_code: wcode,
|
||||||
wcsdevice_code: wcode,
|
instruct_uuid: uuid,
|
||||||
instruct_uuid: uuid,
|
inOut_type: itype,
|
||||||
inOut_type: itype,
|
vehicle_code: vcode,
|
||||||
vehicle_code: vcode,
|
product_area: parea,
|
||||||
product_area: parea,
|
position_code: pcode
|
||||||
position_code: pcode
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
/** 指令操作 */
|
/** 指令操作 */
|
||||||
// 1.1指令分页查询:
|
// 1.1指令分页查询:
|
||||||
export const instPageQuery = (form) => request({
|
export const instPageQuery = (data) => request({
|
||||||
url:'/api/cacheLineHand/instPageQuery',
|
url:'/api/cacheLineHand/instPageQuery',
|
||||||
data: {
|
data: data
|
||||||
form: form
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 1.2指令操作:
|
// 1.2指令操作:
|
||||||
export const instOperation = (uuid, otype) => request({
|
export const instOperation = (uuid, otype) => request({
|
||||||
url:'/api/cacheLineHand/instOperation',
|
url:'/api/cacheLineHand/instOperation',
|
||||||
data: {
|
data: {
|
||||||
form: {
|
instruct_uuid: uuid,
|
||||||
instruct_uuid: uuid,
|
opt_type: otype
|
||||||
opt_type: otype
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user