les功能提交
This commit is contained in:
26
api/les/lesMaterialBind.js
Normal file
26
api/les/lesMaterialBind.js
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备料绑定
|
||||||
|
* @param {Object} data
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
export function bind(data) {
|
||||||
|
return request({
|
||||||
|
url: '/les/location/bind',
|
||||||
|
method: 'put',
|
||||||
|
data: data,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备料解绑
|
||||||
|
* @param {code}
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
export function unBind(code) {
|
||||||
|
return request({
|
||||||
|
url: '/les/location/unbind/' + code,
|
||||||
|
method: 'put',
|
||||||
|
})
|
||||||
|
}
|
||||||
26
api/les/lesMaterialCall.js
Normal file
26
api/les/lesMaterialCall.js
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增任务
|
||||||
|
* @param {Object} data
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
export function addDeliveryTask(data) {
|
||||||
|
return request({
|
||||||
|
url: '/les/deliveryTask',
|
||||||
|
method: 'post',
|
||||||
|
data: data,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {code}
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
export function findPreparation(code) {
|
||||||
|
return request({
|
||||||
|
url: '/les/location/findPreparation/' + code,
|
||||||
|
method: 'get',
|
||||||
|
})
|
||||||
|
}
|
||||||
24
api/les/lesMaterialDelivery.js
Normal file
24
api/les/lesMaterialDelivery.js
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
export function listData() {
|
||||||
|
return request({
|
||||||
|
url: '/les/deliveryTask/list',
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function delivery(data) {
|
||||||
|
return request({
|
||||||
|
url: '/les/deliveryTask/handleDelivery',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function cancel(data) {
|
||||||
|
return request({
|
||||||
|
url: '/les/deliveryTask/handleCancel',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
21
api/les/lesPalletReturn.js
Normal file
21
api/les/lesPalletReturn.js
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增任务
|
||||||
|
* @param {Object} data
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
export function addDeliveryTask(data) {
|
||||||
|
return request({
|
||||||
|
url: '/les/deliveryTask',
|
||||||
|
method: 'post',
|
||||||
|
data: data,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getLastPalletRecyclingDest() {
|
||||||
|
return request({
|
||||||
|
url: '/les/deliveryTask/lastPalletRecyclingDest',
|
||||||
|
method: 'get',
|
||||||
|
})
|
||||||
|
}
|
||||||
316
manifest.json
316
manifest.json
@@ -1,159 +1,159 @@
|
|||||||
{
|
{
|
||||||
"name" : "MES",
|
"name": "MES",
|
||||||
"appid" : "__UNI__66F7FE2",
|
"appid": "__UNI__66F7FE2",
|
||||||
"description" : "",
|
"description": "",
|
||||||
"versionName" : "3.4.1",
|
"versionName": "3.4.2",
|
||||||
"versionCode" : 341,
|
"versionCode": 342,
|
||||||
"transformPx" : false,
|
"transformPx": false,
|
||||||
"sassImplementationName" : "node-sass",
|
"sassImplementationName": "node-sass",
|
||||||
"app-plus" : {
|
"app-plus": {
|
||||||
"usingComponents" : true,
|
"usingComponents": true,
|
||||||
"nvueCompiler" : "uni-app",
|
"nvueCompiler": "uni-app",
|
||||||
"splashscreen" : {
|
"splashscreen": {
|
||||||
"alwaysShowBeforeRender" : true,
|
"alwaysShowBeforeRender": true,
|
||||||
"waiting" : true,
|
"waiting": true,
|
||||||
"autoclose" : true,
|
"autoclose": true,
|
||||||
"delay" : 0
|
"delay": 0
|
||||||
},
|
},
|
||||||
// 禁用 HTML5+ RunTime 提示
|
// 禁用 HTML5+ RunTime 提示
|
||||||
"compatible" : {
|
"compatible": {
|
||||||
"ignoreVersion" : true
|
"ignoreVersion": true
|
||||||
},
|
},
|
||||||
"modules" : {
|
"modules": {
|
||||||
"Camera" : {},
|
"Camera": {},
|
||||||
"Barcode" : {}
|
"Barcode": {}
|
||||||
},
|
},
|
||||||
"distribute" : {
|
"distribute": {
|
||||||
"android" : {
|
"android": {
|
||||||
"permissions" : [
|
"permissions": [
|
||||||
"<uses-permission android:name=\"android.permission.INTERNET\" />",
|
"<uses-permission android:name=\"android.permission.INTERNET\" />",
|
||||||
"<uses-permission android:name=\"android.permission.READ_EXTERNAL_STORAGE\" />",
|
"<uses-permission android:name=\"android.permission.READ_EXTERNAL_STORAGE\" />",
|
||||||
"<uses-permission android:name=\"android.permission.WRITE_EXTERNAL_STORAGE\" />",
|
"<uses-permission android:name=\"android.permission.WRITE_EXTERNAL_STORAGE\" />",
|
||||||
"<uses-permission android:name=\"com.asus.msa.SupplementaryDID.ACCESS\" />",
|
"<uses-permission android:name=\"com.asus.msa.SupplementaryDID.ACCESS\" />",
|
||||||
"<uses-permission android:name=\"com.huawei.android.launcher.permission.CHANGE_BADGE\" />",
|
"<uses-permission android:name=\"com.huawei.android.launcher.permission.CHANGE_BADGE\" />",
|
||||||
"<uses-permission android:name=\"android.permission.INSTALL_PACKAGES\" />",
|
"<uses-permission android:name=\"android.permission.INSTALL_PACKAGES\" />",
|
||||||
"<uses-permission android:name=\"android.permission.REQUEST_INSTALL_PACKAGES\" />",
|
"<uses-permission android:name=\"android.permission.REQUEST_INSTALL_PACKAGES\" />",
|
||||||
"<uses-feature android:name=\"android.hardware.camera\"/>",
|
"<uses-feature android:name=\"android.hardware.camera\"/>",
|
||||||
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
|
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
|
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
|
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.BLUETOOTH\"/>",
|
"<uses-permission android:name=\"android.permission.BLUETOOTH\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.BLUETOOTH_ADMIN\"/>",
|
"<uses-permission android:name=\"android.permission.BLUETOOTH_ADMIN\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
|
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
|
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
|
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
|
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
|
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
|
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
|
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
|
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
|
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
|
||||||
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
|
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
|
||||||
],
|
],
|
||||||
"abiFilters" : [ "armeabi-v7a", "arm64-v8a", "x86" ]
|
"abiFilters": ["armeabi-v7a", "arm64-v8a", "x86"]
|
||||||
},
|
},
|
||||||
"ios" : {
|
"ios": {
|
||||||
"dSYMs" : false
|
"dSYMs": false
|
||||||
},
|
},
|
||||||
"sdkConfigs" : {
|
"sdkConfigs": {
|
||||||
"ad" : {}
|
"ad": {}
|
||||||
},
|
},
|
||||||
"icons" : {
|
"icons": {
|
||||||
"android" : {
|
"android": {
|
||||||
"hdpi" : "unpackage/res/icons/72x72.png",
|
"hdpi": "unpackage/res/icons/72x72.png",
|
||||||
"xhdpi" : "unpackage/res/icons/96x96.png",
|
"xhdpi": "unpackage/res/icons/96x96.png",
|
||||||
"xxhdpi" : "unpackage/res/icons/144x144.png",
|
"xxhdpi": "unpackage/res/icons/144x144.png",
|
||||||
"xxxhdpi" : "unpackage/res/icons/192x192.png"
|
"xxxhdpi": "unpackage/res/icons/192x192.png"
|
||||||
},
|
},
|
||||||
"ios" : {
|
"ios": {
|
||||||
"appstore" : "unpackage/res/icons/1024x1024.png",
|
"appstore": "unpackage/res/icons/1024x1024.png",
|
||||||
"ipad" : {
|
"ipad": {
|
||||||
"app" : "unpackage/res/icons/76x76.png",
|
"app": "unpackage/res/icons/76x76.png",
|
||||||
"app@2x" : "unpackage/res/icons/152x152.png",
|
"app@2x": "unpackage/res/icons/152x152.png",
|
||||||
"notification" : "unpackage/res/icons/20x20.png",
|
"notification": "unpackage/res/icons/20x20.png",
|
||||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
"notification@2x": "unpackage/res/icons/40x40.png",
|
||||||
"proapp@2x" : "unpackage/res/icons/167x167.png",
|
"proapp@2x": "unpackage/res/icons/167x167.png",
|
||||||
"settings" : "unpackage/res/icons/29x29.png",
|
"settings": "unpackage/res/icons/29x29.png",
|
||||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
"settings@2x": "unpackage/res/icons/58x58.png",
|
||||||
"spotlight" : "unpackage/res/icons/40x40.png",
|
"spotlight": "unpackage/res/icons/40x40.png",
|
||||||
"spotlight@2x" : "unpackage/res/icons/80x80.png"
|
"spotlight@2x": "unpackage/res/icons/80x80.png"
|
||||||
},
|
},
|
||||||
"iphone" : {
|
"iphone": {
|
||||||
"app@2x" : "unpackage/res/icons/120x120.png",
|
"app@2x": "unpackage/res/icons/120x120.png",
|
||||||
"app@3x" : "unpackage/res/icons/180x180.png",
|
"app@3x": "unpackage/res/icons/180x180.png",
|
||||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
"notification@2x": "unpackage/res/icons/40x40.png",
|
||||||
"notification@3x" : "unpackage/res/icons/60x60.png",
|
"notification@3x": "unpackage/res/icons/60x60.png",
|
||||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
"settings@2x": "unpackage/res/icons/58x58.png",
|
||||||
"settings@3x" : "unpackage/res/icons/87x87.png",
|
"settings@3x": "unpackage/res/icons/87x87.png",
|
||||||
"spotlight@2x" : "unpackage/res/icons/80x80.png",
|
"spotlight@2x": "unpackage/res/icons/80x80.png",
|
||||||
"spotlight@3x" : "unpackage/res/icons/120x120.png"
|
"spotlight@3x": "unpackage/res/icons/120x120.png"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"splashscreen" : {
|
"splashscreen": {
|
||||||
"useOriginalMsgbox" : false
|
"useOriginalMsgbox": false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nativePlugins" : {
|
"nativePlugins": {
|
||||||
"Fvv-UniSerialPort" : {
|
"Fvv-UniSerialPort": {
|
||||||
"__plugin_info__" : {
|
"__plugin_info__": {
|
||||||
"name" : "安卓串口通信 Fvv-UniSerialPort",
|
"name": "安卓串口通信 Fvv-UniSerialPort",
|
||||||
"description" : "Android平台串口通信插件,支持串口号、波特率、数据位、校验位、停止位、流控等参数设置",
|
"description": "Android平台串口通信插件,支持串口号、波特率、数据位、校验位、停止位、流控等参数设置",
|
||||||
"platforms" : "Android",
|
"platforms": "Android",
|
||||||
"url" : "https://ext.dcloud.net.cn/plugin?id=1787",
|
"url": "https://ext.dcloud.net.cn/plugin?id=1787",
|
||||||
"android_package_name" : "uni.UNI66F7FE2",
|
"android_package_name": "uni.UNI66F7FE2",
|
||||||
"ios_bundle_id" : "uni.UNI66F7FE2",
|
"ios_bundle_id": "uni.UNI66F7FE2",
|
||||||
"isCloud" : true,
|
"isCloud": true,
|
||||||
"bought" : 1,
|
"bought": 1,
|
||||||
"pid" : "1787",
|
"pid": "1787",
|
||||||
"parameters" : {}
|
"parameters": {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"orientation" : [
|
"orientation": [
|
||||||
//竖屏正方向
|
//竖屏正方向
|
||||||
"portrait-primary",
|
"portrait-primary",
|
||||||
//竖屏反方向
|
//竖屏反方向
|
||||||
"portrait-secondary",
|
"portrait-secondary",
|
||||||
//横屏正方向
|
//横屏正方向
|
||||||
"landscape-primary",
|
"landscape-primary",
|
||||||
//横屏反方向
|
//横屏反方向
|
||||||
"landscape-secondary",
|
"landscape-secondary",
|
||||||
//自然方向
|
//自然方向
|
||||||
"default"
|
"default"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"quickapp" : {},
|
"quickapp": {},
|
||||||
"mp-weixin" : {
|
"mp-weixin": {
|
||||||
"appid" : "wx366e867b9fb64fdf",
|
"appid": "wx366e867b9fb64fdf",
|
||||||
"setting" : {
|
"setting": {
|
||||||
"urlCheck" : true,
|
"urlCheck": true,
|
||||||
"es6" : false,
|
"es6": false,
|
||||||
"minified" : true,
|
"minified": true,
|
||||||
"postcss" : true
|
"postcss": true
|
||||||
},
|
},
|
||||||
"optimization" : {
|
"optimization": {
|
||||||
"subPackages" : true
|
"subPackages": true
|
||||||
},
|
},
|
||||||
"usingComponents" : true
|
"usingComponents": true
|
||||||
},
|
},
|
||||||
"vueVersion" : "2",
|
"vueVersion": "2",
|
||||||
"h5" : {
|
"h5": {
|
||||||
"template" : "static/index.html",
|
"template": "static/index.html",
|
||||||
"devServer" : {
|
"devServer": {
|
||||||
"port" : 9090,
|
"port": 9090,
|
||||||
"https" : false
|
"https": false
|
||||||
},
|
},
|
||||||
"title" : "RuoYi-App",
|
"title": "RuoYi-App",
|
||||||
"router" : {
|
"router": {
|
||||||
"mode" : "hash",
|
"mode": "hash",
|
||||||
"base" : "./"
|
"base": "./"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"permissions" : {
|
"permissions": {
|
||||||
"network" : {
|
"network": {
|
||||||
"description" : "用于获取网络状态和IP地址"
|
"description": "用于获取网络状态和IP地址"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
37
pages.json
37
pages.json
@@ -109,10 +109,9 @@
|
|||||||
"navigationBarTitleText": "浏览文本"
|
"navigationBarTitleText": "浏览文本"
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path" : "pages/mes/jobReport/start",
|
"path": "pages/mes/jobReport/start",
|
||||||
"style" :
|
"style": {
|
||||||
{
|
"navigationBarTitleText": "工序开工"
|
||||||
"navigationBarTitleText" : "工序开工"
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/mes/jobReport/pass",
|
"path": "pages/mes/jobReport/pass",
|
||||||
@@ -834,6 +833,36 @@
|
|||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "采购直接入库"
|
"navigationBarTitleText": "采购直接入库"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/les/returnPallet",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "托盘返空"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/les/bindMaterial",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "备料绑定"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/les/callMaterial",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "生产呼料"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/les/chooseTask",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "选择任务"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/les/deliveryMaterial",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "生产配送"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"tabBar": {
|
"tabBar": {
|
||||||
|
|||||||
126
pages/les/bindMaterial.vue
Normal file
126
pages/les/bindMaterial.vue
Normal file
@@ -0,0 +1,126 @@
|
|||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<uni-forms ref="form" :modelValue="formData" :rules="rules">
|
||||||
|
<uni-forms-item label="货位号:" name="locationCode">
|
||||||
|
<uni-easyinput suffixIcon="scan" @iconClick="scanLocationCodeUuid" type="text"
|
||||||
|
v-model="formData.locationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
<uni-forms-item label="批次号:" name="batchNo">
|
||||||
|
<uni-easyinput suffixIcon="scan" @iconClick="scanBatchNoUuid" type="text" v-model="formData.batchNo" />
|
||||||
|
</uni-forms-item>
|
||||||
|
</uni-forms>
|
||||||
|
<uni-row :gutter="10">
|
||||||
|
<uni-col :span="12">
|
||||||
|
<u-button type="success" @click="handleBind">绑定</u-button>
|
||||||
|
</uni-col>
|
||||||
|
<uni-col :span="12">
|
||||||
|
<u-button type="primary" @click="handleUnBind">解绑</u-button>
|
||||||
|
</uni-col>
|
||||||
|
</uni-row>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { bind, unBind } from "@/api/les/lesMaterialBind.js";
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
formData: {},
|
||||||
|
/** 校验规则 */
|
||||||
|
rules: {
|
||||||
|
locationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请输入货位号',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
batchNo: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请选择批次号',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
scanLocationCodeUuid() {
|
||||||
|
const _this = this;
|
||||||
|
uni.scanCode({
|
||||||
|
scanType: ['qrCode', 'barCode'],
|
||||||
|
success: function(res) {
|
||||||
|
_this.formData.locationCode = res.result;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
scanBatchNoUuid() {
|
||||||
|
const _this = this;
|
||||||
|
uni.scanCode({
|
||||||
|
scanType: ['qrCode', 'barCode'],
|
||||||
|
success: function(res) {
|
||||||
|
_this.formData.batchNo = res.result;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleBind() {
|
||||||
|
const _this = this;
|
||||||
|
this.$refs.form.validate().then(res => {
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '您确定绑定该数据吗?',
|
||||||
|
success: function(res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
if (_this.formData.locationCode && _this.formData.batchNo) {
|
||||||
|
_this.$modal.loading('绑定中')
|
||||||
|
bind(_this.formData).then(res => {
|
||||||
|
_this.$modal.closeLoading();
|
||||||
|
_this.$modal.msgSuccess("绑定成功!");
|
||||||
|
setTimeout(() => {
|
||||||
|
this.$tab.switchTab("/pages/work/index");
|
||||||
|
}, 500);
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
_this.$modal.msg("请将信息补充完整")
|
||||||
|
}
|
||||||
|
} else if (res.cancel) {
|
||||||
|
console.log('用户点击取消');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
handleUnBind() {
|
||||||
|
const _this = this;
|
||||||
|
this.$refs.form.validate().then(res => {
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '您确定解绑该数据吗?',
|
||||||
|
success: function(res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
if (_this.formData.locationCode) {
|
||||||
|
_this.$modal.loading('解绑中')
|
||||||
|
unBind(_this.formData.locationCode).then(res => {
|
||||||
|
_this.$modal.closeLoading();
|
||||||
|
_this.$modal.msgSuccess("解绑成功!")
|
||||||
|
setTimeout(() => {
|
||||||
|
this.$tab.switchTab("/pages/work/index");
|
||||||
|
}, 500);
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
_this.$modal.msg("请将信息补充完整")
|
||||||
|
}
|
||||||
|
} else if (res.cancel) {
|
||||||
|
console.log('用户点击取消');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// reset() {
|
||||||
|
// this.formData = {};
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
96
pages/les/callMaterial.vue
Normal file
96
pages/les/callMaterial.vue
Normal file
@@ -0,0 +1,96 @@
|
|||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<uni-forms ref="form" :modelValue="formData" :rules="rules">
|
||||||
|
<uni-forms-item label="发货点位:" :labelWidth='90' name="srcLocationCode">
|
||||||
|
<uni-easyinput type="text" v-model="formData.srcLocationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
<uni-forms-item label="目的货位:" :labelWidth='90' name="destLocationCode">
|
||||||
|
<uni-easyinput suffixIcon="scan" @iconClick="scanDestLocationUuid" type="text" @blur="searchSrcLocation"
|
||||||
|
v-model="formData.destLocationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
</uni-forms>
|
||||||
|
<uni-row :gutter="10">
|
||||||
|
<uni-col>
|
||||||
|
<u-button type="success" @click="handleCall">呼叫</u-button>
|
||||||
|
</uni-col>
|
||||||
|
</uni-row>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { addDeliveryTask, findPreparation } from "@/api/les/lesMaterialCall.js";
|
||||||
|
import LesDeliveryTaskType from "@/utils/enums/LesDeliveryTaskType";
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
formData: {
|
||||||
|
taskType: LesDeliveryTaskType.PRODUCTION
|
||||||
|
},
|
||||||
|
/** 校验规则 */
|
||||||
|
rules: {
|
||||||
|
srcLocationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请输入发货点位',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
destLocationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请选择目的货位',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
searchSrcLocation() {
|
||||||
|
const _this = this;
|
||||||
|
if (_this.formData.destLocationCode == '') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
findPreparation(_this.formData.destLocationCode).then(res => {
|
||||||
|
if (res.code == 200) {
|
||||||
|
this.$set(this.formData, "srcLocationCode", res.data);
|
||||||
|
} else {
|
||||||
|
this.$modal.showToast("未找到对应发货点位")
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
scanDestLocationUuid() {
|
||||||
|
const _this = this;
|
||||||
|
uni.scanCode({
|
||||||
|
scanType: ['qrCode', 'barCode'],
|
||||||
|
success: function(res) {
|
||||||
|
_this.formData.destLocationCode = res.result;
|
||||||
|
_this.searchSrcLocation();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleCall() {
|
||||||
|
const _this = this;
|
||||||
|
this.$refs.form.validate().then(res => {
|
||||||
|
if (_this.formData.srcLocationCode && _this.formData.destLocationCode) {
|
||||||
|
_this.$modal.loading('提交中')
|
||||||
|
addDeliveryTask(_this.formData).then(res => {
|
||||||
|
_this.$modal.closeLoading();
|
||||||
|
_this.$modal.msgSuccess("提交成功!");
|
||||||
|
setTimeout(() => {
|
||||||
|
_this.$tab.switchTab("/pages/work/index");
|
||||||
|
}, 500);
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
_this.$modal.msg("请将信息补充完整")
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// reset() {
|
||||||
|
// const _this = this;
|
||||||
|
// this.formData.srcLocationCode = '';
|
||||||
|
// this.formData.destLocationCode = '';
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
49
pages/les/chooseTask.vue
Normal file
49
pages/les/chooseTask.vue
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
<template>
|
||||||
|
<view class="cu-card article ">
|
||||||
|
<view class="cu-item shadow borderBottom" v-for="(item,index) in list" :key="index">
|
||||||
|
<view class="title">
|
||||||
|
<view class="text-cut">任务类型 : {{item.taskType}}</view>
|
||||||
|
<view>
|
||||||
|
<button type="primary" size="mini" @click="choose(item)" style="float: right;">选择任务</button>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="content">
|
||||||
|
<view class="desc">
|
||||||
|
<view class="text-content">
|
||||||
|
<view>发货点位 : {{item.srcLocationCode}}</view>
|
||||||
|
<view>目的点位 : {{item.destLocationCode}}</view>
|
||||||
|
<view>物料编码 : {{item.material.materialCode}}</view>
|
||||||
|
<view>物料名称 : {{item.material.materialName}}</view>
|
||||||
|
<view>呼叫时间 : {{item.callDatetime}}</view>
|
||||||
|
<view>状态 : {{item.taskStatus}}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { listData } from "@/api/les/lesMaterialDelivery.js"
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
list: {},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
getList() {
|
||||||
|
listData().then(res => {
|
||||||
|
this.list = res.rows;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
choose(data) {
|
||||||
|
this.$tab.navigateTo("/pages/les/deliveryMaterial?formData=" + JSON.stringify(data));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
115
pages/les/deliveryMaterial.vue
Normal file
115
pages/les/deliveryMaterial.vue
Normal file
@@ -0,0 +1,115 @@
|
|||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<uni-forms ref="form" :modelValue="formData" :rules="rules">
|
||||||
|
<uni-forms-item label="发货点位:" :labelWidth='100' name="srcLocationCode">
|
||||||
|
<uni-easyinput type="text" v-model="formData.srcLocationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
<uni-forms-item label="目的点位:" :labelWidth='100' name="destLocationCode">
|
||||||
|
<uni-easyinput type="text" v-model="formData.destLocationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
<uni-forms-item label="机器人类型:" :labelWidth='100' name="RobotType">
|
||||||
|
<uni-data-select placeholder="请选择机器类型" v-model="formData.RobotType" :localdata="RobotData" />
|
||||||
|
</uni-forms-item>
|
||||||
|
<uni-forms-item label="容器类型:" :labelWidth='100' name="ctnrTyp" v-if="formData.RobotType == 2">
|
||||||
|
<uni-easyinput type="text" v-model="formData.ctnrTyp" />
|
||||||
|
</uni-forms-item>
|
||||||
|
</uni-forms>
|
||||||
|
<uni-row :gutter="10">
|
||||||
|
<uni-col :span="12">
|
||||||
|
<u-button type="success" @click="handleDelivery">配送</u-button>
|
||||||
|
</uni-col>
|
||||||
|
<uni-col :span="12">
|
||||||
|
<u-button type="primary" @click="handleCancle">取消</u-button>
|
||||||
|
</uni-col>
|
||||||
|
</uni-row>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import RobotType from "@/utils/enums/RobotType";
|
||||||
|
import { delivery, cancel } from "@/api/les/lesMaterialDelivery.js"
|
||||||
|
export default {
|
||||||
|
onLoad(option) {
|
||||||
|
this.formData = JSON.parse(option.formData);
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
formData: {},
|
||||||
|
RobotData: [
|
||||||
|
{ value: RobotType.LATENT_MOBILE_ROBOT, text: "潜伏车" },
|
||||||
|
{ value: RobotType.LATENT_FORKLIFT_AGV, text: "潜伏叉车" },
|
||||||
|
],
|
||||||
|
/** 校验规则 */
|
||||||
|
rules: {
|
||||||
|
srcLocationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请输入发货点位',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
destLocationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请输入目的货位',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
RobotType: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请选择机器人类型',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
handleDelivery() {
|
||||||
|
const _this = this;
|
||||||
|
this.$refs.form.validate().then(res => {
|
||||||
|
if (_this.formData.srcLocationCode && _this.formData.destLocationCode) {
|
||||||
|
_this.$modal.loading('提交中')
|
||||||
|
delivery(_this.formData).then(res => {
|
||||||
|
_this.$modal.closeLoading();
|
||||||
|
_this.$modal.msgSuccess("提交成功!");
|
||||||
|
_this.reset();
|
||||||
|
setTimeout(() => {
|
||||||
|
this.$tab.switchTab("/pages/les/chooseTask");
|
||||||
|
}, 500);
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
_this.$modal.msg("请将信息补充完整")
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
handleCancle() {
|
||||||
|
const _this = this;
|
||||||
|
const arr = [];
|
||||||
|
arr.push(_this.formData.id);
|
||||||
|
this.$refs.form.validate().then(res => {
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '您确定取消该任务吗?',
|
||||||
|
success: function(res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
_this.$modal.loading('取消中')
|
||||||
|
cancel(arr).then(res => {
|
||||||
|
_this.$modal.closeLoading();
|
||||||
|
_this.$modal.msgSuccess("取消成功!");
|
||||||
|
_this.reset();
|
||||||
|
setTimeout(() => {
|
||||||
|
this.$tab.switchTab("/pages/les/chooseTask");
|
||||||
|
}, 500);
|
||||||
|
})
|
||||||
|
} else if (res.cancel) {
|
||||||
|
console.log('用户点击取消');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// reset() {
|
||||||
|
// this.formData = {};
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
88
pages/les/returnPallet.vue
Normal file
88
pages/les/returnPallet.vue
Normal file
@@ -0,0 +1,88 @@
|
|||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<uni-forms ref="form" :modelValue="formData" :rules="rules">
|
||||||
|
<uni-forms-item label="发货点位:" :labelWidth='90' name="srcLocationCode">
|
||||||
|
<uni-easyinput type="text" suffixIcon="scan" @iconClick="scanSrcLocationUuid"
|
||||||
|
v-model="formData.srcLocationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
<uni-forms-item label="目的点位:" :labelWidth='90' name="destLocationCode">
|
||||||
|
<uni-easyinput type="text" v-model="formData.destLocationCode" />
|
||||||
|
</uni-forms-item>
|
||||||
|
</uni-forms>
|
||||||
|
<uni-row :gutter="10">
|
||||||
|
<uni-col>
|
||||||
|
<u-button type="success" @click="handleCall">呼叫</u-button>
|
||||||
|
</uni-col>
|
||||||
|
</uni-row>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { addDeliveryTask, getLastPalletRecyclingDest } from "@/api/les/lesPalletReturn.js";
|
||||||
|
import LesDeliveryTaskType from "@/utils/enums/LesDeliveryTaskType";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
formData: {
|
||||||
|
taskType: LesDeliveryTaskType.PALLET_RECYCLING
|
||||||
|
},
|
||||||
|
/** 校验规则 */
|
||||||
|
rules: {
|
||||||
|
srcLocationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请选择发货点位',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
destLocationCode: {
|
||||||
|
rules: [{
|
||||||
|
required: true,
|
||||||
|
errorMessage: '请选择目的货位',
|
||||||
|
}, ]
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
getLastPalletRecyclingDest().then(res => {
|
||||||
|
if (res.code == 200) {
|
||||||
|
this.$set(this.formData, "destLocationCode", res.data);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
scanSrcLocationUuid() {
|
||||||
|
const _this = this;
|
||||||
|
uni.scanCode({
|
||||||
|
scanType: ['qrCode', 'barCode'],
|
||||||
|
success: function(res) {
|
||||||
|
_this.formData.destLocationCode = res.result;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleCall() {
|
||||||
|
const _this = this;
|
||||||
|
this.$refs.form.validate().then(res => {
|
||||||
|
if (_this.formData.srcLocationCode && _this.formData.destLocationCode) {
|
||||||
|
_this.$modal.loading('提交中')
|
||||||
|
addDeliveryTask(_this.formData).then(res => {
|
||||||
|
_this.$modal.closeLoading();
|
||||||
|
_this.$modal.msgSuccess("提交成功!");
|
||||||
|
setTimeout(() => {
|
||||||
|
this.$tab.switchTab("/pages/work/index");
|
||||||
|
}, 500);
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
_this.$modal.msg("请将信息补充完整")
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// reset() {
|
||||||
|
// const _this = this;
|
||||||
|
// this.formData.srcLocationCode = '';
|
||||||
|
// this.formData.destLocationCode = '';
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
@@ -937,7 +937,7 @@
|
|||||||
"navigationBarTitleText": "炉长记录"
|
"navigationBarTitleText": "炉长记录"
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "/pages/bom/inspectionRecords",
|
"path": "/pages/les/inspectionRecords",
|
||||||
"permission": "mes:pwo:query",
|
"permission": "mes:pwo:query",
|
||||||
"icon": "icon-jianyanjilu",
|
"icon": "icon-jianyanjilu",
|
||||||
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
@@ -945,7 +945,7 @@
|
|||||||
"navigationBarTitleText": "检验记录"
|
"navigationBarTitleText": "检验记录"
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "/pages/bom/cleaningRecords",
|
"path": "/pages/les/cleaningRecords",
|
||||||
"permission": "mes:pwo:query",
|
"permission": "mes:pwo:query",
|
||||||
"icon": "icon-a-ziyuan13500",
|
"icon": "icon-a-ziyuan13500",
|
||||||
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
@@ -953,7 +953,7 @@
|
|||||||
"navigationBarTitleText": "清炉记录"
|
"navigationBarTitleText": "清炉记录"
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "/pages/bom/recordQuerys",
|
"path": "/pages/les/recordQuerys",
|
||||||
"permission": "mes:pwo:query",
|
"permission": "mes:pwo:query",
|
||||||
"icon": "icon-yonghujiluchaxun",
|
"icon": "icon-yonghujiluchaxun",
|
||||||
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
@@ -961,5 +961,41 @@
|
|||||||
"navigationBarTitleText": "记录查询"
|
"navigationBarTitleText": "记录查询"
|
||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Les",
|
||||||
|
"data": [{
|
||||||
|
"path": "/pages/les/returnPallet",
|
||||||
|
"permission": "les:deliveryTask:list",
|
||||||
|
"icon": "icon-luchangfenxibaogao",
|
||||||
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "托盘返空"
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
"path": "/pages/les/bindMaterial",
|
||||||
|
"permission": "les:basic:location:list",
|
||||||
|
"icon": "icon-jianyanjilu",
|
||||||
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "备料绑定"
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
"path": "/pages/les/callMaterial",
|
||||||
|
"permission": "les:deliveryTask:list",
|
||||||
|
"icon": "icon-a-ziyuan13500",
|
||||||
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "生产呼料"
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
"path": "/pages/les/chooseTask",
|
||||||
|
"permission": "les:deliveryRecord:list",
|
||||||
|
"icon": "icon-yonghujiluchaxun",
|
||||||
|
"color": "linear-gradient(#FEBD5F, #FEAD37)",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "生产配送"
|
||||||
|
}
|
||||||
|
}]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
6
utils/enums/LesDeliveryTaskType.js
Normal file
6
utils/enums/LesDeliveryTaskType.js
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
const LesDeliveryTaskType = {
|
||||||
|
PRODUCTION: 1,
|
||||||
|
PALLET_RECYCLING: 2,
|
||||||
|
}
|
||||||
|
|
||||||
|
export default LesDeliveryTaskType
|
||||||
7
utils/enums/RobotType.js
Normal file
7
utils/enums/RobotType.js
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
const RobotType = {
|
||||||
|
|
||||||
|
LATENT_MOBILE_ROBOT: 1,
|
||||||
|
LATENT_FORKLIFT_AGV: 2,
|
||||||
|
}
|
||||||
|
|
||||||
|
export default RobotType
|
||||||
Reference in New Issue
Block a user