16 Commits

Author SHA1 Message Date
bac0b25a96 - Update screen 29 - 14 - Remove mock data dashboard 2025-07-28 17:11:08 +09:00
dev
2dd0c6a72c Merge pull request 'dev-trungvq7-2207' (#10) from dev-trungvq7-2207 into dev
Reviewed-on: gitadmin/sk_fems_ui#10
2025-07-28 14:39:36 +09:00
dev
631637a8e1 Merge branch 'dev' of http://218.237.212.51:30003/gitadmin/sk_fems_ui into dev-trungvq7-2207 2025-07-28 14:31:49 +09:00
dev
3ff87852e5 Update 2507 2025-07-28 14:31:41 +09:00
dev
117e0adeb9 Merge pull request 'dev-dungtv-0725' (#9) from dev-dungtv-0725 into dev
Reviewed-on: gitadmin/sk_fems_ui#9
2025-07-28 10:59:55 +09:00
402b09440f fix code comment 2025-07-28 08:59:17 +07:00
71f7cf4d30 Merge branch 'dev' of http://218.237.212.51:30003/gitadmin/sk_fems_ui into dev-dungtv-0725 2025-07-28 08:45:04 +07:00
d3984182e8 update screen 8, 10 2025-07-28 08:44:51 +07:00
dev
933d4b751f Merge pull request 'dev-luannv27-2407' (#7) from dev-luannv27-2407 into dev
Reviewed-on: gitadmin/sk_fems_ui#7
2025-07-28 10:35:21 +09:00
020432d5ac update code 2025-07-25 19:05:38 +09:00
3f99958fe3 update slected header 2025-07-25 19:03:41 +09:00
dev
898df6743a Merge pull request 'dev-manhph1-screen18-19-21-28' (#5) from dev-manhph1-screen18-19-21-28 into dev
Reviewed-on: gitadmin/sk_fems_ui#5
2025-07-25 18:50:19 +09:00
dd559629ab dev-manhph1-screen18-19-21-28 2025-07-25 18:11:31 +09:00
dev
d45d141c3c Update 2507 2025-07-25 17:59:38 +09:00
dev
1453e75f9a Merge pull request 'Update to original menu' (#4) from dev-nghiantt-menu into dev
Reviewed-on: gitadmin/sk_fems_ui#4
2025-07-25 16:04:04 +09:00
7227d5d56c Update to original menu 2025-07-25 12:36:03 +09:00
35 changed files with 2081 additions and 3075 deletions

View File

@ -1259,19 +1259,11 @@ a {
opacity: 0; opacity: 0;
} }
.v-list-item__content {
background-color: currentColor;
}
.v-list-item__title { .v-list-item__title {
color: map-deep-get($config, color: map-deep-get($config,
#{$theme}, #{$theme},
"tui-datepicker-calendar-color" "tui-datepicker-calendar-color"
); );
@if $theme ==light {
color: #fff !important;
}
} }
} }
} }
@ -1314,18 +1306,24 @@ a {
.btn-close-menu-list { .btn-close-menu-list {
min-width: 100px; min-width: 100px;
border-color: transparent; border-color: transparent;
background-color: map-deep-get($config, #{$theme}, "btn-header-select-bg") !important;
.v-list-item { .v-list-item {
min-height: 30px; min-height: 30px;
} }
.v-list-item__title { .v-list-item__title {
color: #fff; color: map-deep-get($config, #{$theme}, "btn-header-select-color");
&:hover { &:hover {
color: #46c0ff; color: #46c0ff;
} }
} }
.v-btn {
background-color: transparent !important;
color: map-deep-get($config, #{$theme}, "btn-header-select-color") !important;
}
} }
[hover-tooltip] { [hover-tooltip] {

View File

@ -93,6 +93,7 @@
} }
.search-button { .search-button {
height: 40px;
color: map-deep-get($config, #{$theme}, "search-btn-color"); color: map-deep-get($config, #{$theme}, "search-btn-color");
} }

View File

@ -98,6 +98,17 @@
@include theme($theme); @include theme($theme);
.v-application.#{$theme}-mode { .v-application.#{$theme}-mode {
.grid-title {
font-weight: 600;
font-size: 16px;
line-height: 24px;
letter-spacing: 0;
color: map-deep-get($config,
#{$theme},
"tui-grid-title-color"
);
}
.tui-grid { .tui-grid {
&-table { &-table {
border: 1px solid; border: 1px solid;

View File

@ -1,4 +1,6 @@
.v-select__custom { .v-select__custom {
padding: 0.125rem;
&.v-text-field.v-text-field--solo:not(.v-text-field--solo-flat)>.v-input__control>.v-input__slot { &.v-text-field.v-text-field--solo:not(.v-text-field--solo-flat)>.v-input__control>.v-input__slot {
box-shadow: none; box-shadow: none;
} }
@ -42,6 +44,10 @@
legend { legend {
width: 0; width: 0;
} }
.v-select-list {
padding: 0 1rem;
}
} }
.v-input__custom { .v-input__custom {

View File

@ -102,6 +102,7 @@ $config: (
v-calendar-day-color: #fff, v-calendar-day-color: #fff,
v-calendar-day-in-not-month-color: rgba(255, 255, 255, 0.05), v-calendar-day-in-not-month-color: rgba(255, 255, 255, 0.05),
v-calendar-is-today-background-color: #2d4571, v-calendar-is-today-background-color: #2d4571,
tui-grid-title-color: #FFFFFFD9,
tui-grid-header-backgroundColor: #2a2b2d, tui-grid-header-backgroundColor: #2a2b2d,
tui-grid-header-color: #FFFFFFD9, tui-grid-header-color: #FFFFFFD9,
tui-grid-border-horziontal-color: #212224, tui-grid-border-horziontal-color: #212224,
@ -168,6 +169,8 @@ $config: (
ant-btn-default-bg:#FFFFFF2E, ant-btn-default-bg:#FFFFFF2E,
ant-btn-default-color:#FFFFFFD9, ant-btn-default-color:#FFFFFFD9,
ant-btn-default-border-outlined:#424242, ant-btn-default-border-outlined:#424242,
btn-header-select-bg: #1F1F1F,
btn-header-select-color:#FFFFFFD9,
), ),
light: (w-g5: $--color-gray_555, light: (w-g5: $--color-gray_555,
g5-w: $--color-white, g5-w: $--color-white,
@ -236,6 +239,7 @@ $config: (
v-calendar-day-color: #111, v-calendar-day-color: #111,
v-calendar-day-in-not-month-color: #f8f8f8, v-calendar-day-in-not-month-color: #f8f8f8,
v-calendar-is-today-background-color: #e3eaf3, v-calendar-is-today-background-color: #e3eaf3,
tui-grid-title-color: #000000E0,
tui-grid-header-backgroundColor: #fafafa, //#e0e0e0, tui-grid-header-backgroundColor: #fafafa, //#e0e0e0,
tui-grid-header-color: rgba(0, 0, 0, 0.88), tui-grid-header-color: rgba(0, 0, 0, 0.88),
tui-grid-border-horziontal-color: #e0e0e0, tui-grid-border-horziontal-color: #e0e0e0,
@ -300,5 +304,7 @@ $config: (
ant-btn-default-bg:#00000026, ant-btn-default-bg:#00000026,
ant-btn-default-color:#000000E0, ant-btn-default-color:#000000E0,
ant-btn-default-border-outlined:#D9D9D9, ant-btn-default-border-outlined:#D9D9D9,
btn-header-select-color:#1F1F1F,
btn-header-select-bg:#FFFFFF,
), ),
); );

View File

@ -27,7 +27,7 @@
/> --> /> -->
</template> </template>
<v-list class="pa-2"> <v-list class="pa-2 btn-close-menu-list" >
<!-- <v-list-item class="mb-1">--> <!-- <v-list-item class="mb-1">-->
<!-- <div class="d-flex align-center">--> <!-- <div class="d-flex align-center">-->
<!-- <v-avatar class="mr-1" size="20">--> <!-- <v-avatar class="mr-1" size="20">-->

View File

@ -1,19 +1,26 @@
<template> <template>
<h1 class="h1-title"> <h1 class="h1-title">
<v-avatar size="12" :style="{ backgroundColor: 'currentColor' }"></v-avatar> <v-avatar size="12" :style="{ backgroundColor: 'currentColor' }"></v-avatar>
{{ text }} {{ text ? text : menuNm}}
</h1> </h1>
</template> </template>
<script> <script>
import { mapState } from 'vuex';
export default { export default {
name: "PageTitle", name: "PageTitle",
props: { props: {
text: { text: {
type: String, type: String,
required: true, required: false,
}, },
}, },
computed: {
...mapState({
menuNm: state => state.activeMenuInfo.menuNm,
}),
}
}; };
</script> </script>

View File

@ -1,5 +1,5 @@
// Gauge chart options // Gauge chart options
export default function getGaugeChartOption({ title, value, min = 0, max = 160, unit = '%', isDarkMode = false, backgroundRadius = 97 }) { export default function getGaugeChartOption({ title, min = 0, max = 160, unit = '%', isDarkMode = false, backgroundRadius = 97 }) {
const colorRanges = isDarkMode const colorRanges = isDarkMode
? [ ? [
[0.375, '#49AA19'], // Dark Green [0.375, '#49AA19'], // Dark Green

View File

@ -2,7 +2,7 @@
export default function getLineChartOption({ export default function getLineChartOption({
xAxisData = [], xAxisData = [],
seriesData = [], seriesData = [],
legendData = [], // legendData = [],
isDarkMode = false, isDarkMode = false,
}) { }) {
@ -31,7 +31,7 @@ export default function getLineChartOption({
}, },
legend: { legend: {
data: legendData, // data: legendData,
icon: 'circle', icon: 'circle',
top: '0%', top: '0%',
right: '5%', right: '5%',

View File

@ -71,14 +71,12 @@
</div> </div>
</div> </div>
<v-card-actions class="px-6 py-4 d-flex align-center justify-end"> <v-card-actions class="px-6 py-4 d-flex align-center justify-end">
<!-- <v-btn :ripple="false" @click="setUpdate($event)">확인</v-btn>
<v-btn :ripple="false" @click="dialogOpenCloseEvent(dialog)">닫기</v-btn> --> <a-button :ripple="false" @click="dialogOpenCloseEvent(dialog)"
<!-- <v-btn v-if="item.closeBtnFg || false" :ripple="false" @click="deleteBtnAction($event)">삭제</v-btn> -->
<a-button :ripple="false" @click="setUpdate($event)" class="mr-2">확인</a-button>
<a-button :ripple="false" type="primary" @click="dialogOpenCloseEvent(dialog)"
class="mr-2">닫기</a-button> class="mr-2">닫기</a-button>
<a-button v-if="item.closeBtnFg || false" :ripple="false" icon="delete" type="danger" ghost danger <a-button v-if="item.closeBtnFg || false" :ripple="false" type="danger" ghost danger
@click="deleteBtnAction($event)">삭제</a-button> @click="deleteBtnAction($event)" class="mr-2">삭제</a-button>
<a-button :ripple="false" type="primary" @click="setUpdate($event)" >확인</a-button>
</v-card-actions> </v-card-actions>
</v-card> </v-card>
</v-dialog> </v-dialog>
@ -298,46 +296,46 @@ export default {
}, },
async setSelectValueList01() { async setSelectValueList01() {
// form으로 popup 사용할 때 인자로 eqpmKindId, eqpmGrpId 보내줘야한다. // form으로 popup 사용할 때 인자로 eqpmKindId, eqpmGrpId 보내줘야한다.
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: 'selectEqpmGrpCodeList', apiKey: 'selectEqpmGrpCodeList',
// resKey: 'eqpmGrpCodeLists', resKey: 'eqpmGrpCodeLists',
// sendParam: { sendParam: {
// eqpmKindId: eqpmKindId:
// this.item.eqpmKindId != undefined this.item.eqpmKindId != undefined
// ? this.item.eqpmKindId ? this.item.eqpmKindId
// : this.searchParam.eqpmKindId, : this.searchParam.eqpmKindId,
// }, },
// // form을 통해 popup을 사용할 경우 -> this.item.eqpmKindId 사용 // form을 통해 popup을 사용할 경우 -> this.item.eqpmKindId 사용
// // 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다. // 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다.
// }); });
// if (res.length > 0) { if (res.length > 0) {
// this.selectValueList01 = await res.map(obj => { this.selectValueList01 = await res.map(obj => {
// return { return {
// text: obj.eqpmGrpNm, text: obj.eqpmGrpNm,
// value: obj.eqpmGrpId, value: obj.eqpmGrpId,
// }; };
// }); });
// // form을 통해 popup을 사용할 경우 -> this.item.eqpmGrpId 사용 // form을 통해 popup을 사용할 경우 -> this.item.eqpmGrpId 사용
// // 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택 // 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택
// // console.log('this.item.eqpmGrpId : ', this.item.eqpmGrpId); // console.log('this.item.eqpmGrpId : ', this.item.eqpmGrpId);
// // console.log('this.searchParam.eqpmGrpId : ', this.searchParam.eqpmGrpId); // console.log('this.searchParam.eqpmGrpId : ', this.searchParam.eqpmGrpId);
// this.selectValue01 = this.selectValue01 =
// this.item.eqpmGrpId != undefined this.item.eqpmGrpId != undefined
// ? this.item.eqpmGrpId ? this.item.eqpmGrpId
// : this.searchParam.eqpmGrpId != undefined : this.searchParam.eqpmGrpId != undefined
// ? this.searchParam.eqpmGrpId ? this.searchParam.eqpmGrpId
// : this.selectValueList01[0].value; : this.selectValueList01[0].value;
// } else { } else {
// this.selectValueList01 = []; this.selectValueList01 = [];
// this.selectValue01 = null; this.selectValue01 = null;
// } }
this.selectValueList01 = [ // this.selectValueList01 = [
{ label: '냉동기고온', value: '냉동기고온' }, // { label: '냉동기고온', value: '냉동기고온' },
{ label: '냉동기저온', value: '냉동기저온' }, // { label: '냉동기저온', value: '냉동기저온' },
{ label: '공조기', value: '공조기' }, // { label: '공조기', value: '공조기' },
{ label: '보일러', value: '보일러' } // { label: '보일러', value: '보일러' }
]; // ];
}, },
search() { search() {
this.getGridData(); this.getGridData();
@ -388,44 +386,35 @@ export default {
this.loadGrid = false; this.loadGrid = false;
let res = []; let res = [];
// res = await this.postApiReturn({ res = await this.postApiReturn({
// apiKey: 'selectEgrpPysclQtyPop', apiKey: 'selectEgrpPysclQtyPop',
// resKey: 'egrpPysclQtyData', resKey: 'egrpPysclQtyData',
// sendParam: { sendParam: {
// searchWord: this.searchWord, searchWord: this.searchWord,
// eqpmGrpId: this.selectValue01, eqpmGrpId: this.selectValue01,
// openMode: this.item.openMode, openMode: this.item.openMode,
// }, },
// }); });
// let newRes = []; let newRes = [];
// let tempTagList = this.pyscPopVal.split('/*wq2a/'); let tempTagList = this.pyscPopVal.split('/*wq2a/');
// let tagList = tempTagList.filter(item => item != ''); let tagList = tempTagList.filter(item => item != '');
// if (tagList.length > 0) { if (tagList.length > 0) {
// newRes = res.filter(item => { newRes = res.filter(item => {
// return !tagList.includes(item.pysclQtyId); return !tagList.includes(item.pysclQtyId);
// }); });
// res = newRes; res = newRes;
// }
// //이미 선택된 값들 제거(배열)
// if (this.item.dataList) {
// if (this.item.dataList.length > 0) {
// newRes = res.filter(item => {
// return !this.item.dataList.includes(item.pysclQtyId);
// });
// res = newRes;
// }
// }
res = [
{
'pysclQtyId': 'PYSCL00001',
'pysclQtyCd': 'AMP_1A',
'pysclQtyNm': '회로1 전류A',
'pysclQtyTpNm': 'TAG'
} }
]
//이미 선택된 값들 제거(배열)
if (this.item.dataList) {
if (this.item.dataList.length > 0) {
newRes = res.filter(item => {
return !this.item.dataList.includes(item.pysclQtyId);
});
res = newRes;
}
}
this.setModalGridData({ this.setModalGridData({
modalKey: this.myModalKey, modalKey: this.myModalKey,
gridKey: this.grid_01, gridKey: this.grid_01,

View File

@ -2,12 +2,8 @@
<v-row class="search-box" align="center"> <v-row class="search-box" align="center">
<v-col :cols="option.labelCols" class="py-0"> <v-col :cols="option.labelCols" class="py-0">
<label for="" class="search-box-label"> <label for="" class="search-box-label">
<v-icon <v-icon v-if="item.iconShow" small
v-if="item.iconShow" :class="['mr-1', item.required ? 'icon-orange' : 'icon-blue']">$icoBulletPoint</v-icon>
small
:class="['mr-1', item.required ? 'icon-orange' : 'icon-blue']"
>$icoBulletPoint</v-icon
>
{{ option.labelContent }} {{ option.labelContent }}
</label> </label>
</v-col> </v-col>
@ -30,9 +26,9 @@
<div class="pa-6 pt-0"> <div class="pa-6 pt-0">
<v-row align="center"> <v-row align="center">
<v-col :cols="5"> <v-col :cols="5">
<component :is="'SelectBox'" ref="SelectBox1" :labelCols="12" :textCols="12" :iconShow="true" <component :is="'SelectBox'" ref="SelectBox1" :labelCols="12" :textCols="12"
:propsValue="selectValue01" :itemList="selectValueList01" :label="'설비그룹'" :iconShow="true" :propsValue="selectValue01" :itemList="selectValueList01"
@update:propsValue="selectValue01 = $event" :readonly="item.openMode == undefined :label="'설비그룹'" @update:propsValue="selectValue01 = $event" :readonly="item.openMode == undefined
? openMode ? openMode
: item.openMode == 'ALL' : item.openMode == 'ALL'
? false ? false
@ -47,9 +43,9 @@
물리량명 물리량명
</label> </label>
</v-col> </v-col>
<v-col :cols="9"> <v-text-field append-icon="" class="v-input__custom" <v-col :cols="9"> <v-text-field append-icon="" class="v-input__custom" outlined
outlined :hide-details="true" v-model="searchWord" :hide-details="true" v-model="searchWord" @keyup.enter="search"><template
@keyup.enter="search"><template v-slot:append> v-slot:append>
<!-- Custom SVG icon --> <!-- Custom SVG icon -->
<v-icon>$icoSearch</v-icon> <v-icon>$icoSearch</v-icon>
@ -76,9 +72,9 @@
</div> </div>
</div> </div>
<v-card-actions class="px-6 py-4 d-flex align-center justify-end"> <v-card-actions class="px-6 py-4 d-flex align-center justify-end">
<a-button :ripple="false" @click="setUpdate($event)" class="mr-2">확인</a-button> <a-button :ripple="false" @click="dialogOpenCloseEvent(dialog)" class="mr-2">닫기</a-button>
<a-button :ripple="false" type="primary" @click="dialogOpenCloseEvent(dialog)" <a-button :ripple="false" type="primary" @click="setUpdate($event)">확인</a-button>
class="mr-2">닫기</a-button>
</v-card-actions> </v-card-actions>
</v-card> </v-card>
</v-dialog> </v-dialog>
@ -274,36 +270,30 @@ export default {
this.gridInit(); this.gridInit();
}, },
async setSelectValueList01() { async setSelectValueList01() {
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: 'selectEqpmGrpCodeList', apiKey: 'selectEqpmGrpCodeList',
// resKey: 'eqpmGrpCodeLists', resKey: 'eqpmGrpCodeLists',
// sendParam: { eqpmKindId: this.searchParam.eqpmKindId }, sendParam: { eqpmKindId: this.searchParam.eqpmKindId },
// // 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다. // 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다.
// }); });
// if (res.length > 0) { if (res.length > 0) {
// this.selectValueList01 = await res.map(obj => { this.selectValueList01 = await res.map(obj => {
// return { return {
// text: obj.eqpmGrpNm, text: obj.eqpmGrpNm,
// value: obj.eqpmGrpId, value: obj.eqpmGrpId,
// }; };
// }); });
// // 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택 // 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택
// this.selectValue01 = this.selectValue01 =
// this.searchParam.eqpmGrpId != undefined this.searchParam.eqpmGrpId != undefined
// ? this.searchParam.eqpmGrpId ? this.searchParam.eqpmGrpId
// : this.selectValueList01[0].value; : this.selectValueList01[0].value;
// // this.selectValue01 = this.selectValueList01[0].value; // this.selectValue01 = this.selectValueList01[0].value;
// } else { } else {
// this.selectValueList01 = []; this.selectValueList01 = [];
// this.selectValue01 = null; this.selectValue01 = null;
// } }
this.selectValueList01 = [
{ label: '냉동기고온', value: '냉동기고온' },
{ label: '냉동기저온', value: '냉동기저온' },
{ label: '공조기', value: '공조기' },
{ label: '보일러', value: '보일러' }
];
}, },
search() { search() {
this.getGridData(); this.getGridData();
@ -341,33 +331,25 @@ export default {
}, },
async getGridData() { async getGridData() {
this.loadGrid = false; this.loadGrid = false;
// let res = [];
// let res = await this.postApiReturn({
// apiKey: 'selectEqpmBaseInfoPop',
// resKey: 'epqmBaseInfoData',
// sendParam: {
// eqpmGrpId: this.selectValue01,
// searchWord: this.searchWord,
// // openMode : this.item.openMode == undefined ? this.openMode : this.item.openMode
// },
// });
// // grid와 popup eqpmId 값 중복되는 것 제거하는 로직 - 시작
// let newRes = [];
// if (this.bindingGridEqpmIdList.length > 0) {
// newRes = res.filter(item => {
// return !this.bindingGridEqpmIdList.includes(item.eqpmId);
// });
// res = newRes;
// }
// grid와 popup eqpmId 값 중복되는 것 제거하는 로직 - 끝
const res = [
{
'eqpmId': 'PYSCL00001',
'eqpmNm': 'AMP_1A',
let res = await this.postApiReturn({
apiKey: 'selectEqpmBaseInfoPop',
resKey: 'epqmBaseInfoData',
sendParam: {
eqpmGrpId: this.selectValue01,
searchWord: this.searchWord,
// openMode : this.item.openMode == undefined ? this.openMode : this.item.openMode
},
});
// grid와 popup eqpmId 값 중복되는 것 제거하는 로직 - 시작
let newRes = [];
if (this.bindingGridEqpmIdList.length > 0) {
newRes = res.filter(item => {
return !this.bindingGridEqpmIdList.includes(item.eqpmId);
});
res = newRes;
} }
] // grid와 popup eqpmId 값 중복되는 것 제거하는 로직 - 끝
this.setModalGridData({ this.setModalGridData({
modalKey: this.myModalKey, modalKey: this.myModalKey,
@ -441,9 +423,9 @@ export default {
// this.dialog = false; // this.dialog = false;
// return; // return;
// } // }
// if (this.myBindingData.length <= 0) { if (this.myBindingData.length <= 0) {
// return alert('설비상세 리스트를 먼저 선택해주세요.'); return alert('설비상세 리스트를 먼저 선택해주세요.');
// } }
this.dialog = !val; this.dialog = !val;
}, },
}, },

View File

@ -36,7 +36,7 @@
계산설명 계산설명
</label> </label>
</v-col> </v-col>
<v-col :cols="10" class="mr-4 py-0" > <v-col :cols="11" class="pr-8 py-0" >
<v-text-field append-icon="" class="v-input__custom" outlined <v-text-field append-icon="" class="v-input__custom" outlined
:hide-details="true" v-model="searchWord" @keyup.enter="search"><template v-slot:append> :hide-details="true" v-model="searchWord" @keyup.enter="search"><template v-slot:append>
<!-- Custom SVG icon --> <!-- Custom SVG icon -->
@ -45,7 +45,7 @@
</template></v-text-field> </template></v-text-field>
</v-col> </v-col>
<v-col cols="1" class="py-0"> <v-col cols="1" class="py-0" style="display: flex; justify-content: flex-end;">
<a-button icon="search" type="primary" @click="search()" class="search-button">조회</a-button> <a-button icon="search" type="primary" @click="search()" class="search-button">조회</a-button>
<!-- <v-btn :ripple="false" @click="initSearch()"> <!-- <v-btn :ripple="false" @click="initSearch()">
초기화 초기화
@ -63,10 +63,8 @@
</div> </div>
</div> </div>
<v-card-actions class="pa-5 d-flex align-center justify-end"> <v-card-actions class="pa-5 d-flex align-center justify-end">
<!-- <v-btn :ripple="false" @click="setUpdate($event)">확인</v-btn> <a-button :ripple="false" @click="dialogOpenCloseEvent(dialog)" class="mr-2">닫기</a-button>
<v-btn :ripple="false" @click="dialogOpenCloseEvent(dialog)">닫기</v-btn> --> <a-button :ripple="false" type="primary" @click="setUpdate($event)" >확인</a-button>
<a-button :ripple="false" @click="setUpdate($event)" class="mr-2">확인</a-button>
<a-button :ripple="false" type="primary" @click="dialogOpenCloseEvent(dialog)">닫기</a-button>
</v-card-actions> </v-card-actions>
</v-card> </v-card>
</v-dialog> </v-dialog>
@ -306,38 +304,22 @@ export default {
}, },
async getGridData() { async getGridData() {
this.loadGrid = false; this.loadGrid = false;
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: 'selectEqpmCalcPop', apiKey: 'selectEqpmCalcPop',
// resKey: 'eqpmCalcPopData', resKey: 'eqpmCalcPopData',
// sendParam: { sendParam: {
// calcDescLike: this.searchWord, calcDescLike: this.searchWord,
// openMode: this.item.openMode != undefined ? this.item.openMode : this.openMode openMode: this.item.openMode != undefined ? this.item.openMode : this.openMode
// },
// });
// if (this.myBindingData['calcProc'] != '' || this.myBindingData['calcProc'] != null || this.myBindingData['calcProc'] != undefined) {
// let newRes = [];
// newRes = res.filter(item => {
// return item.calcProc != this.myBindingData['calcProc']
// });
// res = newRes;
// }
const res = [
{
'calcProc': 'AVG_CNT2',
'argCnt': '2',
'calcDesc': '두개 변수에 대한 평균'
}, },
});
if (this.myBindingData['calcProc'] != '' || this.myBindingData['calcProc'] != null || this.myBindingData['calcProc'] != undefined) {
let newRes = [];
newRes = res.filter(item => {
return item.calcProc != this.myBindingData['calcProc']
});
res = newRes;
}
{ 'calcProc': 'PROC001', argCnt: 2, 'calcDesc': '덧셈 연산' },
{ 'calcProc': 'PROC002', argCnt: 1, 'calcDesc': '제곱 연산' },
{ 'calcProc': 'PROC003', argCnt: 2, 'calcDesc': '곱셈 연산' },
{ 'calcProc': 'PROC004', argCnt: 1, 'calcDesc': '루트 연산' },
{ 'calcProc': 'PROC005', argCnt: 3, 'calcDesc': '최대값 계산' },
{ 'calcProc': 'PROC006', argCnt: 3, 'calcDesc': '최소값 계산' },
]
this.setModalGridData({ this.setModalGridData({
modalKey: this.myModalKey, modalKey: this.myModalKey,
gridKey: this.grid_01, gridKey: this.grid_01,

View File

@ -124,7 +124,7 @@ export default {
return { return {
dialog: false, dialog: false,
loadGrid: true, loadGrid: false,
grid_01: 'grid_01', grid_01: 'grid_01',
myModalKey: 'evtObjPop', myModalKey: 'evtObjPop',
modalDataKey: 'modalData2', modalDataKey: 'modalData2',
@ -165,35 +165,6 @@ export default {
computed: { computed: {
...mapState({ ...mapState({
searchParam(state) { searchParam(state) {
const myOptions = {
columnOptions: {
resizable: true,
},
treeColumnOptions: {
name: 'readPlcNm', // Showing tree table
useIcon: false, // Not using icon
indentWidth: 10,
},
};
const dataPathMock = {
'grid_01': {
column: [
{ header: '검침개소명', name: 'readPlcNm', align: 'left', minWidth: 400, },
{ header: '검침개소', name: 'plcKind', minWidth: 100, align: 'center', },
// {
// header: '사용 여부', name: 'useFg', minWidth: 100, align: 'center',
// },
],
data: sampleData,
option: myOptions
}
};
return {
modalData2: {
evtObjPop: dataPathMock
}
}
// end test
return state.pageData[this.parentPrgmId]; return state.pageData[this.parentPrgmId];
}, },
myBindingData(state) { myBindingData(state) {
@ -277,6 +248,9 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 38,
},
}; };
this.setModalGridOption({ this.setModalGridOption({
modalKey: this.myModalKey, modalKey: this.myModalKey,
@ -300,7 +274,7 @@ export default {
}); });
}, },
async getGridData() { async getGridData() {
// this.loadGrid = false; this.loadGrid = false;
const res = await this.postApiReturn({ const res = await this.postApiReturn({
apiKey: 'selectTagBaseInfo', apiKey: 'selectTagBaseInfo',
@ -376,7 +350,6 @@ export default {
// this.dialog = false; // this.dialog = false;
// return; // return;
// } // }
console.log("this.dialog: ", this.dialog);
this.dialog = !val; this.dialog = !val;
}, },
}, },
@ -389,50 +362,6 @@ var evtObjPop = {
option: {}, option: {},
}, },
}; };
const sampleData = [
{
readPlcNm: '서울 본사',
plcKind: '본사',
useFg: '사용',
_children: [
{
readPlcNm: '서울 본사 - 1층',
plcKind: '층',
useFg: '사용',
},
{
readPlcNm: '서울 본사 - 2층',
plcKind: '층',
useFg: '미사용',
},
],
},
{
readPlcNm: '부산 지사',
plcKind: '지사',
useFg: '사용',
_children: [
{
readPlcNm: '부산 지사 - A동',
plcKind: '건물',
useFg: '사용',
_children: [
{
readPlcNm: '부산 지사 - A동 1층',
plcKind: '층',
useFg: '사용',
},
],
},
],
},
{
readPlcNm: '대전 창고',
plcKind: '창고',
useFg: '미사용',
},
];
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>

View File

@ -20,10 +20,10 @@
outlined outlined
:multiple="multiple" :multiple="multiple"
:hide-details="true" :hide-details="true"
append-icon=""
:class="['v-select__custom', customClass]" :class="['v-select__custom', customClass]"
:disabled="disabled" :disabled="disabled"
:readonly="readonly" :readonly="readonly"
append-icon=""
><template v-slot:append> ><template v-slot:append>
<v-icon>$icoChevronDown</v-icon> <v-icon>$icoChevronDown</v-icon>
</template></v-select> </template></v-select>

View File

@ -1,7 +1,7 @@
<template> <template>
<div class="pb-5 h100"> <div class="pb-5 h100">
<div class="d-flex align-center justify-space-between"> <div class="d-flex align-center justify-space-between">
<span class="text-h6">공통그룹코드</span> <span class="grid-title">공통그룹코드</span>
<div> <div>
<Buttons <Buttons
:parentPrgmId="parentPrgmId" :parentPrgmId="parentPrgmId"
@ -126,7 +126,7 @@ export default {
{ {
header: '사용여부', header: '사용여부',
name: 'useFg', name: 'useFg',
align: 'center', align: 'left',
formatter({ value }) { formatter({ value }) {
const newValue = _this.pageData.useFgList.filter( const newValue = _this.pageData.useFgList.filter(
item => item.commCd == value, item => item.commCd == value,

View File

@ -7,7 +7,7 @@
</div> </div>
<div ref="gridParent"> <div ref="gridParent">
<Grid :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName" :parentPrgmId="parentPrgmId" <Grid :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName" :parentPrgmId="parentPrgmId"
@getRowsData="getRowData" :innerTabGridInfo="innerTabGridInfo" :dataPath="dataPathMock" /> @getRowsData="getRowData" :innerTabGridInfo="innerTabGridInfo" />
</div> </div>
<div ref="formParent" class="mt-4"> <div ref="formParent" class="mt-4">
<component :is="'Form'" :parentPrgmId="parentPrgmId" :bindingData="gridName" :detailList="detailDataSetTagList" <component :is="'Form'" :parentPrgmId="parentPrgmId" :bindingData="gridName" :detailList="detailDataSetTagList"

View File

@ -271,63 +271,6 @@ export default {
value: myColumns, value: myColumns,
}); });
const res = [
{
"comId": "COM001",
"ercId": "ERC001",
"objMm": "202507",
"objYm": "2025-07",
"unitPrce": 120.5,
"peakPow": 450,
"baseChrg": 30000,
"notiChrg": 32500,
"rmrk": "Standard summer rate",
"blocId": "BLOC001",
"regUserNo": "USER001",
"regDttm": "2025-07-01T09:00:00",
"procUserNo": "USER002",
"procDttm": "2025-07-15T14:30:00"
},
{
"comId": "COM002",
"ercId": "ERC002",
"objMm": "202507",
"objYm": "2025-07",
"unitPrce": 98.75,
"peakPow": 300,
"baseChrg": 25000,
"notiChrg": 27000,
"rmrk": "Reduced rate for solar",
"blocId": "BLOC002",
"regUserNo": "USER003",
"regDttm": "2025-07-02T10:15:00",
"procUserNo": "USER004",
"procDttm": "2025-07-16T11:45:00"
},
{
"comId": "COM003",
"ercId": "ERC003",
"objMm": "202507",
"objYm": "2025-07",
"unitPrce": 110.0,
"peakPow": 400,
"baseChrg": 28000,
"notiChrg": 29500,
"rmrk": "Geothermal adjustment",
"blocId": "BLOC003",
"regUserNo": "USER005",
"regDttm": "2025-07-03T08:45:00",
"procUserNo": "USER006",
"procDttm": "2025-07-17T13:20:00"
}
]
this.setGridData({
gridKey: this.gridName,
value: res,
});
this.loadGrid = true; this.loadGrid = true;
}, },
async btnActions(action) { async btnActions(action) {

View File

@ -22,7 +22,6 @@
:editorGrid="true" :editorGrid="true"
:innerTabGridInfo="innerTabGridInfo" :innerTabGridInfo="innerTabGridInfo"
@getRowsData="getRowData" @getRowsData="getRowData"
:dataPath="dataPathMock"
/> />
</div> </div>
</v-card-actions> </v-card-actions>
@ -51,22 +50,10 @@ export default {
}, },
data() { data() {
return { return {
loadGrid: true, loadGrid: false,
gridName: 'rowDetailGrid', gridName: 'rowDetailGrid',
rowKey: null, rowKey: null,
edtingFinishFlag: 'Y', edtingFinishFlag: 'Y',
dataPathMock: {
"rowDetailGrid": {
column: [
{header: '추가 정보',name: 'addInfoId'},
{header: 'Data 구분',name: 'addInfoDataKind',align: 'center'},
{header: '추가 정보 값',name: 'addInfoVal',align: 'center', renderer: {type: NewCustomRenderer},editor: {type: NewCustomEditor},formatter(data) {return data.row.addInfoDataKind;},}
],
data: dataPathDataExample,
option: {
}
}
},
}; };
}, },
computed: { computed: {
@ -444,37 +431,4 @@ export default {
search() {}, search() {},
}, },
}; };
const dataPathDataExample =
[
{
addInfoId:"경보 여부",
addInfoDataKind:"FG",
addInfoVal:"1"
},
{
addInfoId:"예상 피크전력 여부",
addInfoDataKind:"FG",
addInfoVal:"0"
},
{
addInfoId:"피크전력 여부",
addInfoDataKind:"FG",
addInfoVal:"1"
},
{
addInfoId:"TAG 채널",
addInfoDataKind:"숫자",
addInfoVal:"채널"
},
{
addInfoId:"PLC IP",
addInfoDataKind:"문자",
addInfoVal:"채널"
},
{
addInfoId:"PLC 포트",
addInfoDataKind:"숫자",
addInfoVal:"채널"
},
]
</script> </script>

View File

@ -28,9 +28,7 @@
<span class="body-2">닫기</span> <span class="body-2">닫기</span>
<v-icon size="20">mdi-chevron-down</v-icon></a-button> --> <v-icon size="20">mdi-chevron-down</v-icon></a-button> -->
</template> </template>
<v-list class="py-2 btn-close-menu-list" :style="{ <v-list class="py-2 btn-close-menu-list">
backgroundColor: isDarkMode ? '#144985' : '#3f4d7d',
}">
<v-list-item class="px-2"> <v-list-item class="px-2">
<v-list-item-title @click="delAllTabsData()" class="body-2">전체 닫기</v-list-item-title> <v-list-item-title @click="delAllTabsData()" class="body-2">전체 닫기</v-list-item-title>
</v-list-item> </v-list-item>
@ -56,9 +54,7 @@
<span class="body-2">즐겨찾기</span> <span class="body-2">즐겨찾기</span>
<v-icon size="20">mdi-chevron-down</v-icon></a-button> --> <v-icon size="20">mdi-chevron-down</v-icon></a-button> -->
</template> </template>
<v-list v-if="myMenuList.length > 0" class="py-2 btn-close-menu-list" :style="{ <v-list v-if="myMenuList.length > 0" class="py-2 btn-close-menu-list">
backgroundColor: isDarkMode ? '#144985' : '#3f4d7d',
}">
<v-list-item v-for="item in myMenuList" :key="item.menuId" class="px-2" style="cursor: pointer"> <v-list-item v-for="item in myMenuList" :key="item.menuId" class="px-2" style="cursor: pointer">
<v-list-item-title @click="moveToMyMenu(item.url, item.menuId, item.prgmId)" class="body-2">{{ <v-list-item-title @click="moveToMyMenu(item.url, item.menuId, item.prgmId)" class="body-2">{{
item.menuNm item.menuNm
@ -69,7 +65,9 @@
<a-button id="refresh" class="btn-header" @click="removeBookMark" v-if="bookmarkBtn == 1"> <a-button id="refresh" class="btn-header" @click="removeBookMark" v-if="bookmarkBtn == 1">
<span class="material-icons" style="font-size: 17px">star</span> <span class="material-icons" style="font-size: 17px">star</span>
</a-button> </a-button>
<a-button id="refresh" class="btn-header" @click="addBookMark" v-if="bookmarkBtn == 0"> <a-button id="refresh" class="btn-header" :style="{
display: 'flex',
alignItems: 'center'}" @click="addBookMark" v-if="bookmarkBtn == 0">
<span class="material-icons" style="font-size: 17px">star_border</span> <span class="material-icons" style="font-size: 17px">star_border</span>
</a-button> </a-button>
<a-button <a-button
@ -178,9 +176,7 @@
<span class="body-2">닫기</span> <span class="body-2">닫기</span>
<v-icon size="20">mdi-chevron-down</v-icon></a-button> <v-icon size="20">mdi-chevron-down</v-icon></a-button>
</template> </template>
<v-list class="py-2 btn-close-menu-list" :style="{ <v-list class="py-2 btn-close-menu-list" >
backgroundColor: isDarkMode ? '#144985' : '#3f4d7d',
}">
<v-list-item class="px-2"> <v-list-item class="px-2">
<v-list-item-title @click="delAllTabsData()" class="body-2">전체 닫기</v-list-item-title> <v-list-item-title @click="delAllTabsData()" class="body-2">전체 닫기</v-list-item-title>
</v-list-item> </v-list-item>
@ -206,9 +202,7 @@
<span class="body-2">즐겨찾기</span> <span class="body-2">즐겨찾기</span>
<v-icon size="20">mdi-chevron-down</v-icon></a-button> <v-icon size="20">mdi-chevron-down</v-icon></a-button>
</template> </template>
<v-list v-if="myMenuList.length > 0" class="py-2 btn-close-menu-list" :style="{ <v-list v-if="myMenuList.length > 0" class="py-2 btn-close-menu-list" >
backgroundColor: isDarkMode ? '#144985' : '#3f4d7d',
}">
<v-list-item v-for="item in myMenuList" :key="item.menuId" class="px-2" style="cursor: pointer"> <v-list-item v-for="item in myMenuList" :key="item.menuId" class="px-2" style="cursor: pointer">
<v-list-item-title @click="moveToMyMenu(item.url, item.menuId, item.prgmId)" class="body-2">{{ <v-list-item-title @click="moveToMyMenu(item.url, item.menuId, item.prgmId)" class="body-2">{{
item.menuNm item.menuNm
@ -456,17 +450,15 @@ export default {
this.activeTree.push(ov); this.activeTree.push(ov);
} else { } else {
this.myPrgmId = nv; this.myPrgmId = nv;
console.log("menu:", this.menuData);
if (this.menuData[nv].url) { if (this.menuData[nv].url) {
const menuUrl = this.menuData[nv].url; const menuUrl = this.menuData[nv].url;
const menuId = this.menuData[nv].menuId; const menuId = this.menuData[nv].menuId;
const isCommMenu = menuUrl.indexOf("comm/"); const isCommMenu = menuUrl.indexOf('comm/');
const isEmsMenu = menuUrl.indexOf("ems/"); const isEmsMenu = menuUrl.indexOf('ems/');
const isCmmsMenu = menuUrl.indexOf("cmms/"); const isCmmsMenu = menuUrl.indexOf('cmms/');
// console.log('activeTree...'); // console.log('activeTree...');
console.log(isEmsMenu);
if (isCommMenu > -1 || isEmsMenu > -1 || isCmmsMenu > -1) { if (isCommMenu > -1 || isEmsMenu > -1 || isCmmsMenu > -1) {
// console.log('activeTree if stmt1'); // console.log('activeTree if stmt1');
@ -475,18 +467,9 @@ export default {
// console.log('if isLoading stmt1'); // console.log('if isLoading stmt1');
// return; // return;
// } // }
console.log("this:", this.menuData[nv].url);
this.$router.push({ this.$router.push({
path: `/${this.menuData[nv].url}?prgmId=${nv}`, path: `${this.menuData[nv].url}?prgmId=${nv}`,
}); });
// this.$router.replace("/").then(() => {
// alert("hihi");
// this.$router.push({
// path: `${this.menuData[nv].url}?prgmId=${nv}`,
// });
// });
// this.$router.beforeEach((to, from, next) => { // this.$router.beforeEach((to, from, next) => {
// if(_this.isLoading == true){ // if(_this.isLoading == true){
// next(false); // next(false);
@ -512,12 +495,14 @@ export default {
// return; // return;
// } // }
this.$refs.routerTab.openIframe( this.$refs.routerTab.openIframe(
encodeURI(`http://localhost:9999${this.menuData[nv].url}?prgmId=${nv}`), encodeURI(
this.menuData[nv].menuNm `http://localhost:9999${this.menuData[nv].url}?prgmId=${nv}`,
),
this.menuData[nv].menuNm,
); );
} }
this.$axios.get(`${this.menuData[nv].url}?$menuId=${menuId}`); this.$axios.get(`${this.menuData[nv].url}?$menuId=${menuId}`);
} else alert("지정된 페이지 경로가 없습니다."); } else alert('지정된 페이지 경로가 없습니다.');
} }
} }
}, },

View File

@ -1,33 +1,65 @@
<template> <template>
<div class="l-layout"> <div class="l-layout">
<PageTitle text="공통코드" />
<v-row ref="searchFilter"> <v-row ref="searchFilter">
<v-col :cols="12"> <v-col :cols="12">
<v-card class="searchFilter"> <v-card class="searchFilter">
<v-row align="center" no-gutters> <v-row align="center" no-gutters>
<v-col :cols="4"> <v-col :cols="3">
<component <component
:is="'selectCodeList'" :is="'selectCodeList'"
:parentPrgmId="myPrgmId" :parentPrgmId="myPrgmId"
:label="'시스템구분'" :label="'시스템구분'"
dataKey="sysDivCd" dataKey="sysDivCd"
:labelCols="12"
:textCols="12"
:sendParam="{ commGrpCd: 'CO_SYSDIV', useFg: '1' }" :sendParam="{ commGrpCd: 'CO_SYSDIV', useFg: '1' }"
:addAll="true" :addAll="true"
customClass="select-large"
/> />
</v-col> </v-col>
<v-col :cols="4"> <v-col :cols="3">
<component <component
:is="'selectCodeList'" :is="'selectCodeList'"
:parentPrgmId="myPrgmId" :parentPrgmId="myPrgmId"
:label="'사용여부'" :label="'사용여부'"
:labelCols="12"
:textCols="12"
:dataKey="'useFg'" :dataKey="'useFg'"
customClass="select-large"
:sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }" :sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }"
/> />
</v-col> </v-col>
<v-col :cols="4" class="text-right"> <v-col :cols="3">
<BtnSearch @click="search" /> <InputText
:parentPrgmId="myPrgmId"
label="그룹코드"
valueNm="commGrpCd"
:searchOption="true"
:labelCols="12"
:textCols="12"
customClass="input-large"
/>
</v-col>
<v-col :cols="3">
<InputText
:parentPrgmId="myPrgmId"
label="그룹코드명"
valueNm="commGrpCdNm"
:searchOption="true"
:labelCols="12"
:textCols="12"
customClass="input-large"
/>
</v-col>
<v-col :cols="12" class="text-right">
<BtnSearch style="margin-top:20px" @click="search" />
</v-col> </v-col>
</v-row> </v-row>
<v-row align="center" no-gutters> <!-- <v-row align="center" no-gutters>
<v-col :cols="4"> <v-col :cols="4">
<InputText <InputText
:parentPrgmId="myPrgmId" :parentPrgmId="myPrgmId"
@ -48,7 +80,7 @@
:textCols="8" :textCols="8"
/> />
</v-col> </v-col>
</v-row> </v-row> -->
</v-card> </v-card>
</v-col> </v-col>
</v-row> </v-row>
@ -85,7 +117,7 @@
<v-card class="pb-5"> <v-card class="pb-5">
<v-card-title>공통그룹코드 상세</v-card-title> <v-card-title>공통그룹코드 상세</v-card-title>
<div class="px-5" style="height:calc(100% - 70px)"> <div class="px-5" style="height:calc(100% - 70px)">
<v-tabs v-model="tab" :hide-slider="true"> <v-tabs v-model="tab" >
<v-tab <v-tab
v-for="item in items" v-for="item in items"
:key="item.id" :key="item.id"
@ -132,6 +164,7 @@ import Form from '~/components/common/form/Form';
import CommCdTab from '@/components/pages/comm/CommCdTab'; import CommCdTab from '@/components/pages/comm/CommCdTab';
import Grid from '~/components/common/Grid'; import Grid from '~/components/common/Grid';
import Utility from '~/plugins/utility'; import Utility from '~/plugins/utility';
import PageTitle from "~/components/common/PageTitle";
let myTitle; let myTitle;
let myPrgmId; let myPrgmId;
@ -158,6 +191,7 @@ export default {
Form, Form,
CommCdTab, CommCdTab,
Grid, Grid,
PageTitle
}, },
data() { data() {
return { return {
@ -229,6 +263,9 @@ export default {
const myOptions = { const myOptions = {
scrollX: false, scrollX: false,
header: {
height: 38,
},
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
@ -241,7 +278,7 @@ export default {
{ {
header: '시스템구분', header: '시스템구분',
name: 'sysDivCd', name: 'sysDivCd',
align: 'center', align: 'left',
formatter({ value }) { formatter({ value }) {
let commCdNm = ''; let commCdNm = '';
if (sysCdList.length > 0) { if (sysCdList.length > 0) {
@ -278,7 +315,7 @@ export default {
{ {
header: '사용여부', header: '사용여부',
name: 'useFg', name: 'useFg',
align: 'center', align: 'left',
formatter({ value }) { formatter({ value }) {
const newValue = _this.pageData.useFgList.filter( const newValue = _this.pageData.useFgList.filter(
item => item.commCd == value, item => item.commCd == value,
@ -554,7 +591,10 @@ const myDetail = [
valueNm: 'commGrpCd', valueNm: 'commGrpCd',
disabled: true, disabled: true,
cols: 6, cols: 6,
class: 'py-2', labelCols: 12,
textCols: 12,
iconShow: true,
class: 'py-2 pr-2',
required: true, required: true,
}, },
{ {
@ -563,7 +603,10 @@ const myDetail = [
valueNm: 'commGrpNm', valueNm: 'commGrpNm',
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2', labelCols: 12,
textCols: 12,
iconShow: true,
class: 'py-2 pl-2',
required: true, required: true,
}, },
{ {
@ -572,7 +615,10 @@ const myDetail = [
valueNm: 'sysDivCd', valueNm: 'sysDivCd',
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2', labelCols: 12,
textCols: 12,
iconShow: true,
class: 'py-2 pr-2 mt-3',
list: 'sysDivCdList', list: 'sysDivCdList',
itemText: 'commCdNm', itemText: 'commCdNm',
itemValue: 'commCd', itemValue: 'commCd',
@ -584,7 +630,10 @@ const myDetail = [
valueNm: 'useFg', valueNm: 'useFg',
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2', labelCols: 12,
textCols: 12,
iconShow: true,
class: 'py-2 pl-2 mt-10',
value: { '1': true, '0': false }, value: { '1': true, '0': false },
required: true, required: true,
}, },
@ -594,7 +643,10 @@ const myDetail = [
valueNm: 'rmrk', valueNm: 'rmrk',
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2', labelCols: 12,
textCols: 12,
iconShow: true,
class: 'py-2 pr-2 mt-3',
}, },
]; ];
</script> </script>

View File

@ -344,7 +344,7 @@
<v-row> <v-row>
<v-col cols="auto" style="text-align: left"> <v-col cols="auto" style="text-align: left">
<!-- <p class="textInfo">{{ ngDtlCnt }}</p> --> <!-- <p class="textInfo">{{ ngDtlCnt }}</p> -->
<p class="card-text-info">200</p> <p class="card-text-info">{{ ngDtlCnt }}</p>
</v-col> </v-col>
<v-col :cols="3" style="text-align: left"> </v-col> <v-col :cols="3" style="text-align: left"> </v-col>
</v-row> </v-row>
@ -369,7 +369,7 @@
<v-row> <v-row>
<v-col cols="auto" style="text-align: left"> <v-col cols="auto" style="text-align: left">
<!-- <p class="textInfo">{{ ngDtlSolvCnt }}</p> --> <!-- <p class="textInfo">{{ ngDtlSolvCnt }}</p> -->
<p class="card-text-info">100</p> <p class="card-text-info">{{ ngDtlSolvCnt }}</p>
</v-col> </v-col>
<v-col :cols="3" style="text-align: left"> </v-col> <v-col :cols="3" style="text-align: left"> </v-col>
</v-row> </v-row>
@ -580,11 +580,7 @@ export default {
Chart, Chart,
UnusedStatPopPage, UnusedStatPopPage,
EtcStatPopPage, EtcStatPopPage,
BtnSearch, PageTitle
AntCard,
CheckBox,
RadioStandard,
PageTitle,
}, },
computed: { computed: {
...mapState({ ...mapState({
@ -607,7 +603,6 @@ export default {
// let chartOption = this.getGuageChartOption2(this.chart_01); // let chartOption = this.getGuageChartOption2(this.chart_01);
let chartOption = getGaugeChartOption({ let chartOption = getGaugeChartOption({
title: this.chart_01, title: this.chart_01,
value: 75,
isDarkMode: this.isDarkMode, isDarkMode: this.isDarkMode,
}); });
chartOption["series"][0]["data"][0].value = this.$store.state.pageData[myPrgmId][ chartOption["series"][0]["data"][0].value = this.$store.state.pageData[myPrgmId][
@ -618,7 +613,6 @@ export default {
// let chartOption3 = this.getGuageChartOption2(this.chart_03); // let chartOption3 = this.getGuageChartOption2(this.chart_03);
let chartOption3 = getGaugeChartOption({ let chartOption3 = getGaugeChartOption({
title: this.chart_03, title: this.chart_03,
value: 75,
isDarkMode: this.isDarkMode, isDarkMode: this.isDarkMode,
}); });
chartOption3["series"][0]["data"][0].value = this.$store.state.pageData[myPrgmId][ chartOption3["series"][0]["data"][0].value = this.$store.state.pageData[myPrgmId][
@ -719,13 +713,9 @@ export default {
// this.search(); // this.search();
await this.gridInit(); await this.gridInit();
await new Promise((resolve) => setTimeout(resolve, 1500)); await new Promise((resolve) => setTimeout(resolve, 1500));
await this.getTodayEfficiencyStatus();
await this.getEnrgAndCO2Data();
await this.getGridData();
if (this.$router.currentRoute.fullPath == this.myHome.root) { if (this.$router.currentRoute.fullPath == this.myHome.root) {
this.dtToday = Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm"); this.dtToday = Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm");
await this.getEnrgAndCO2Data(); await this.getEnrgAndCO2Data();
await this.getCompareEqpmTotData(); await this.getCompareEqpmTotData();
await this.getTodayEfficiencyStatus(); await this.getTodayEfficiencyStatus();
@ -757,7 +747,6 @@ export default {
gridHeight = this.$refs.gridParent.offsetHeight - 35; gridHeight = this.$refs.gridParent.offsetHeight - 35;
// console.log("gridHeight : ", gridHeight); // console.log("gridHeight : ", gridHeight);
} }
const myOptions = { const myOptions = {
// scrollX: false, // scrollX: false,
setScroll: true, setScroll: true,
@ -770,12 +759,10 @@ export default {
height: 38, height: 38,
}, },
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
value: Object.assign(Utility.defaultGridOption(gridHeight), myOptions), value: Object.assign(Utility.defaultGridOption(gridHeight), myOptions),
}); });
let hhMapper = { let hhMapper = {
"00": "00~01", "00": "00~01",
"01": "01~02", "01": "01~02",
@ -807,7 +794,7 @@ export default {
header: "NO", header: "NO",
name: "rowNum", name: "rowNum",
width: 70, width: 70,
align: "right", align: "center",
// hidden: true, // hidden: true,
}, },
{ {
@ -855,98 +842,99 @@ export default {
}); });
this.loadGrid = true; this.loadGrid = true;
this.isGridLoading = false;
// this.getGridData(); // this.getGridData();
}, },
async getGridData() { async getGridData() {
this.loadGrid = false; this.loadGrid = false;
// console // console
// const res = await this.postApiReturn({ const res = await this.postApiReturn({
// apiKey: 'selectIssueGdIdxData', apiKey: "selectIssueGdIdxData",
// resKey: 'issueGdIdxData', resKey: "issueGdIdxData",
// sendParam: {}, sendParam: {},
// });
let fakeData = [
{
alrmKind: "WARN",
alrmMsg: "냉동기 전류부하율이 @V1%로 높음 (평균 @V2% 대비 @V3% 낮음) -@EQPM",
careStndVal: 50,
warnStndVal: 60,
eccId: "ECC000004",
eqpmGrpNm: "냉동기저온1",
eqpmGrpId: "EQG000001",
eqpmKindId: "EKIND0001",
eqpmId: "CHI-201",
eqpmNm: "CHI-201",
fabId: "ECC000003",
fabNm: "삼천1공장",
gdIdxId: "GD00001",
gdIdxNm: "전류부하율 평균 편차",
rowKey: 0,
rowNum: 1,
rowSpanMap: {},
sortKey: 0,
sortSeq: 1,
totDttm: Utility.setFormatDate(new Date(), "YYYY-MM-DD"),
totTime: "2022-12-20 02:43:24",
totVal: 70,
},
{
alrmKind: "WARN",
alrmMsg: "냉동기 냉각수 유량 부하율이 @V1%로 높음 -@EQPM",
careStndVal: 70,
warnStndVal: 100,
eccId: "ECC000004",
eqpmGrpNm: "냉동기고온1",
eqpmGrpId: "EQG000001",
eqpmKindId: "EKIND0001",
eqpmId: "CHI-302",
eqpmNm: "CHI-302",
fabId: "ECC000004",
fabNm: "삼천1공장",
gdIdxId: "GD00011",
gdIdxNm: "냉각수 유량 부하율",
rowKey: 0,
rowNum: 2,
rowSpanMap: {},
sortKey: 0,
sortSeq: 1,
totDttm: Utility.setFormatDate(new Date(), "YYYY-MM-DD"),
totTime: "2022-12-20 07:23:38",
totVal: 120,
},
];
this.setGridData({
gridKey: this.gridName,
value: fakeData,
}); });
// let fakeData = [
// {
// 'alrmKind' : "WARN",
// 'alrmMsg' : "냉동기 전류부하율이 @V1%로 높음 (평균 @V2% 대비 @V3% 낮음) -@EQPM",
// 'careStndVal' : 50,
// 'warnStndVal' : 60,
// 'eccId' : "ECC000004",
// 'eqpmGrpNm' : "냉동기저온1",
// 'eqpmGrpId' : "EQG000001",
// 'eqpmKindId' : "EKIND0001",
// 'eqpmId' : "CHI-201",
// 'eqpmNm' : "CHI-201",
// 'fabId' : "ECC000003",
// 'fabNm' : "삼천1공장",
// 'gdIdxId' : "GD00001",
// 'gdIdxNm' : "전류부하율 평균 편차",
// 'rowKey' : 0,
// 'rowNum' : 1,
// 'rowSpanMap' : {},
// 'sortKey' : 0,
// 'sortSeq' : 1,
// 'totDttm' : Utility.setFormatDate(new Date(), 'YYYY-MM-DD'),
// 'totTime' : '2022-12-20 02:43:24',
// 'totVal' : 70
// },
// {
// 'alrmKind' : "WARN",
// 'alrmMsg' : "냉동기 냉각수 유량 부하율이 @V1%로 높음 -@EQPM",
// 'careStndVal' : 70,
// 'warnStndVal' : 100,
// 'eccId' : "ECC000004",
// 'eqpmGrpNm' : "냉동기고온1",
// 'eqpmGrpId' : "EQG000001",
// 'eqpmKindId' : "EKIND0001",
// 'eqpmId' : "CHI-302",
// 'eqpmNm' : "CHI-302",
// 'fabId' : "ECC000004",
// 'fabNm' : "삼천1공장",
// 'gdIdxId' : "GD00011",
// 'gdIdxNm' : "냉각수 유량 부하율",
// 'rowKey' : 0,
// 'rowNum' : 2,
// 'rowSpanMap' : {},
// 'sortKey' : 0,
// 'sortSeq' : 1,
// 'totDttm' : Utility.setFormatDate(new Date(), 'YYYY-MM-DD'),
// 'totTime' : '2022-12-20 07:23:38',
// 'totVal' : 120
// }
// ]
// this.setGridData({ // this.setGridData({
// gridKey: this.gridName, // gridKey: this.gridName,
// value: res, // value: fakeData,
// }); // });
this.setGridData({
gridKey: this.gridName,
value: res,
});
this.loadGrid = true; this.loadGrid = true;
}, },
async getEnrgAndCO2Data() { async getEnrgAndCO2Data() {
this.loadChart_01 = false; this.loadChart_01 = false;
const res = []; const res = await this.postApiReturn({
apiKey: "selectEnrgAndCO2Data",
resKey: "enrgAndCO2Data",
sendParam: {},
});
// ////////////////////////////////////////// // //////////////////////////////////////////
// // 시연용 data 세팅 // // 시연용 data 세팅
res[0] = {}; // res[0]['dayVal'] = 18.0;
res[0]["dayVal"] = 18.0; // res[0]['mnthVal'] = 507.0;
res[0]["mnthVal"] = 507.0; // res[0]['planVal'] = 653.0;
res[0]["planVal"] = 653.0; // res[0]['co2DayVal'] = 9.0;
res[0]["co2DayVal"] = 9.0; // res[0]['co2MnthVal'] = 238.0;
res[0]["co2MnthVal"] = 238.0; // res[0]['co2PlanVal'] = 307.0;
res[0]["co2PlanVal"] = 307.0; // res[0]['co2YearVal'] = 1224.0;
res[0]["co2YearVal"] = 1224.0; // res[0]['effcRt'] = 77.59;
res[0]["effcRt"] = 77.59;
// ////////////////////////////////////////// // //////////////////////////////////////////
// 대시보드 표기 // 대시보드 표기
this.enrgUsageDayVal = this.numberFormatter( this.enrgUsageDayVal = this.numberFormatter(
parseFloat(res[0]["dayVal"]).toFixed(0) parseFloat(res[0]["dayVal"]).toFixed(0)
); );
@ -964,20 +952,17 @@ export default {
parseFloat(res[0]["co2BefMnthVal"]).toFixed(0) parseFloat(res[0]["co2BefMnthVal"]).toFixed(0)
); );
this.CO2YearVal = this.numberFormatter(parseFloat(res[0]["co2YearVal"]).toFixed(0)); this.CO2YearVal = this.numberFormatter(parseFloat(res[0]["co2YearVal"]).toFixed(0));
this.$nextTick(() => { this.$nextTick(() => {
let chartOption = null; let chartOption = null;
// chartOption = this.getGuageChartOption2(this.chart_01); // chartOption = this.getGuageChartOption2(this.chart_01);
chartOption = getGaugeChartOption({ chartOption = getGaugeChartOption({
title: "Energy Usage", title: "Energy Usage",
value: 75,
isDarkMode: this.isDarkMode, isDarkMode: this.isDarkMode,
}); });
console.log("charto:", chartOption); console.log("charto:", chartOption);
chartOption["series"][0]["data"][0].value = chartOption["series"][0]["data"][0].value =
res[0]["effcRt"] != null ? res[0]["effcRt"] : 0; res[0]["effcRt"] != null ? res[0]["effcRt"] : 0;
this.$store.state.pageData[myPrgmId][this.chart_01] = chartOption; this.$store.state.pageData[myPrgmId][this.chart_01] = chartOption;
console.log("gauge chart ops:", chartOption);
// if(res[0]['effcRt'] == undefined || res[0]['effcRt'] == null){ // if(res[0]['effcRt'] == undefined || res[0]['effcRt'] == null){
// res[0]['effcRt'] = null; // res[0]['effcRt'] = null;
// } // }
@ -993,12 +978,11 @@ export default {
}, },
async getCompareEqpmTotData() { async getCompareEqpmTotData() {
this.loadChart_02 = false; this.loadChart_02 = false;
// const res = await this.postApiReturn({ const res = await this.postApiReturn({
// apiKey: "selectCompareEqpmTotData", apiKey: "selectCompareEqpmTotData",
// resKey: "compareEqpmTotData", resKey: "compareEqpmTotData",
// sendParam: {}, sendParam: {},
// }); });
const res = "abc";
this.$nextTick(() => { this.$nextTick(() => {
this.setChart02Data(res); this.setChart02Data(res);
}); });
@ -1007,25 +991,24 @@ export default {
}, },
async getTodayEfficiencyStatus() { async getTodayEfficiencyStatus() {
this.loadChart_03 = false; this.loadChart_03 = false;
// const res = await this.postApiReturn({ const res = await this.postApiReturn({
// apiKey: 'selectTodayEfficiencyStatus', apiKey: "selectTodayEfficiencyStatus",
// resKey: 'todayEfficiencyStatus', resKey: "todayEfficiencyStatus",
// sendParam: {}, sendParam: {},
// }); });
// 대시보드 표기 // 대시보드 표기
// this.ngDtlCnt = this.numberFormatter(res[0]['ngDtlCnt']); this.ngDtlCnt = this.numberFormatter(res[0]["ngDtlCnt"]);
// this.ngDtlSolvCnt = this.numberFormatter(res[0]['ngDtlSolvCnt']); this.ngDtlSolvCnt = this.numberFormatter(res[0]["ngDtlSolvCnt"]);
// let effcRt = this.numberFormatter( let effcRt = this.numberFormatter(
// (res[0]['ngDtlSolvCnt'] / res[0]['ngDtlCnt']) * 100, (res[0]["ngDtlSolvCnt"] / res[0]["ngDtlCnt"]) * 100
// ); );
let effcRt = this.numberFormatter(78.21); // let effcRt = this.numberFormatter(78.21)
this.$nextTick(() => { this.$nextTick(() => {
let chartOption = null; let chartOption = null;
// chartOption = this.getGuageChartOption2(this.chart_03); // chartOption = this.getGuageChartOption2(this.chart_03);
chartOption = getGaugeChartOption({ chartOption = getGaugeChartOption({
title: "Today Efficiency", title: "Today Efficiency",
value: 75,
isDarkMode: this.isDarkMode, isDarkMode: this.isDarkMode,
}); });
chartOption["series"][0]["data"][0].value = isNaN(effcRt) ? 0 : effcRt; chartOption["series"][0]["data"][0].value = isNaN(effcRt) ? 0 : effcRt;
@ -1037,15 +1020,14 @@ export default {
}, },
async getTodayNgTopTen() { async getTodayNgTopTen() {
this.loadChart_04 = false; this.loadChart_04 = false;
// const res = await this.postApiReturn({ const res = await this.postApiReturn({
// apiKey: "selectTodayNgTopTen", apiKey: "selectTodayNgTopTen",
// resKey: "todayNgTopTen", resKey: "todayNgTopTen",
// sendParam: {}, sendParam: {},
// }); });
const res = "abc"; this.setPageData({
// this.setPageData({ chart04Data: res,
// chart04Data: res, });
// });
this.$nextTick(() => { this.$nextTick(() => {
this.setChart04Data(res); this.setChart04Data(res);
}); });
@ -1054,12 +1036,11 @@ export default {
}, },
async getCompareEqpmTGdChart() { async getCompareEqpmTGdChart() {
this.loadChart_05 = false; this.loadChart_05 = false;
// const res = await this.postApiReturn({ const res = await this.postApiReturn({
// apiKey: "selectCompareEqpmTGdChart", apiKey: "selectCompareEqpmTGdChart",
// resKey: "compareEqpmTGdChart", resKey: "compareEqpmTGdChart",
// sendParam: {}, sendParam: {},
// }); });
const res = "aaa";
this.$nextTick(() => { this.$nextTick(() => {
this.setChart05Data(res); this.setChart05Data(res);
}); });
@ -1067,12 +1048,12 @@ export default {
this.isLine2Loading = false; this.isLine2Loading = false;
}, },
async setChart05Data(data) { async setChart05Data(data) {
// if (this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart != undefined) { if (this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart != undefined) {
// this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart.series = []; this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart.series = [];
// } }
// if (!data.length) { if (!data.length) {
// return; return;
// } }
let xAxisData = []; let xAxisData = [];
let seriesData = []; let seriesData = [];
// let legendData = { // let legendData = {
@ -1081,7 +1062,7 @@ export default {
// dayVal: "금일", // dayVal: "금일",
// }; // };
let legendData = ["전전일", "전일", "금일"]; // let legendData = ["전전일", "전일", "금일"];
let befBefValDataList = { let befBefValDataList = {
name: "전전일", name: "전전일",
@ -1109,37 +1090,36 @@ export default {
}; };
// for (var i = 0; i < data.length; i++) { // for (var i = 0; i < data.length; i++) {
//////없애야함////// //////없애야함//////
let total = 0; // let total = 0;
let hour = Utility.setFormatDate( let hour = Utility.setFormatDate(
new Date().setTime(new Date().getTime() - 1 * 60 * 60 * 1000), new Date().setTime(new Date().getTime() - 1 * 60 * 60 * 1000),
"HH" "HH"
); );
//////없애야함////// //////없애야함//////
for (var i = 0; i < 24; i++) { for (var i = 0; i < 24; i++) {
// if (data[i].tm != undefined) { if (data[i].tm != undefined) {
// xAxisData.push(parseInt(data[i].tm)); xAxisData.push(parseInt(data[i].tm));
// } else { } else {
// xAxisData.push(i);
// }
xAxisData.push(i); xAxisData.push(i);
}
// //////없애야함////// // //////없애야함//////
let num = parseInt(Math.random() * (13 - 7) + 7); // let num = parseInt(Math.random() * (13 - 7) + 7);
let num2 = parseInt(Math.random() * (11 - 6) + 6); // let num2 = parseInt(Math.random() * (11 - 6) + 6);
let num3 = parseInt(Math.random() * (10 - 5) + 5); // let num3 = parseInt(Math.random() * (10 - 5) + 5);
let tempTotal = num + num2 + num3; // let tempTotal = num + num2 + num3;
total += tempTotal; // total += tempTotal;
let befBefVal = num; // let befBefVal = num;
let befVal = num2; // let befVal = num2;
let dayVal = num3; // let dayVal = num3;
// ////////////////// // //////////////////
// let befBefVal = data[i].befBefVal != undefined ? data[i].befBefVal : 0; let befBefVal = data[i].befBefVal != undefined ? data[i].befBefVal : 0;
// let befVal = data[i].befVal != undefined ? data[i].befVal : 0; let befVal = data[i].befVal != undefined ? data[i].befVal : 0;
befBefValDataList["data"].push(befBefVal); befBefValDataList["data"].push(befBefVal);
befValDataList["data"].push(befVal); befValDataList["data"].push(befVal);
if (i <= parseInt(hour)) { if (i <= parseInt(hour)) {
// let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0; let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0;
dayValDataList["data"].push(dayVal); dayValDataList["data"].push(dayVal);
} }
} }
@ -1151,7 +1131,7 @@ export default {
var chartOption = getLineChartOption({ var chartOption = getLineChartOption({
xAxisData: xAxisData, xAxisData: xAxisData,
legendData: legendData, // legendData: legendData,
seriesData: seriesData, seriesData: seriesData,
isDarkMode: this.isDarkMode, isDarkMode: this.isDarkMode,
}); });
@ -1188,20 +1168,18 @@ export default {
console.log("chart 5 data:", seriesData); console.log("chart 5 data:", seriesData);
await this.$nextTick(() => {}); await this.$nextTick(() => {});
// this.setChartOption({ this.setChartOption({
// chartKey: "compareEqpmTGdChart", chartKey: "compareEqpmTGdChart",
// value: chartOption, value: chartOption,
// }); });
this.$store.state.pageData[myPrgmId]["compareEqpmTGdChart"] = chartOption;
}, },
async setChart04Data(data) { async setChart04Data(data) {
// if (this.$store.state.pageData[this.myPrgmId].todayNgTopTen != undefined) { if (this.$store.state.pageData[this.myPrgmId].todayNgTopTen != undefined) {
// this.$store.state.pageData[this.myPrgmId].todayNgTopTen.series = []; this.$store.state.pageData[this.myPrgmId].todayNgTopTen.series = [];
// } }
// if (!data.length) { if (!data.length) {
// return; return;
// } }
let seriesData = [ let seriesData = [
{ {
type: "pie", type: "pie",
@ -1219,51 +1197,52 @@ export default {
}, },
]; ];
let pidChartdata = []; let pidChartdata = [];
// for (var i = 0; i < data.length; i++) { for (var i = 0; i < data.length; i++) {
// if (data[i].eqpmId != undefined) { if (data[i].eqpmId != undefined) {
// pidChartdata.push({
// value: data[i]["ngDtlCnt"],
// name: data[i]["eqpmId"],
// groupId: data[i]["eqpmNm"],
// });
// }
// }
let eqpmNmList = [
"CHI-202",
"CHI-201",
"UT_LT_CH101",
"UT_LT_CH102",
"UT_LT_CH103",
"UT_LT_CH104",
"UT_LT_CH105",
"U-CH-013",
"U-CH-014",
"U-CH-015",
"U-CH-016",
"U-CH-017",
"U-CH-018",
"U-CH-019",
"U-CH-015B",
"U-CH-015C",
"U-CH-015D",
"U-CH-015E",
"UT_HT_CT101",
"UT_HT_CT102",
"UT_HT_CT103",
"UT_HT_CP101",
"VCB_A",
"U-CH-012",
"U-CH-015F",
"U-CH-016A",
];
for (var i = 1; i < 21; i++) {
pidChartdata.push({ pidChartdata.push({
// value: data[i]['ngDtlCnt'], value: data[i]["ngDtlCnt"],
value: i + parseInt(Math.random() * (9 - 5) + 5), name: data[i]["eqpmId"],
name: eqpmNmList[i], groupId: data[i]["eqpmNm"],
groupId: eqpmNmList[i],
}); });
} }
}
// let eqpmNmList = [
// 'CHI-202',
// 'CHI-201',
// 'UT_LT_CH101',
// 'UT_LT_CH102',
// 'UT_LT_CH103',
// 'UT_LT_CH104',
// 'UT_LT_CH105',
// 'U-CH-013',
// 'U-CH-014',
// 'U-CH-015',
// 'U-CH-016',
// 'U-CH-017',
// 'U-CH-018',
// 'U-CH-019',
// 'U-CH-015B',
// 'U-CH-015C',
// 'U-CH-015D',
// 'U-CH-015E',
// 'UT_HT_CT101',
// 'UT_HT_CT102',
// 'UT_HT_CT103',
// 'UT_HT_CP101',
// 'VCB_A',
// 'U-CH-012',
// 'U-CH-015F',
// 'U-CH-016A',
// ]
// for(var i=1; i<21; i++){
// pidChartdata.push({
// // value: data[i]['ngDtlCnt'],
// value: i+parseInt(Math.random()*(9-5)+5),
// name: eqpmNmList[i],
// groupId: eqpmNmList[i]
// });
// }
seriesData[0]["data"] = [...pidChartdata]; seriesData[0]["data"] = [...pidChartdata];
var chartOption = { var chartOption = {
grid: { grid: {
@ -1293,17 +1272,15 @@ export default {
series: seriesData, series: seriesData,
}; };
await this.$nextTick(() => {}); await this.$nextTick(() => {});
// this.setChartOption({ chartKey: "todayNgTopTen", value: chartOption }); this.setChartOption({ chartKey: "todayNgTopTen", value: chartOption });
this.$store.state.pageData[myPrgmId]["todayNgTopTen"] = chartOption;
this.$store.state.pageData[myPrgmId]["chart04Data"] = chartOption;
}, },
async setChart02Data(data) { async setChart02Data(data) {
// if (this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart != undefined) { if (this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart != undefined) {
// this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart.series = []; this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart.series = [];
// } }
// if (!data.length) { if (!data.length) {
// return; return;
// } }
let xAxisData = []; let xAxisData = [];
let seriesData = []; let seriesData = [];
// let legendMapper = { // let legendMapper = {
@ -1311,7 +1288,6 @@ export default {
// 'befVal' : '전일', // 'befVal' : '전일',
// 'dayVal' : '금일' // 'dayVal' : '금일'
// } // }
let legendData = ["전전일", "전일", "금일"];
let befBefValDataList = { let befBefValDataList = {
name: "전전일", name: "전전일",
type: "line", type: "line",
@ -1336,82 +1312,38 @@ export default {
lineStyle: { width: 2 }, lineStyle: { width: 2 },
data: [], data: [],
}; };
// // for (var i = 0; i < data.length; i++) { // for (var i = 0; i < data.length; i++) {
let hour = Utility.setFormatDate( let hour = Utility.setFormatDate(
new Date().setTime(new Date().getTime() - 1 * 60 * 60 * 1000), new Date().setTime(new Date().getTime() - 1 * 60 * 60 * 1000),
"HH" "HH"
); );
// for (var i = 0; i < 24; i++) {
// if (data[i].tm != undefined) {
// xAxisData.push(parseInt(data[i].tm));
// } else {
// xAxisData.push(i);
// }
// //////없애야함//////
for (var i = 0; i < 24; i++) { for (var i = 0; i < 24; i++) {
if (data[i].tm != undefined) {
xAxisData.push(parseInt(data[i].tm));
} else {
xAxisData.push(i); xAxisData.push(i);
}
//////없애야함//////
let num = parseInt(Math.random() * (13 - 10) + 10) // let num = parseInt(Math.random() * (13 - 10) + 10).toString().padStart(2, '0');
.toString() // let num2 = parseInt(Math.random() * (9 - 1) + 1).toString().padStart(2, '0');
.padStart(2, "0"); // let num3 = parseInt(Math.random() * (13 - 10) + 10).toString().padStart(2, '0');
let num2 = parseInt(Math.random() * (9 - 1) + 1) // let num4 = parseInt(Math.random() * (9 - 1) + 1).toString().padStart(2, '0');
.toString() // let num5 = parseInt(Math.random() * (13 - 10) + 10).toString().padStart(2, '0');
.padStart(2, "0"); // let num6 = parseInt(Math.random() * (9 - 1) + 1).toString().padStart(2, '0');
let num3 = parseInt(Math.random() * (13 - 10) + 10) // let befBefVal = num+num2;
.toString() // let befVal = num3+num4;
.padStart(2, "0"); // let dayVal = num5+num6;
let num4 = parseInt(Math.random() * (9 - 1) + 1) // //////없애야함//////
.toString() let befBefVal = data[i].befBefVal != undefined ? data[i].befBefVal : 0;
.padStart(2, "0"); let befVal = data[i].befVal != undefined ? data[i].befVal : 0;
let num5 = parseInt(Math.random() * (13 - 10) + 10)
.toString()
.padStart(2, "0");
let num6 = parseInt(Math.random() * (9 - 1) + 1)
.toString()
.padStart(2, "0");
let befBefVal = num + num2;
let befVal = num3 + num4;
let dayVal = num5 + num6;
befBefValDataList["data"].push(befBefVal); befBefValDataList["data"].push(befBefVal);
befValDataList["data"].push(befVal); befValDataList["data"].push(befVal);
if (i <= parseInt(hour)) { if (i <= parseInt(hour)) {
// let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0; let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0;
dayValDataList["data"].push(dayVal); dayValDataList["data"].push(dayVal);
} }
} }
// let num = parseInt(Math.random() * (13 - 10) + 10)
// .toString()
// .padStart(2, "0");
// let num2 = parseInt(Math.random() * (9 - 1) + 1)
// .toString()
// .padStart(2, "0");
// let num3 = parseInt(Math.random() * (13 - 10) + 10)
// .toString()
// .padStart(2, "0");
// let num4 = parseInt(Math.random() * (9 - 1) + 1)
// .toString()
// .padStart(2, "0");
// let num5 = parseInt(Math.random() * (13 - 10) + 10)
// .toString()
// .padStart(2, "0");
// let num6 = parseInt(Math.random() * (9 - 1) + 1)
// .toString()
// .padStart(2, "0");
// let befBefVal = num + num2;
// let befVal = num3 + num4;
// let dayVal = num5 + num6;
// //////없애야함//////
// let befBefVal = data[i].befBefVal != undefined ? data[i].befBefVal : 0;
// let befVal = data[i].befVal != undefined ? data[i].befVal : 0;
// befBefValDataList["data"].push(befBefVal);
// befValDataList["data"].push(befVal);
// if (i <= parseInt(hour)) {
// let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0;
// dayValDataList["data"].push(dayVal);
// }
// }
seriesData = [befBefValDataList, befValDataList, dayValDataList]; seriesData = [befBefValDataList, befValDataList, dayValDataList];
// seriesData = [ // seriesData = [
@ -1433,7 +1365,7 @@ export default {
// ]; // ];
var chartOption = getLineChartOption({ var chartOption = getLineChartOption({
xAxisData: xAxisData, xAxisData: xAxisData,
legendData: legendData, // legendData: legendData,
seriesData: seriesData, seriesData: seriesData,
isDarkMode: this.isDarkMode, isDarkMode: this.isDarkMode,
}); });
@ -1468,12 +1400,10 @@ export default {
// series: seriesData, // series: seriesData,
// }; // };
await this.$nextTick(() => {}); await this.$nextTick(() => {});
this.$store.state.pageData[myPrgmId][this.chart_02] = chartOption; this.setChartOption({
chartKey: "compareEqpmTotChart",
// this.setChartOption({ value: chartOption,
// chartKey: "compareEqpmTotChart", });
// value: chartOption,
// });
}, },
getGuageChartOption(chartName) { getGuageChartOption(chartName) {
const gaugeColors = [ const gaugeColors = [
@ -1506,8 +1436,8 @@ export default {
splitNumber: 10, splitNumber: 10,
itemStyle: { itemStyle: {
// color: '#FFAB91' // color: '#FFAB91'
// color: 'auto', color: "auto",
color: gaugeColors, // color:gaugeColors
}, },
progress: { progress: {
// show: true, // show: true,
@ -1518,8 +1448,8 @@ export default {
// show: false // show: false
show: true, show: true,
itemStyle: { itemStyle: {
color: "#FFAB91", // color: '#FFAB91',
// color: 'auto', color: "auto",
}, },
}, },
axisLine: { axisLine: {
@ -1565,140 +1495,12 @@ export default {
fontSize: 15, fontSize: 15,
// fontSize: 20, // fontSize: 20,
fontWeight: "bolder", fontWeight: "bolder",
formatter: "30%", formatter: "{value} %",
color: "auto", color: "auto",
}, },
data: [ data: [
{ {
name: "new", value: NaN,
value: 344,
},
],
},
],
};
return guageChartOption;
},
getGuageChartOption2(chartName) {
const gaugeColors = [
[0, "#ed1c24"],
[0.6, "#ed1c24"],
[0.8, "#f7931e"],
[1.0, "#009245"],
];
const gaugeColors2 = [
[0, "#009245"],
[0.6, "#009245"],
[0.8, "#f7931e"],
[1.0, "#ed1c24"],
];
var guageChartOption = {
grid: {
// top: '-10%',
bottom: 0,
},
title: {},
graphic: [
{
type: "circle",
left: "center",
top: "center",
shape: {
r: 97, // radius of the background circle
},
style: {
fill: this.isDarkMode ? "#141415" : "#F5F5F5", // Light grey color
opacity: 0.3, // Semi-transparent
},
z: 0, // make sure it's behind the gauge
},
],
series: [
{
type: "gauge",
radius: "90%",
startAngle: 225,
endAngle: -45,
min: 0,
max: 160,
// progress: {
// show: true,
// width: 15,
// },
axisLine: {
lineStyle: {
width: 12,
color: [
[0.375, "#3CB371"], // Green (060)
[0.5, "#FFD700"], // Yellow (6080)
[0.625, "#FFA500"], // Orange (80100)
[1, "#FF4500"], // Red (100160)
],
},
},
axisTick: {
distance: -5,
length: 5,
lineStyle: {
color: "#000000",
width: 1,
},
},
splitLine: {
distance: -12,
length: 8,
lineStyle: {
color: "#000000",
width: 2,
},
},
axisLabel: {
color: this.isDarkMode ? "#fff" : "#333333",
distance: 23,
fontSize: 9,
},
pointer: {
show: true,
length: "70%",
width: 6,
itemStyle: {
color: "#FA8C16", // Set your desired pointer color here
},
},
title: {
show: false,
offsetCenter: [0, "40%"],
fontSize: 18,
},
detail: {
valueAnimation: true,
fontWeight: 500, // or "normal", "lighter", "bolder", or a number like 600
fontFamily: "Oxanium, sans-serif", // or any custom font
fontSize: 30,
lineHeight: 25,
offsetCenter: [0, "60%"],
color: this.isDarkMode ? "#fff" : "#333333",
formatter: function (value) {
return `{valueStyle|${value}}\n{percentStyle|%}`;
},
rich: {
// valueStyle: {
// fontSize: 25,
// fontWeight: "bold",
// },
percentStyle: {
fontSize: 10,
color: this.isDarkMode ? "#fff" : "#333333",
// fontWeight: "normal",
},
},
},
data: [
{
value: 16,
name: "에너지사용효율", // "Energy Usage Efficiency"
}, },
], ],
}, },
@ -1909,32 +1711,18 @@ export default {
}); });
}, },
topTenChartClickEvent(event) { topTenChartClickEvent(event) {
// let chartData = this.pageData.chart04Data; let chartData = this.pageData.chart04Data;
// console.log("chart data first", this.pageData); // let chartData = this.$store.state.pageData[myPrgmId][this.chart_04]['series'][0]['data']
let chartData = this.$store.state.pageData[myPrgmId][this.chart_04]["series"][0][
"data"
];
console.log("select equipment", event["data"]["groupId"]);
let selectedChartData = chartData.filter((item) => { let selectedChartData = chartData.filter((item) => {
return item.eqpmId == event["data"]["groupId"]; return item.eqpmId == event["data"]["groupId"];
}); });
console.log("chart data", selectedChartData); var data = {
// var data = {
// cmCycle: "CYC_DAY",
// fromDt: Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm"),
// fabId: selectedChartData[0].fabId,
// eqpmKindId: selectedChartData[0].eqpmKindId,
// eqpmGrpId: selectedChartData[0].eqpmGrpId,
// eqpmId: selectedChartData[0].eqpmId,
// };
var fake_data = {
cmCycle: "CYC_DAY", cmCycle: "CYC_DAY",
fromDt: Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm"), fromDt: Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm"),
fabId: 4555, fabId: selectedChartData[0].fabId,
eqpmKindId: 99988, eqpmKindId: selectedChartData[0].eqpmKindId,
eqpmGrpId: 88888, eqpmGrpId: selectedChartData[0].eqpmGrpId,
eqpmId: 99900, eqpmId: selectedChartData[0].eqpmId,
}; };
var key = "tick_" + Math.random(); var key = "tick_" + Math.random();
this.$router.push({ this.$router.push({
@ -1944,8 +1732,7 @@ export default {
// tick:key // tick:key
}, },
params: { params: {
// ...data, ...data,
...fake_data,
key: key, key: key,
}, },
}); });

View File

@ -16,8 +16,8 @@
</v-card> </v-card>
</v-col> </v-col>
</v-row> </v-row>
<v-row ref="contents"> <v-row ref="contents" class="pt-2">
<v-col :cols="5" style="height:100%"> <v-col :cols="5" style="height:100%" class="pr-2">
<v-card class="pb-5"> <v-card class="pb-5">
<div class="d-flex align-center justify-space-between pa-4"> <div class="d-flex align-center justify-space-between pa-4">
<v-card-title class="pa-0 custom-title-4">효율지표 리스트</v-card-title> <v-card-title class="pa-0 custom-title-4">효율지표 리스트</v-card-title>
@ -32,7 +32,7 @@
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
<v-col :cols="7" style="height:100%"> <v-col :cols="7" style="height:100%" class="pl-2">
<v-card class="pb-5"> <v-card class="pb-5">
<v-card-title class="custom-title-4 pa-4 pb-2">효율지표 상세 <v-card-title class="custom-title-4 pa-4 pb-2">효율지표 상세
</v-card-title> </v-card-title>

View File

@ -12,6 +12,7 @@
:textCols="12" :textCols="12"
:labelCols="12" :labelCols="12"
:parentPrgmId="myPrgmId" :parentPrgmId="myPrgmId"
:customClass="'select-large'"
/> />
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
@ -22,6 +23,7 @@
dataKey="searchErcKind" dataKey="searchErcKind"
:sendParam="{ commGrpCd: 'EM_ERCKIND', useFg: '1' }" :sendParam="{ commGrpCd: 'EM_ERCKIND', useFg: '1' }"
:addAll="true" :addAll="true"
:customClass="'select-large'"
/> />
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
@ -34,13 +36,9 @@
:addAll="true" :addAll="true"
:textCols="12" :textCols="12"
:labelCols="12" :labelCols="12"
:customClass="'select-large'"
/> />
</v-col> </v-col>
<v-col :cols="3" class="text-right">
<BtnSearch @click="search" />
</v-col>
</v-row>
<v-row align="center" no-gutters>
<v-col :cols="3"> <v-col :cols="3">
<component <component
:is="'selectCodeList'" :is="'selectCodeList'"
@ -49,8 +47,11 @@
dataKey="searchChrgKind" dataKey="searchChrgKind"
:sendParam="{ commGrpCd: 'EM_ENGCHAGKIND', useFg: '1' }" :sendParam="{ commGrpCd: 'EM_ENGCHAGKIND', useFg: '1' }"
:addAll="true" :addAll="true"
:customClass="'select-large'"
/> />
</v-col> </v-col>
</v-row>
<v-row align="center" no-gutters>
<v-col :cols="3"> <v-col :cols="3">
<component <component
:is="'selectCodeList'" :is="'selectCodeList'"
@ -59,6 +60,7 @@
dataKey="useFg" dataKey="useFg"
:sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }" :sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }"
:addAll="true" :addAll="true"
:customClass="'select-large'"
/> />
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
@ -69,8 +71,14 @@
:textCols="12" :textCols="12"
:labelCols="12" :labelCols="12"
:searchOption="true" :searchOption="true"
:customClass="'input-large'"
/> />
</v-col> </v-col>
<v-col :cols="3">
</v-col>
<v-col :cols="3" class="text-right">
<BtnSearch :size="'default'" @click="search" />
</v-col>
</v-row> </v-row>
</v-card> </v-card>
</v-col> </v-col>
@ -323,6 +331,9 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 38,
},
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
@ -332,12 +343,12 @@ export default {
const _this = this; const _this = this;
const myColumns = [ const myColumns = [
{ header: '회사 ID', name: 'comId', hidden: true }, { header: '회사 ID', name: 'comId', hidden: true },
{ header: '에너지원ID', name: 'ercId', width: 120, align: 'center' }, { header: '에너지원ID', name: 'ercId', width: 120, align: 'left' },
{ header: '에너지원명', name: 'ercNm', align: 'left' }, { header: '에너지원명', name: 'ercNm', align: 'left' },
{ {
header: '에너지원 유형', header: '에너지원 유형',
name: 'ercKind', name: 'ercKind',
align: 'center', align: 'left',
formatter({ value }) { formatter({ value }) {
let retVal = ''; let retVal = '';
const newValue = _this.pageData.ercKindList.filter( const newValue = _this.pageData.ercKindList.filter(
@ -450,7 +461,7 @@ export default {
header: '사용 여부', header: '사용 여부',
name: 'useFg', name: 'useFg',
width: 95, width: 95,
align: 'center', align: 'left',
formatter({ value }) { formatter({ value }) {
value = value === true ? '1' : '0'; value = value === true ? '1' : '0';
const newValue = _this.pageData.useFgList.filter( const newValue = _this.pageData.useFgList.filter(
@ -479,74 +490,24 @@ export default {
this.loadGrid = true; this.loadGrid = true;
}, },
async getRowGridData() { async getRowGridData() {
let res = [ let res = [];
{
"comId": "COM001",
"ercId": "ERC001",
"ercNm": "LNG 가스",
"ercKind": "GAS",
"readObjId": "READ001",
"readPlcId": "PLC001",
"chrgKind": "FIXED",
"unitPrce": 120.5,
"prceFg": "1",
"peakPow": 500,
"elecContId": "EC001",
"elecContNm": "계약A",
"blocId": "BLOC001",
"useFg": true
},
{
"comId": "COM002",
"ercId": "ERC002",
"ercNm": "태양광",
"ercKind": "ELEC",
"readObjId": "READ002",
"readPlcId": "PLC002",
"chrgKind": "VARIABLE",
"unitPrce": 95.0,
"prceFg": "0",
"peakPow": 300,
"elecContId": "EC002",
"elecContNm": "계약B",
"blocId": "BLOC002",
"useFg": false
},
{
"comId": "COM003",
"ercId": "ERC003",
"ercNm": "지열",
"ercKind": "HEAT",
"readObjId": "READ003",
"readPlcId": "PLC003",
"chrgKind": "FIXED",
"unitPrce": 110.0,
"prceFg": "1",
"peakPow": 450,
"elecContId": "EC003",
"elecContNm": "계약C",
"blocId": "BLOC003",
"useFg": true
}
]
;
// if (this.pageData.blocMstrList.length > 0) { if (this.pageData.blocMstrList.length > 0) {
// res = await this.postApiReturn({ res = await this.postApiReturn({
// apiKey: 'selectErcInfo', apiKey: 'selectErcInfo',
// resKey: 'ercInfoData', resKey: 'ercInfoData',
// sendParam: { sendParam: {
// blocId: this.pageData.blocMstrList[this.pageData.blocId].blocId, blocId: this.pageData.blocMstrList[this.pageData.blocId].blocId,
// ercKind: this.pageData.searchErcKind, ercKind: this.pageData.searchErcKind,
// readObjId: this.pageData.searchReadObj, readObjId: this.pageData.searchReadObj,
// chrgKind: this.pageData.searchChrgKind, chrgKind: this.pageData.searchChrgKind,
// useFg: this.pageData.useFg, useFg: this.pageData.useFg,
// ercNmLike: this.pageData.ercNm, ercNmLike: this.pageData.ercNm,
// }, },
// }); });
// } else { } else {
// this.setPageData({ isFind: false }); this.setPageData({ isFind: false });
// } }
const newRes = res.map(item => { const newRes = res.map(item => {
const newObj = { const newObj = {
...item, ...item,
@ -798,133 +759,8 @@ const defaultData = {
/* data 세팅 */ /* data 세팅 */
// 로컬 gridName 값과 동일한 이름으로 세팅 // 로컬 gridName 값과 동일한 이름으로 세팅
rowGrid: { rowGrid: {
data: [ data: [],
{ column: [], // myColumns,
"comId": "COM001",
"ercId": "ERC001",
"ercNm": "LNG 가스",
"ercKind": "GAS",
"readObjId": "READ001",
"readPlcId": "PLC001",
"chrgKind": "FIXED",
"unitPrce": 120.5,
"prceFg": "1",
"peakPow": 500,
"elecContId": "EC001",
"elecContNm": "계약A",
"blocId": "BLOC001",
"useFg": true
},
{
"comId": "COM002",
"ercId": "ERC002",
"ercNm": "태양광",
"ercKind": "ELEC",
"readObjId": "READ002",
"readPlcId": "PLC002",
"chrgKind": "VARIABLE",
"unitPrce": 95.0,
"prceFg": "0",
"peakPow": 300,
"elecContId": "EC002",
"elecContNm": "계약B",
"blocId": "BLOC002",
"useFg": false
},
{
"comId": "COM003",
"ercId": "ERC003",
"ercNm": "지열",
"ercKind": "HEAT",
"readObjId": "READ003",
"readPlcId": "PLC003",
"chrgKind": "FIXED",
"unitPrce": 110.0,
"prceFg": "1",
"peakPow": 450,
"elecContId": "EC003",
"elecContNm": "계약C",
"blocId": "BLOC003",
"useFg": true
}
],
column: [
{ header: '회사 ID', name: 'comId', hidden: true },
{ header: '에너지원ID', name: 'ercId', width: 120, align: 'center' },
{ header: '에너지원명', name: 'ercNm', align: 'left' },
{
header: '에너지원 유형',
name: 'ercKind',
align: 'center',
},
{
header: '검침대상',
name: 'readObjId',
align: 'left',
},
{
header: '검침 개소 ID',
name: 'readPlcId',
width: 80,
align: 'center',
hidden: true,
},
{
header: '고지 유형',
name: 'chrgKind',
width: 80,
align: 'center',
hidden: true,
},
{
header: '기본단가',
name: 'unitPrce',
width: 100,
align: 'right',
hidden: true,
},
{
header: '단가 사용여부',
name: 'prceFg',
width: 100,
align: 'center',
hidden: true,
},
{
header: '피크 전력',
name: 'peakPow',
width: 100,
align: 'right',
hidden: true,
},
{
header: '전력 계약',
name: 'elecContId',
width: 100,
align: 'center',
hidden: true,
},
{
header: '전력 계약',
name: 'elecContNm',
width: 100,
align: 'center',
hidden: true,
},
{
header: '사업장',
name: 'blocId',
width: 100,
align: 'center',
hidden: true,
},
{
header: '사용 여부',
name: 'useFg',
width: 95,
align: 'center',
}
], // myColumns,
option: {}, // myOptions option: {}, // myOptions
defaultRow: { defaultRow: {
comId: '', comId: '',
@ -1160,3 +996,6 @@ const myDetail = [
}, },
]; ];
</script> </script>
<style lang="scss">
@import '@/assets/scss/common.scss';
</style>

View File

@ -29,10 +29,10 @@
</v-card> </v-card>
</v-col> </v-col>
</v-row> </v-row>
<v-row ref="contents"> <v-row ref="contents" class="mt-3">
<v-col :cols="5" class="h100"> <v-col :cols="5" class="h100 pr-2">
<v-card class="pb-5"> <v-card class="pb-5">
<v-card-title class="d-flex align-center justify-space-between pa-4"> <v-card-title class="d-flex align-center justify-space-between pa-5">
물리량 리스트 물리량 리스트
<Buttons :parentPrgmId="myPrgmId" :bindingData="gridName" :detailList="detailList" <Buttons :parentPrgmId="myPrgmId" :bindingData="gridName" :detailList="detailList"
@ -44,12 +44,12 @@
:parentPrgmId="myPrgmId" @getRowsData="getRowData" :parentPrgmId="myPrgmId" @getRowsData="getRowData"
@sendSelectedRowStatInfo="getSelectedRowStatInfo" :selectedRowDataWatchFlag="true" @sendSelectedRowStatInfo="getSelectedRowStatInfo" :selectedRowDataWatchFlag="true"
:preventFocusChangeEventFlag="true" :preventFocusChangeEventFlag="true"
:preventFocusChangeEventTargetGridList="editingGridList" :dataPath="dataPathExample" /> :preventFocusChangeEventTargetGridList="editingGridList" />
</div> </div>
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
<v-col :cols="7" class="h100"> <v-col :cols="7" class="h100 pl-2">
<v-card class="pb-5 px-4"> <v-card class="pb-5 px-4">
<v-card-title class="px-0">물리량 상세</v-card-title> <v-card-title class="px-0">물리량 상세</v-card-title>
<v-row no-gutters> <v-row no-gutters>
@ -136,7 +136,7 @@
<v-col :cols="12" style="height:100%"> <v-col :cols="12" style="height:100%">
<div ref="gridParent2" style="height:100%"> <div ref="gridParent2" style="height:100%">
<component :ref="gridName2" :is="loadGrid2 ? 'Grid' : null" :gridName="gridName2" <component :ref="gridName2" :is="loadGrid2 ? 'Grid' : null" :gridName="gridName2"
:parentPrgmId="myPrgmId" @getRowsData="getRowData2" :dataPath="dataPathExample2" /> :parentPrgmId="myPrgmId" @getRowsData="getRowData2" />
</div> </div>
</v-col> </v-col>
</v-row> </v-row>
@ -223,7 +223,7 @@ export default {
formatterSelectList01: [], formatterSelectList01: [],
formatterSelectList02: [], formatterSelectList02: [],
loadGrid: true, loadGrid: false,
dataPathExample: { dataPathExample: {
"rowGrid": { "rowGrid": {
data: [ data: [
@ -279,59 +279,7 @@ export default {
} }
}, },
dataPathExample2: { loadGrid2: false,
"rowGrid2": {
data:
[
{
"argSeq": "1",
"argPysclQtyId": "001",
"eqpmGrpId": "EQPM-GRP-A",
"pysclQtyCd": "TEMP001"
},
{
"argSeq": "2",
"argPysclQtyId": "002",
"eqpmGrpId": "EQPM-GRP-B",
"pysclQtyCd": "PRESS001"
},
{
"argSeq": "3",
"argPysclQtyId": "003",
"eqpmGrpId": "EQPM-GRP-C",
"pysclQtyCd": "FLOW001"
},
{
"argSeq": "4",
"argPysclQtyId": "004",
"eqpmGrpId": "EQPM-GRP-D",
"pysclQtyCd": "HUMID001"
},
{
"argSeq": "5",
"argPysclQtyId": "005",
"eqpmGrpId": "EQPM-GRP-E",
"pysclQtyCd": "VOLT001"
}
]
,
column: [
{ header: '순번', name: 'argSeq', editor: 'text' },
{ header: '물리량 ID', name: 'argPysclQtyId' },
{
header: '설비그룹',
name: 'eqpmGrpId',
},
{ header: '물리량 코드', name: 'pysclQtyCd' },
],
}
},
loadGrid2: true,
detailList: myDetail, detailList: myDetail,
readOnlyValueList: [ readOnlyValueList: [
@ -1001,6 +949,10 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 37,
},
rowHeight: 'auto',
}; };
this.setGridOption({ this.setGridOption({
@ -1066,6 +1018,10 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 37,
},
rowHeight: 'auto',
}; };
this.setGridOption({ this.setGridOption({

View File

@ -1,19 +1,13 @@
<template> <template>
<div ref="mainDiv" class="l-layout"> <div ref="mainDiv" class="l-layout">
<PageTitle/>
<v-row ref="searchFilter"> <v-row ref="searchFilter">
<v-col :cols="12"> <v-col :cols="12">
<v-card class="searchFilter"> <v-card class="searchFilter">
<v-row align="end" no-gutters> <v-row align="end" no-gutters>
<v-col :cols="5"> <v-col :cols="5">
<InputText <InputText :parentPrgmId="myPrgmId" label="설비종류명" valueNm="eqpmKindNm" :searchOption="true"
:parentPrgmId="myPrgmId" :textCols="12" :labelCols="12" customClass="input-large" />
label="설비종류명"
valueNm="eqpmKindNm"
:searchOption="true"
:textCols="12"
:labelCols="12"
customClass="input-large"
/>
</v-col> </v-col>
<v-col :cols="7" class="text-right"> <v-col :cols="7" class="text-right">
<BtnSearch @click="search" size="large" /> <BtnSearch @click="search" size="large" />
@ -25,41 +19,27 @@
<v-row ref="contents"> <v-row ref="contents">
<v-col :cols="5" class="h100"> <v-col :cols="5" class="h100">
<v-card class="pb-5"> <v-card class="pb-5">
<div class="d-flex align-center justify-space-between pa-5"> <div class="d-flex align-center justify-space-between pa-4" style="padding-bottom: 30px !important;">
<v-card-title class="pa-0">설비종류</v-card-title> <v-card-title class="pa-0">설비종류</v-card-title>
<Buttons <Buttons :parentPrgmId="myPrgmId" :bindingData="gridName" :btnActionsFnc="btnActions" />
:parentPrgmId="myPrgmId"
:bindingData="gridName"
:btnActionsFnc="btnActions"
/>
</div> </div>
<div class="h100 px-5" style="height:calc(100% - 70px)"> <div class="h100 px-5" style="height:calc(100% - 70px)">
<div ref="gridParent" class="w100 h100"> <div ref="gridParent" class="w100 h100">
<component <component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName"
:ref="gridName" :parentPrgmId="myPrgmId" @getRowsData="getRowData"
:is="loadGrid ? 'Grid' : null" :preventFocusChangeEventFlag="false" />
:gridName="gridName"
:parentPrgmId="myPrgmId"
@getRowsData="getRowData"
:preventFocusChangeEventFlag="false"
:dataPath="dataPathMock"
/>
</div> </div>
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
<v-col :cols="7" class="h100"> <v-col :cols="7" class="h100">
<v-card class="pb-5"> <v-card class="pb-5">
<div class="d-flex align-center justify-space-between pa-5"> <div class="d-flex align-center justify-space-between pa-4" style="padding-bottom: 30px !important;">
<v-card-title class="pa-0">설비종류 상세</v-card-title> <v-card-title class="pa-0">설비종류 상세</v-card-title>
</div> </div>
<div class="px-5" style="height:calc(100% - 76px)"> <div class="px-5" style="height:calc(100% - 76px)">
<component <component :is="'Form'" :parentPrgmId="myPrgmId" :detailList="detailList"
:is="'Form'" @gridEditingFinish="gridEditingFinish" />
:parentPrgmId="myPrgmId"
:detailList="detailList"
@gridEditingFinish="gridEditingFinish"
/>
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
@ -78,6 +58,8 @@ import Form from '~/components/common/form/Form';
import Grid from '~/components/common/Grid'; import Grid from '~/components/common/Grid';
import Utility from '~/plugins/utility'; import Utility from '~/plugins/utility';
import SelectBox from '@/components/common/select/SelectBox'; import SelectBox from '@/components/common/select/SelectBox';
import PageTitle from "~/components/common/PageTitle";
let myTitle; let myTitle;
// const myPrgmId = "PRG0013"; // const myPrgmId = "PRG0013";
let myPrgmId; let myPrgmId;
@ -108,6 +90,7 @@ export default {
Grid, Grid,
Utility, Utility,
SelectBox, SelectBox,
PageTitle,
}, },
data() { data() {
return { return {
@ -118,21 +101,6 @@ export default {
detailList: myDetail, detailList: myDetail,
selectValueList01: [], selectValueList01: [],
selectValue01: null, selectValue01: null,
dataPathMock: {
'eqpmKindGrid': {
column: [
{ header: '설비종류ID', name: 'eqpmKindId', headerAlign: 'center' },
{ header: '설비종류명', name: 'eqpmKindNm', headerAlign: 'left' },
{ header: '등록자NO', name: 'regUserNo', hidden: true},
{ header: '등록일시', name: 'regDttm', hidden: true },
{ header: '수정자NO', name: 'procUserNo', hidden: true },
{ header: '수정일시', name: 'procDttm', hidden: true}
],
data: dataPathDataExample,
defaultRow: dataPathDataExample,
option: {}
}
},
}; };
}, },
computed: { computed: {
@ -164,7 +132,7 @@ export default {
defaultData: defaultData, defaultData: defaultData,
}); });
}, },
created() {}, created() { },
mounted() { mounted() {
this.gridInit(); this.gridInit();
// this.init(); // this.init();
@ -184,6 +152,8 @@ export default {
const myOptions = { const myOptions = {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, header: {
height: 38,
}, },
}; };
this.setGridOption({ this.setGridOption({
@ -398,7 +368,7 @@ const myDetail = [
textCols: 12, textCols: 12,
}, },
{ {
type: 'InputTextReg', type: 'InputText',
label: '설비종류명', label: '설비종류명',
valueNm: 'eqpmKindNm', valueNm: 'eqpmKindNm',
disabled: false, disabled: false,
@ -458,14 +428,4 @@ const myDetail = [
textCols: 12, textCols: 12,
}, },
]; ];
import { getPathDataExample } from '@/const/const'
const dataPathDataExample = getPathDataExample({
eqpmKindId: 'EKIND0005',
eqpmKindNm: 'VCB',
regUserNo: '사용',
regDttm: 'EQP_HVAC_LT_CH001',
procUserNo: '사용',
procDttm: 'EQP_HVAC_LT_CH001',
});
</script> </script>

View File

@ -1,41 +1,23 @@
<template> <template>
<div ref="mainDiv" class="l-layout"> <div ref="mainDiv" class="l-layout">
<PageTitle />
<v-row ref="searchFilter"> <v-row ref="searchFilter">
<v-col :cols="12"> <v-col :cols="12">
<v-card class="searchFilter"> <v-card class="searchFilter">
<v-row align="end" no-gutters> <v-row align="end" no-gutters>
<v-col :cols="3"> <v-col :cols="3">
<component <component :is="'selectCodeList'" :parentPrgmId="myPrgmId" :label="'사용여부'" dataKey="useFg"
:is="'selectCodeList'" :sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }" :addAll="true"
:parentPrgmId="myPrgmId" customClass="select-large" />
:label="'사용여부'"
dataKey="useFg"
:sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }"
:addAll="true"
customClass="select-large"
/>
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
<component <component :is="'SelectBox'" ref="SelectBox1" :propsValue="selectValue01"
:is="'SelectBox'" :itemList="selectValueList01" :label="'설비종류'"
ref="SelectBox1" @update:propsValue="selectValue01 = $event" customClass="select-large" />
:propsValue="selectValue01"
:itemList="selectValueList01"
:label="'설비종류'"
@update:propsValue="selectValue01 = $event"
customClass="select-large"
/>
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
<InputText <InputText :parentPrgmId="myPrgmId" label="설비 그룹 명" valueNm="eqpmGrpNm" :searchOption="true"
:parentPrgmId="myPrgmId" :textCols="12" :labelCols="12" customClass="input-large" />
label="설비 그룹 명"
valueNm="eqpmGrpNm"
:searchOption="true"
:textCols="12"
:labelCols="12"
customClass="input-large"
/>
</v-col> </v-col>
<v-col :cols="3" class="text-right"> <v-col :cols="3" class="text-right">
<BtnSearch @click="search" size="large" /> <BtnSearch @click="search" size="large" />
@ -47,41 +29,28 @@
<v-row ref="contents"> <v-row ref="contents">
<v-col :cols="5" class="h100"> <v-col :cols="5" class="h100">
<v-card class="pb-5"> <v-card class="pb-5">
<v-card-title class="d-flex justify-space-between align-end"> <div class="d-flex align-center justify-space-between pa-4"
<span class="tit ft-size_20 ft-weight_600">설비 그룹</span> style="padding-bottom: 30px !important;">
<Buttons <v-card-title class="pa-0">설비 그룹</v-card-title>
:parentPrgmId="myPrgmId" <Buttons :parentPrgmId="myPrgmId" :bindingData="gridName" :btnActionsFnc="btnActions" />
:bindingData="gridName" </div>
:btnActionsFnc="btnActions"
/>
</v-card-title>
<div class="h100 px-5" style="height:calc(100% - 70px)"> <div class="h100 px-5" style="height:calc(100% - 70px)">
<div ref="gridParent" class="w100 h100"> <div ref="gridParent" class="w100 h100">
<component <component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName"
:ref="gridName" :parentPrgmId="myPrgmId" @getRowsData="getRowData" />
:is="loadGrid ? 'Grid' : null"
:gridName="gridName"
:parentPrgmId="myPrgmId"
@getRowsData="getRowData"
:dataPath="dataPathMock"
/>
</div> </div>
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
<v-col :cols="7" class="h100"> <v-col :cols="7" class="h100">
<v-card class="pb-5"> <v-card class="pb-5">
<div class="d-flex align-center justify-space-between pa-5"> <div class="d-flex align-center justify-space-between pa-4"
style="padding-bottom: 30px !important;">
<v-card-title class="pa-0">설비 그룹 상세</v-card-title> <v-card-title class="pa-0">설비 그룹 상세</v-card-title>
</div> </div>
<div class="px-5" style="height:calc(100% - 76px)"> <div class="px-5" style="height:calc(100% - 76px)">
<component <component :is="'Form'" :parentPrgmId="myPrgmId" :detailList="detailList"
:is="'Form'" @gridEditingFinish="gridEditingFinish" />
:parentPrgmId="myPrgmId"
:detailList="detailList"
@gridEditingFinish="gridEditingFinish"
/>
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
@ -100,6 +69,8 @@ import Form from '~/components/common/form/Form';
import Grid from '~/components/common/Grid'; import Grid from '~/components/common/Grid';
import Utility from '~/plugins/utility'; import Utility from '~/plugins/utility';
import SelectBox from '@/components/common/select/SelectBox'; import SelectBox from '@/components/common/select/SelectBox';
import PageTitle from "~/components/common/PageTitle";
let myTitle; let myTitle;
// const myPrgmId = "PRG0013"; // const myPrgmId = "PRG0013";
let myPrgmId; let myPrgmId;
@ -130,34 +101,17 @@ export default {
Grid, Grid,
Utility, Utility,
SelectBox, SelectBox,
PageTitle,
}, },
data() { data() {
return { return {
myPrgmId: myPrgmId, myPrgmId: myPrgmId,
gridName: 'rowGrid', gridName: 'rowGrid',
loadGrid: true, loadGrid: false,
tab: null, tab: null,
detailList: myDetail, detailList: myDetail,
selectValueList01: [], selectValueList01: [],
selectValue01: null, selectValue01: null,
dataPathMock: {
'rowGrid': {
column: [
{ header: '회사 ID', name: 'comId', hidden: true },
{ header: '설비 그룹 ID', name: 'eqpmGrpId'},
{ header: '설비 그룹 명', name: 'eqpmGrpNm'},
{ header: '설비종류', name: 'eqpmKindId'},
{ header: '사용여부', name: 'useFg'},
{ header: '등록자NO', name: 'regUserNo', hidden: true},
{ header: '등록일시', name: 'regDttm', hidden: true },
{ header: '수정자NO', name: 'procUserNo', hidden: true },
{ header: '수정일시', name: 'procDttm', hidden: true}
],
data: dataPathDataExample,
defaultRow: dataPathDataExample,
options:{}
}
},
}; };
}, },
computed: { computed: {
@ -203,7 +157,7 @@ export default {
defaultData: defaultData, defaultData: defaultData,
}); });
}, },
created() {}, created() { },
mounted() { mounted() {
this.setSelectValueList01(); this.setSelectValueList01();
// if (this.loadFlag) { // if (this.loadFlag) {
@ -252,12 +206,15 @@ export default {
} }
}, },
gridInit() { gridInit() {
const gridHeight = this.$refs.gridParent.offsetHeight - 70; const gridHeight = this.$refs.gridParent.offsetHeight - 30;
const myOptions = { const myOptions = {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 38,
},
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
@ -512,7 +469,7 @@ const myDetail = [
placeholder: '시스템 자동입력', placeholder: '시스템 자동입력',
}, },
{ {
type: 'InputTextReg', type: 'InputText',
label: '설비 그룹 명', label: '설비 그룹 명',
valueNm: 'eqpmGrpNm', valueNm: 'eqpmGrpNm',
disabled: false, disabled: false,
@ -600,18 +557,4 @@ const myDetail = [
textCols: 12, textCols: 12,
}, },
]; ];
import { getPathDataExample } from '@/const/const'
const dataPathDataExample = getPathDataExample({
comId: 'EKIND0005',
eqpmGrpId: 'EQG000010',
eqpmGrpNm:'냉수파이프고온',
eqpmKindId:'냉동파이프',
useFg:'1',
regUserNo: '사용',
regDttm: 'EQP_HVAC_LT_CH001',
procUserNo: '사용',
procDttm: 'EQP_HVAC_LT_CH001',
});
</script> </script>

View File

@ -37,11 +37,11 @@
:btnActionsFnc="btnActions" /> :btnActionsFnc="btnActions" />
</div> </div>
<div class="h100 px-4" style="height:calc(100% - 70px)"> <div class="h100 px-4" style="height:calc(100% - 70px)">
<div ref="gridParent" > <div ref="gridParent" style="height: 30%">
<component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName" <component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName"
:parentPrgmId="myPrgmId" @getRowsData="getRowData" :dataPath="dataPathExample" /> :parentPrgmId="myPrgmId" @getRowsData="getRowData" :dataPath="dataPathExample" />
</div> </div>
<div class="d-flex py-4"> <div class="d-flex py-4" >
<component :is="'Form'" :parentPrgmId="myPrgmId" :detailList="detailList" <component :is="'Form'" :parentPrgmId="myPrgmId" :detailList="detailList"
@gridEditingFinish="gridEditingFinish" /> @gridEditingFinish="gridEditingFinish" />
</div> </div>
@ -112,7 +112,7 @@ export default {
myPrgmId: myPrgmId, myPrgmId: myPrgmId,
initedFlag: false, initedFlag: false,
gridName: 'rowGrid', gridName: 'rowGrid',
loadGrid: true, loadGrid: false,
detailList: myDetail, detailList: myDetail,
selectValue01: null, selectValue01: null,
selectValueList01: [], selectValueList01: [],
@ -125,102 +125,102 @@ export default {
// pysclQtyId3 : null, // pysclQtyId3 : null,
// pysclQtyId4 : null // pysclQtyId4 : null
// } // }
dataPathExample: { // dataPathExample: {
"rowGrid": { // "rowGrid": {
data: [ // data: [
{ // {
gdIdxId: 'GD001', // gdIdxId: 'GD001',
gdIdxNm: '온도 가이드', // gdIdxNm: '온도 가이드',
eqpmGrpId: 'EQ001', // eqpmGrpId: 'EQ001',
upTotMeth: 'AVG', // upTotMeth: 'AVG',
careStndVal: 50, // careStndVal: 50,
warnStndVal: 70, // warnStndVal: 70,
alrmMsg: '온도가 기준치를 초과했습니다.', // alrmMsg: '온도가 기준치를 초과했습니다.',
},
{
gdIdxId: 'GD002',
gdIdxNm: '습도 가이드',
eqpmGrpId: 'EQ002',
upTotMeth: 'MAX',
careStndVal: 30,
warnStndVal: 60,
alrmMsg: '습도가 기준치를 초과했습니다.',
},
{
gdIdxId: 'GD003',
gdIdxNm: '압력 가이드',
eqpmGrpId: 'EQ003',
upTotMeth: 'SUM',
careStndVal: 100,
warnStndVal: 150,
alrmMsg: '압력이 기준치를 초과했습니다.',
}
],
column: [
{
header: '가이드',
name: 'gdIdxId',
width: 100,
align: 'center',
},
{
header: '가이드명',
name: 'gdIdxNm',
width: 210,
align: 'left',
},
{
header: '설비그룹ID',
name: 'eqpmGrpId',
width: 100,
align: 'center',
// formatter({ value }) {
// let retVal = '';
// const newValue = _this.pageData.eqpmGrpList.filter(item => item.value == value);
// if (newValue.length > 0) {
// retVal = newValue[0].text;
// }
// return retVal;
// }, // },
}, // {
{ // gdIdxId: 'GD002',
header: '상위집계방법', // gdIdxNm: '습도 가이드',
name: 'upTotMeth', // eqpmGrpId: 'EQ002',
width: 100, // upTotMeth: 'MAX',
align: 'center', // careStndVal: 30,
// formatter({ value }) { // warnStndVal: 60,
// let retVal = ''; // alrmMsg: '습도가 기준치를 초과했습니다.',
// const newValue = _this.pageData.upTotMethList.filter(item => item.commCd == value);
// if (newValue.length > 0) {
// retVal = newValue[0].commCdNm;
// }
// return retVal;
// }, // },
}, // {
{ // gdIdxId: 'GD003',
header: '주의기준', // gdIdxNm: '압력 가이드',
name: 'careStndVal', // eqpmGrpId: 'EQ003',
width: 100, // upTotMeth: 'SUM',
align: 'right', // careStndVal: 100,
}, // warnStndVal: 150,
{ // alrmMsg: '압력이 기준치를 초과했습니다.',
header: '경고기준', // }
name: 'warnStndVal',
width: 100,
align: 'right',
},
{
header: '알람메세지',
name: 'alrmMsg',
minWidth: 860,
align: 'left',
}
]
} // ],
} // column: [
// {
// header: '가이드',
// name: 'gdIdxId',
// width: 100,
// align: 'center',
// },
// {
// header: '가이드명',
// name: 'gdIdxNm',
// width: 210,
// align: 'left',
// },
// {
// header: '설비그룹ID',
// name: 'eqpmGrpId',
// width: 100,
// align: 'center',
// // formatter({ value }) {
// // let retVal = '';
// // const newValue = _this.pageData.eqpmGrpList.filter(item => item.value == value);
// // if (newValue.length > 0) {
// // retVal = newValue[0].text;
// // }
// // return retVal;
// // },
// },
// {
// header: '상위집계방법',
// name: 'upTotMeth',
// width: 100,
// align: 'center',
// // formatter({ value }) {
// // let retVal = '';
// // const newValue = _this.pageData.upTotMethList.filter(item => item.commCd == value);
// // if (newValue.length > 0) {
// // retVal = newValue[0].commCdNm;
// // }
// // return retVal;
// // },
// },
// {
// header: '주의기준',
// name: 'careStndVal',
// width: 100,
// align: 'right',
// },
// {
// header: '경고기준',
// name: 'warnStndVal',
// width: 100,
// align: 'right',
// },
// {
// header: '알람메세지',
// name: 'alrmMsg',
// minWidth: 860,
// align: 'left',
// }
// ]
// }
// }
}; };
}, },
computed: { computed: {
@ -352,60 +352,46 @@ export default {
}); });
}, },
async getEqpmKind() { async getEqpmKind() {
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: 'selectEqpmKindCodeList', apiKey: 'selectEqpmKindCodeList',
// resKey: 'eqpmKindCodeLists', resKey: 'eqpmKindCodeLists',
// sendParam: {}, sendParam: {},
// }); });
// if (res.length > 0) { if (res.length > 0) {
// this.selectValueList01 = await res.map(item => { this.selectValueList01 = await res.map(item => {
// return { return {
// text: item.eqpmKindNm, text: item.eqpmKindNm,
// value: item.eqpmKindId, value: item.eqpmKindId,
// }; };
// }); });
// this.selectValue01 = this.selectValueList01[0].value; this.selectValue01 = this.selectValueList01[0].value;
// } else { } else {
// this.selectValueList01 = []; this.selectValueList01 = [];
// this.selectValue01 = null; this.selectValue01 = null;
// } }
this.selectValueList01 = [
{ label: 'Etcher', value: 'EQK001' },
{ label: 'Deposition', value: 'EQK002' },
{ label: 'Inspection', value: 'EQK003' },
];
this.selectValue01 = 'EQK001';
this.setPageData({ this.setPageData({
eqpmKindList: this.selectValueList01, eqpmKindList: this.selectValueList01,
eqpmKindId: this.selectValue01, eqpmKindId: this.selectValue01,
}); });
}, },
async getEqpmGrp() { async getEqpmGrp() {
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: 'selectEqpmGrpCodeList', apiKey: 'selectEqpmGrpCodeList',
// resKey: 'eqpmGrpCodeLists', resKey: 'eqpmGrpCodeLists',
// sendParam: { eqpmKindId: this.selectValue01 }, sendParam: { eqpmKindId: this.selectValue01 },
// }); });
// if (res.length > 0) { if (res.length > 0) {
// this.selectValueList02 = await res.map(item => { this.selectValueList02 = await res.map(item => {
// return { return {
// text: item.eqpmGrpNm, text: item.eqpmGrpNm,
// value: item.eqpmGrpId, value: item.eqpmGrpId,
// }; };
// }); });
// this.selectValue02 = this.selectValueList02[0].value; this.selectValue02 = this.selectValueList02[0].value;
// } else { } else {
// this.selectValueList02 = []; this.selectValueList02 = [];
// this.selectValue02 = null; this.selectValue02 = null;
// } }
this.selectValueList02 = [
{ label: '냉동기고온', value: '냉동기고온' },
{ label: '냉동기저온', value: '냉동기저온' },
{ label: '공조기', value: '공조기' },
{ label: '보일러', value: '보일러' }
];
this.setPageData({ this.setPageData({
eqpmGrpList: this.selectValueList02, eqpmGrpList: this.selectValueList02,
@ -419,6 +405,10 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 37,
},
rowHeight: 'auto',
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
@ -636,100 +626,100 @@ export default {
async getRowGridData() { async getRowGridData() {
this.loadGrid = false; this.loadGrid = false;
let res = []; let res = [];
const newRes = [ // const newRes = [
{ // {
comId: 'COM001', // comId: 'COM001',
gdIdxId: 'GD001', // gdIdxId: 'GD001',
gdIdxNm: '온도 가이드', // gdIdxNm: '온도 가이드',
eqpmGrpId: 'EQ001', // eqpmGrpId: 'EQ001',
upTotMeth: 'AVG', // upTotMeth: 'AVG',
sortSeq: 1, // sortSeq: 1,
pysclQtyId1: 'TEMP', // pysclQtyId1: 'TEMP',
pysclQtyId2: null, // pysclQtyId2: null,
pysclQtyId3: null, // pysclQtyId3: null,
pysclQtyId4: null, // pysclQtyId4: null,
ctgr1: '환경', // ctgr1: '환경',
ctgr2: '내부', // ctgr2: '내부',
careStndVal: 50, // careStndVal: 50,
warnStndVal: 70, // warnStndVal: 70,
gdMeth: '자동', // gdMeth: '자동',
useFg: '1', // useFg: '1',
alrmMsg: '온도가 기준치를 초과했습니다.', // alrmMsg: '온도가 기준치를 초과했습니다.',
calcProc: 'PROC001', // calcProc: 'PROC001',
calcDesc: '평균 계산', // calcDesc: '평균 계산',
calcMeth: '(A+B)/2', // calcMeth: '(A+B)/2',
unit: 'C', // unit: 'C',
argCnt: 2, // argCnt: 2,
rowStat: null,
},
{
comId: 'COM002',
gdIdxId: 'GD002',
gdIdxNm: '습도 가이드',
eqpmGrpId: 'EQ002',
upTotMeth: 'MAX',
sortSeq: 2,
pysclQtyId1: 'HUMID',
pysclQtyId2: null,
pysclQtyId3: null,
pysclQtyId4: null,
ctgr1: '환경',
ctgr2: '외부',
careStndVal: 30,
warnStndVal: 60,
gdMeth: '수동',
useFg: '0',
alrmMsg: '습도가 기준치를 초과했습니다.',
calcProc: 'PROC002',
calcDesc: '최대값 계산',
calcMeth: 'MAX(A,B)',
unit: '%',
argCnt: 2,
rowStat: null,
},
];
// res = await this.postApiReturn({
// apiKey: 'selectEqpmGdIdxDataList',
// resKey: 'eqpmGdIdxDataList',
// sendParam: {
// eqpmGrpId: this.selectValue02,
// gdIdxNmLike: this.pageData.gdIdxNm,
// },
// });
// const newRes = res.map(item => {
// const newObj = {
// ...item,
// rowStat: null, // rowStat: null,
// }; // },
// return newObj; // {
// }); // comId: 'COM002',
// gdIdxId: 'GD002',
// gdIdxNm: '습도 가이드',
// eqpmGrpId: 'EQ002',
// upTotMeth: 'MAX',
// sortSeq: 2,
// pysclQtyId1: 'HUMID',
// pysclQtyId2: null,
// pysclQtyId3: null,
// pysclQtyId4: null,
// ctgr1: '환경',
// ctgr2: '외부',
// careStndVal: 30,
// warnStndVal: 60,
// gdMeth: '수동',
// useFg: '0',
// alrmMsg: '습도가 기준치를 초과했습니다.',
// calcProc: 'PROC002',
// calcDesc: '최대값 계산',
// calcMeth: 'MAX(A,B)',
// unit: '%',
// argCnt: 2,
// rowStat: null,
// },
// ];
res = await this.postApiReturn({
apiKey: 'selectEqpmGdIdxDataList',
resKey: 'eqpmGdIdxDataList',
sendParam: {
eqpmGrpId: this.selectValue02,
gdIdxNmLike: this.pageData.gdIdxNm,
},
});
const newRes = res.map(item => {
const newObj = {
...item,
rowStat: null,
};
return newObj;
});
this.setGridData({ this.setGridData({
gridKey: this.gridName, gridKey: this.gridName,
value: newRes, value: newRes,
}); });
//this.loadGrid = true; //this.loadGrid = true;
// this.$nextTick(() => { this.$nextTick(() => {
// if (newRes.length > 0) { if (newRes.length > 0) {
// try { try {
// this.$refs[this.gridName].focus({ this.$refs[this.gridName].focus({
// //rowKey: 0, //rowKey: 0,
// rowKey: rowKey:
// this.pageData.rowGridSelectKey == '' || this.pageData.rowGridSelectKey == '' ||
// this.pageData.rowGridSelectKey == null this.pageData.rowGridSelectKey == null
// ? 0 ? 0
// : this.pageData.rowGridSelectKey == : this.pageData.rowGridSelectKey ==
// this.$refs[this.gridName].getData().length - 1 this.$refs[this.gridName].getData().length - 1
// ? this.pageData.rowGridSelectKey ? this.pageData.rowGridSelectKey
// : 0, : 0,
// columnName: 'gdIdxId', columnName: 'gdIdxId',
// setScroll: true, setScroll: true,
// }); });
// } catch (error) { } } catch (error) { }
// } else { } else {
// this.detailDataInit(); this.detailDataInit();
// } }
// }); });
this.loadGrid = true; this.loadGrid = true;
}, },
async getRowData(data) { async getRowData(data) {

View File

@ -29,7 +29,7 @@
</v-card> </v-card>
</v-col> </v-col>
</v-row> </v-row>
<v-row ref="contents" class="mt-4"> <v-row ref="contents" class="mt-3">
<v-col :cols="12" style="height: 100%"> <v-col :cols="12" style="height: 100%">
<!-- <v-card class="py-5"> --> <!-- <v-card class="py-5"> -->
<v-card style="height: 60%"> <v-card style="height: 60%">
@ -115,8 +115,8 @@
</v-card> </v-card>
<v-row style="height: 40%" class="mt-4"> <v-row style="height: 40%" class="mt-3">
<v-col :cols="6" style="height: 100%"> <v-col :cols="6" style="height: 100%" class="pr-2">
<v-card class="pb-5"> <v-card class="pb-5">
<div class="d-flex align-center justify-space-between pa-4"> <div class="d-flex align-center justify-space-between pa-4">
<v-card-title class="pa-0 custom-title-4 ">설비상세 리스트</v-card-title> <v-card-title class="pa-0 custom-title-4 ">설비상세 리스트</v-card-title>
@ -126,12 +126,12 @@
<div ref="gridParent" class="w100 h100"> <div ref="gridParent" class="w100 h100">
<component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName" <component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName"
:parentPrgmId="myPrgmId" @getRowsData="getRowData" :parentPrgmId="myPrgmId" @getRowsData="getRowData"
:dataPath="dataPathExample" /> />
</div> </div>
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
<v-col :cols="6" style="height: 100%"> <v-col :cols="6" style="height: 100%" class="pl-2">
<v-card class="pb-5"> <v-card class="pb-5">
<div class="d-flex align-center justify-space-between pa-4"> <div class="d-flex align-center justify-space-between pa-4">
<v-card-title class="pa-0 custom-title-4">설비가이드 기준 정보</v-card-title> <v-card-title class="pa-0 custom-title-4">설비가이드 기준 정보</v-card-title>
@ -201,7 +201,7 @@ export default {
readonlyFg: true, readonlyFg: true,
initedFlag: false, initedFlag: false,
gridName: 'rowGrid', gridName: 'rowGrid',
loadGrid: true, loadGrid: false,
detailList: myDetail, detailList: myDetail,
selectValue01: null, selectValue01: null,
selectValueList01: [], selectValueList01: [],
@ -209,62 +209,62 @@ export default {
selectValueList02: [], selectValueList02: [],
selectValue03: null, selectValue03: null,
selectValueList03: [], selectValueList03: [],
dataPathExample: { // dataPathExample: {
"rowGrid": { // "rowGrid": {
data: [ // data: [
{ // {
eqpmId: 'EQ001', // eqpmId: 'EQ001',
originEqpmId: 'ORIG001', // originEqpmId: 'ORIG001',
eqpmNm: '냉각기 A', // eqpmNm: '냉각기 A',
careStndVal: 75, // careStndVal: 75,
warnStndVal: 90, // warnStndVal: 90,
}, // },
{ // {
eqpmId: 'EQ002', // eqpmId: 'EQ002',
originEqpmId: 'ORIG002', // originEqpmId: 'ORIG002',
eqpmNm: '펌프 B', // eqpmNm: '펌프 B',
careStndVal: 60, // careStndVal: 60,
warnStndVal: 80, // warnStndVal: 80,
}, // },
{ // {
eqpmId: 'EQ003', // eqpmId: 'EQ003',
originEqpmId: 'ORIG003', // originEqpmId: 'ORIG003',
eqpmNm: '모터 C', // eqpmNm: '모터 C',
careStndVal: 50, // careStndVal: 50,
warnStndVal: 70, // warnStndVal: 70,
}, // },
{ // {
eqpmId: 'EQ004', // eqpmId: 'EQ004',
originEqpmId: 'ORIG004', // originEqpmId: 'ORIG004',
eqpmNm: '밸브 D', // eqpmNm: '밸브 D',
careStndVal: 65, // careStndVal: 65,
warnStndVal: 85, // warnStndVal: 85,
}, // },
{ // {
eqpmId: 'EQ005', // eqpmId: 'EQ005',
originEqpmId: 'ORIG005', // originEqpmId: 'ORIG005',
eqpmNm: '컨트롤러 E', // eqpmNm: '컨트롤러 E',
careStndVal: 55, // careStndVal: 55,
warnStndVal: 75, // warnStndVal: 75,
}, // },
], // ],
column: [ // column: [
{ header: '설비', name: 'eqpmId', align: 'left' }, // { header: '설비', name: 'eqpmId', align: 'left' },
{ // {
header: 'origin설비', // header: 'origin설비',
name: 'originEqpmId', // name: 'originEqpmId',
align: 'center', // align: 'center',
hidden: true, // hidden: true,
}, // },
{ header: '설비명', name: 'eqpmNm', align: 'left' }, // { header: '설비명', name: 'eqpmNm', align: 'left' },
{ header: '주의기준', name: 'careStndVal', align: 'right' }, // { header: '주의기준', name: 'careStndVal', align: 'right' },
{ header: '심각기준', name: 'warnStndVal', align: 'right' }, // { header: '심각기준', name: 'warnStndVal', align: 'right' },
] // ]
} // }
} // }
}; };
}, },
computed: { computed: {
@ -408,6 +408,10 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 37,
},
rowHeight: 'auto',
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
@ -511,69 +515,69 @@ export default {
this.loadGrid = false; this.loadGrid = false;
let res = []; let res = [];
// if (this.selectValue01 && this.selectValue02 && this.selectValue03) { if (this.selectValue01 && this.selectValue02 && this.selectValue03) {
// res = await this.postApiReturn({ res = await this.postApiReturn({
// apiKey: 'selectEqpmGdDetl', apiKey: 'selectEqpmGdDetl',
// resKey: 'eqpmGdDetlData', resKey: 'eqpmGdDetlData',
// sendParam: { sendParam: {
// gdIdxId: this.selectValue03, gdIdxId: this.selectValue03,
},
});
}
// grid에서 eqpmId를 기억해서 popup에서 중복되는 값을 제거하는데 사용하기위해 저장 - 시작
let eqpmIdList = res.map(item => {
return item.eqpmId;
});
this.setPageData({ nowGridEqpmIdList: eqpmIdList });
// grid에서 eqpmId를 기억해서 popup에서 중복되는 값을 제거하는데 사용하기위해 저장 - 끝
const newRes = res.map(item => {
const newObj = {
...item,
rowStat: null,
};
return newObj;
});
// const newRes = [
// {
// eqpmId: 'EQ001',
// originEqpmId: 'ORIG001',
// eqpmNm: '냉각기 A',
// careStndVal: 75,
// warnStndVal: 90,
// },
// {
// eqpmId: 'EQ002',
// originEqpmId: 'ORIG002',
// eqpmNm: '펌프 B',
// careStndVal: 60,
// warnStndVal: 80,
// },
// {
// eqpmId: 'EQ003',
// originEqpmId: 'ORIG003',
// eqpmNm: '모터 C',
// careStndVal: 50,
// warnStndVal: 70,
// },
// {
// eqpmId: 'EQ004',
// originEqpmId: 'ORIG004',
// eqpmNm: '밸브 D',
// careStndVal: 65,
// warnStndVal: 85,
// },
// {
// eqpmId: 'EQ005',
// originEqpmId: 'ORIG005',
// eqpmNm: '컨트롤러 E',
// careStndVal: 55,
// warnStndVal: 75,
// }, // },
// });
// }
// // grid에서 eqpmId를 기억해서 popup에서 중복되는 값을 제거하는데 사용하기위해 저장 - 시작 // ]
// let eqpmIdList = res.map(item => {
// return item.eqpmId;
// });
// this.setPageData({ nowGridEqpmIdList: eqpmIdList });
// // grid에서 eqpmId를 기억해서 popup에서 중복되는 값을 제거하는데 사용하기위해 저장 - 끝
// const newRes = res.map(item => {
// const newObj = {
// ...item,
// rowStat: null,
// };
// return newObj;
// });
const newRes = [
{
eqpmId: 'EQ001',
originEqpmId: 'ORIG001',
eqpmNm: '냉각기 A',
careStndVal: 75,
warnStndVal: 90,
},
{
eqpmId: 'EQ002',
originEqpmId: 'ORIG002',
eqpmNm: '펌프 B',
careStndVal: 60,
warnStndVal: 80,
},
{
eqpmId: 'EQ003',
originEqpmId: 'ORIG003',
eqpmNm: '모터 C',
careStndVal: 50,
warnStndVal: 70,
},
{
eqpmId: 'EQ004',
originEqpmId: 'ORIG004',
eqpmNm: '밸브 D',
careStndVal: 65,
warnStndVal: 85,
},
{
eqpmId: 'EQ005',
originEqpmId: 'ORIG005',
eqpmNm: '컨트롤러 E',
careStndVal: 55,
warnStndVal: 75,
},
]
this.setGridData({ this.setGridData({
gridKey: this.gridName, gridKey: this.gridName,
value: newRes, value: newRes,

View File

@ -73,10 +73,8 @@
:is="loadGrid ? 'Grid' : null" :is="loadGrid ? 'Grid' : null"
:gridName="gridName" :gridName="gridName"
:parentPrgmId="myPrgmId" :parentPrgmId="myPrgmId"
:dataPath="dataPathMock"
/> />
</div> </div>
</v-card> </v-card>
</v-col> </v-col>
</v-row> </v-row>
@ -154,53 +152,6 @@ export default {
required: false, required: false,
formFg: false, formFg: false,
}, },
dataPathMock: {
"rowGrid": {
column: [
{
header: 'TAG ID',
name: 'tagId',
minWidth: 500,
},
{
header: 'TAG명',
name: 'tagNm',
},
{
header: '대상일시',
name: 'readDttm',
align:"center",
width: 200,
},
{
header: '값',
name: 'readVal',
width: 100,
align:"center"
},
{
header: '취득일시',
name: 'regDttm',
width: 200,
align:"center"
},
{
header: '적재일시',
name: 'procDttm',
width: 200,
align:"center"
},
],
data: dataPathDataExample,
defaultRow: dataPathDataExample,
option: {
pageOptions: {
useClient: true,
perPage: 10,
},
}
}
},
}; };
}, },
computed: { computed: {
@ -316,13 +267,15 @@ export default {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
header: {
height: 38,
},
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
value: Object.assign(Utility.defaultGridOption(gridHeight), myOptions), value: Object.assign(Utility.defaultGridOption(gridHeight), myOptions),
}); });
let myColumns = [ let myColumns = [
{ {
header: 'TAG ID', header: 'TAG ID',
@ -569,13 +522,4 @@ const defaultData = {
}, },
}, },
}; };
import { getPathDataExample } from '@/const/const'
const dataPathDataExample = getPathDataExample({
"tagId": "ICHEON.ELEC.EQID101.VCB_111A_ACC_WH_PV",
"tagNm": "ICHEON VCB_111A 적산 전력",
"readDttm": "2023-01-10 00:00:00",
"readVal": "581.27",
"regDttm": "2023-01-09 15:03:08",
"procDttm": "2023-01-10 00:03:09",
});
</script> </script>

View File

@ -1,80 +1,40 @@
<template> <template>
<div class="l-layout"> <div class="l-layout">
<PageTitle/>
<v-row ref="searchFilter"> <v-row ref="searchFilter">
<v-col :cols="12"> <v-col :cols="12">
<v-card class="searchFilter"> <v-card class="searchFilter">
<v-row align="center" no-gutters> <v-row align="center" no-gutters>
<v-col :cols="3"> <v-col :cols="3">
<!-- 사업장 --> <!-- 사업장 -->
<component <component :is="'SelectBlocMstr'" ref="SelectBlocMstr" :parentPrgmId="myPrgmId"
:is="'SelectBlocMstr'" :textCols="12" customClass="select-large" />
ref="SelectBlocMstr"
:parentPrgmId="myPrgmId"
:textCols="12"
customClass="select-large"
/>
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
<component <component :is="'selectCodeList'" :parentPrgmId="myPrgmId" :label="'측정 Data 유형'"
:is="'selectCodeList'" dataKey="searchReadDataType" :sendParam="{ commGrpCd: 'EM_READ_DATA_TYPE', useFg: '1' }"
:parentPrgmId="myPrgmId" :addAll="true" :textCols="12" customClass="select-large" />
:label="'측정 Data 유형'"
dataKey="searchReadDataType"
:sendParam="{ commGrpCd: 'EM_READ_DATA_TYPE', useFg: '1' }"
:addAll="true"
:textCols="12"
customClass="select-large"
/>
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
<component <component :is="'SelectReadObj'" :parentPrgmId="myPrgmId" :label="'측정대상'"
:is="'SelectReadObj'" dataKey="searchReadObj" :sendParam="{ useFg: '1' }" :labelCols="12" :textCols="12"
:parentPrgmId="myPrgmId" :addAll="true" customClass="select-large" />
:label="'측정대상'"
dataKey="searchReadObj"
:sendParam="{ useFg: '1' }"
:labelCols="12"
:textCols="12"
:addAll="true"
customClass="select-large"
/>
</v-col> </v-col>
</v-row> </v-row>
<v-row align="end" no-gutters> <v-row align="end" no-gutters>
<v-col :cols="3"> <v-col :cols="3">
<component <component :is="'selectCodeList'" :parentPrgmId="myPrgmId" :label="'사용여부'" dataKey="useFg"
:is="'selectCodeList'" :sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }" :addAll="true" :textCols="12"
:parentPrgmId="myPrgmId" customClass="select-large" />
:label="'사용여부'"
dataKey="useFg"
:sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }"
:addAll="true"
:textCols="12"
customClass="select-large"
/>
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
<InputText <InputText :parentPrgmId="myPrgmId" label="TAG ID" valueNm="tagId" :labelCols="12"
:parentPrgmId="myPrgmId" :textCols="12" :searchOption="true" customClass="input-large" />
label="TAG ID"
valueNm="tagId"
:labelCols="12"
:textCols="12"
:searchOption="true"
customClass="input-large"
/>
</v-col> </v-col>
<v-col :cols="3"> <v-col :cols="3">
<InputText <InputText :parentPrgmId="myPrgmId" label="TAG명" valueNm="tagNm" :labelCols="12"
:parentPrgmId="myPrgmId" :textCols="12" :searchOption="true" customClass="input-large" />
label="TAG명"
valueNm="tagNm"
:labelCols="12"
:textCols="12"
:searchOption="true"
customClass="input-large"
/>
</v-col> </v-col>
<v-col :cols="3" class="d-flex align-end justify-end text-right"> <v-col :cols="3" class="d-flex align-end justify-end text-right">
<BtnSearch @click="search" size="large" /> <BtnSearch @click="search" size="large" />
@ -88,29 +48,14 @@
<v-card class="pb-5"> <v-card class="pb-5">
<v-card-title class="d-flex justify-space-between align-end"> <v-card-title class="d-flex justify-space-between align-end">
<span class="tit ft-size_20 ft-weight_600">TAG 정보</span> <span class="tit ft-size_20 ft-weight_600">TAG 정보</span>
<Buttons <Buttons :parentPrgmId="myPrgmId" :bindingData="gridName" :detailList="detailList"
:parentPrgmId="myPrgmId" :btnActionsFnc="btnActions" />
:bindingData="gridName"
:detailList="detailList"
:btnActionsFnc="btnActions"
/>
</v-card-title> </v-card-title>
<v-card-actions> <v-card-actions>
<div <div ref="gridParent" class="w100" style="height: calc(100vh - 400px)">
ref="gridParent" <component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName"
class="w100" :parentPrgmId="myPrgmId" @getRowsData="getRowData"
style="height: calc(100vh - 400px)" @sendSelectedRowStatInfo="getSelectedRowStatInfo" :selectedRowDataWatchFlag="true" />
>
<component
:ref="gridName"
:is="loadGrid ? 'Grid' : null"
:gridName="gridName"
:parentPrgmId="myPrgmId"
@getRowsData="getRowData"
@sendSelectedRowStatInfo="getSelectedRowStatInfo"
:selectedRowDataWatchFlag="true"
:dataPath="dataPathMock"
/>
</div> </div>
</v-card-actions> </v-card-actions>
<!-- <div class="d-flex align-center justify-space-between"> <!-- <div class="d-flex align-center justify-space-between">
@ -129,32 +74,16 @@
<v-card-title>TAG 상세</v-card-title> <v-card-title>TAG 상세</v-card-title>
<div class="px-5" style="height:calc(100% - 70px)"> <div class="px-5" style="height:calc(100% - 70px)">
<v-tabs v-model="tab"> <v-tabs v-model="tab">
<v-tab <v-tab v-for="item in items" :key="item.id" :disabled="item.disabledFlag">
v-for="item in items"
:key="item.id"
:disabled="item.disabledFlag"
>
{{ item.name }} {{ item.name }}
</v-tab> </v-tab>
</v-tabs> </v-tabs>
<v-tabs-items <v-tabs-items v-model="tab" style="height: calc(100% - 65px);" class="py-6">
v-model="tab"
style="height: calc(100% - 65px);"
class="py-6"
>
<v-tab-item v-for="(item, idx) in items" :key="item.id"> <v-tab-item v-for="(item, idx) in items" :key="item.id">
<component <component v-if="item.id == 'tagBaseInfoTab'" :is="'Form'" :parentPrgmId="myPrgmId"
v-if="item.id == 'tagBaseInfoTab'" :detailList="detailList" @gridEditingFinish="gridEditingFinish" />
:is="'Form'" <TagAddInfoTab v-if="item.id == 'tagAddInfoTab'" :parentPrgmId="myPrgmId"
:parentPrgmId="myPrgmId" :innerTabGridInfo="{ tab, idx }" />
:detailList="detailList"
@gridEditingFinish="gridEditingFinish"
/>
<TagAddInfoTab
v-if="item.id == 'tagAddInfoTab'"
:parentPrgmId="myPrgmId"
:innerTabGridInfo="{ tab, idx }"
/>
</v-tab-item> </v-tab-item>
</v-tabs-items> </v-tabs-items>
</div> </div>
@ -178,12 +107,13 @@ import TagAddInfoTab from '@/components/pages/ems/TagInfo/TagAddInfoTab';
import Grid from '~/components/common/Grid'; import Grid from '~/components/common/Grid';
import Utility from '~/plugins/utility'; import Utility from '~/plugins/utility';
import pagination from '~/components/Pagination'; import pagination from '~/components/Pagination';
import PageTitle from "~/components/common/PageTitle";
let myTitle; let myTitle;
// const myPrgmId = "PRG0051"; // const myPrgmId = "PRG0051";
let myPrgmId; let myPrgmId;
export default { export default {
mixins: [mixinGlobal,resize], mixins: [mixinGlobal, resize],
async asyncData(context) { async asyncData(context) {
const myState = context.store.state; const myState = context.store.state;
// context.store.commit("setActiveMenuInfo", myState.menuData[myPrgmId]); // context.store.commit("setActiveMenuInfo", myState.menuData[myPrgmId]);
@ -210,6 +140,7 @@ export default {
TagAddInfoTab, TagAddInfoTab,
Grid, Grid,
pagination, pagination,
PageTitle
}, },
data() { data() {
return { return {
@ -223,123 +154,11 @@ export default {
], ],
detailList: myDetail, detailList: myDetail,
alrmFg: null, alrmFg: null,
dataPathMock: { itemsPerPage: 10,
"rowGrid": { itemsPerPageArray: [10, 20, 30],
column: [ limit: 20,
{ header: '회사 ID', name: 'comId', hidden: true }, page: 1,
{ totalCount: 0,
header: 'TAG ID',
name: 'tagId',
width: 'auto',
minWidth: 340,
align: 'left',
},
{
header: 'TAG 명',
name: 'tagNm',
width: 'auto',
minWidth: 220,
align: 'left',
},
{
header: '측정 값 유형',
name: 'readDataTypeCd',
width: 90,
align: 'left',
},
{
header: '측정대상',
name: 'readObjId',
width: 100,
align: 'left',
},
{ header: '배율', name: 'mgnf', width: 80, align: 'right' },
{
header: '단위',
name: 'unitCd',
width: 80,
align: 'left',
},
{
header: '최소값',
name: 'rangMin',
width: 100,
align: 'right',
hidden: true,
},
{
header: '최대값',
name: 'rangMax',
width: 100,
align: 'right',
hidden: true,
},
{
header: '경고 상상',
name: 'alrmHihi',
width: 100,
align: 'right',
hidden: true,
},
{
header: '경고 상',
name: 'alrmHi',
width: 100,
align: 'right',
hidden: true,
},
{
header: '경고 하',
name: 'alrmLo',
width: 100,
align: 'right',
hidden: true,
},
{
header: '경고 하하',
name: 'alrmLolo',
width: 100,
align: 'right',
hidden: true,
},
{
header: '사업장',
name: 'blocId',
width: 100,
align: 'center',
hidden: true,
},
{
header: '집계 여부',
name: 'totFg',
width: 80,
align: 'center',
hidden: true,
},
{
header: '사용 여부',
name: 'useFg',
width: 80,
align: 'center',
hidden: true,
},
],
data: dataPathDataExample,
defaultRow: dataPathDataExample,
option: {
pageOptions: {
useClient: true,
perPage: 10,
},
scrollX: true
}
}
},
// itemsPerPage: 10,
// itemsPerPageArray: [10, 20, 30],
// limit: 20,
// page: 1,
// totalCount: 0,
}; };
}, },
computed: { computed: {
@ -456,12 +275,20 @@ export default {
this.gridInit(); this.gridInit();
}, },
gridInit() { gridInit() {
const gridHeight = this.$refs.gridParent.offsetHeight - 16; const gridHeight = this.$refs.gridParent.offsetHeight - 180;
const myOptions = { const myOptions = {
columnOptions: { columnOptions: {
resizable: true, resizable: true,
}, },
pageOptions: {
useClient: true,
perPage: 10,
},
scrollX: true,
header: {
height: 38,
},
}; };
this.setGridOption({ this.setGridOption({
gridKey: this.gridName, gridKey: this.gridName,
@ -709,7 +536,7 @@ export default {
columnName: 'tagId', columnName: 'tagId',
setScroll: true, setScroll: true,
}); });
} catch (error) {} } catch (error) { }
// this.$refs[this.gridName].focus({ // this.$refs[this.gridName].focus({
// rowKey: 0, // rowKey: 0,
// columnName: "tagId", // columnName: "tagId",
@ -946,7 +773,7 @@ export default {
gridEditingFinish(data) { gridEditingFinish(data) {
this.$refs[this.gridName].editingFinish(data); this.$refs[this.gridName].editingFinish(data);
}, },
changeGrid: async function(pageNum, limit) { changeGrid: async function (pageNum, limit) {
this.page = pageNum; this.page = pageNum;
this.limit = limit; this.limit = limit;
@ -1094,7 +921,7 @@ const myDetail = [
label: 'TAG ID', label: 'TAG ID',
valueNm: 'tagId', valueNm: 'tagId',
disabled: false, disabled: false,
iconShow:true, iconShow: true,
cols: 6, cols: 6,
class: 'py-2 pr-4', class: 'py-2 pr-4',
required: false, required: false,
@ -1106,7 +933,7 @@ const myDetail = [
label: 'TAG 명', label: 'TAG 명',
valueNm: 'tagNm', valueNm: 'tagNm',
disabled: false, disabled: false,
iconShow:true, iconShow: true,
cols: 6, cols: 6,
class: 'py-2 pl-4', class: 'py-2 pl-4',
required: false, required: false,
@ -1118,7 +945,7 @@ const myDetail = [
label: '측정 값 유형', label: '측정 값 유형',
valueNm: 'readDataTypeCd', valueNm: 'readDataTypeCd',
disabled: false, disabled: false,
iconShow:true, iconShow: true,
cols: 6, cols: 6,
class: 'py-2 pr-4 pt-5', class: 'py-2 pr-4 pt-5',
list: 'readDataTypeCdList', list: 'readDataTypeCdList',
@ -1139,7 +966,7 @@ const myDetail = [
itemText: 'readObjNm', itemText: 'readObjNm',
itemValue: 'readObjId', itemValue: 'readObjId',
required: true, required: true,
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1151,7 +978,7 @@ const myDetail = [
cols: 6, cols: 6,
class: 'py-2 pr-4 pt-5', class: 'py-2 pr-4 pt-5',
required: true, required: true,
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1165,7 +992,7 @@ const myDetail = [
list: 'unitCdList', list: 'unitCdList',
itemText: 'commCdNm', itemText: 'commCdNm',
itemValue: 'commCd', itemValue: 'commCd',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1176,7 +1003,7 @@ const myDetail = [
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2 pr-4 pt-5', class: 'py-2 pr-4 pt-5',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1187,7 +1014,7 @@ const myDetail = [
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2 pl-4 pt-5', class: 'py-2 pl-4 pt-5',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1198,7 +1025,7 @@ const myDetail = [
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2 pr-4 pt-5', class: 'py-2 pr-4 pt-5',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1209,7 +1036,7 @@ const myDetail = [
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2 pl-4 pt-5', class: 'py-2 pl-4 pt-5',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1220,7 +1047,7 @@ const myDetail = [
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2 pr-4 pt-5', class: 'py-2 pr-4 pt-5',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1231,7 +1058,7 @@ const myDetail = [
disabled: false, disabled: false,
cols: 6, cols: 6,
class: 'py-2 pl-4 pt-5', class: 'py-2 pl-4 pt-5',
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1243,7 +1070,7 @@ const myDetail = [
cols: 6, cols: 6,
class: 'py-2 pr-4 pt-5', class: 'py-2 pr-4 pt-5',
value: { '1': true, '0': false }, value: { '1': true, '0': false },
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1256,7 +1083,7 @@ const myDetail = [
class: 'py-2 pl-4 pt-5', class: 'py-2 pl-4 pt-5',
value: { '1': true, '0': false }, value: { '1': true, '0': false },
required: false, required: false,
iconShow:true, iconShow: true,
labelCols: 12, labelCols: 12,
textCols: 12, textCols: 12,
}, },
@ -1285,25 +1112,4 @@ const myDetail = [
class: 'py-2', class: 'py-2',
}, },
]; ];
import { getPathDataExample } from '@/const/const'
const dataPathDataExample = getPathDataExample({
"comId": "",
"tagId": "INCHEON.ELEC.EQID.VCB_111A_ACCWH_PV",
"tagNm": "ICHEON VCB_111A - 적산 전력",
"readDataTypeCd": "적산",
"readObjId": "적산",
"mgnf": "적산",
"unitCd":"적산",
"rangMin":"1",
"rangMax":"10",
"alrmHihi":"1",
"alrmHi":"10",
"alrmLo":"1",
"alrmLolo":"10",
"blocId":"1",
"totFg":"1",
"useFg":"1",
});
</script> </script>

View File

@ -44,7 +44,7 @@
<div class="px-5" style="min-height:calc(100% - 76px)"> <div class="px-5" style="min-height:calc(100% - 76px)">
<div ref="gridParent" class="w100 h100"> <div ref="gridParent" class="w100 h100">
<component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName" :parentPrgmId="myPrgmId" <component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName" :parentPrgmId="myPrgmId"
@getRowsData="getRowData" @sendSelectedRowStatInfo="getSelectedRowStatInfo" :dataPath="dataPathMock" @getRowsData="getRowData" @sendSelectedRowStatInfo="getSelectedRowStatInfo"
:selectedRowDataWatchFlag="true" /> :selectedRowDataWatchFlag="true" />
</div> </div>
</div> </div>

View File

@ -195,28 +195,16 @@ export default {
}); });
}, },
async getEqpmKind() { async getEqpmKind() {
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: "selectEqpmKindCodeList", apiKey: 'selectEqpmKindCodeList',
// resKey: "eqpmKindCodeLists", resKey: 'eqpmKindCodeLists',
// sendParam: {}, sendParam: {},
// }); });
let res = [
{
eqpmKindId: "냉동기저온",
eqpmKindNm: "냉동기저온",
},
{
eqpmKindId: "냉동기고온",
eqpmKindNm: "냉동기고온",
},
];
if (res.length > 0) { if (res.length > 0) {
this.selectValueList01 = await res.map((item) => { this.selectValueList01 = await res.map(item => {
return { return {
// text: item.eqpmKindNm, text: item.eqpmKindNm,
label: item.eqpmKindNm,
value: item.eqpmKindId, value: item.eqpmKindId,
}; };
}); });
@ -233,29 +221,24 @@ export default {
gridInit() {}, gridInit() {},
getRowGridData() {}, getRowGridData() {},
async getData() { async getData() {
// let res = await this.postApiReturn({ let res = await this.postApiReturn({
// apiKey: "selectEnrgEffcTotSumm", apiKey: 'selectEnrgEffcTotSumm',
// resKey: "totSummData", resKey: 'totSummData',
// sendParam: { sendParam: {
// fromDt: this.pageData.fromDt, fromDt: this.pageData.fromDt,
// eqpmKindId: this.selectValue01, eqpmKindId: this.selectValue01,
// }, },
// }); });
let res = ["aaa", "bbb"];
await this.getChartData(res); await this.getChartData(res);
// this.selectData = res.filter((item, i) => { this.selectData = res.filter((item, i) => {
// return ( return (
// res.findIndex((item2, j) => { res.findIndex((item2, j) => {
// return item.eqpmGrpId === item2.eqpmGrpId; return item.eqpmGrpId === item2.eqpmGrpId;
// }) === i }) === i
// ); );
// }); });
this.selectData = [
{ eqpmGrpId: "G001", eqpmGrpNm: "Group A", otherProp: "..." },
{ eqpmGrpId: "G002", eqpmGrpNm: "Group B", otherProp: "..." },
];
}, },
barClick(event, chartName) { barClick(event, chartName) {
var data = {}; var data = {};
@ -302,37 +285,25 @@ export default {
// } // }
// }); // });
// data.map((item) => { data.map(item => {
// if (chartDataObj[item.eqpmGrpId] != null) { if (chartDataObj[item.eqpmGrpId] != null) {
// chartDataObj[item.eqpmGrpId].push(item); chartDataObj[item.eqpmGrpId].push(item);
// } else { } else {
// chartDataObj[item.eqpmGrpId] = [item]; chartDataObj[item.eqpmGrpId] = [item];
// } }
// }); });
chartDataObj = {
group1: [
{ fabNm: "Fab A", okCnt: 120, ngCnt: 30 },
{ fabNm: "Fab B", okCnt: 150, ngCnt: 20 },
{ fabNm: "Fab C", okCnt: 100, ngCnt: 50 },
],
group2: [
{ fabNm: "Fab D", okCnt: 180, ngCnt: 10 },
{ fabNm: "Fab E", okCnt: 160, ngCnt: 25 },
{ fabNm: "Fab F", okCnt: 140, ngCnt: 35 },
],
};
// chartDataObj.keys()[0] // chartDataObj.keys()[0]
var i = 0; var i = 0;
for (var x of Object.keys(chartDataObj)) { for (var x of Object.keys(chartDataObj)) {
this.loadChartList.push(false); this.loadChartList.push(false);
i++; i++;
this.objList["chart_0" + i] = chartDataObj[x]; this.objList['chart_0' + i] = chartDataObj[x];
this.chartNameList.push("chart_0" + i); this.chartNameList.push('chart_0' + i);
this.setPageData({ this.setPageData({
[this.chartNameList[i - 1]]: Utility.defaultChartOption(true), [this.chartNameList[i - 1]]: Utility.defaultChartOption(true),
}); });
this.setChartData(chartDataObj[x], i); this.setChartData(chartDataObj[x], i);
} }
// this.setChartData(chartDataObj[Object.keys(chartDataObj)[0]]); // this.setChartData(chartDataObj[Object.keys(chartDataObj)[0]]);

View File

@ -266,8 +266,8 @@ export default {
}, },
created() { }, created() { },
async mounted() { async mounted() {
console.log('----DEBUG---'); // console.log('----DEBUG---');
await this.initTest(); // await this.initTest();
// End Debug Test--- // End Debug Test---
await this.init(); await this.init();
this.initedFlag = true; this.initedFlag = true;

View File

@ -103,7 +103,6 @@
<component <component
:ref="gridName" :ref="gridName"
class="tagTrndGrid" class="tagTrndGrid"
v-if="loadGrid"
:is="loadGrid ? 'Grid' : null" :is="loadGrid ? 'Grid' : null"
:gridName="gridName" :gridName="gridName"
:parentPrgmId="myPrgmId" :parentPrgmId="myPrgmId"
@ -330,7 +329,6 @@ export default {
} else { } else {
this.dumyChartFg = false; this.dumyChartFg = false;
} }
this.dumyChartFg = true;
if (this.initedFlag && this.tagList.length > 0) { if (this.initedFlag && this.tagList.length > 0) {
this.search(); this.search();
} }
@ -409,12 +407,12 @@ export default {
getAddInfoList: "modules/search/getAddInfoList", getAddInfoList: "modules/search/getAddInfoList",
}), }),
async init() { async init() {
await this.setPageData({ this.setPageData({
rowGridSelectKey: 0, rowGridSelectKey: 0,
rowGridSelectData: null, rowGridSelectData: null,
}); });
await this.gridInit(); this.gridInit();
this.setChartNull2(); this.setChartNull();
}, },
async search() { async search() {
// search가 2번 타는 경우: // search가 2번 타는 경우:
@ -513,12 +511,6 @@ export default {
gridKey: this.gridName, gridKey: this.gridName,
value: myColumns, value: myColumns,
}); });
this.setGridData({
gridKey: this.gridName,
value: newRes,
});
this.loadGrid = true; this.loadGrid = true;
}, },
getRowData(data) { getRowData(data) {
@ -530,6 +522,7 @@ export default {
async btnActions(action) { async btnActions(action) {
switch (action) { switch (action) {
case "add" /* */: case "add" /* */:
console.log('aa:',this.tagList);
// if(this.pageData.totalSelectedTags.split('/*wq2a/').length>5){ // if(this.pageData.totalSelectedTags.split('/*wq2a/').length>5){
if (this.tagList.length >= 5) { if (this.tagList.length >= 5) {
alert("TAG는 최대 5개까지 선택 가능합니다."); alert("TAG는 최대 5개까지 선택 가능합니다.");
@ -1216,40 +1209,8 @@ const defaultData = {
rowGridSelectData: null, rowGridSelectData: null,
/* Griddata 세팅 */ /* Griddata 세팅 */
rowGrid: { rowGrid: {
data: [ data: [],
{ column: [],
eqpmGrpNm: "냉동기고온",
eqpmGrpId: "UT_HT_CH201",
eqpmId: "UT_HT_CH201",
eqpmNm: "UT_HT_CH201",
tagId: "ICHEON.HVAC.EQP_HT_CH004.UT_HT_CH201.CHI_AMP_1A_PV",
tagNm: "ICHEON 고온 냉동기 201호기 - 회로1 전류A",
// rowStat: "I",
},
{
eqpmGrpNm: "냉동기고온",
eqpmGrpId: "UT_HT_CH201",
eqpmId: "UT_HT_CH201",
eqpmNm: "UT_HT_CH201",
tagId: "ICHEON.HVAC.EQP_HT_CH004.UT_HT_CH201.CHI_AMP_1A_PV",
tagNm: "ICHEON 고온 냉동기 201호기 - 회로1 전류A",
// rowStat: "I",
},
],
column: [
{ header: "설비그룹", name: "eqpmGrpNm", align: "left", width: 150 },
{
header: "설비그룹 ID",
name: "eqpmGrpId",
align: "center",
hidden: true,
},
{ header: "설비ID", name: "eqpmId", align: "left", width: 200 },
{ header: "설비명", name: "eqpmNm", align: "left", width: 200 },
{ header: "TAG ID", name: "tagId", align: "left", width: 500 },
{ header: "TAG 명", name: "tagNm", align: "left" },
// { header: "rowStat", name: "rowStat", align: "center", hidden: true },
],
option: {}, option: {},
defaultRow: { defaultRow: {
eqpmGrpNm: null, eqpmGrpNm: null,

View File

@ -275,11 +275,11 @@ export default {
} }
} }
.v-btn { .v-btn {
@if $theme == dark { // @if $theme == dark {
background-color: #18579e; // background-color: #18579e;
} @else { // } @else {
background-color: #3f4d7d; // background-color: #3f4d7d;
} // }
} }
} }
} }