外包材
This commit is contained in:
@@ -141,7 +141,7 @@
|
||||
try {
|
||||
let res = await insideCodeInsert(e)
|
||||
if (res) {
|
||||
this.dataList.push(res.data)
|
||||
this.dataList = [...this.dataList, ...res.data]
|
||||
} else {
|
||||
this.dataList = []
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">总数量</span>
|
||||
<span class="filter_label filter_input_disabled">总数量</span>
|
||||
</view>
|
||||
<view class="zd-col-24">
|
||||
<input type="number" v-model="num" class="filter_input filter_input_disabled" disabled>
|
||||
@@ -124,7 +124,7 @@
|
||||
try {
|
||||
let res = await getPalletAssembly(e)
|
||||
if (res) {
|
||||
this.dataList.push(res.data)
|
||||
this.dataList = [...this.dataList, ...res.data]
|
||||
this.num = this.dataList.reduce((sum, item) => sum + Number(item.qty), 0)
|
||||
} else {
|
||||
this.dataList = []
|
||||
|
||||
@@ -152,7 +152,7 @@
|
||||
try {
|
||||
let res = await directlyOutCodeInsert(e)
|
||||
if (res) {
|
||||
this.dataList.push(res.data)
|
||||
this.dataList = [...this.dataList, ...res.data]
|
||||
this.dataList.forEach(e => {
|
||||
e.initialQty = e.qty
|
||||
})
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">总数量</span>
|
||||
<span class="filter_label filter_input_disabled">总数量</span>
|
||||
</view>
|
||||
<view class="zd-col-24">
|
||||
<input type="number" v-model="num" class="filter_input filter_input_disabled" disabled>
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">总数量</span>
|
||||
<span class="filter_label filter_input_disabled">总数量</span>
|
||||
</view>
|
||||
<view class="zd-col-24">
|
||||
<input type="number" v-model="num" class="filter_input filter_input_disabled" disabled>
|
||||
|
||||
@@ -102,7 +102,18 @@
|
||||
return {
|
||||
title: '',
|
||||
// options: [],
|
||||
options: [{text:'原粉区', value: '1'}, {text:'批料室', value: '1'}, {text:'粉碎室1', value: 'f1'}, {text:'粉碎室2', value: 'f2'}],
|
||||
// options: [{text:'原粉区', value: '1'}, {text:'批料室', value: '1'}, {text:'粉碎室1', value: 'f1'}, {text:'粉碎室2', value: 'f2'}],
|
||||
// options: [{text:'原粉区', value: '1', aaa:'n1'}, {text:'批料室', value: '1', aaa:'n1'}],
|
||||
options: [{
|
||||
forder_seg: 4,
|
||||
updateid: 1,
|
||||
text:"AGy对接区",
|
||||
updatename:"管理员",
|
||||
update_time: "2026-01-07 10:28:48",
|
||||
value:"AGVDTO1",
|
||||
workshop_code:"1"
|
||||
}
|
||||
],
|
||||
index: '',
|
||||
val1: '',
|
||||
val2: '',
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<view class="zd_container">
|
||||
<!-- 产线转运 -->
|
||||
<!-- 点对点转运 -->
|
||||
<nav-bar :title="title"></nav-bar>
|
||||
<view class="zd_content">
|
||||
<view class="zd_wrapper">
|
||||
@@ -40,8 +40,7 @@
|
||||
<script>
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
// import {queryVehicleType} from '@/utils/mork2.js'
|
||||
import {queryVehicleType, createTask} from '@/utils/getData2.js'
|
||||
import {createTask} from '@/utils/getData3.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
@@ -50,34 +49,18 @@
|
||||
data() {
|
||||
return {
|
||||
title: '',
|
||||
vehicleCode: null,
|
||||
code1: '',
|
||||
code2: '',
|
||||
options: [],
|
||||
options: [{text:'普通任务', value: '1'}],
|
||||
index: '',
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
onLoad (options) {
|
||||
this.title = options.title
|
||||
this._queryVehicleType()
|
||||
},
|
||||
methods: {
|
||||
/** 下拉框*/
|
||||
async _queryVehicleType () {
|
||||
try {
|
||||
let res = await queryVehicleType()
|
||||
if (res && res.data.length > 0) {
|
||||
this.options = [...res.data]
|
||||
} else {
|
||||
this.options = []
|
||||
}
|
||||
} catch (e) {
|
||||
this.options = []
|
||||
}
|
||||
},
|
||||
toEmpty () {
|
||||
this.vehicleCode = null
|
||||
this.code1 = ''
|
||||
this.code2 = ''
|
||||
this.index = ''
|
||||
@@ -90,7 +73,7 @@
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await createTask(this.vehicleCode, this.code1, this.code2, this.index)
|
||||
let res = await createTask(this.code1, this.code2, this.index)
|
||||
if (res) {
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
@@ -47,12 +47,12 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(e, i) in dataList" :key="i" :class="{'checked': e.material_id === pkId}" @tap="toCheck(e)">
|
||||
<tr v-for="(e, i) in dataList" :key="i">
|
||||
<td>{{e.task_time}}</td>
|
||||
<td>{{e.vehicle_code}}</td>
|
||||
<td>{{e.point_code1}}</td>
|
||||
<td>{{e.point_code2}}</td>
|
||||
<td>{{['生成', '', '', '下发', '执行中', '完成'][Number(e.task_status)]}}</td>
|
||||
<td>{{['', '', '', '', '', '完成', '取消'][Number(e.task_status)]}}</td>
|
||||
<td>{{e.task_code}}</td>
|
||||
<td>{{e.config_name}}</td>
|
||||
<td>{{e.car_no}}</td>
|
||||
@@ -73,7 +73,7 @@
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import {getDate} from '@/utils/utils.js'
|
||||
import {queryHistoryTask} from '@/utils/getData2.js'
|
||||
import {queryHistoryTask} from '@/utils/getData3.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
<view class="zd-col-13">
|
||||
<search-box v-model="vehicleCode"/>
|
||||
</view>
|
||||
<button class="mini-btn" type="primary" @tap="_updatePointqueryPointInfo">查询</button>
|
||||
<button class="mini-btn" type="primary" @tap="_pdaPointAndPointqueryPointDtl">查询</button>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper grid-wraper">
|
||||
@@ -28,6 +28,8 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<th>序号</th>
|
||||
<th>点位编码</th>
|
||||
<th>载具编码</th>
|
||||
<th>物料编码</th>
|
||||
<th>物料名称</th>
|
||||
<th>批次</th>
|
||||
@@ -38,6 +40,8 @@
|
||||
<tbody>
|
||||
<tr v-for="(e, i) in dataList" :key="i" :class="{'checked': e.material_code === pkId}">
|
||||
<td>{{i+1}}</td>
|
||||
<td>{{e.point_code}}</td>
|
||||
<td>{{e.vehicle_code}}</td>
|
||||
<td>{{e.material_code}}</td>
|
||||
<td>{{e.material_name}}</td>
|
||||
<td>{{e.pcsn}}</td>
|
||||
@@ -51,7 +55,7 @@
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-5 button-default" @tap="toEmpty">清空</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !pointCode || !vehicleCode}" :disabled="disabled" @tap="_bindVehicle">绑定</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !pointCode || !vehicleCode}" :disabled="disabled" @tap="_bind">绑定</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !pointCode || !vehicleCode}" :disabled="disabled" @tap="_clearVehicle">清载具</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !pointCode || !vehicleCode}" :disabled="disabled" @tap="_clearMaterial">清物料</button>
|
||||
</view>
|
||||
@@ -61,8 +65,7 @@
|
||||
<script>
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
// import {updatePointqueryPointInfo} from '@/utils/mork2.js'
|
||||
import {updatePointqueryPointInfo, bindVehicle, clearVehicle, clearMaterial} from '@/utils/getData2.js'
|
||||
import {pdaPointAndPointqueryPointDtl, bind, clearVehicle, clearMaterial} from '@/utils/getData3.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
@@ -81,9 +84,12 @@
|
||||
this.title = options.title
|
||||
},
|
||||
methods: {
|
||||
async _updatePointqueryPointInfo () {
|
||||
async _pdaPointAndPointqueryPointDtl () {
|
||||
if (!this.pointCode && !this.vehicleCode) {
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await updatePointqueryPointInfo(this.pointCode, this.vehicleCode)
|
||||
let res = await pdaPointAndPointqueryPointDtl(this.pointCode, this.vehicleCode)
|
||||
if (res && res.data.length > 0) {
|
||||
this.dataList = [...res.data]
|
||||
} else {
|
||||
@@ -99,9 +105,9 @@
|
||||
this.dataList = []
|
||||
this.disabled = false
|
||||
},
|
||||
async _bindVehicle () {
|
||||
async _bind () {
|
||||
try {
|
||||
let res = await bindVehicle(this.pointCode, this.vehicleCode)
|
||||
let res = await bind(this.pointCode, this.vehicleCode, this.dataList)
|
||||
if (res) {
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
@@ -115,7 +121,7 @@
|
||||
},
|
||||
async _clearVehicle () {
|
||||
try {
|
||||
let res = await clearVehicle(this.pointCode, this.vehicleCode)
|
||||
let res = await clearVehicle(this.pointCode, this.vehicleCode, this.dataList)
|
||||
if (res) {
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
@@ -129,7 +135,7 @@
|
||||
},
|
||||
async _clearMaterial () {
|
||||
try {
|
||||
let res = await clearMaterial(this.pointCode, this.vehicleCode)
|
||||
let res = await clearMaterial(this.pointCode, this.vehicleCode, this.dataList)
|
||||
if (res) {
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
<td>{{e.vehicle_code}}</td>
|
||||
<td>{{e.point_code1}}</td>
|
||||
<td>{{e.point_code2}}</td>
|
||||
<td>{{['生成', '', '', '下发', '执行中', '完成'][Number(e.task_status)]}}</td>
|
||||
<td>{{['生成', '申请', '创建完成', '下发', '执行中'][Number(e.task_status)]}}</td>
|
||||
<td>{{e.task_code}}</td>
|
||||
<td>{{e.config_name}}</td>
|
||||
<td>{{e.car_no}}</td>
|
||||
@@ -46,7 +46,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-8 button-primary" :class="{'button-info': !pkId}" :disabled="disabled1" @tap="_taskOperation">重新生成</button>
|
||||
<button class="zd-col-8 button-primary" :class="{'button-info': !pkId}" :disabled="disabled1" @tap="_taskOperation">重新下发</button>
|
||||
<button class="zd-col-8 button-primary" :class="{'button-info': !pkId}" :disabled="disabled2" @tap="_forceConfirmTask">强制完成</button>
|
||||
<button class="zd-col-6 button-primary" @tap="toJump('ls-search?title=历史查询')">历史查询</button>
|
||||
</view>
|
||||
@@ -56,7 +56,7 @@
|
||||
<script>
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import {queryTask, taskOperation, forceConfirmTask} from '@/utils/getData2.js'
|
||||
import {queryTask, taskOperation, forceConfirmTask} from '@/utils/getData3.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">总数量</span>
|
||||
<span class="filter_label filter_input_disabled">总数量</span>
|
||||
</view>
|
||||
<view class="zd-col-24">
|
||||
<input type="number" v-model="num" class="filter_input filter_input_disabled" disabled>
|
||||
@@ -82,7 +82,7 @@
|
||||
index: '',
|
||||
val1: '',
|
||||
dataList: [],
|
||||
dataList: [{material_code: 'm001', qty: 100, checked: false, initialQty: 100}, {material_code: 'm002', qty: 200, checked: false, initialQty: 200}],
|
||||
// dataList: [{material_code: 'm001', qty: 100, checked: false, initialQty: 100}, {material_code: 'm002', qty: 200, checked: false, initialQty: 200}],
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">总数量</span>
|
||||
<span class="filter_label filter_input_disabled">总数量</span>
|
||||
</view>
|
||||
<view class="zd-col-24">
|
||||
<input type="number" v-model="num" class="filter_input filter_input_disabled" disabled>
|
||||
@@ -74,7 +74,7 @@
|
||||
allCheck: false,
|
||||
checkedArr: [],
|
||||
dataList: [],
|
||||
dataList: [{material_code: 'm001', qty: 100, checked: false, initialQty: 100}, {material_code: 'm002', qty: 200, checked: false, initialQty: 200}],
|
||||
// dataList: [{material_code: 'm001', qty: 100, checked: false, initialQty: 100}, {material_code: 'm002', qty: 200, checked: false, initialQty: 200}],
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-6">
|
||||
<span class="filter_label">区域</span>
|
||||
<span class="filter_label filter_input_disabled">区域</span>
|
||||
</view>
|
||||
<view class="zd-col-18 filter_select">
|
||||
<uni-data-select v-model="index1" :localdata="options1"></uni-data-select>
|
||||
<uni-data-select v-model="index1" :localdata="options1" disabled></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
@@ -140,6 +140,7 @@
|
||||
let res = await queryPointRegion(this.val1)
|
||||
if (res && res.data) {
|
||||
this.options1 = [...res.data]
|
||||
this.index1 = this.options1[0].value
|
||||
} else {
|
||||
this.options1 = []
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">总数量</span>
|
||||
<span class="filter_label filter_input_disabled">总数量</span>
|
||||
</view>
|
||||
<view class="zd-col-24">
|
||||
<input type="number" v-model="num" class="filter_input filter_input_disabled" disabled>
|
||||
@@ -85,7 +85,7 @@
|
||||
allCheck: false,
|
||||
checkedArr: [],
|
||||
dataList: [],
|
||||
dataList: [{material_code: 'm001', qty: 100, checked: false, initialQty: 100}, {material_code: 'm002', qty: 200, checked: false, initialQty: 200}],
|
||||
// dataList: [{material_code: 'm001', qty: 100, checked: false, initialQty: 100}, {material_code: 'm002', qty: 200, checked: false, initialQty: 200}],
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user