Compare commits

...

14 Commits

Author SHA1 Message Date
zwq
5d2d510e23 修改成本表格 2024-03-26 09:04:17 +08:00
a8531c95d6 Merge pull request 'projects/mesxc-zhp' (#272) from projects/mesxc-zhp into projects/mesxc-test
Reviewed-on: #272
2024-03-26 08:17:42 +08:00
‘937886381’
b593bcee5a Merge branch 'projects/mesxc-test' into projects/mesxc-zhp 2024-03-25 18:42:34 +08:00
‘937886381’
a750e565e2 修改bug 2024-03-25 18:42:00 +08:00
17b4d5f812 Merge pull request 'projects/mesxc-zhp' (#271) from projects/mesxc-zhp into projects/mesxc-test
Reviewed-on: #271
2024-03-25 17:00:21 +08:00
‘937886381’
d5a645e6f1 Merge branch 'projects/mesxc-test' into projects/mesxc-zhp 2024-03-25 16:58:15 +08:00
‘937886381’
3823c3cb3e 修改bug 2024-03-25 16:57:41 +08:00
906b05ef51 Merge pull request 'projects/mesxc-zhp' (#270) from projects/mesxc-zhp into projects/mesxc-test
Reviewed-on: #270
2024-03-22 22:20:01 +08:00
‘937886381’
bcadc83725 Merge branch 'projects/mesxc-test' into projects/mesxc-zhp 2024-03-22 17:14:57 +08:00
‘937886381’
649be9a18b 修改bug 2024-03-22 17:14:34 +08:00
f9447912d9 Merge pull request 'projects/mesxc-zhp' (#268) from projects/mesxc-zhp into projects/mesxc-test
Reviewed-on: #268
2024-03-22 16:46:58 +08:00
‘937886381’
95abfcf158 Merge branch 'projects/mesxc-test' into projects/mesxc-zhp 2024-03-22 16:45:56 +08:00
‘937886381’
ba2aa7b1b8 修改bug 2024-03-22 16:45:17 +08:00
4b29eede9d Merge pull request '更新成本bug' (#267) from projects/mesxc-zwq into projects/mesxc-test
Reviewed-on: #267
2024-03-22 16:23:30 +08:00
25 changed files with 171 additions and 128 deletions

View File

@ -1,7 +1,7 @@
### ###
# @Author: Do not edit # @Author: Do not edit
# @Date: 2023-08-29 09:40:39 # @Date: 2023-08-29 09:40:39
# @LastEditTime: 2024-03-22 14:18:33 # @LastEditTime: 2024-03-25 15:59:53
# @LastEditors: zhp # @LastEditors: zhp
# @Description: # @Description:
### ###

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2024-01-29 16:50:26 * @Date: 2024-01-29 16:50:26
* @LastEditTime: 2024-03-13 09:07:37 * @LastEditTime: 2024-03-25 18:33:48
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -793,11 +793,11 @@ export default {
// formatDate(item.planStartTime) || '', // formatDate(item.planStartTime) || '',
// `<span style="color:rgba(255,255,255,0.5)" >${item.line || ''} // `<span style="color:rgba(255,255,255,0.5)" >${item.line || ''}
// </span>`, // </span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.name || ''}</span>`, `<span style="color:rgba(255,255,255,0.5)">${ele.name || ''}</span>`,
// `<span style="color:rgba(255,255,255,0.5)">${item.code || ''}</span>`, // `<span style="color:rgba(255,255,255,0.5)">${item.code || ''}</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.run || ''}</span>`, `<span style="color:rgba(255,255,255,0.5)">${ele.run || ''}</span>`,
// `<span style="color:rgba(255,255,255,0.5)">${item.error || ''}</span>`, // `<span style="color:rgba(255,255,255,0.5)">${item.error || ''}</span>`,
]); ])
} }
this.realEqConfig.data = this.realEqList this.realEqConfig.data = this.realEqList
this.$refs['realEqScrollBoard'].updateRows(this.realEqList) this.$refs['realEqScrollBoard'].updateRows(this.realEqList)

View File

@ -2,7 +2,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2023-09-21 09:06:28 * @Date: 2023-09-21 09:06:28
* @LastEditTime: 2024-01-29 15:39:59 * @LastEditTime: 2024-03-25 18:34:58
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -158,7 +158,7 @@ export default {
legend: { legend: {
itemWidth: 10, itemWidth: 10,
itemHeight: 10, itemHeight: 10,
top: '1%', top: '20',
// right: '20px', // right: '20px',
data: ['产线产量', '产线良品率'], data: ['产线产量', '产线良品率'],
textStyle: { textStyle: {

View File

@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<div :id="id" :class="className" :style="{ height: height + 'px', width: width }" /> <div :id="id" :class="className" :style="{ height: '420px', width: width }" />
</div> </div>
</template> </template>
@ -19,7 +19,7 @@ export default {
}, },
className: { className: {
type: String, type: String,
default: 'chart' default: 'enChart'
}, },
width: { width: {
type: String, type: String,
@ -84,7 +84,7 @@ export default {
}, },
methods: { methods: {
initChart(nameList, dataList) { initChart(nameList, dataList) {
console.log('1111', dataList); // console.log('1111', dataList);
// console.log(1) // console.log(1)
this.chart = echarts.init(document.getElementById(this.id)) this.chart = echarts.init(document.getElementById(this.id))
// if (dataList.length !== 0) { // if (dataList.length !== 0) {
@ -123,13 +123,7 @@ export default {
type: 'shadow' // 线'line' | 'shadow' type: 'shadow' // 线'line' | 'shadow'
} }
}, },
grid: { grid: { top: 90, right: 60, bottom: 20, left: 90 },
top: 30,
left: '2%',
right: '2%',
bottom: '3%',
containLabel: true
},
// legend: { // legend: {
// itemWidth: 10, // itemWidth: 10,
// itemHeight: 10, // itemHeight: 10,
@ -205,4 +199,11 @@ export default {
} }
} }
</script> </script>
<style>
.enChart {
position: absolute;
height: 100%;
width: 100%;
top: -30px;
}
</style>

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2023-12-27 13:54:52 * @Date: 2023-12-27 13:54:52
* @LastEditTime: 2024-03-13 09:04:11 * @LastEditTime: 2024-03-25 18:37:26
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -92,18 +92,20 @@ export default {
methods: { methods: {
initChart(nameList, topNameList, nameWasteList, passRateList, wasteList) { initChart(nameList, topNameList, nameWasteList, passRateList, wasteList) {
let rawData = [] let rawData = []
rawData.push(passRateList,wasteList) let colors = ['#0fdedb', '#2359ec']
// console.log(1) if (passRateList && wasteList) {
const totalData = []; rawData.push(passRateList, wasteList)
for (let i = 0; i < rawData[0].length; ++i) { // console.log(1)
let sum = 0; const totalData = [];
for (let j = 0; j < rawData.length; ++j) { for (let i = 0; i < rawData[0].length; ++i) {
sum += rawData[j][i]; let sum = 0;
for (let j = 0; j < rawData.length; ++j) {
sum += rawData[j][i];
}
totalData.push(sum);
} }
totalData.push(sum); console.log('total', totalData);
} }
let colors = ['#0fdedb', '#2359ec' ]
console.log('total', totalData);
this.chart = echarts.init(document.getElementById(this.id)) this.chart = echarts.init(document.getElementById(this.id))
const series = [ const series = [
'良品', '良品',
@ -123,9 +125,9 @@ export default {
formatter: (params) => Math.round(params.value * 1000) / 10 + '%' formatter: (params) => Math.round(params.value * 1000) / 10 + '%'
}, },
color:colors[sid], color:colors[sid],
data: rawData[sid].map((d, did) => data: rawData.length != 0 ? rawData[sid].map((d, did) =>
totalData[did] <= 0 ? 0 : d / totalData[did] totalData[did] <= 0 ? 0 : d / totalData[did]
) ) : []
}; };
}); });
// let series = [ // let series = [
@ -172,6 +174,7 @@ export default {
legend: { legend: {
itemWidth: 12, itemWidth: 12,
itemHeight: 12, itemHeight: 12,
top:'10',
icon: 'rect', icon: 'rect',
textStyle: { textStyle: {
color: '#ffffff' color: '#ffffff'

View File

@ -2,7 +2,7 @@
* @Author: zwq * @Author: zwq
* @Date: 2021-07-19 15:18:30 * @Date: 2021-07-19 15:18:30
* @LastEditors: zhp * @LastEditors: zhp
* @LastEditTime: 2024-03-21 16:07:39 * @LastEditTime: 2024-03-25 16:54:49
* @Description: * @Description:
--> -->
<template> <template>
@ -605,10 +605,7 @@ export default {
} }
}, },
created() { created() {
// this.fetchList('exception-alarm') this.getData()
// this.fetchList('inAndOutOfEachLine')
// this.fetchList('order-process')
// this.fetchList('line-chart-data')
this.init() this.init()
setTimeout(() => { setTimeout(() => {
window.location.reload() window.location.reload()
@ -671,6 +668,22 @@ export default {
// removeEventListener('resize', resizeFun) // removeEventListener('resize', resizeFun)
// }, // },
methods: { methods: {
getData() {
let processArr = qualityMonthList.map((item, index) => [
// console.log(item)
`<span style="color:rgba(255,255,255,0.5)" >${index + 1 || ''}
</span>`,
// formatDate(item.planStartTime) || '',
`
<span style="color:rgba(255,255,255,0.5)" >${item.productionLineName || ''}
</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.sectionName || ''}</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.count || ''}</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.inspectionTypeName || ''}</span>`,
])
this.processConfig.data = processArr
this.$refs['processScrollBoard'].updateRows(processArr)
},
// getList() { // getList() {
// // this.$axios.get( // // this.$axios.get(
// // 'base/core-production-line/listAll', // // 'base/core-production-line/listAll',
@ -867,20 +880,6 @@ export default {
// this.$nextTick(() => { // this.$nextTick(() => {
this.$refs.productLineChart.initChart(nameList, passRateList, outputNumList) this.$refs.productLineChart.initChart(nameList, passRateList, outputNumList)
} else if (this.SJGInitWebSocket === 'inspection') { } else if (this.SJGInitWebSocket === 'inspection') {
let processArr = qualityMonthList.map((item, index) => [
// console.log(item)
`<span style="color:rgba(255,255,255,0.5)" >${index + 1 || ''}
</span>`,
// formatDate(item.planStartTime) || '',
`
<span style="color:rgba(255,255,255,0.5)" >${item.productionLineName || ''}
</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.sectionName || ''}</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.count || ''}</span>`,
`<span style="color:rgba(255,255,255,0.5)">${item.inspectionTypeName || ''}</span>`,
])
this.processConfig.data = processArr
this.$refs['processScrollBoard'].updateRows(processArr)
} }
}, },
// //

View File

@ -12,6 +12,7 @@
:table-props="tableProps" :table-props="tableProps"
:page="listQuery.pageNo" :page="listQuery.pageNo"
:limit="listQuery.pageSize" :limit="listQuery.pageSize"
:max-height="tableH"
:table-data="tableData"></base-table> :table-data="tableData"></base-table>
<pagination <pagination
:limit.sync="listQuery.pageSize" :limit.sync="listQuery.pageSize"
@ -69,6 +70,7 @@ export default {
}, },
tableData: [], tableData: [],
tableProps, tableProps,
tableH: this.tableHeight(260),
drawerVisible: false, drawerVisible: false,
formConfig: [ formConfig: [
{ {
@ -109,6 +111,9 @@ export default {
}, },
components: {}, components: {},
created() { created() {
window.addEventListener('resize', () => {
this.tableH = this.tableHeight(260)
})
getEnergyTypeListAll().then((response) => { getEnergyTypeListAll().then((response) => {
this.formConfig[0].selectOptions = response.data; this.formConfig[0].selectOptions = response.data;
}); });
@ -133,7 +138,7 @@ export default {
switch (val.btnName) { switch (val.btnName) {
case 'search': case 'search':
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 20;
this.listQuery.energyTypeId = val.energyTypeId; this.listQuery.energyTypeId = val.energyTypeId;
this.listQuery.searchTime = val.searchTime ? val.searchTime[0] : null; this.listQuery.searchTime = val.searchTime ? val.searchTime[0] : null;
this.listQuery.startTime = val.searchTime this.listQuery.startTime = val.searchTime

View File

@ -12,6 +12,7 @@
:table-props="tableProps" :table-props="tableProps"
:page="listQuery.pageNo" :page="listQuery.pageNo"
:limit="listQuery.pageSize" :limit="listQuery.pageSize"
:max-height="tableH"
:table-data="tableData"></base-table> :table-data="tableData"></base-table>
<pagination <pagination
:limit.sync="listQuery.pageSize" :limit.sync="listQuery.pageSize"
@ -79,6 +80,7 @@ export default {
}, },
tableData: [], tableData: [],
tableProps, tableProps,
tableH: this.tableHeight(260),
drawerVisible: false, drawerVisible: false,
formConfig: [ formConfig: [
{ {
@ -133,6 +135,9 @@ export default {
}, },
components: {}, components: {},
created() { created() {
window.addEventListener('resize', () => {
this.tableH = this.tableHeight(260)
})
const end = new Date(); const end = new Date();
const start = new Date(); const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30); start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
@ -150,7 +155,7 @@ export default {
switch (val.btnName) { switch (val.btnName) {
case 'search': case 'search':
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 20;
this.listQuery.reportType = val.reportType; this.listQuery.reportType = val.reportType;
this.listQuery.energyTypeId = val.energyTypeId; this.listQuery.energyTypeId = val.energyTypeId;
this.listQuery.reportTime = val.searchTime this.listQuery.reportTime = val.searchTime

View File

@ -2,7 +2,7 @@
* @Author: zwq * @Author: zwq
* @Date: 2022-08-24 11:19:43 * @Date: 2022-08-24 11:19:43
* @LastEditors: zwq * @LastEditors: zwq
* @LastEditTime: 2023-12-07 09:35:33 * @LastEditTime: 2024-03-25 14:11:46
* @Description: * @Description:
*/ */
export default { export default {
@ -17,7 +17,7 @@ export default {
}, },
tableData: [], tableData: [],
listQuery: { listQuery: {
pageSize: 10, pageSize: 20,
pageNo: 1, pageNo: 1,
total: 1, total: 1,
}, },

View File

@ -12,6 +12,7 @@
:table-props="tableProps" :table-props="tableProps"
:page="listQuery.pageNo" :page="listQuery.pageNo"
:limit="listQuery.pageSize" :limit="listQuery.pageSize"
:max-height="tableH"
:table-data="tableData"> :table-data="tableData">
<method-btn <method-btn
v-if="tableBtn.length" v-if="tableBtn.length"
@ -61,7 +62,7 @@ const tableProps = [
{ {
prop: 'code', prop: 'code',
label: '原料编码', label: '原料编码',
width: 190, width: 180,
}, },
{ {
prop: 'grade', prop: 'grade',
@ -98,6 +99,7 @@ export default {
deleteURL: deleteCostMaterialSet, deleteURL: deleteCostMaterialSet,
}, },
tableProps, tableProps,
tableH: this.tableHeight(260),
tableBtn: [ tableBtn: [
this.$auth.hasPermi(`cost:rawMaterialConfig:update`) this.$auth.hasPermi(`cost:rawMaterialConfig:update`)
? { ? {
@ -146,6 +148,9 @@ export default {
AddOrUpdate, AddOrUpdate,
}, },
created() { created() {
window.addEventListener('resize', () => {
this.tableH = this.tableHeight(260)
})
getHotMaterialList().then((response) => { getHotMaterialList().then((response) => {
this.formConfig[0].selectOptions = response.data; this.formConfig[0].selectOptions = response.data;
}); });
@ -155,14 +160,14 @@ export default {
switch (val.btnName) { switch (val.btnName) {
case 'search': case 'search':
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 20;
this.listQuery.materialId = val.name; this.listQuery.materialId = val.name;
this.getDataList(); this.getDataList();
break; break;
case 'reset': case 'reset':
this.$refs.searchBarForm.resetForm(); this.$refs.searchBarForm.resetForm();
this.listQuery = { this.listQuery = {
pageSize: 10, pageSize: 20,
pageNo: 1, pageNo: 1,
total: 1, total: 1,
}; };

View File

@ -12,6 +12,7 @@
:table-props="tableProps" :table-props="tableProps"
:page="listQuery.pageNo" :page="listQuery.pageNo"
:limit="listQuery.pageSize" :limit="listQuery.pageSize"
:max-height="tableH"
:table-data="tableData"></base-table> :table-data="tableData"></base-table>
<pagination <pagination
:limit.sync="listQuery.pageSize" :limit.sync="listQuery.pageSize"
@ -74,6 +75,7 @@ export default {
}, },
tableData: [], tableData: [],
tableProps, tableProps,
tableH: this.tableHeight(260),
drawerVisible: false, drawerVisible: false,
formConfig: [ formConfig: [
{ {
@ -114,6 +116,9 @@ export default {
}, },
components: {}, components: {},
created() { created() {
window.addEventListener('resize', () => {
this.tableH = this.tableHeight(260)
})
getHotMaterialList().then((response) => { getHotMaterialList().then((response) => {
this.formConfig[0].selectOptions = response.data; this.formConfig[0].selectOptions = response.data;
}); });
@ -138,7 +143,7 @@ export default {
switch (val.btnName) { switch (val.btnName) {
case 'search': case 'search':
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 20;
this.listQuery.materialId = val.materialId; this.listQuery.materialId = val.materialId;
this.listQuery.searchTime = val.searchTime ? val.searchTime[0] : null; this.listQuery.searchTime = val.searchTime ? val.searchTime[0] : null;
this.listQuery.startTime = val.searchTime this.listQuery.startTime = val.searchTime

View File

@ -12,6 +12,7 @@
:table-props="tableProps" :table-props="tableProps"
:page="listQuery.pageNo" :page="listQuery.pageNo"
:limit="listQuery.pageSize" :limit="listQuery.pageSize"
:max-height="tableH"
:table-data="tableData"></base-table> :table-data="tableData"></base-table>
<pagination <pagination
:limit.sync="listQuery.pageSize" :limit.sync="listQuery.pageSize"
@ -41,7 +42,7 @@ const tableProps = [
{ {
prop: 'reportName', prop: 'reportName',
label: '时间', label: '时间',
minWidth: 150, minWidth: 160,
}, },
{ {
prop: 'rawMaterialName', prop: 'rawMaterialName',
@ -78,6 +79,7 @@ export default {
}, },
tableData: [], tableData: [],
tableProps, tableProps,
tableH: this.tableHeight(260),
drawerVisible: false, drawerVisible: false,
formConfig: [ formConfig: [
{ {
@ -132,6 +134,9 @@ export default {
}, },
components: {}, components: {},
created() { created() {
window.addEventListener('resize', () => {
this.tableH = this.tableHeight(260)
})
const end = new Date(); const end = new Date();
const start = new Date(); const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30); start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
@ -149,7 +154,7 @@ export default {
switch (val.btnName) { switch (val.btnName) {
case 'search': case 'search':
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 20;
this.listQuery.reportType = val.reportType; this.listQuery.reportType = val.reportType;
this.listQuery.materialId = val.materialId; this.listQuery.materialId = val.materialId;
this.listQuery.times = val.searchTime this.listQuery.times = val.searchTime

View File

@ -2,11 +2,11 @@
* @Author: zwq * @Author: zwq
* @Date: 2021-11-18 14:16:25 * @Date: 2021-11-18 14:16:25
* @LastEditors: zhp * @LastEditors: zhp
* @LastEditTime: 2024-03-20 09:18:30 * @LastEditTime: 2024-03-22 17:11:55
* @Description: * @Description:
--> -->
<template> <template>
<el-drawer :visible.sync="visible" :show-close="false" :wrapper-closable="false" class="drawer" size="50%"> <el-drawer :visible.sync="visible" :show-close="false" :wrapper-closable="true" class="drawer" size="50%">
<small-title slot="title" :no-padding="true"> <small-title slot="title" :no-padding="true">
{{ isdetail ? '详情' : !dataForm.id ? '新增' : '编辑' }} {{ isdetail ? '详情' : !dataForm.id ? '新增' : '编辑' }}
</small-title> </small-title>
@ -75,7 +75,7 @@
:limit.sync="listQuery.pageSize" :page-sizes="[5, 10, 15]" @pagination="getList" /> :limit.sync="listQuery.pageSize" :page-sizes="[5, 10, 15]" @pagination="getList" />
</div> </div>
</div> </div>
<div class="drawer-body__footer"> <div v-if="!isdetail" class="drawer-body__footer">
<el-button style="" @click="goback()">取消</el-button> <el-button style="" @click="goback()">取消</el-button>
<el-button type="primary" @click="dataFormSubmit()">确定</el-button> <el-button type="primary" @click="dataFormSubmit()">确定</el-button>
</div> </div>
@ -198,7 +198,7 @@ export default {
} }
// //
if (this.dataForm.id) { if (this.dataForm.id) {
this.urlOptions.updateURL(this.dataForm).then(response => { this.urlOptions.updateURL(this.dataForm).then(res => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.visible = false; this.visible = false;
this.$emit("refreshDataList"); this.$emit("refreshDataList");
@ -206,7 +206,7 @@ export default {
return; return;
} }
// //
this.urlOptions.createURL(this.dataForm).then(response => { this.urlOptions.createURL(this.dataForm).then(res => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.idAttrShow = true; this.idAttrShow = true;
this.dataForm.id = res.data this.dataForm.id = res.data

View File

@ -2,7 +2,7 @@
* @Author: zwq * @Author: zwq
* @Date: 2021-11-18 14:16:25 * @Date: 2021-11-18 14:16:25
* @LastEditors: zhp * @LastEditors: zhp
* @LastEditTime: 2024-03-22 09:01:30 * @LastEditTime: 2024-03-25 14:07:31
* @Description: * @Description:
--> -->
<template> <template>
@ -289,7 +289,7 @@ export default {
} }
// //
if (this.dataForm.id) { if (this.dataForm.id) {
this.urlOptions.updateURL(this.dataForm).then(response => { this.urlOptions.updateURL(this.dataForm).then(res => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.visible = false; this.visible = false;
this.$emit("refreshDataList"); this.$emit("refreshDataList");
@ -297,7 +297,7 @@ export default {
return; return;
} }
// //
this.urlOptions.createURL(this.dataForm).then(response => { this.urlOptions.createURL(this.dataForm).then(res => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.idAttrShow = true; this.idAttrShow = true;
this.dataForm.id = res.data this.dataForm.id = res.data

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2023-11-08 15:30:27 * @Date: 2023-11-08 15:30:27
* @LastEditTime: 2023-12-04 15:19:33 * @LastEditTime: 2024-03-25 14:14:04
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -118,7 +118,7 @@ export default {
this.$refs['dataForm'].resetFields(); this.$refs['dataForm'].resetFields();
if (this.dataForm.id) { if (this.dataForm.id) {
getProcessEquValueBomDet({ getProcessEquValueBomDet({
id: this.dataForm.id id: this.dataForm.id,
}).then((res) => { }).then((res) => {
this.dataForm = res.data; this.dataForm = res.data;
const arr = [] const arr = []

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2023-11-08 14:00:52 * @Date: 2023-11-08 14:00:52
* @LastEditTime: 2023-11-09 09:59:53 * @LastEditTime: 2024-03-25 14:09:33
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -25,24 +25,24 @@ export default {
}, },
data() { data() {
return { return {
state: false // state: false
}
},
computed: {
state() {
return this.injectData.enabled === 1 ? true : false
} }
}, },
// computed: {
// readonly() {
// return !!this.injectData.readonly
// }
// },
mounted() { mounted() {
this.mapToState() // this.mapToState()
}, },
methods: { methods: {
mapToState() { // mapToState() {
if (this.injectData.prop === 'enabled') { // if (this.injectData.prop === 'enabled') {
this.state = this.injectData.enabled === 1 ? true : false // this.state = this.injectData.enabled === 1 ? true : false
} // }
}, // },
changeHandler() { changeHandler() {
// let params = {} // let params = {}
let payload = {} let payload = {}

View File

@ -299,14 +299,14 @@ export default {
getCookie() { getCookie() {
// const username = getUsername(); // const username = getUsername();
// const password = getPassword(); // const password = getPassword();
// const rememberMe = getRememberMe(); const rememberMe = getRememberMe()
const tenantName = getTenantName(); // const tenantName = getTenantName();
this.loginForm = { this.loginForm = {
...this.loginForm, ...this.loginForm,
username: username ? username : this.loginForm.username, username: this.loginForm.username,
password: password ? password : this.loginForm.password, password: this.loginForm.password,
rememberMe: rememberMe ? getRememberMe() : false, rememberMe: rememberMe ? getRememberMe() : false,
tenantName: tenantName ? tenantName : this.loginForm.tenantName, tenantName: this.loginForm.tenantName,
}; };
}, },
handleLogin(captchaParams) { handleLogin(captchaParams) {

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2023-12-08 13:46:17 * @Date: 2023-12-08 13:46:17
* @LastEditTime: 2024-03-21 10:40:52 * @LastEditTime: 2024-03-25 08:50:25
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -73,12 +73,12 @@
</el-form-item> </el-form-item>
</el-row> </el-row>
<el-row :gutter="24" v-for="(item,index) in ingredientList" :key="item.id"> <el-row :gutter="24" v-for="(item,index) in ingredientList" :key="item.id">
<el-col :span="8"> <el-col :span="6">
<el-form-item label="成分"> <el-form-item label="成分">
{{ item.name }} {{ item.name }}
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="6">
<el-form-item :prop="'checkValueList.' + index + '.checkValue'" label="成分含量" <el-form-item :prop="'checkValueList.' + index + '.checkValue'" label="成分含量"
:rules="[{ required: true, message: '成分含量不能为空', trigger: 'blur' }]"> :rules="[{ required: true, message: '成分含量不能为空', trigger: 'blur' }]">
<el-input oninput="value=value.replace(/[^\d]/g,'')" :disabled="isdetail" <el-input oninput="value=value.replace(/[^\d]/g,'')" :disabled="isdetail"
@ -92,12 +92,12 @@
</span> </span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4"> <el-col :span="6">
<el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最小值"> <el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最小值">
<el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.minValue"></el-input> <el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.minValue"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4"> <el-col :span="6">
<el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最大值"> <el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最大值">
<el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.maxValue"></el-input> <el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.maxValue"></el-input>
</el-form-item> </el-form-item>

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2023-11-06 15:15:30 * @Date: 2023-11-06 15:15:30
* @LastEditTime: 2024-03-20 09:38:10 * @LastEditTime: 2024-03-22 17:13:16
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -10,7 +10,7 @@
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="8"> <el-col :span="8">
<el-form-item label="工单号" prop="workOrderId"> <el-form-item label="工单号" prop="workOrderId">
<el-select v-model="dataForm.workOrderId" placeholder="请选择工单号"> <el-select filterable v-model="dataForm.workOrderId" placeholder="请选择工单号">
<el-option v-for="dict in workOrderList" :key="dict.id" :label="dict.name" :value="dict.id" /> <el-option v-for="dict in workOrderList" :key="dict.id" :label="dict.name" :value="dict.id" />
</el-select> </el-select>
</el-form-item> </el-form-item>
@ -58,6 +58,13 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-col :span="8">
<el-form-item label="来源" prop="source">
<el-select v-model="dataForm.source" placeholder="请选择来源" multiple>
<el-option v-for="dict in sourceList" :key="dict.id" :label="dict.name" :value="dict.id" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="备注" prop="remark"> <el-form-item label="备注" prop="remark">
<el-input v-model="dataForm.remark" placeholder="备注" /> <el-input v-model="dataForm.remark" placeholder="备注" />

View File

@ -2,7 +2,7 @@
* @Author: zwq * @Author: zwq
* @Date: 2023-08-01 14:55:51 * @Date: 2023-08-01 14:55:51
* @LastEditors: zhp * @LastEditors: zhp
* @LastEditTime: 2024-03-21 15:14:04 * @LastEditTime: 2024-03-25 16:07:07
* @Description: * @Description:
--> -->
<template> <template>
@ -64,7 +64,7 @@ const tableProps = [
{ {
prop: 'source', prop: 'source',
label: '数据来源', label: '数据来源',
filter: (val) => val == 1 ? '内部' : '外部' filter: (val) => val == 1 ? '手动' : '自动'
}, },
{ {
prop: 'remark', prop: 'remark',

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: zhp * @Author: zhp
* @Date: 2024-01-24 15:15:24 * @Date: 2024-01-24 15:15:24
* @LastEditTime: 2024-03-22 10:14:23 * @LastEditTime: 2024-03-22 17:05:51
* @LastEditors: zhp * @LastEditors: zhp
* @Description: * @Description:
--> -->
@ -66,7 +66,7 @@ export default {
}; };
}, },
created() { created() {
this.getDict() // this.getDict()
this.getTodayStartTimeAndEndTime() this.getTodayStartTimeAndEndTime()
this.getDataList() this.getDataList()
}, },
@ -104,6 +104,8 @@ export default {
}, },
async getDataList() { async getDataList() {
const res = await getCorePLList()
this.proLineList = res.data;
this.dataListLoading = true this.dataListLoading = true
if (this.listQuery.reportTime.length == 0) { if (this.listQuery.reportTime.length == 0) {
this.$message({ this.$message({
@ -135,9 +137,9 @@ export default {
// item.dailyOutputTrend = null // item.dailyOutputTrend = null
// } // }
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
} }
}) })
}) })

View File

@ -57,7 +57,7 @@ export default {
}, },
created() { created() {
this.getCurrentMonthFirst() this.getCurrentMonthFirst()
this.getDict() // this.getDict()
this.getDataList() this.getDataList()
}, },
methods: { methods: {
@ -98,6 +98,8 @@ export default {
}, },
// //
async getDataList() { async getDataList() {
const res = await getCorePLList()
this.proLineList = res.data;
this.dataListLoading = true; this.dataListLoading = true;
if (this.listQuery.reportTime.length == 0) { if (this.listQuery.reportTime.length == 0) {
this.$message({ this.$message({
@ -129,9 +131,9 @@ export default {
// item.dailyOutputTrend = null // item.dailyOutputTrend = null
// } // }
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
} }
}) })
}) })

View File

@ -86,23 +86,23 @@ export default {
}, },
], ],
}; };
}, },
created () {
// this.getDict()
},
mounted() { mounted() {
// const day = new Date().getDay() // const day = new Date().getDay()
// console.log('', day) // console.log('', day)
this.getCurrentWeekStartTimeAndEndTime() this.getCurrentWeekStartTimeAndEndTime()
// this.changeTime(new Date(new Date().getTime() - day * 24 * 60 * 60 * 1000)) // this.changeTime(new Date(new Date().getTime() - day * 24 * 60 * 60 * 1000))
this.getDict()
this.getDataList() this.getDataList()
}, },
methods: { methods: {
async getDict() { // async getDict() {
// 线 // // 线
await getCorePLList().then(res => {
this.proLineList = res.data;
// this.getDataList() // },
});
},
getCurrentWeekStartTimeAndEndTime() { getCurrentWeekStartTimeAndEndTime() {
this.reportTime = new Date() this.reportTime = new Date()
var weekday = new Array(7); var weekday = new Array(7);
@ -187,6 +187,8 @@ export default {
}, },
// //
async getDataList() { async getDataList() {
const res = await getCorePLList()
this.proLineList = res.data;
this.dataListLoading = true; this.dataListLoading = true;
if (this.listQuery.reportTime.length == 0) { if (this.listQuery.reportTime.length == 0) {
this.$message({ this.$message({
@ -218,9 +220,9 @@ export default {
// item.dailyOutputTrend = null // item.dailyOutputTrend = null
// } // }
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
} }
}) })
}) })

View File

@ -53,7 +53,7 @@ export default {
}; };
}, },
created() { created() {
this.getDict() // this.getDict()
}, },
mounted () { mounted () {
this.getCurrentYearFirst() this.getCurrentYearFirst()
@ -98,6 +98,8 @@ export default {
}, },
// //
async getDataList() { async getDataList() {
const res = await getCorePLList()
this.proLineList = res.data;
this.dataListLoading = true; this.dataListLoading = true;
if (this.listQuery.reportTime.length == 0) { if (this.listQuery.reportTime.length == 0) {
this.$message({ this.$message({
@ -129,9 +131,9 @@ export default {
// item.dailyOutputTrend = null // item.dailyOutputTrend = null
// } // }
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
} }
}) })
}) })

View File

@ -83,8 +83,8 @@ export default {
captchaEnable: true, captchaEnable: true,
loginForm: { loginForm: {
loginType: "uname", loginType: "uname",
username: "admin", username: "",
password: "admin123", password: "",
rememberMe: false, rememberMe: false,
captchaVerification: "", captchaVerification: "",
}, },
@ -140,12 +140,12 @@ export default {
this.$refs.verify.show() this.$refs.verify.show()
}, },
getCookie() { getCookie() {
const username = getUsername(); // const username = getUsername();
const password = getPassword(); // const password = getPassword();
const rememberMe = getRememberMe(); const rememberMe = getRememberMe();
this.loginForm = { this.loginForm = {
username: username ? username : this.loginForm.username, username: this.loginForm.username,
password: password ? password : this.loginForm.password, password: this.loginForm.password,
rememberMe: rememberMe ? getRememberMe() : false, rememberMe: rememberMe ? getRememberMe() : false,
loginType: this.loginForm.loginType, loginType: this.loginForm.loginType,
}; };