Merge pull request 'projects/mesxc-dy' (#173) from projects/mesxc-dy into projects/mesxc-test
Reviewed-on: #173
This commit is contained in:
commit
2e8852f667
10
.env.dev
10
.env.dev
@ -1,8 +1,8 @@
|
|||||||
###
|
###
|
||||||
# @Author: Do not edit
|
# @Author: Do not edit
|
||||||
# @Date: 2023-08-29 09:40:39
|
# @Date: 2023-08-29 09:40:39
|
||||||
# @LastEditTime: 2024-01-04 15:50:26
|
# @LastEditTime: 2024-01-08 16:23:54
|
||||||
# @LastEditors: zhp
|
# @LastEditors: DY
|
||||||
# @Description:
|
# @Description:
|
||||||
###
|
###
|
||||||
# 开发环境配置
|
# 开发环境配置
|
||||||
@ -15,9 +15,7 @@ VUE_APP_TITLE = MES系统
|
|||||||
# VUE_APP_BASE_API = 'http://100.64.0.26:48082'
|
# VUE_APP_BASE_API = 'http://100.64.0.26:48082'
|
||||||
|
|
||||||
VUE_APP_BASE_API = 'http://192.168.0.33:48082'
|
VUE_APP_BASE_API = 'http://192.168.0.33:48082'
|
||||||
|
# VUE_APP_BASE_API = 'http://192.168.1.101:8080'
|
||||||
# VUE_APP_BASE_API = 'http://10.70.2.2:8080'
|
|
||||||
|
|
||||||
# VUE_APP_BASE_API = 'http://192.168.4.173:48080'
|
# VUE_APP_BASE_API = 'http://192.168.4.173:48080'
|
||||||
# VUE_APP_BASE_API = 'http://192.168.2.173:48080'
|
# VUE_APP_BASE_API = 'http://192.168.2.173:48080'
|
||||||
# VUE_APP_BASE_API = 'http://192.168.1.49:48082'
|
# VUE_APP_BASE_API = 'http://192.168.1.49:48082'
|
||||||
@ -25,7 +23,7 @@ VUE_APP_BASE_API = 'http://192.168.0.33:48082'
|
|||||||
# VUE_APP_BASE_API = 'http://192.168.4.159:48080'
|
# VUE_APP_BASE_API = 'http://192.168.4.159:48080'
|
||||||
# VUE_APP_BASE_API = 'http://192.168.1.104:48082'
|
# VUE_APP_BASE_API = 'http://192.168.1.104:48082'
|
||||||
# VUE_APP_BASE_API = 'http://192.168.1.62:48082'
|
# VUE_APP_BASE_API = 'http://192.168.1.62:48082'
|
||||||
VUE_APP_BASE_API = 'http://192.168.1.78:48082'
|
# VUE_APP_BASE_API = 'http://192.168.1.78:48082'
|
||||||
# socket地址
|
# socket地址
|
||||||
VUE_APP_Socket_API = 'ws://192.168.0.33:48082'
|
VUE_APP_Socket_API = 'ws://192.168.0.33:48082'
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* @Author: zwq
|
* @Author: zwq
|
||||||
* @Date: 2021-11-18 14:16:25
|
* @Date: 2021-11-18 14:16:25
|
||||||
* @LastEditors: DY
|
* @LastEditors: DY
|
||||||
* @LastEditTime: 2023-12-06 10:36:56
|
* @LastEditTime: 2024-01-08 16:11:03
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
@ -253,6 +253,7 @@ export default {
|
|||||||
dataRule: {
|
dataRule: {
|
||||||
code: [{ required: true, message: "产品编码不能为空", trigger: "blur" }],
|
code: [{ required: true, message: "产品编码不能为空", trigger: "blur" }],
|
||||||
name: [{ required: true, message: "产品名称不能为空", trigger: "blur" }],
|
name: [{ required: true, message: "产品名称不能为空", trigger: "blur" }],
|
||||||
|
specifications: [{ required: true, message: "规格不能为空", trigger: "blur" }],
|
||||||
materialType: [{ required: true, message: "物料类型不能为空", trigger: "change" }],
|
materialType: [{ required: true, message: "物料类型不能为空", trigger: "change" }],
|
||||||
productType: [{ required: true, message: "产品类型不能为空", trigger: "change" }],
|
productType: [{ required: true, message: "产品类型不能为空", trigger: "change" }],
|
||||||
processTime: [{ required: true, message: "产线生产单位用时不能为空", trigger: "blur" }]
|
processTime: [{ required: true, message: "产线生产单位用时不能为空", trigger: "blur" }]
|
||||||
|
@ -51,10 +51,10 @@ export default {
|
|||||||
components: {},
|
components: {},
|
||||||
props: {},
|
props: {},
|
||||||
data() {
|
data() {
|
||||||
const now = new Date();
|
// const now = new Date().getTime();
|
||||||
// const [y, m, d] = [now.getFullYear(), now.getMonth(), now.getDate()];
|
// const [y, m, d] = [now.getFullYear(), now.getMonth(), now.getDate()];
|
||||||
const today = new Date().getTime();
|
const today = new Date().getTime();
|
||||||
const tenminAgo = today - (10 * 60 * 1000);
|
const tenminAgo = new Date(today - (10 * 60 * 1000)).getTime();
|
||||||
return {
|
return {
|
||||||
searchBarFormConfig: [
|
searchBarFormConfig: [
|
||||||
{
|
{
|
||||||
@ -77,7 +77,7 @@ export default {
|
|||||||
dateType: 'datetimerange', // datetimerange
|
dateType: 'datetimerange', // datetimerange
|
||||||
format: 'yyyy-MM-dd HH:mm:ss',
|
format: 'yyyy-MM-dd HH:mm:ss',
|
||||||
// valueFormat: 'yyyy-MM-dd HH:mm:ss',
|
// valueFormat: 'yyyy-MM-dd HH:mm:ss',
|
||||||
valueFormat: 'timestamp',
|
valueFormat: 'yyyy-MM-dd HH:mm:ss',
|
||||||
rangeSeparator: '-',
|
rangeSeparator: '-',
|
||||||
startPlaceholder: '开始时间',
|
startPlaceholder: '开始时间',
|
||||||
endPlaceholder: '结束时间',
|
endPlaceholder: '结束时间',
|
||||||
@ -94,8 +94,8 @@ export default {
|
|||||||
},
|
},
|
||||||
],
|
],
|
||||||
queryParams: {
|
queryParams: {
|
||||||
id: null,
|
equipmentId: null,
|
||||||
time: [tenminAgo, today],
|
recordTime: [parseTime(tenminAgo), parseTime(today)],
|
||||||
},
|
},
|
||||||
tableList: [
|
tableList: [
|
||||||
// {
|
// {
|
||||||
@ -118,7 +118,7 @@ export default {
|
|||||||
beforeRouteEnter(to, from, next) {
|
beforeRouteEnter(to, from, next) {
|
||||||
if (Object.keys(to.params).length > 0) {
|
if (Object.keys(to.params).length > 0) {
|
||||||
next((vm) => {
|
next((vm) => {
|
||||||
vm.$set(vm.queryParams, 'id', to.params.equipmentId);
|
vm.$set(vm.queryParams, 'equipmentId', to.params.equipmentId);
|
||||||
vm.$set(
|
vm.$set(
|
||||||
vm.searchBarFormConfig[0],
|
vm.searchBarFormConfig[0],
|
||||||
'defaultSelect',
|
'defaultSelect',
|
||||||
@ -132,7 +132,7 @@ export default {
|
|||||||
vm.$set(
|
vm.$set(
|
||||||
vm.searchBarFormConfig[2],
|
vm.searchBarFormConfig[2],
|
||||||
'defaultSelect',
|
'defaultSelect',
|
||||||
vm.queryParams.time
|
vm.queryParams.recordTime
|
||||||
);
|
);
|
||||||
vm.handleQuery();
|
vm.handleQuery();
|
||||||
});
|
});
|
||||||
@ -167,7 +167,7 @@ export default {
|
|||||||
},
|
},
|
||||||
beforeRouteLeave(to, from, next) {
|
beforeRouteLeave(to, from, next) {
|
||||||
// clean job
|
// clean job
|
||||||
this.$set(this.queryParams, 'id', null);
|
this.$set(this.queryParams, 'equipmentId', null);
|
||||||
this.$set(this.searchBarFormConfig[0], 'defaultSelect', null);
|
this.$set(this.searchBarFormConfig[0], 'defaultSelect', null);
|
||||||
this.$set(this.searchBarFormConfig[1], 'defaultSelect', null);
|
this.$set(this.searchBarFormConfig[1], 'defaultSelect', null);
|
||||||
this.tableList = [];
|
this.tableList = [];
|
||||||
@ -204,7 +204,7 @@ export default {
|
|||||||
props.push({
|
props.push({
|
||||||
label: item.name,
|
label: item.name,
|
||||||
prop: item.name,
|
prop: item.name,
|
||||||
width: 128,
|
// width: 128,
|
||||||
});
|
});
|
||||||
firstLineData[item.name] = `${item.minValue ?? ''}-${
|
firstLineData[item.name] = `${item.minValue ?? ''}-${
|
||||||
item.maxValue ?? ''
|
item.maxValue ?? ''
|
||||||
@ -280,14 +280,15 @@ export default {
|
|||||||
|
|
||||||
async handleSearchBarBtnClick({ btnName, timeVal }) {
|
async handleSearchBarBtnClick({ btnName, timeVal }) {
|
||||||
if (timeVal && timeVal.length > 0) {
|
if (timeVal && timeVal.length > 0) {
|
||||||
if (timeVal[1] - timeVal[0] <= 10 * 60 * 1000) {
|
console.log('nihc ', timeVal)
|
||||||
this.queryParams.time = timeVal;
|
if (new Date(timeVal[1]).getTime() - new Date(timeVal[0]).getTime() <= 10 * 60 * 1000) {
|
||||||
|
this.queryParams.recordTime = timeVal;
|
||||||
await this.handleQuery();
|
await this.handleQuery();
|
||||||
} else {
|
} else {
|
||||||
this.$message.warning('时间范围最大一小时限制!')
|
this.$message.warning('时间范围最大一小时限制!')
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.queryParams.time = [];
|
this.queryParams.recordTime = [];
|
||||||
this.$message.warning('时间段必选!')
|
this.$message.warning('时间段必选!')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user