AGV下拉选择站点功能实现
This commit is contained in:
@@ -56,3 +56,27 @@ export function FinisBatchingTask(params) {
|
||||
params
|
||||
})
|
||||
}
|
||||
// 返程起点下拉
|
||||
export function getStartOptions(params) {
|
||||
return request({
|
||||
url: '/mes/mm/materialinput/emptycarreturn_start',
|
||||
method: 'get',
|
||||
params
|
||||
})
|
||||
}
|
||||
// 返程终点下拉
|
||||
export function getEndOptions(params) {
|
||||
return request({
|
||||
url: '/mes/mm/materialinput/emptycarreturn_end',
|
||||
method: 'get',
|
||||
params
|
||||
})
|
||||
}
|
||||
// 所有点位下拉
|
||||
export function getAllOptions(params) {
|
||||
return request({
|
||||
url: '/mes/mm/MmFinishedwarehouse/finish_point',
|
||||
method: 'get',
|
||||
params
|
||||
})
|
||||
}
|
||||
@@ -94,13 +94,13 @@
|
||||
<u-text text="起点" size="48"></u-text>
|
||||
</u-col>
|
||||
<u-col span="4">
|
||||
<u-input v-model="start_point" placeholder="请输入起点" clearable></u-input>
|
||||
<uni-data-select v-model="start_point" :localdata="startOptions"></uni-data-select>
|
||||
</u-col>
|
||||
<u-col span="2">
|
||||
<u-text text="终点" size="48"></u-text>
|
||||
</u-col>
|
||||
<u-col span="4">
|
||||
<u-input v-model="end_point" placeholder="请输入终点" clearable></u-input>
|
||||
<uni-data-select v-model="end_point" :localdata="endOptions"></uni-data-select>
|
||||
</u-col>
|
||||
</u-row>
|
||||
<u-gap height="20"></u-gap>
|
||||
@@ -124,7 +124,9 @@
|
||||
getIngredientTask_son,
|
||||
getfabgopoints,
|
||||
go_workshop,
|
||||
emergency_stop_agv
|
||||
emergency_stop_agv,
|
||||
getStartOptions,
|
||||
getEndOptions
|
||||
} from '@/api/materialManagement/MaterialRequsition.js';
|
||||
export default {
|
||||
data() {
|
||||
@@ -148,7 +150,10 @@
|
||||
start_point: '',
|
||||
end_point: '',
|
||||
fab_go_points: [],
|
||||
reqCode: ''
|
||||
reqCode: '',
|
||||
// 空车返程
|
||||
startOptions: [],
|
||||
endOptions: []
|
||||
};
|
||||
},
|
||||
watch: {},
|
||||
@@ -167,6 +172,7 @@
|
||||
},
|
||||
mounted() {
|
||||
this.getInitList();
|
||||
this.getSelectOptions();
|
||||
},
|
||||
methods: {
|
||||
// todo 分页查询
|
||||
@@ -194,6 +200,32 @@
|
||||
}
|
||||
});
|
||||
},
|
||||
getSelectOptions() {
|
||||
getStartOptions().then(res => {
|
||||
if (res.code === 200) {
|
||||
let _list = [];
|
||||
res.data.forEach(item => {
|
||||
_list.push({
|
||||
value: item,
|
||||
text: item
|
||||
})
|
||||
})
|
||||
this.startOptions = _list;
|
||||
}
|
||||
})
|
||||
getEndOptions().then(res => {
|
||||
if (res.code === 200) {
|
||||
let _list = [];
|
||||
res.data.forEach(item => {
|
||||
_list.push({
|
||||
value: item,
|
||||
text: item
|
||||
})
|
||||
})
|
||||
this.endOptions = _list;
|
||||
}
|
||||
})
|
||||
},
|
||||
sectionChange(index) {
|
||||
this.current = index;
|
||||
this.start_point = '';
|
||||
@@ -234,6 +266,7 @@
|
||||
//todo 确认起点
|
||||
confirm_startpoint(point) {
|
||||
this.start_point = point;
|
||||
this.get_fab_go_points();
|
||||
},
|
||||
//todo获取车间点
|
||||
get_fab_go_points() {
|
||||
|
||||
@@ -7,13 +7,13 @@
|
||||
<u-text text="起点" size="48"></u-text>
|
||||
</u-col>
|
||||
<u-col span="4">
|
||||
<u-input v-model="start_point" placeholder="请输入起点" clearable></u-input>
|
||||
<uni-data-select v-model="start_point" :localdata="startOptions" placeholder="请选择起点"></uni-data-select>
|
||||
</u-col>
|
||||
<u-col span="2">
|
||||
<u-text text="终点" size="48"></u-text>
|
||||
</u-col>
|
||||
<u-col span="4">
|
||||
<u-input v-model="end_point" placeholder="请输入终点" clearable></u-input>
|
||||
<uni-data-select v-model="end_point" :localdata="endOptions" placeholder="请选择终点"></uni-data-select>
|
||||
</u-col>
|
||||
</u-row>
|
||||
<u-gap height="20"></u-gap>
|
||||
@@ -34,14 +34,17 @@
|
||||
<script>
|
||||
import {
|
||||
go_workshop,
|
||||
emergency_stop_agv
|
||||
emergency_stop_agv,
|
||||
getAllOptions
|
||||
} from '@/api/materialManagement/MaterialRequsition.js';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
start_point: '',
|
||||
startOptions:[],
|
||||
end_point: '',
|
||||
endOptions:[],
|
||||
reqCode: ''
|
||||
};
|
||||
},
|
||||
@@ -54,7 +57,19 @@
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
|
||||
getAllOptions().then(res=>{
|
||||
if(res.code===200){
|
||||
let _list = [];
|
||||
res.data.forEach(item => {
|
||||
_list.push({
|
||||
value: item,
|
||||
text: item
|
||||
})
|
||||
})
|
||||
this.startOptions = _list;
|
||||
this.endOptions = _list;
|
||||
}
|
||||
})
|
||||
|
||||
},
|
||||
start_agv() {
|
||||
|
||||
Reference in New Issue
Block a user