projects/mes-test #133

Merged
gtz217 merged 281 commits from projects/mes-test into projects/mes 2023-11-30 09:11:34 +08:00
31 changed files with 239 additions and 155 deletions
Showing only changes of commit bc3959412d - Show all commits

View File

@ -1,3 +1,10 @@
###
# @Author: zhp
# @Date: 2023-11-07 19:11:40
# @LastEditTime: 2023-11-16 16:40:59
# @LastEditors: zhp
# @Description:
###
# 生产环境配置
ENV = 'production'
@ -5,7 +12,8 @@ ENV = 'production'
VUE_APP_TITLE = MES系统
# 芋道管理系统/生产环境
VUE_APP_BASE_API = '/prod-api'
VUE_APP_BASE_API = 'http://192.168.0.33:48082'
# 根据服务器或域名修改
# PUBLIC_PATH = 'http://my-pi.com:8888/yudao-admin/'

Binary file not shown.

View File

@ -1,7 +1,7 @@
/*
* @Author: Do not edit
* @Date: 2023-11-08 15:56:52
* @LastEditTime: 2023-11-13 09:15:17
* @LastEditTime: 2023-11-16 20:15:02
* @LastEditors: DY
* @Description:
*/
@ -60,3 +60,11 @@ export function getcheckConfigByEqList(query) {
params: query
})
}
// 删除设备巡检记录
export function deleteEqCheckLog(id) {
return request({
url: '/base/equipment-check-log/delete?id=' + id,
method: 'delete'
})
}

View File

@ -0,0 +1,16 @@
/*
* @Author: Do not edit
* @Date: 2023-11-08 15:56:52
* @LastEditTime: 2023-11-16 20:22:12
* @LastEditors: DY
* @Description:
*/
import request from '@/utils/request'
// 删除设备保养记录
export function deleteEqMaintainLog(id) {
return request({
url: '/base/equipment-maintain-log/delete?id=' + id,
method: 'delete'
})
}

View File

@ -1,7 +1,7 @@
/*
* @Author: Do not edit
* @Date: 2023-11-10 16:09:33
* @LastEditTime: 2023-11-10 16:50:08
* @LastEditTime: 2023-11-16 18:57:08
* @LastEditors: DY
* @Description:
*/
@ -23,3 +23,11 @@ export function updateEqRepair(data) {
data: data
})
}
// 删除维修记录
export function deleteRepair(id) {
return request({
url: '/base/equipment-repair-log/delete?id=' + id,
method: 'delete'
})
}

View File

@ -1,7 +1,7 @@
/*
* @Author: Do not edit
* @Date: 2023-11-11 16:18:57
* @LastEditTime: 2023-11-11 17:28:54
* @LastEditTime: 2023-11-16 20:52:06
* @LastEditors: DY
* @Description:
*/
@ -49,3 +49,20 @@ export function getSparePartList(query) {
params: query
})
}
// 删除设备备品备件配置
export function deleteConfig(id) {
return request({
url: '/base/equipment-spare-part-config/delete?id=' + id,
method: 'delete'
})
}
// 获得备品备件分页
export function getSparePartPage(query) {
return request({
url: '/base/equipment-spare-part/page',
method: 'get',
params: query
})
}

View File

@ -1,7 +1,7 @@
/*
* @Author: zhp
* @Date: 2023-11-07 19:47:48
* @LastEditTime: 2023-11-08 16:59:32
* @LastEditTime: 2023-11-16 17:49:23
* @LastEditors: zhp
* @Description:
*/
@ -12,7 +12,7 @@ export function processEquMaterialBomPage(data) {
return request({
url: '/extend/process-equ-material-bom/page',
method: 'get',
data: data
params: data
})
}

View File

@ -1,18 +1,18 @@
/*
* @Author: zhp
* @Date: 2023-11-09 09:37:14
* @LastEditTime: 2023-11-09 14:20:02
* @LastEditTime: 2023-11-16 17:47:21
* @LastEditors: zhp
* @Description:
*/
import request from '@/utils/request'
// 获得能耗统计查询分页
export function processEquValueBomPage(data) {
return request({
url: '/extend/process-equ-value-bom/page',
method: 'get',
data: data
params: data
})
}

View File

@ -1,7 +1,7 @@
/*
* @Author: zhp
* @Date: 2023-11-07 14:10:18
* @LastEditTime: 2023-11-14 14:46:04
* @LastEditTime: 2023-11-16 17:49:52
* @LastEditors: zhp
* @Description:
*/
@ -12,7 +12,7 @@ export function getStatisticalDataPage(query) {
return request({
url: '/base/statistical-data/getStatisticData',
method: 'get',
data: query
params: query
})
}

View File

@ -94,8 +94,11 @@ $buttonHeight: $buttonH * 1px;
display: flex;
.pic {
flex: 3;
width: 1px;
min-width: 800px;
// 元素
width: $picWidth;
// width: $picWidth;
height: $picHeight;
background-image: url($picImage);
background-repeat: no-repeat;
@ -116,7 +119,8 @@ $buttonHeight: $buttonH * 1px;
.field {
position: relative;
margin-top: 8%;
flex: 1;
flex: 2;
// width: 800px;
display: flex;
flex-direction: column;
align-items: center;
@ -170,7 +174,7 @@ $buttonHeight: $buttonH * 1px;
}
.form {
margin-top: 32px;
margin-top: 0;
box-sizing: border-box;
// width: $formWidth;
width: 100%;
@ -307,6 +311,19 @@ $buttonHeight: $buttonH * 1px;
}
// - - - - - PC 最小尺寸设置
@media screen and (min-width: 1920px) {
.container {
.content {
.field {
flex: initial;
width: 800px;
}
}
}
}
@media screen and (min-width: 599px) and (max-width: 1366px) {
.container {
min-width: 599px;

View File

@ -17,7 +17,7 @@
<!-- 对话框(添加) -->
<base-dialog :dialogTitle="title" :dialogVisible="open" @close="cancel" @cancel="cancel" width="60%"
@confirm="submitForm">
<DialogForm v-if="open" key="index-dialog-form" ref="form" label-position="top" size="small" :dataForm="form"
<DialogForm v-if="open" key="index-dialog-form" ref="form" label-position="top" size="small" v-model="form"
:rows="computedRows" />
</base-dialog>

View File

@ -202,7 +202,7 @@ export default {
}
},
created() {
this.init()
// this.init()
// console.log('aaaaaa')
// this.otherPaper()
},
@ -227,64 +227,67 @@ export default {
changeMode() {
// hiprintTemplate.clear()
// console.log(this.modelData)
const { mode } = this
const provider = providers[mode]
hiprint.init({
providers: [provider.f]
})
this.$nextTick(() => {
const { mode } = this
const provider = providers[mode]
hiprint.init({
providers: [provider.f]
})
// $('#hiprint-printTemplate').empty()
// console.log(JSON.parse(this.modelData))
hiprint.setConfig()
//
hiprint.setConfig({
movingDistance: 2.5,
text: {
supportOptions: [
{
name: 'styler',
hidden: true
},
{
name: 'formatter',
hidden: true
}
]
// $('#hiprint-printTemplate').empty()
// console.log(JSON.parse(this.modelData))
hiprint.setConfig()
//
hiprint.setConfig({
movingDistance: 2.5,
text: {
supportOptions: [
{
name: 'styler',
hidden: true
},
{
name: 'formatter',
hidden: true
}
]
}
})
// console.log(this.modelData)
// console.log($('#hiprint-printTemplate').empty())
if (this.modelData != {}) {
console.log(this.modelData);
$('.hiprintEpContainer').empty()
hiprint.PrintElementTypeManager.build('.hiprintEpContainer', provider.value)
$('.hiprint-printTemplate').empty()
hiprintTemplate = new hiprint.PrintTemplate({
template: JSON.parse(this.modelData),
settingContainer: '#PrintElementOptionSetting',
paginationContainer: '.hiprint-printPagination'
})
} else {
$('.hiprintEpContainer').empty()
console.log(this.modelData);
hiprint.PrintElementTypeManager.build('.hiprintEpContainer', provider.value)
$('.hiprint-printTemplate').empty()
// const templates = this.$ls.get('KEY_TEMPLATES', {})
const template = provider.value
// console.log(template)
hiprintTemplate = new hiprint.PrintTemplate({
template: template,
settingContainer: '#PrintElementOptionSetting',
paginationContainer: '.hiprint-printPagination'
})
}
hiprintTemplate.design('#hiprint-printTemplate')
// console.log(hiprintTemplate)
console.log(hiprintTemplate);
// hiprintTemplate.design('#hiprint-printTemplate', { grid: true })
// , zoomtrue
this.scaleValue = hiprintTemplate.editingPanel.scale || 1
// this.scaleValue = hiprintTemplate.editingPanel.scale || 1
})
// console.log(this.modelData)
// console.log($('#hiprint-printTemplate').empty())
if (this.modelData) {
// console.log(this.modelData);
$('.hiprintEpContainer').empty()
hiprint.PrintElementTypeManager.build('.hiprintEpContainer', provider.value)
$('.hiprint-printTemplate').empty()
hiprintTemplate = new hiprint.PrintTemplate({
template: JSON.parse(this.modelData),
settingContainer: '#PrintElementOptionSetting',
paginationContainer: '.hiprint-printPagination'
})
} else {
$('.hiprintEpContainer').empty()
hiprint.PrintElementTypeManager.build('.hiprintEpContainer', provider.value)
$('.hiprint-printTemplate').empty()
// const templates = this.$ls.get('KEY_TEMPLATES', {})
const template = provider.value
// console.log(template)
hiprintTemplate = new hiprint.PrintTemplate({
template: template,
settingContainer: '#PrintElementOptionSetting',
paginationContainer: '.hiprint-printPagination'
})
}
// hiprintTemplate.design('#hiprint-printTemplate')
// console.log(hiprintTemplate)
console.log(hiprintTemplate);
hiprintTemplate.design('#hiprint-printTemplate', { grid: true })
// , zoomtrue
this.scaleValue = hiprintTemplate.editingPanel.scale || 1
// this.scaleValue = hiprintTemplate.editingPanel.scale || 1
},
/**
* 设置纸张大小

View File

@ -38,7 +38,7 @@
@close="cancel"
@cancel="cancel"
@confirm="submitForm">
<DialogForm v-if="open" ref="form" :dataForm="form" :rows="rows" />
<DialogForm v-if="open" ref="form" v-model="form" :rows="rows" />
</base-dialog>
<!-- 抽屉 详情 -->

View File

@ -38,7 +38,7 @@
@close="cancel"
@cancel="cancel"
@confirm="submitForm">
<DialogForm v-if="open" ref="form" :dataForm="form" :rows="rows" />
<DialogForm v-if="open" ref="form" v-model="form" :rows="rows" />
</base-dialog>
<!-- 抽屉 详情 -->

View File

@ -49,7 +49,8 @@
filterable
:disabled="isdetail"
style="width: 100%"
placeholder="请选择巡检配置">
placeholder="请选择巡检配置"
@change="setInspectionContet">
<el-option
v-for="dict in configList"
:key="dict.id"
@ -107,20 +108,15 @@
</el-button>
<el-button v-else type="primary" @click="dataFormSubmit()">确定</el-button>
</div>
<!-- <attr-add
v-if="addOrUpdateVisible"
ref="addOrUpdate"
:config-id="dataForm.id"
@refreshDataList="getList" /> -->
</el-drawer>
</template>
<script>
import SmallTitle from '../../../base/alarm/Record/SmallTitle.vue';
import { createCheckLog, updateCheckLog, getcheckAllList, getcheckConfigByEqList, getEqCheckLog } from '@/api/equipment/base/inspection/record'
import { createCheckLog, updateCheckLog, getcheckConfigByEqList, getEqCheckLog } from '@/api/equipment/base/inspection/record'
import { getEquipmentAll } from '@/api/base/equipment'
import Editor from "@/components/Editor";
import { getCheckDetPage } from "@/api/equipment/base/inspection/settings";
// import FileUpload from "@/components/FileUpload";
// import { parseTime } from '../../../../core/mixins/code-filter';
// import attrAdd from './attr-add';
@ -176,7 +172,8 @@ export default {
equipmentId: undefined,
actualTime: undefined,
responsible: undefined,
description: undefined
description: undefined,
files: []
},
list: [],
eqList: [],
@ -224,8 +221,20 @@ export default {
resetFields(args) {
return this.$refs.dataForm.resetFields(args);
},
initData() {
this.dataForm = {
id: undefined,
configId: undefined,
equipmentId: undefined,
actualTime: undefined,
responsible: undefined,
description: undefined,
files: []
}
this.list = []
},
init(id, isdetail) {
// this.initData();
this.initData();
this.isdetail = isdetail || false;
this.dataForm.id = id || undefined;
this.visible = true;
@ -247,39 +256,12 @@ export default {
});
this.formLoading = false
},
handleClick(raw) {
if (raw.type === 'delete') {
this.$confirm(
`确定要删除名称为${raw.data.sparePartName}的数据?`,
'提示',
{
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
}
)
.then(() => {
deleteConfigDet(raw.data.id).then(({ data }) => {
this.$message({
message: '操作成功',
type: 'success',
duration: 1500,
onClose: () => {
this.getList();
},
});
});
})
.catch(() => {});
} else {
this.addNew(raw.data.id);
}
},
getList() {
//
getcheckAllList({
...this.listQuery,
configId: this.dataForm.id,
setInspectionContet() {
//
getCheckDetPage({
pageNo: 1,
pageSize: 99,
configId: this.dataForm.configId,
}).then((response) => {
this.list = response.data.list;
this.listQuery.total = response.data.total;
@ -308,6 +290,8 @@ export default {
})
})
this.dataForm.files = arry
} else {
this.dataForm.files = []
}
//

View File

@ -57,7 +57,7 @@
import moment from 'moment';
import basicPageMixin from '@/mixins/lb/basicPageMixin';
import addRecord from './addRecord.vue';
import { exportCheckLogExcel } from '@/api/equipment/base/inspection/record'
import { exportCheckLogExcel, deleteEqCheckLog } from '@/api/equipment/base/inspection/record'
import { parseTime } from '../../../../core/mixins/code-filter';
const timeFilter = (val) => moment(val).format('yyyy-MM-DD HH:mm:ss');
@ -349,9 +349,9 @@ export default {
handleDelete(row) {
const id = row.id;
this.$modal
.confirm('是否确认删除记录"' + row.name + '"?')
.confirm('是否删除设备巡检记录配置名称为"' + row.configName + '"的数据项?')
.then(function () {
return this.delete({ id });
return deleteEqCheckLog(id);
})
.then(() => {
this.getList();

View File

@ -42,7 +42,7 @@
v-if="open"
ref="form"
v-model="form"
:disabled="mode == 'detail'"
:disabled="mode == 'detail'"
:has-files="true"
:rows="rows" />
</base-dialog>
@ -53,6 +53,7 @@
import moment from 'moment';
import basicPageMixin from '@/mixins/lb/basicPageMixin';
import Editor from '@/components/Editor';
import { deleteEqMaintainLog } from '@/api/equipment/base/maintain/record'
const timeFilter = (val) => moment(val).format('yyyy-MM-DD HH:mm:ss');
@ -131,7 +132,7 @@ export default {
label: '时间段',
dateType: 'daterange', // datetimerange
format: 'yyyy-MM-dd',
valueFormat: 'timestamp',
valueFormat: 'yyyy-MM-dd HH:mm:ss',
rangeSeparator: '-',
startPlaceholder: '开始日期',
endPlaceholder: '结束日期',
@ -430,9 +431,9 @@ export default {
handleDelete(row) {
const id = row.id;
this.$modal
.confirm('是否确认删除记录"' + row.name + '"?')
.confirm('是否删除设备保养单号为"' + row.maintainOrderNumber + '"的数据项?')
.then(function () {
return this.delete({ id });
return deleteEqMaintainLog(id);
})
.then(() => {
this.getList();

View File

@ -56,6 +56,7 @@
import moment from 'moment';
import basicPageMixin from '@/mixins/lb/basicPageMixin';
import CustomDialogForm from './CustomDialogForm.vue';
import { deleteRepair } from '@/api/equipment/base/repair'
const timeFilter = (val) => moment(val).format('yyyy-MM-DD HH:mm:ss');
@ -239,7 +240,7 @@ export default {
//
form: {},
basePath: '/base/equipment-repair-log',
mode: null,
mode: null
};
},
created() {
@ -375,9 +376,9 @@ export default {
handleDelete(row) {
const id = row.id;
this.$modal
.confirm('是否确认删除记录"' + row.name + '"?')
.then(function () {
return this.delete({ id });
.confirm('是否确认删除维修单号为"' + row.repairOrderNumber + '"的数据?')
.then(() => {
return deleteRepair(id);
})
.then(() => {
this.getList();
@ -411,6 +412,7 @@ export default {
},
//
handleTableBtnClick({ data, type }) {
console.log('nihc', data, type)
switch (type) {
case 'edit':
this.handleUpdate(data);

View File

@ -188,6 +188,7 @@ export default {
getSparePartConfig(this.dataForm.id).then(response => {
this.formLoading = false
this.dataForm = response.data;
this.getList()
});
} else {
// if (this.urlOptions.isGetCode) {
@ -257,7 +258,9 @@ export default {
padding: 18px;
}
.action_btn {
float: right;
/* float: right; */
display: flex;
justify-content: right;
margin: 5px 15px;
font-size: 14px;
}

View File

@ -44,7 +44,7 @@
<script>
import {
createConfigDet,
getSparePartList
getSparePartPage
} from '@/api/equipment/base/spare-parts/config';
export default {
@ -72,8 +72,12 @@ export default {
},
methods: {
async getDict() {
const res = await getSparePartList()
this.partList = res.data
await getSparePartPage({
pageNo: 1,
pageSize: 99
}).then(res => {
this.partList = res.data.list;
})
},
init(id) {
this.dataForm.id = id || '';

View File

@ -59,6 +59,7 @@ import basicPageMixin from '@/mixins/lb/basicPageMixin';
import { publicFormatter } from '@/utils/dict';
import Editor from '@/components/Editor';
import addSparts from './addSparts.vue';
import { deleteConfig } from '@/api/equipment/base/spare-parts/config'
const timeFilter = (val) => moment(val).format('yyyy-MM-DD HH:mm:ss');
@ -282,7 +283,7 @@ export default {
const id = row.id;
this.info({ id }).then((response) => {
this.form = response.data;
this.form.responsible = this.form.responsible.split(',')
this.form.responsible = this.form.responsible ? this.form.responsible.split(',') : undefined
this.open = true;
this.title = '修改备品备件配置';
});
@ -315,9 +316,9 @@ export default {
handleDelete(row) {
const id = row.id;
this.$modal
.confirm('是否确认删除记录"' + row.name + '"?')
.confirm('是否确认删除配置名为"' + row.name + '"的数据?')
.then(function () {
return this.delete({ id });
return deleteConfig(id);
})
.then(() => {
this.getList();

View File

@ -328,7 +328,7 @@ export default {
this.initState();
const { code, data } = await this.$axios({
url: '/analysis/equipment-analysis/quantity',
url: '/monitoring/equipment-monitor/quantity-series',
method: 'get',
params: this.queryParams,
});

View File

@ -210,7 +210,7 @@ export default {
async getList() {
const { code, data } = await this.$axios({
url: '/analysis/equipment-analysis/status',
url: '/monitoring/equipment-monitor/status-series',
method: 'get',
params: this.queryParams,
});

View File

@ -174,7 +174,7 @@ export default {
this.listQuery.pageSize = 10;
this.listQuery.equipmentId = val.equipmentId ? val.equipmentId : undefined;
this.listQuery.name = val.name ? val.name : undefined;
this.listQuery.name = val.name ? val.name : undefined;
this.listQuery.code = val.code ? val.code : undefined;
this.getDataList();
break;
case 'reset':

View File

@ -96,7 +96,7 @@ export default {
},
{
type: 'input',
label: '物料配方名称',
label: '参数配方名称',
// selectOptions: [],
// labelField: 'name',
// valueField: 'id',
@ -104,7 +104,7 @@ export default {
},
{
type: 'input',
label: '物料配方编码',
label: '参数配方编码',
// selectOptions: [],
// labelField: 'name',
// valueField: 'id',
@ -174,7 +174,7 @@ export default {
this.listQuery.pageSize = 10;
this.listQuery.equipmentId = val.equipmentId ? val.equipmentId : undefined;
this.listQuery.name = val.name ? val.name : undefined;
this.listQuery.name = val.name ? val.name : undefined;
this.listQuery.code = val.code ? val.code : undefined;
this.getDataList();
break;
case 'reset':

View File

@ -42,7 +42,7 @@
<DialogForm
v-if="open"
ref="form"
:dataForm="form"
v-model="form"
:rows="[
[
{

View File

@ -40,7 +40,7 @@
<DialogForm
v-if="open"
ref="form"
:dataForm="form"
v-model="form"
:rows="[
[
{
@ -208,7 +208,11 @@ export default {
name: null,
},
//
form: {},
form: {
name: null,
code: undefined,
remark:undefined
},
};
},
// watch: {

View File

@ -246,7 +246,7 @@ export default {
//
async getWorksectionList(plId) {
const response = await this.$axios(
'/base/workshop-section/listByParentId',
'/base/core-workshop-section/listByParentId',
{
params: {
id: plId,

View File

@ -13,9 +13,8 @@
<!-- <pre><code v-html="jsondemo"></code></pre> -->
<el-skeleton v-if="initing" :rows="6" animated />
<div v-else :class="{ 'no-data-bg': !list || list.length == 0 }">
<div v-else >
<base-table
v-if="list && list.length > 0"
:table-props="tableProps"
:page="queryParams.pageNo"
:limit="queryParams.pageSize"

View File

@ -71,7 +71,10 @@ export default {
placeholder: '请选择工单号',
param: 'workOrderIdList',
selectOptions: [],
multiple:true,
multiple: true,
labelField: 'name',
valueField: 'id',
defaultSelect: []
},
{
type: 'select',
@ -91,8 +94,8 @@ export default {
label: '时间段',
dateType: 'daterange', // datetimerange
// format: 'yyyy-MM-dd HH:mm:ss',
format: 'yyyy-MM-dd',
valueFormat: 'timestamp',
format: 'yyyy-MM-dd HH:mm:ss',
valueFormat: 'yyyy-MM-dd HH:mm:ss',
rangeSeparator: '-',
startPlaceholder: '开始日期',
endPlaceholder: '结束日期',
@ -246,7 +249,11 @@ export default {
},
mounted() {
if (this.$route.query.woIdString) {
this.queryParams.workOrderIdList = this.$route.query.woIdString
console.log(this.$route.query.woIdString);
this.queryParams.workOrderIdList = [this.$route.query.woIdString]
// let arr =[]
this.searchBarFormConfig[0].defaultSelect = [this.$route.query.woIdString]
console.log(this.searchBarFormConfig[0].defaultSelect);
}
// if (this.$route.params.startTime && this.$route.params.endTime) {
// this.searchBarFormConfig[0].defaultSelect = [
@ -301,7 +308,8 @@ export default {
this.getDict()
},
/** 查询列表 */
async getDataList() {
async getDataList() {
console.log(this.queryParams);
this.loading = true;
//
const {

View File

@ -1,13 +1,13 @@
<!--
* @Author: zhp
* @Date: 2023-10-17 09:26:38
* @LastEditTime: 2023-10-30 14:53:34
* @LastEditTime: 2023-11-16 18:52:00
* @LastEditors: zhp
* @Description:
-->
<template>
<div>
<doc-alert title="报表设计器" url="https://doc.iocoder.cn/report/" />
<!-- <doc-alert title="报表设计器" url="https://doc.iocoder.cn/report/" /> -->
<i-frame :src="url" />
</div>
</template>
@ -17,6 +17,7 @@ import {getAccessToken} from "@/utils/auth";
export default {
name: "JimuReport",
components: { iFrame },
data() {
return {
url: process.env.VUE_APP_BASE_API + "/jmreport/list?token=" + getAccessToken(),