Compare commits
7 Commits
dev-dungtv
...
dev-nghian
Author | SHA1 | Date | |
---|---|---|---|
bbaf26af86 | |||
aec9353ab2 | |||
2dd0c6a72c | |||
631637a8e1 | |||
3ff87852e5 | |||
117e0adeb9 | |||
d45d141c3c |
@ -92,9 +92,12 @@
|
||||
background: map-deep-get($config, #{$theme}, "basic-button-background");
|
||||
}
|
||||
|
||||
.searchFilter{
|
||||
.search-button {
|
||||
height: 40px;
|
||||
color: map-deep-get($config, #{$theme}, "search-btn-color");
|
||||
}
|
||||
}
|
||||
|
||||
.v-dialog {
|
||||
.ant-btn-icon-only {
|
||||
|
@ -98,6 +98,17 @@
|
||||
@include theme($theme);
|
||||
|
||||
.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 {
|
||||
&-table {
|
||||
border: 1px solid;
|
||||
|
@ -102,6 +102,7 @@ $config: (
|
||||
v-calendar-day-color: #fff,
|
||||
v-calendar-day-in-not-month-color: rgba(255, 255, 255, 0.05),
|
||||
v-calendar-is-today-background-color: #2d4571,
|
||||
tui-grid-title-color: #FFFFFFD9,
|
||||
tui-grid-header-backgroundColor: #2a2b2d,
|
||||
tui-grid-header-color: #FFFFFFD9,
|
||||
tui-grid-border-horziontal-color: #212224,
|
||||
@ -238,6 +239,7 @@ $config: (
|
||||
v-calendar-day-color: #111,
|
||||
v-calendar-day-in-not-month-color: #f8f8f8,
|
||||
v-calendar-is-today-background-color: #e3eaf3,
|
||||
tui-grid-title-color: #000000E0,
|
||||
tui-grid-header-backgroundColor: #fafafa, //#e0e0e0,
|
||||
tui-grid-header-color: rgba(0, 0, 0, 0.88),
|
||||
tui-grid-border-horziontal-color: #e0e0e0,
|
||||
|
@ -1,5 +1,5 @@
|
||||
// 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
|
||||
? [
|
||||
[0.375, '#49AA19'], // Dark Green
|
||||
|
@ -2,7 +2,7 @@
|
||||
export default function getLineChartOption({
|
||||
xAxisData = [],
|
||||
seriesData = [],
|
||||
legendData = [],
|
||||
// legendData = [],
|
||||
isDarkMode = false,
|
||||
}) {
|
||||
|
||||
@ -31,7 +31,7 @@ export default function getLineChartOption({
|
||||
},
|
||||
|
||||
legend: {
|
||||
data: legendData,
|
||||
// data: legendData,
|
||||
icon: 'circle',
|
||||
top: '0%',
|
||||
right: '5%',
|
||||
|
@ -71,14 +71,12 @@
|
||||
</div>
|
||||
</div>
|
||||
<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> -->
|
||||
<!-- <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)"
|
||||
|
||||
<a-button :ripple="false" @click="dialogOpenCloseEvent(dialog)"
|
||||
class="mr-2">닫기</a-button>
|
||||
<a-button v-if="item.closeBtnFg || false" :ripple="false" icon="delete" type="danger" ghost danger
|
||||
@click="deleteBtnAction($event)">삭제</a-button>
|
||||
<a-button v-if="item.closeBtnFg || false" :ripple="false" type="danger" ghost danger
|
||||
@click="deleteBtnAction($event)" class="mr-2">삭제</a-button>
|
||||
<a-button :ripple="false" type="primary" @click="setUpdate($event)" >확인</a-button>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
@ -298,46 +296,46 @@ export default {
|
||||
},
|
||||
async setSelectValueList01() {
|
||||
// form으로 popup 사용할 때 인자로 eqpmKindId, eqpmGrpId 보내줘야한다.
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: 'selectEqpmGrpCodeList',
|
||||
// resKey: 'eqpmGrpCodeLists',
|
||||
// sendParam: {
|
||||
// eqpmKindId:
|
||||
// this.item.eqpmKindId != undefined
|
||||
// ? this.item.eqpmKindId
|
||||
// : this.searchParam.eqpmKindId,
|
||||
// },
|
||||
// // form을 통해 popup을 사용할 경우 -> this.item.eqpmKindId 사용
|
||||
// // 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다.
|
||||
// });
|
||||
// if (res.length > 0) {
|
||||
// this.selectValueList01 = await res.map(obj => {
|
||||
// return {
|
||||
// text: obj.eqpmGrpNm,
|
||||
// value: obj.eqpmGrpId,
|
||||
// };
|
||||
// });
|
||||
// // form을 통해 popup을 사용할 경우 -> this.item.eqpmGrpId 사용
|
||||
// // 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택
|
||||
// // console.log('this.item.eqpmGrpId : ', this.item.eqpmGrpId);
|
||||
// // console.log('this.searchParam.eqpmGrpId : ', this.searchParam.eqpmGrpId);
|
||||
// this.selectValue01 =
|
||||
// this.item.eqpmGrpId != undefined
|
||||
// ? this.item.eqpmGrpId
|
||||
// : this.searchParam.eqpmGrpId != undefined
|
||||
// ? this.searchParam.eqpmGrpId
|
||||
// : this.selectValueList01[0].value;
|
||||
// } else {
|
||||
// this.selectValueList01 = [];
|
||||
// this.selectValue01 = null;
|
||||
// }
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmGrpCodeList',
|
||||
resKey: 'eqpmGrpCodeLists',
|
||||
sendParam: {
|
||||
eqpmKindId:
|
||||
this.item.eqpmKindId != undefined
|
||||
? this.item.eqpmKindId
|
||||
: this.searchParam.eqpmKindId,
|
||||
},
|
||||
// form을 통해 popup을 사용할 경우 -> this.item.eqpmKindId 사용
|
||||
// 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다.
|
||||
});
|
||||
if (res.length > 0) {
|
||||
this.selectValueList01 = await res.map(obj => {
|
||||
return {
|
||||
text: obj.eqpmGrpNm,
|
||||
value: obj.eqpmGrpId,
|
||||
};
|
||||
});
|
||||
// form을 통해 popup을 사용할 경우 -> this.item.eqpmGrpId 사용
|
||||
// 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택
|
||||
// console.log('this.item.eqpmGrpId : ', this.item.eqpmGrpId);
|
||||
// console.log('this.searchParam.eqpmGrpId : ', this.searchParam.eqpmGrpId);
|
||||
this.selectValue01 =
|
||||
this.item.eqpmGrpId != undefined
|
||||
? this.item.eqpmGrpId
|
||||
: this.searchParam.eqpmGrpId != undefined
|
||||
? this.searchParam.eqpmGrpId
|
||||
: this.selectValueList01[0].value;
|
||||
} else {
|
||||
this.selectValueList01 = [];
|
||||
this.selectValue01 = null;
|
||||
}
|
||||
|
||||
this.selectValueList01 = [
|
||||
{ label: '냉동기고온', value: '냉동기고온' },
|
||||
{ label: '냉동기저온', value: '냉동기저온' },
|
||||
{ label: '공조기', value: '공조기' },
|
||||
{ label: '보일러', value: '보일러' }
|
||||
];
|
||||
// this.selectValueList01 = [
|
||||
// { label: '냉동기고온', value: '냉동기고온' },
|
||||
// { label: '냉동기저온', value: '냉동기저온' },
|
||||
// { label: '공조기', value: '공조기' },
|
||||
// { label: '보일러', value: '보일러' }
|
||||
// ];
|
||||
},
|
||||
search() {
|
||||
this.getGridData();
|
||||
@ -388,44 +386,35 @@ export default {
|
||||
this.loadGrid = false;
|
||||
|
||||
let res = [];
|
||||
// res = await this.postApiReturn({
|
||||
// apiKey: 'selectEgrpPysclQtyPop',
|
||||
// resKey: 'egrpPysclQtyData',
|
||||
// sendParam: {
|
||||
// searchWord: this.searchWord,
|
||||
// eqpmGrpId: this.selectValue01,
|
||||
// openMode: this.item.openMode,
|
||||
// },
|
||||
// });
|
||||
// let newRes = [];
|
||||
// let tempTagList = this.pyscPopVal.split('/*wq2a/');
|
||||
// let tagList = tempTagList.filter(item => item != '');
|
||||
// if (tagList.length > 0) {
|
||||
// newRes = res.filter(item => {
|
||||
// return !tagList.includes(item.pysclQtyId);
|
||||
// });
|
||||
// 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'
|
||||
|
||||
res = await this.postApiReturn({
|
||||
apiKey: 'selectEgrpPysclQtyPop',
|
||||
resKey: 'egrpPysclQtyData',
|
||||
sendParam: {
|
||||
searchWord: this.searchWord,
|
||||
eqpmGrpId: this.selectValue01,
|
||||
openMode: this.item.openMode,
|
||||
},
|
||||
});
|
||||
let newRes = [];
|
||||
let tempTagList = this.pyscPopVal.split('/*wq2a/');
|
||||
let tagList = tempTagList.filter(item => item != '');
|
||||
if (tagList.length > 0) {
|
||||
newRes = res.filter(item => {
|
||||
return !tagList.includes(item.pysclQtyId);
|
||||
});
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
this.setModalGridData({
|
||||
modalKey: this.myModalKey,
|
||||
gridKey: this.grid_01,
|
||||
|
@ -2,12 +2,8 @@
|
||||
<v-row class="search-box" align="center">
|
||||
<v-col :cols="option.labelCols" class="py-0">
|
||||
<label for="" class="search-box-label">
|
||||
<v-icon
|
||||
v-if="item.iconShow"
|
||||
small
|
||||
:class="['mr-1', item.required ? 'icon-orange' : 'icon-blue']"
|
||||
>$icoBulletPoint</v-icon
|
||||
>
|
||||
<v-icon v-if="item.iconShow" small
|
||||
:class="['mr-1', item.required ? 'icon-orange' : 'icon-blue']">$icoBulletPoint</v-icon>
|
||||
{{ option.labelContent }}
|
||||
</label>
|
||||
</v-col>
|
||||
@ -30,9 +26,9 @@
|
||||
<div class="pa-6 pt-0">
|
||||
<v-row align="center">
|
||||
<v-col :cols="5">
|
||||
<component :is="'SelectBox'" ref="SelectBox1" :labelCols="12" :textCols="12" :iconShow="true"
|
||||
:propsValue="selectValue01" :itemList="selectValueList01" :label="'설비그룹'"
|
||||
@update:propsValue="selectValue01 = $event" :readonly="item.openMode == undefined
|
||||
<component :is="'SelectBox'" ref="SelectBox1" :labelCols="12" :textCols="12"
|
||||
:iconShow="true" :propsValue="selectValue01" :itemList="selectValueList01"
|
||||
:label="'설비그룹'" @update:propsValue="selectValue01 = $event" :readonly="item.openMode == undefined
|
||||
? openMode
|
||||
: item.openMode == 'ALL'
|
||||
? false
|
||||
@ -47,9 +43,9 @@
|
||||
물리량명
|
||||
</label>
|
||||
</v-col>
|
||||
<v-col :cols="9"> <v-text-field append-icon="" class="v-input__custom"
|
||||
outlined :hide-details="true" v-model="searchWord"
|
||||
@keyup.enter="search"><template v-slot:append>
|
||||
<v-col :cols="9"> <v-text-field append-icon="" class="v-input__custom" outlined
|
||||
:hide-details="true" v-model="searchWord" @keyup.enter="search"><template
|
||||
v-slot:append>
|
||||
<!-- Custom SVG icon -->
|
||||
<v-icon>$icoSearch</v-icon>
|
||||
|
||||
@ -76,9 +72,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<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" type="primary" @click="dialogOpenCloseEvent(dialog)"
|
||||
class="mr-2">닫기</a-button>
|
||||
<a-button :ripple="false" @click="dialogOpenCloseEvent(dialog)" class="mr-2">닫기</a-button>
|
||||
<a-button :ripple="false" type="primary" @click="setUpdate($event)">확인</a-button>
|
||||
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
@ -274,36 +270,30 @@ export default {
|
||||
this.gridInit();
|
||||
},
|
||||
async setSelectValueList01() {
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: 'selectEqpmGrpCodeList',
|
||||
// resKey: 'eqpmGrpCodeLists',
|
||||
// sendParam: { eqpmKindId: this.searchParam.eqpmKindId },
|
||||
// // 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다.
|
||||
// });
|
||||
// if (res.length > 0) {
|
||||
// this.selectValueList01 = await res.map(obj => {
|
||||
// return {
|
||||
// text: obj.eqpmGrpNm,
|
||||
// value: obj.eqpmGrpId,
|
||||
// };
|
||||
// });
|
||||
// // 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택
|
||||
// this.selectValue01 =
|
||||
// this.searchParam.eqpmGrpId != undefined
|
||||
// ? this.searchParam.eqpmGrpId
|
||||
// : this.selectValueList01[0].value;
|
||||
// // this.selectValue01 = this.selectValueList01[0].value;
|
||||
// } else {
|
||||
// this.selectValueList01 = [];
|
||||
// this.selectValue01 = null;
|
||||
// }
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmGrpCodeList',
|
||||
resKey: 'eqpmGrpCodeLists',
|
||||
sendParam: { eqpmKindId: this.searchParam.eqpmKindId },
|
||||
// 부모 페이지에서 설비종류인 eqpmKindId 값을 꼭 가져와야한다.
|
||||
});
|
||||
if (res.length > 0) {
|
||||
this.selectValueList01 = await res.map(obj => {
|
||||
return {
|
||||
text: obj.eqpmGrpNm,
|
||||
value: obj.eqpmGrpId,
|
||||
};
|
||||
});
|
||||
// 부모 페이지에서 설비그룹을 선택한 값이 있다면(eqpmGrpId) 그 값으로 바인딩 아닐 경우 조회한 데이터의 첫번째 값으로 선택
|
||||
this.selectValue01 =
|
||||
this.searchParam.eqpmGrpId != undefined
|
||||
? this.searchParam.eqpmGrpId
|
||||
: this.selectValueList01[0].value;
|
||||
// this.selectValue01 = this.selectValueList01[0].value;
|
||||
} else {
|
||||
this.selectValueList01 = [];
|
||||
this.selectValue01 = null;
|
||||
}
|
||||
|
||||
this.selectValueList01 = [
|
||||
{ label: '냉동기고온', value: '냉동기고온' },
|
||||
{ label: '냉동기저온', value: '냉동기저온' },
|
||||
{ label: '공조기', value: '공조기' },
|
||||
{ label: '보일러', value: '보일러' }
|
||||
];
|
||||
},
|
||||
search() {
|
||||
this.getGridData();
|
||||
@ -341,33 +331,25 @@ export default {
|
||||
},
|
||||
async getGridData() {
|
||||
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({
|
||||
modalKey: this.myModalKey,
|
||||
@ -441,9 +423,9 @@ export default {
|
||||
// this.dialog = false;
|
||||
// return;
|
||||
// }
|
||||
// if (this.myBindingData.length <= 0) {
|
||||
// return alert('설비상세 리스트를 먼저 선택해주세요.');
|
||||
// }
|
||||
if (this.myBindingData.length <= 0) {
|
||||
return alert('설비상세 리스트를 먼저 선택해주세요.');
|
||||
}
|
||||
this.dialog = !val;
|
||||
},
|
||||
},
|
||||
|
@ -36,7 +36,7 @@
|
||||
계산설명
|
||||
</label>
|
||||
</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
|
||||
:hide-details="true" v-model="searchWord" @keyup.enter="search"><template v-slot:append>
|
||||
<!-- Custom SVG icon -->
|
||||
@ -45,7 +45,7 @@
|
||||
|
||||
</template></v-text-field>
|
||||
</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>
|
||||
<!-- <v-btn :ripple="false" @click="initSearch()">
|
||||
초기화
|
||||
@ -63,10 +63,8 @@
|
||||
</div>
|
||||
</div>
|
||||
<v-card-actions class="pa-5 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="setUpdate($event)" class="mr-2">확인</a-button>
|
||||
<a-button :ripple="false" type="primary" @click="dialogOpenCloseEvent(dialog)">닫기</a-button>
|
||||
<a-button :ripple="false" @click="dialogOpenCloseEvent(dialog)" class="mr-2">닫기</a-button>
|
||||
<a-button :ripple="false" type="primary" @click="setUpdate($event)" >확인</a-button>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
@ -306,38 +304,22 @@ export default {
|
||||
},
|
||||
async getGridData() {
|
||||
this.loadGrid = false;
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: 'selectEqpmCalcPop',
|
||||
// resKey: 'eqpmCalcPopData',
|
||||
// sendParam: {
|
||||
// calcDescLike: this.searchWord,
|
||||
// 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': '두개 변수에 대한 평균'
|
||||
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmCalcPop',
|
||||
resKey: 'eqpmCalcPopData',
|
||||
sendParam: {
|
||||
calcDescLike: this.searchWord,
|
||||
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;
|
||||
}
|
||||
|
||||
{ '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({
|
||||
modalKey: this.myModalKey,
|
||||
gridKey: this.grid_01,
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="pb-5 h100">
|
||||
<div class="d-flex align-center justify-space-between">
|
||||
<span class="text-h6">공통그룹코드</span>
|
||||
<span class="grid-title">공통그룹코드</span>
|
||||
<div>
|
||||
<Buttons
|
||||
:parentPrgmId="parentPrgmId"
|
||||
@ -126,7 +126,7 @@ export default {
|
||||
{
|
||||
header: '사용여부',
|
||||
name: 'useFg',
|
||||
align: 'center',
|
||||
align: 'left',
|
||||
formatter({ value }) {
|
||||
const newValue = _this.pageData.useFgList.filter(
|
||||
item => item.commCd == value,
|
||||
|
@ -271,63 +271,6 @@ export default {
|
||||
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;
|
||||
},
|
||||
async btnActions(action) {
|
||||
|
@ -1,33 +1,65 @@
|
||||
<template>
|
||||
<div class="l-layout">
|
||||
<PageTitle text="공통코드" />
|
||||
<v-row ref="searchFilter">
|
||||
<v-col :cols="12">
|
||||
<v-card class="searchFilter">
|
||||
<v-row align="center" no-gutters>
|
||||
<v-col :cols="4">
|
||||
<v-col :cols="3">
|
||||
<component
|
||||
:is="'selectCodeList'"
|
||||
:parentPrgmId="myPrgmId"
|
||||
:label="'시스템구분'"
|
||||
dataKey="sysDivCd"
|
||||
:labelCols="12"
|
||||
:textCols="12"
|
||||
:sendParam="{ commGrpCd: 'CO_SYSDIV', useFg: '1' }"
|
||||
:addAll="true"
|
||||
customClass="select-large"
|
||||
/>
|
||||
</v-col>
|
||||
<v-col :cols="4">
|
||||
<v-col :cols="3">
|
||||
<component
|
||||
:is="'selectCodeList'"
|
||||
:parentPrgmId="myPrgmId"
|
||||
:label="'사용여부'"
|
||||
:labelCols="12"
|
||||
:textCols="12"
|
||||
:dataKey="'useFg'"
|
||||
customClass="select-large"
|
||||
:sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }"
|
||||
/>
|
||||
</v-col>
|
||||
<v-col :cols="4" class="text-right">
|
||||
<BtnSearch @click="search" />
|
||||
<v-col :cols="3">
|
||||
<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-row>
|
||||
<v-row align="center" no-gutters>
|
||||
<!-- <v-row align="center" no-gutters>
|
||||
<v-col :cols="4">
|
||||
<InputText
|
||||
:parentPrgmId="myPrgmId"
|
||||
@ -48,7 +80,7 @@
|
||||
:textCols="8"
|
||||
/>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-row> -->
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
@ -85,7 +117,7 @@
|
||||
<v-card class="pb-5">
|
||||
<v-card-title>공통그룹코드 상세</v-card-title>
|
||||
<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-for="item in items"
|
||||
:key="item.id"
|
||||
@ -132,6 +164,7 @@ import Form from '~/components/common/form/Form';
|
||||
import CommCdTab from '@/components/pages/comm/CommCdTab';
|
||||
import Grid from '~/components/common/Grid';
|
||||
import Utility from '~/plugins/utility';
|
||||
import PageTitle from "~/components/common/PageTitle";
|
||||
|
||||
let myTitle;
|
||||
let myPrgmId;
|
||||
@ -158,6 +191,7 @@ export default {
|
||||
Form,
|
||||
CommCdTab,
|
||||
Grid,
|
||||
PageTitle
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@ -229,6 +263,9 @@ export default {
|
||||
|
||||
const myOptions = {
|
||||
scrollX: false,
|
||||
header: {
|
||||
height: 38,
|
||||
},
|
||||
};
|
||||
this.setGridOption({
|
||||
gridKey: this.gridName,
|
||||
@ -241,7 +278,7 @@ export default {
|
||||
{
|
||||
header: '시스템구분',
|
||||
name: 'sysDivCd',
|
||||
align: 'center',
|
||||
align: 'left',
|
||||
formatter({ value }) {
|
||||
let commCdNm = '';
|
||||
if (sysCdList.length > 0) {
|
||||
@ -278,7 +315,7 @@ export default {
|
||||
{
|
||||
header: '사용여부',
|
||||
name: 'useFg',
|
||||
align: 'center',
|
||||
align: 'left',
|
||||
formatter({ value }) {
|
||||
const newValue = _this.pageData.useFgList.filter(
|
||||
item => item.commCd == value,
|
||||
@ -554,7 +591,10 @@ const myDetail = [
|
||||
valueNm: 'commGrpCd',
|
||||
disabled: true,
|
||||
cols: 6,
|
||||
class: 'py-2',
|
||||
labelCols: 12,
|
||||
textCols: 12,
|
||||
iconShow: true,
|
||||
class: 'py-2 pr-2',
|
||||
required: true,
|
||||
},
|
||||
{
|
||||
@ -563,7 +603,10 @@ const myDetail = [
|
||||
valueNm: 'commGrpNm',
|
||||
disabled: false,
|
||||
cols: 6,
|
||||
class: 'py-2',
|
||||
labelCols: 12,
|
||||
textCols: 12,
|
||||
iconShow: true,
|
||||
class: 'py-2 pl-2',
|
||||
required: true,
|
||||
},
|
||||
{
|
||||
@ -572,7 +615,10 @@ const myDetail = [
|
||||
valueNm: 'sysDivCd',
|
||||
disabled: false,
|
||||
cols: 6,
|
||||
class: 'py-2',
|
||||
labelCols: 12,
|
||||
textCols: 12,
|
||||
iconShow: true,
|
||||
class: 'py-2 pr-2 mt-3',
|
||||
list: 'sysDivCdList',
|
||||
itemText: 'commCdNm',
|
||||
itemValue: 'commCd',
|
||||
@ -584,7 +630,10 @@ const myDetail = [
|
||||
valueNm: 'useFg',
|
||||
disabled: false,
|
||||
cols: 6,
|
||||
class: 'py-2',
|
||||
labelCols: 12,
|
||||
textCols: 12,
|
||||
iconShow: true,
|
||||
class: 'py-2 pl-2 mt-10',
|
||||
value: { '1': true, '0': false },
|
||||
required: true,
|
||||
},
|
||||
@ -594,7 +643,10 @@ const myDetail = [
|
||||
valueNm: 'rmrk',
|
||||
disabled: false,
|
||||
cols: 6,
|
||||
class: 'py-2',
|
||||
labelCols: 12,
|
||||
textCols: 12,
|
||||
iconShow: true,
|
||||
class: 'py-2 pr-2 mt-3',
|
||||
},
|
||||
];
|
||||
</script>
|
||||
|
@ -344,7 +344,7 @@
|
||||
<v-row>
|
||||
<v-col cols="auto" style="text-align: left">
|
||||
<!-- <p class="textInfo">{{ ngDtlCnt }}</p> -->
|
||||
<p class="card-text-info">200</p>
|
||||
<p class="card-text-info">{{ ngDtlCnt }}</p>
|
||||
</v-col>
|
||||
<v-col :cols="3" style="text-align: left"> 건 </v-col>
|
||||
</v-row>
|
||||
@ -369,7 +369,7 @@
|
||||
<v-row>
|
||||
<v-col cols="auto" style="text-align: left">
|
||||
<!-- <p class="textInfo">{{ ngDtlSolvCnt }}</p> -->
|
||||
<p class="card-text-info">100</p>
|
||||
<p class="card-text-info">{{ ngDtlSolvCnt }}</p>
|
||||
</v-col>
|
||||
<v-col :cols="3" style="text-align: left"> 건 </v-col>
|
||||
</v-row>
|
||||
@ -580,11 +580,7 @@ export default {
|
||||
Chart,
|
||||
UnusedStatPopPage,
|
||||
EtcStatPopPage,
|
||||
BtnSearch,
|
||||
AntCard,
|
||||
CheckBox,
|
||||
RadioStandard,
|
||||
PageTitle,
|
||||
PageTitle
|
||||
},
|
||||
computed: {
|
||||
...mapState({
|
||||
@ -607,7 +603,6 @@ export default {
|
||||
// let chartOption = this.getGuageChartOption2(this.chart_01);
|
||||
let chartOption = getGaugeChartOption({
|
||||
title: this.chart_01,
|
||||
value: 75,
|
||||
isDarkMode: this.isDarkMode,
|
||||
});
|
||||
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 = getGaugeChartOption({
|
||||
title: this.chart_03,
|
||||
value: 75,
|
||||
isDarkMode: this.isDarkMode,
|
||||
});
|
||||
chartOption3["series"][0]["data"][0].value = this.$store.state.pageData[myPrgmId][
|
||||
@ -719,13 +713,9 @@ export default {
|
||||
// this.search();
|
||||
await this.gridInit();
|
||||
await new Promise((resolve) => setTimeout(resolve, 1500));
|
||||
|
||||
await this.getTodayEfficiencyStatus();
|
||||
await this.getEnrgAndCO2Data();
|
||||
await this.getGridData();
|
||||
|
||||
if (this.$router.currentRoute.fullPath == this.myHome.root) {
|
||||
this.dtToday = Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm");
|
||||
|
||||
await this.getEnrgAndCO2Data();
|
||||
await this.getCompareEqpmTotData();
|
||||
await this.getTodayEfficiencyStatus();
|
||||
@ -755,9 +745,7 @@ export default {
|
||||
if (this.$refs.gridParent != undefined) {
|
||||
// gridHeight = gridHeight*0.9
|
||||
gridHeight = this.$refs.gridParent.offsetHeight - 35;
|
||||
// console.log("gridHeight : ", gridHeight);
|
||||
}
|
||||
|
||||
const myOptions = {
|
||||
// scrollX: false,
|
||||
setScroll: true,
|
||||
@ -770,12 +758,10 @@ export default {
|
||||
height: 38,
|
||||
},
|
||||
};
|
||||
|
||||
this.setGridOption({
|
||||
gridKey: this.gridName,
|
||||
value: Object.assign(Utility.defaultGridOption(gridHeight), myOptions),
|
||||
});
|
||||
|
||||
let hhMapper = {
|
||||
"00": "00~01",
|
||||
"01": "01~02",
|
||||
@ -807,7 +793,7 @@ export default {
|
||||
header: "NO",
|
||||
name: "rowNum",
|
||||
width: 70,
|
||||
align: "right",
|
||||
align: "center",
|
||||
// hidden: true,
|
||||
},
|
||||
{
|
||||
@ -855,98 +841,99 @@ export default {
|
||||
});
|
||||
|
||||
this.loadGrid = true;
|
||||
this.isGridLoading = false;
|
||||
|
||||
// this.getGridData();
|
||||
},
|
||||
async getGridData() {
|
||||
this.loadGrid = false;
|
||||
// console
|
||||
// const res = await this.postApiReturn({
|
||||
// apiKey: 'selectIssueGdIdxData',
|
||||
// resKey: 'issueGdIdxData',
|
||||
// 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,
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: "selectIssueGdIdxData",
|
||||
resKey: "issueGdIdxData",
|
||||
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: res,
|
||||
// value: fakeData,
|
||||
// });
|
||||
|
||||
this.setGridData({
|
||||
gridKey: this.gridName,
|
||||
value: res,
|
||||
});
|
||||
|
||||
this.loadGrid = true;
|
||||
},
|
||||
async getEnrgAndCO2Data() {
|
||||
this.loadChart_01 = false;
|
||||
const res = [];
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: "selectEnrgAndCO2Data",
|
||||
resKey: "enrgAndCO2Data",
|
||||
sendParam: {},
|
||||
});
|
||||
// //////////////////////////////////////////
|
||||
// // 시연용 data 세팅
|
||||
res[0] = {};
|
||||
res[0]["dayVal"] = 18.0;
|
||||
res[0]["mnthVal"] = 507.0;
|
||||
res[0]["planVal"] = 653.0;
|
||||
res[0]["co2DayVal"] = 9.0;
|
||||
res[0]["co2MnthVal"] = 238.0;
|
||||
res[0]["co2PlanVal"] = 307.0;
|
||||
res[0]["co2YearVal"] = 1224.0;
|
||||
res[0]["effcRt"] = 77.59;
|
||||
// res[0]['dayVal'] = 18.0;
|
||||
// res[0]['mnthVal'] = 507.0;
|
||||
// res[0]['planVal'] = 653.0;
|
||||
// res[0]['co2DayVal'] = 9.0;
|
||||
// res[0]['co2MnthVal'] = 238.0;
|
||||
// res[0]['co2PlanVal'] = 307.0;
|
||||
// res[0]['co2YearVal'] = 1224.0;
|
||||
// res[0]['effcRt'] = 77.59;
|
||||
// //////////////////////////////////////////
|
||||
// 대시보드 표기
|
||||
|
||||
this.enrgUsageDayVal = this.numberFormatter(
|
||||
parseFloat(res[0]["dayVal"]).toFixed(0)
|
||||
);
|
||||
@ -964,20 +951,16 @@ export default {
|
||||
parseFloat(res[0]["co2BefMnthVal"]).toFixed(0)
|
||||
);
|
||||
this.CO2YearVal = this.numberFormatter(parseFloat(res[0]["co2YearVal"]).toFixed(0));
|
||||
|
||||
this.$nextTick(() => {
|
||||
let chartOption = null;
|
||||
// chartOption = this.getGuageChartOption2(this.chart_01);
|
||||
chartOption = getGaugeChartOption({
|
||||
title: "Energy Usage",
|
||||
value: 75,
|
||||
isDarkMode: this.isDarkMode,
|
||||
});
|
||||
console.log("charto:", chartOption);
|
||||
chartOption["series"][0]["data"][0].value =
|
||||
res[0]["effcRt"] != null ? res[0]["effcRt"] : 0;
|
||||
this.$store.state.pageData[myPrgmId][this.chart_01] = chartOption;
|
||||
console.log("gauge chart ops:", chartOption);
|
||||
// if(res[0]['effcRt'] == undefined || res[0]['effcRt'] == null){
|
||||
// res[0]['effcRt'] = null;
|
||||
// }
|
||||
@ -993,12 +976,11 @@ export default {
|
||||
},
|
||||
async getCompareEqpmTotData() {
|
||||
this.loadChart_02 = false;
|
||||
// const res = await this.postApiReturn({
|
||||
// apiKey: "selectCompareEqpmTotData",
|
||||
// resKey: "compareEqpmTotData",
|
||||
// sendParam: {},
|
||||
// });
|
||||
const res = "abc";
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: "selectCompareEqpmTotData",
|
||||
resKey: "compareEqpmTotData",
|
||||
sendParam: {},
|
||||
});
|
||||
this.$nextTick(() => {
|
||||
this.setChart02Data(res);
|
||||
});
|
||||
@ -1007,25 +989,24 @@ export default {
|
||||
},
|
||||
async getTodayEfficiencyStatus() {
|
||||
this.loadChart_03 = false;
|
||||
// const res = await this.postApiReturn({
|
||||
// apiKey: 'selectTodayEfficiencyStatus',
|
||||
// resKey: 'todayEfficiencyStatus',
|
||||
// sendParam: {},
|
||||
// });
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: "selectTodayEfficiencyStatus",
|
||||
resKey: "todayEfficiencyStatus",
|
||||
sendParam: {},
|
||||
});
|
||||
|
||||
// 대시보드 표기
|
||||
// this.ngDtlCnt = this.numberFormatter(res[0]['ngDtlCnt']);
|
||||
// this.ngDtlSolvCnt = this.numberFormatter(res[0]['ngDtlSolvCnt']);
|
||||
// let effcRt = this.numberFormatter(
|
||||
// (res[0]['ngDtlSolvCnt'] / res[0]['ngDtlCnt']) * 100,
|
||||
// );
|
||||
let effcRt = this.numberFormatter(78.21);
|
||||
this.ngDtlCnt = this.numberFormatter(res[0]["ngDtlCnt"]);
|
||||
this.ngDtlSolvCnt = this.numberFormatter(res[0]["ngDtlSolvCnt"]);
|
||||
let effcRt = this.numberFormatter(
|
||||
(res[0]["ngDtlSolvCnt"] / res[0]["ngDtlCnt"]) * 100
|
||||
);
|
||||
// let effcRt = this.numberFormatter(78.21)
|
||||
this.$nextTick(() => {
|
||||
let chartOption = null;
|
||||
// chartOption = this.getGuageChartOption2(this.chart_03);
|
||||
chartOption = getGaugeChartOption({
|
||||
title: "Today Efficiency",
|
||||
value: 75,
|
||||
isDarkMode: this.isDarkMode,
|
||||
});
|
||||
chartOption["series"][0]["data"][0].value = isNaN(effcRt) ? 0 : effcRt;
|
||||
@ -1037,15 +1018,14 @@ export default {
|
||||
},
|
||||
async getTodayNgTopTen() {
|
||||
this.loadChart_04 = false;
|
||||
// const res = await this.postApiReturn({
|
||||
// apiKey: "selectTodayNgTopTen",
|
||||
// resKey: "todayNgTopTen",
|
||||
// sendParam: {},
|
||||
// });
|
||||
const res = "abc";
|
||||
// this.setPageData({
|
||||
// chart04Data: res,
|
||||
// });
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: "selectTodayNgTopTen",
|
||||
resKey: "todayNgTopTen",
|
||||
sendParam: {},
|
||||
});
|
||||
this.setPageData({
|
||||
chart04Data: res,
|
||||
});
|
||||
this.$nextTick(() => {
|
||||
this.setChart04Data(res);
|
||||
});
|
||||
@ -1054,12 +1034,11 @@ export default {
|
||||
},
|
||||
async getCompareEqpmTGdChart() {
|
||||
this.loadChart_05 = false;
|
||||
// const res = await this.postApiReturn({
|
||||
// apiKey: "selectCompareEqpmTGdChart",
|
||||
// resKey: "compareEqpmTGdChart",
|
||||
// sendParam: {},
|
||||
// });
|
||||
const res = "aaa";
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: "selectCompareEqpmTGdChart",
|
||||
resKey: "compareEqpmTGdChart",
|
||||
sendParam: {},
|
||||
});
|
||||
this.$nextTick(() => {
|
||||
this.setChart05Data(res);
|
||||
});
|
||||
@ -1067,12 +1046,12 @@ export default {
|
||||
this.isLine2Loading = false;
|
||||
},
|
||||
async setChart05Data(data) {
|
||||
// if (this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart != undefined) {
|
||||
// this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart.series = [];
|
||||
// }
|
||||
// if (!data.length) {
|
||||
// return;
|
||||
// }
|
||||
if (this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart != undefined) {
|
||||
this.$store.state.pageData[this.myPrgmId].compareEqpmTGdChart.series = [];
|
||||
}
|
||||
if (!data.length) {
|
||||
return;
|
||||
}
|
||||
let xAxisData = [];
|
||||
let seriesData = [];
|
||||
// let legendData = {
|
||||
@ -1081,7 +1060,7 @@ export default {
|
||||
// dayVal: "금일",
|
||||
// };
|
||||
|
||||
let legendData = ["전전일", "전일", "금일"];
|
||||
// let legendData = ["전전일", "전일", "금일"];
|
||||
|
||||
let befBefValDataList = {
|
||||
name: "전전일",
|
||||
@ -1109,37 +1088,36 @@ export default {
|
||||
};
|
||||
// for (var i = 0; i < data.length; i++) {
|
||||
//////없애야함//////
|
||||
let total = 0;
|
||||
// let total = 0;
|
||||
let hour = Utility.setFormatDate(
|
||||
new Date().setTime(new Date().getTime() - 1 * 60 * 60 * 1000),
|
||||
"HH"
|
||||
);
|
||||
//////없애야함//////
|
||||
for (var i = 0; i < 24; i++) {
|
||||
// if (data[i].tm != undefined) {
|
||||
// xAxisData.push(parseInt(data[i].tm));
|
||||
// } else {
|
||||
// xAxisData.push(i);
|
||||
// }
|
||||
if (data[i].tm != undefined) {
|
||||
xAxisData.push(parseInt(data[i].tm));
|
||||
} else {
|
||||
xAxisData.push(i);
|
||||
}
|
||||
|
||||
// //////없애야함//////
|
||||
let num = parseInt(Math.random() * (13 - 7) + 7);
|
||||
let num2 = parseInt(Math.random() * (11 - 6) + 6);
|
||||
let num3 = parseInt(Math.random() * (10 - 5) + 5);
|
||||
let tempTotal = num + num2 + num3;
|
||||
total += tempTotal;
|
||||
let befBefVal = num;
|
||||
let befVal = num2;
|
||||
let dayVal = num3;
|
||||
// let num = parseInt(Math.random() * (13 - 7) + 7);
|
||||
// let num2 = parseInt(Math.random() * (11 - 6) + 6);
|
||||
// let num3 = parseInt(Math.random() * (10 - 5) + 5);
|
||||
// let tempTotal = num + num2 + num3;
|
||||
// total += tempTotal;
|
||||
// let befBefVal = num;
|
||||
// let befVal = num2;
|
||||
// let dayVal = num3;
|
||||
// //////////////////
|
||||
// let befBefVal = data[i].befBefVal != undefined ? data[i].befBefVal : 0;
|
||||
// let befVal = data[i].befVal != undefined ? data[i].befVal : 0;
|
||||
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;
|
||||
let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0;
|
||||
dayValDataList["data"].push(dayVal);
|
||||
}
|
||||
}
|
||||
@ -1151,7 +1129,7 @@ export default {
|
||||
|
||||
var chartOption = getLineChartOption({
|
||||
xAxisData: xAxisData,
|
||||
legendData: legendData,
|
||||
// legendData: legendData,
|
||||
seriesData: seriesData,
|
||||
isDarkMode: this.isDarkMode,
|
||||
});
|
||||
@ -1186,22 +1164,19 @@ export default {
|
||||
// series: seriesData,
|
||||
// };
|
||||
|
||||
console.log("chart 5 data:", seriesData);
|
||||
await this.$nextTick(() => {});
|
||||
// this.setChartOption({
|
||||
// chartKey: "compareEqpmTGdChart",
|
||||
// value: chartOption,
|
||||
// });
|
||||
|
||||
this.$store.state.pageData[myPrgmId]["compareEqpmTGdChart"] = chartOption;
|
||||
this.setChartOption({
|
||||
chartKey: "compareEqpmTGdChart",
|
||||
value: chartOption,
|
||||
});
|
||||
},
|
||||
async setChart04Data(data) {
|
||||
// if (this.$store.state.pageData[this.myPrgmId].todayNgTopTen != undefined) {
|
||||
// this.$store.state.pageData[this.myPrgmId].todayNgTopTen.series = [];
|
||||
// }
|
||||
// if (!data.length) {
|
||||
// return;
|
||||
// }
|
||||
if (this.$store.state.pageData[this.myPrgmId].todayNgTopTen != undefined) {
|
||||
this.$store.state.pageData[this.myPrgmId].todayNgTopTen.series = [];
|
||||
}
|
||||
if (!data.length) {
|
||||
return;
|
||||
}
|
||||
let seriesData = [
|
||||
{
|
||||
type: "pie",
|
||||
@ -1219,51 +1194,52 @@ export default {
|
||||
},
|
||||
];
|
||||
let pidChartdata = [];
|
||||
// for (var i = 0; i < data.length; i++) {
|
||||
// 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++) {
|
||||
for (var i = 0; i < data.length; i++) {
|
||||
if (data[i].eqpmId != undefined) {
|
||||
pidChartdata.push({
|
||||
// value: data[i]['ngDtlCnt'],
|
||||
value: i + parseInt(Math.random() * (9 - 5) + 5),
|
||||
name: eqpmNmList[i],
|
||||
groupId: eqpmNmList[i],
|
||||
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({
|
||||
// // value: data[i]['ngDtlCnt'],
|
||||
// value: i+parseInt(Math.random()*(9-5)+5),
|
||||
// name: eqpmNmList[i],
|
||||
// groupId: eqpmNmList[i]
|
||||
// });
|
||||
// }
|
||||
seriesData[0]["data"] = [...pidChartdata];
|
||||
var chartOption = {
|
||||
grid: {
|
||||
@ -1293,17 +1269,15 @@ export default {
|
||||
series: seriesData,
|
||||
};
|
||||
await this.$nextTick(() => {});
|
||||
// this.setChartOption({ chartKey: "todayNgTopTen", value: chartOption });
|
||||
this.$store.state.pageData[myPrgmId]["todayNgTopTen"] = chartOption;
|
||||
this.$store.state.pageData[myPrgmId]["chart04Data"] = chartOption;
|
||||
this.setChartOption({ chartKey: "todayNgTopTen", value: chartOption });
|
||||
},
|
||||
async setChart02Data(data) {
|
||||
// if (this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart != undefined) {
|
||||
// this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart.series = [];
|
||||
// }
|
||||
// if (!data.length) {
|
||||
// return;
|
||||
// }
|
||||
if (this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart != undefined) {
|
||||
this.$store.state.pageData[this.myPrgmId].compareEqpmTotChart.series = [];
|
||||
}
|
||||
if (!data.length) {
|
||||
return;
|
||||
}
|
||||
let xAxisData = [];
|
||||
let seriesData = [];
|
||||
// let legendMapper = {
|
||||
@ -1311,7 +1285,6 @@ export default {
|
||||
// 'befVal' : '전일',
|
||||
// 'dayVal' : '금일'
|
||||
// }
|
||||
let legendData = ["전전일", "전일", "금일"];
|
||||
let befBefValDataList = {
|
||||
name: "전전일",
|
||||
type: "line",
|
||||
@ -1336,82 +1309,38 @@ export default {
|
||||
lineStyle: { width: 2 },
|
||||
data: [],
|
||||
};
|
||||
// // for (var i = 0; i < data.length; i++) {
|
||||
// for (var i = 0; i < data.length; i++) {
|
||||
let hour = Utility.setFormatDate(
|
||||
new Date().setTime(new Date().getTime() - 1 * 60 * 60 * 1000),
|
||||
"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++) {
|
||||
if (data[i].tm != undefined) {
|
||||
xAxisData.push(parseInt(data[i].tm));
|
||||
} else {
|
||||
xAxisData.push(i);
|
||||
}
|
||||
//////없애야함//////
|
||||
|
||||
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 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;
|
||||
let dayVal = data[i].dayVal != undefined ? data[i].dayVal : 0;
|
||||
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 = [
|
||||
@ -1433,7 +1362,7 @@ export default {
|
||||
// ];
|
||||
var chartOption = getLineChartOption({
|
||||
xAxisData: xAxisData,
|
||||
legendData: legendData,
|
||||
// legendData: legendData,
|
||||
seriesData: seriesData,
|
||||
isDarkMode: this.isDarkMode,
|
||||
});
|
||||
@ -1468,12 +1397,10 @@ export default {
|
||||
// series: seriesData,
|
||||
// };
|
||||
await this.$nextTick(() => {});
|
||||
this.$store.state.pageData[myPrgmId][this.chart_02] = chartOption;
|
||||
|
||||
// this.setChartOption({
|
||||
// chartKey: "compareEqpmTotChart",
|
||||
// value: chartOption,
|
||||
// });
|
||||
this.setChartOption({
|
||||
chartKey: "compareEqpmTotChart",
|
||||
value: chartOption,
|
||||
});
|
||||
},
|
||||
getGuageChartOption(chartName) {
|
||||
const gaugeColors = [
|
||||
@ -1506,8 +1433,8 @@ export default {
|
||||
splitNumber: 10,
|
||||
itemStyle: {
|
||||
// color: '#FFAB91'
|
||||
// color: 'auto',
|
||||
color: gaugeColors,
|
||||
color: "auto",
|
||||
// color:gaugeColors
|
||||
},
|
||||
progress: {
|
||||
// show: true,
|
||||
@ -1518,8 +1445,8 @@ export default {
|
||||
// show: false
|
||||
show: true,
|
||||
itemStyle: {
|
||||
color: "#FFAB91",
|
||||
// color: 'auto',
|
||||
// color: '#FFAB91',
|
||||
color: "auto",
|
||||
},
|
||||
},
|
||||
axisLine: {
|
||||
@ -1565,140 +1492,12 @@ export default {
|
||||
fontSize: 15,
|
||||
// fontSize: 20,
|
||||
fontWeight: "bolder",
|
||||
formatter: "30%",
|
||||
formatter: "{value} %",
|
||||
color: "auto",
|
||||
},
|
||||
data: [
|
||||
{
|
||||
name: "new",
|
||||
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 (0–60)
|
||||
[0.5, "#FFD700"], // Yellow (60–80)
|
||||
[0.625, "#FFA500"], // Orange (80–100)
|
||||
[1, "#FF4500"], // Red (100–160)
|
||||
],
|
||||
},
|
||||
},
|
||||
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"
|
||||
value: NaN,
|
||||
},
|
||||
],
|
||||
},
|
||||
@ -1847,7 +1646,6 @@ export default {
|
||||
}[state];
|
||||
},
|
||||
chartClickEvent(argData, $event) {
|
||||
// console.log('chartClickEvent', argData);
|
||||
let pageMapper = {
|
||||
dashBoard_enrgUsageGauge: {
|
||||
pageName: "ems-effc-EnrgUseTotSummPage",
|
||||
@ -1909,32 +1707,18 @@ export default {
|
||||
});
|
||||
},
|
||||
topTenChartClickEvent(event) {
|
||||
// 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"
|
||||
];
|
||||
console.log("select equipment", event["data"]["groupId"]);
|
||||
let chartData = this.pageData.chart04Data;
|
||||
// let chartData = this.$store.state.pageData[myPrgmId][this.chart_04]['series'][0]['data']
|
||||
let selectedChartData = chartData.filter((item) => {
|
||||
return item.eqpmId == event["data"]["groupId"];
|
||||
});
|
||||
console.log("chart data", selectedChartData);
|
||||
// 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 = {
|
||||
var data = {
|
||||
cmCycle: "CYC_DAY",
|
||||
fromDt: Utility.setFormatDate(new Date(), "YYYY-MM-DD HH:mm"),
|
||||
fabId: 4555,
|
||||
eqpmKindId: 99988,
|
||||
eqpmGrpId: 88888,
|
||||
eqpmId: 99900,
|
||||
fabId: selectedChartData[0].fabId,
|
||||
eqpmKindId: selectedChartData[0].eqpmKindId,
|
||||
eqpmGrpId: selectedChartData[0].eqpmGrpId,
|
||||
eqpmId: selectedChartData[0].eqpmId,
|
||||
};
|
||||
var key = "tick_" + Math.random();
|
||||
this.$router.push({
|
||||
@ -1944,8 +1728,7 @@ export default {
|
||||
// tick:key
|
||||
},
|
||||
params: {
|
||||
// ...data,
|
||||
...fake_data,
|
||||
...data,
|
||||
key: key,
|
||||
},
|
||||
});
|
||||
|
@ -16,8 +16,8 @@
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row ref="contents">
|
||||
<v-col :cols="5" style="height:100%">
|
||||
<v-row ref="contents" class="pt-2">
|
||||
<v-col :cols="5" style="height:100%" class="pr-2">
|
||||
<v-card class="pb-5">
|
||||
<div class="d-flex align-center justify-space-between pa-4">
|
||||
<v-card-title class="pa-0 custom-title-4">효율지표 리스트</v-card-title>
|
||||
@ -32,7 +32,7 @@
|
||||
</div>
|
||||
</v-card>
|
||||
</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-title class="custom-title-4 pa-4 pb-2">효율지표 상세
|
||||
</v-card-title>
|
||||
|
@ -12,6 +12,7 @@
|
||||
:textCols="12"
|
||||
:labelCols="12"
|
||||
:parentPrgmId="myPrgmId"
|
||||
:customClass="'select-large'"
|
||||
/>
|
||||
</v-col>
|
||||
<v-col :cols="3">
|
||||
@ -22,6 +23,7 @@
|
||||
dataKey="searchErcKind"
|
||||
:sendParam="{ commGrpCd: 'EM_ERCKIND', useFg: '1' }"
|
||||
:addAll="true"
|
||||
:customClass="'select-large'"
|
||||
/>
|
||||
</v-col>
|
||||
<v-col :cols="3">
|
||||
@ -34,13 +36,9 @@
|
||||
:addAll="true"
|
||||
:textCols="12"
|
||||
:labelCols="12"
|
||||
:customClass="'select-large'"
|
||||
/>
|
||||
</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">
|
||||
<component
|
||||
:is="'selectCodeList'"
|
||||
@ -49,8 +47,11 @@
|
||||
dataKey="searchChrgKind"
|
||||
:sendParam="{ commGrpCd: 'EM_ENGCHAGKIND', useFg: '1' }"
|
||||
:addAll="true"
|
||||
:customClass="'select-large'"
|
||||
/>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row align="center" no-gutters>
|
||||
<v-col :cols="3">
|
||||
<component
|
||||
:is="'selectCodeList'"
|
||||
@ -59,6 +60,7 @@
|
||||
dataKey="useFg"
|
||||
:sendParam="{ commGrpCd: 'CO_USEFG', useFg: '1' }"
|
||||
:addAll="true"
|
||||
:customClass="'select-large'"
|
||||
/>
|
||||
</v-col>
|
||||
<v-col :cols="3">
|
||||
@ -69,8 +71,14 @@
|
||||
:textCols="12"
|
||||
:labelCols="12"
|
||||
:searchOption="true"
|
||||
:customClass="'input-large'"
|
||||
/>
|
||||
</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-card>
|
||||
</v-col>
|
||||
@ -323,6 +331,9 @@ export default {
|
||||
columnOptions: {
|
||||
resizable: true,
|
||||
},
|
||||
header: {
|
||||
height: 38,
|
||||
},
|
||||
};
|
||||
this.setGridOption({
|
||||
gridKey: this.gridName,
|
||||
@ -332,12 +343,12 @@ export default {
|
||||
const _this = this;
|
||||
const myColumns = [
|
||||
{ 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: 'ercKind',
|
||||
align: 'center',
|
||||
align: 'left',
|
||||
formatter({ value }) {
|
||||
let retVal = '';
|
||||
const newValue = _this.pageData.ercKindList.filter(
|
||||
@ -450,7 +461,7 @@ export default {
|
||||
header: '사용 여부',
|
||||
name: 'useFg',
|
||||
width: 95,
|
||||
align: 'center',
|
||||
align: 'left',
|
||||
formatter({ value }) {
|
||||
value = value === true ? '1' : '0';
|
||||
const newValue = _this.pageData.useFgList.filter(
|
||||
@ -479,74 +490,24 @@ export default {
|
||||
this.loadGrid = true;
|
||||
},
|
||||
async getRowGridData() {
|
||||
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
|
||||
}
|
||||
]
|
||||
;
|
||||
let res = [];
|
||||
|
||||
// if (this.pageData.blocMstrList.length > 0) {
|
||||
// res = await this.postApiReturn({
|
||||
// apiKey: 'selectErcInfo',
|
||||
// resKey: 'ercInfoData',
|
||||
// sendParam: {
|
||||
// blocId: this.pageData.blocMstrList[this.pageData.blocId].blocId,
|
||||
// ercKind: this.pageData.searchErcKind,
|
||||
// readObjId: this.pageData.searchReadObj,
|
||||
// chrgKind: this.pageData.searchChrgKind,
|
||||
// useFg: this.pageData.useFg,
|
||||
// ercNmLike: this.pageData.ercNm,
|
||||
// },
|
||||
// });
|
||||
// } else {
|
||||
// this.setPageData({ isFind: false });
|
||||
// }
|
||||
if (this.pageData.blocMstrList.length > 0) {
|
||||
res = await this.postApiReturn({
|
||||
apiKey: 'selectErcInfo',
|
||||
resKey: 'ercInfoData',
|
||||
sendParam: {
|
||||
blocId: this.pageData.blocMstrList[this.pageData.blocId].blocId,
|
||||
ercKind: this.pageData.searchErcKind,
|
||||
readObjId: this.pageData.searchReadObj,
|
||||
chrgKind: this.pageData.searchChrgKind,
|
||||
useFg: this.pageData.useFg,
|
||||
ercNmLike: this.pageData.ercNm,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
this.setPageData({ isFind: false });
|
||||
}
|
||||
const newRes = res.map(item => {
|
||||
const newObj = {
|
||||
...item,
|
||||
@ -798,133 +759,8 @@ const defaultData = {
|
||||
/* data 세팅 */
|
||||
// 로컬 gridName 값과 동일한 이름으로 세팅
|
||||
rowGrid: {
|
||||
data: [
|
||||
{
|
||||
"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,
|
||||
data: [],
|
||||
column: [], // myColumns,
|
||||
option: {}, // myOptions
|
||||
defaultRow: {
|
||||
comId: '',
|
||||
|
@ -29,10 +29,10 @@
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row ref="contents">
|
||||
<v-col :cols="5" class="h100">
|
||||
<v-row ref="contents" class="mt-3">
|
||||
<v-col :cols="5" class="h100 pr-2">
|
||||
<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"
|
||||
@ -44,12 +44,12 @@
|
||||
:parentPrgmId="myPrgmId" @getRowsData="getRowData"
|
||||
@sendSelectedRowStatInfo="getSelectedRowStatInfo" :selectedRowDataWatchFlag="true"
|
||||
:preventFocusChangeEventFlag="true"
|
||||
:preventFocusChangeEventTargetGridList="editingGridList" :dataPath="dataPathExample" />
|
||||
:preventFocusChangeEventTargetGridList="editingGridList" />
|
||||
</div>
|
||||
</div>
|
||||
</v-card>
|
||||
</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-title class="px-0">물리량 상세</v-card-title>
|
||||
<v-row no-gutters>
|
||||
@ -136,7 +136,7 @@
|
||||
<v-col :cols="12" style="height:100%">
|
||||
<div ref="gridParent2" style="height:100%">
|
||||
<component :ref="gridName2" :is="loadGrid2 ? 'Grid' : null" :gridName="gridName2"
|
||||
:parentPrgmId="myPrgmId" @getRowsData="getRowData2" :dataPath="dataPathExample2" />
|
||||
:parentPrgmId="myPrgmId" @getRowsData="getRowData2" />
|
||||
</div>
|
||||
</v-col>
|
||||
</v-row>
|
||||
@ -223,7 +223,7 @@ export default {
|
||||
formatterSelectList01: [],
|
||||
formatterSelectList02: [],
|
||||
|
||||
loadGrid: true,
|
||||
loadGrid: false,
|
||||
dataPathExample: {
|
||||
"rowGrid": {
|
||||
data: [
|
||||
@ -279,59 +279,7 @@ export default {
|
||||
|
||||
}
|
||||
},
|
||||
dataPathExample2: {
|
||||
"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,
|
||||
loadGrid2: false,
|
||||
detailList: myDetail,
|
||||
|
||||
readOnlyValueList: [
|
||||
@ -1001,6 +949,10 @@ export default {
|
||||
columnOptions: {
|
||||
resizable: true,
|
||||
},
|
||||
header: {
|
||||
height: 37,
|
||||
},
|
||||
rowHeight: 'auto',
|
||||
};
|
||||
|
||||
this.setGridOption({
|
||||
@ -1066,6 +1018,10 @@ export default {
|
||||
columnOptions: {
|
||||
resizable: true,
|
||||
},
|
||||
header: {
|
||||
height: 37,
|
||||
},
|
||||
rowHeight: 'auto',
|
||||
};
|
||||
|
||||
this.setGridOption({
|
||||
|
@ -37,11 +37,11 @@
|
||||
:btnActionsFnc="btnActions" />
|
||||
</div>
|
||||
<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"
|
||||
:parentPrgmId="myPrgmId" @getRowsData="getRowData" :dataPath="dataPathExample" />
|
||||
</div>
|
||||
<div class="d-flex py-4">
|
||||
<div class="d-flex py-4" >
|
||||
<component :is="'Form'" :parentPrgmId="myPrgmId" :detailList="detailList"
|
||||
@gridEditingFinish="gridEditingFinish" />
|
||||
</div>
|
||||
@ -112,7 +112,7 @@ export default {
|
||||
myPrgmId: myPrgmId,
|
||||
initedFlag: false,
|
||||
gridName: 'rowGrid',
|
||||
loadGrid: true,
|
||||
loadGrid: false,
|
||||
detailList: myDetail,
|
||||
selectValue01: null,
|
||||
selectValueList01: [],
|
||||
@ -125,102 +125,102 @@ export default {
|
||||
// pysclQtyId3 : null,
|
||||
// pysclQtyId4 : null
|
||||
// }
|
||||
dataPathExample: {
|
||||
"rowGrid": {
|
||||
data: [
|
||||
// dataPathExample: {
|
||||
// "rowGrid": {
|
||||
// data: [
|
||||
|
||||
{
|
||||
gdIdxId: 'GD001',
|
||||
gdIdxNm: '온도 가이드',
|
||||
eqpmGrpId: 'EQ001',
|
||||
upTotMeth: 'AVG',
|
||||
careStndVal: 50,
|
||||
warnStndVal: 70,
|
||||
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: 'GD001',
|
||||
// gdIdxNm: '온도 가이드',
|
||||
// eqpmGrpId: 'EQ001',
|
||||
// upTotMeth: 'AVG',
|
||||
// careStndVal: 50,
|
||||
// warnStndVal: 70,
|
||||
// alrmMsg: '온도가 기준치를 초과했습니다.',
|
||||
// },
|
||||
},
|
||||
{
|
||||
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;
|
||||
// {
|
||||
// gdIdxId: 'GD002',
|
||||
// gdIdxNm: '습도 가이드',
|
||||
// eqpmGrpId: 'EQ002',
|
||||
// upTotMeth: 'MAX',
|
||||
// careStndVal: 30,
|
||||
// warnStndVal: 60,
|
||||
// alrmMsg: '습도가 기준치를 초과했습니다.',
|
||||
// },
|
||||
},
|
||||
{
|
||||
header: '주의기준',
|
||||
name: 'careStndVal',
|
||||
width: 100,
|
||||
align: 'right',
|
||||
},
|
||||
{
|
||||
header: '경고기준',
|
||||
name: 'warnStndVal',
|
||||
width: 100,
|
||||
align: 'right',
|
||||
},
|
||||
{
|
||||
header: '알람메세지',
|
||||
name: 'alrmMsg',
|
||||
minWidth: 860,
|
||||
align: 'left',
|
||||
}
|
||||
]
|
||||
// {
|
||||
// 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;
|
||||
// // },
|
||||
// },
|
||||
// {
|
||||
// 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: {
|
||||
@ -352,60 +352,46 @@ export default {
|
||||
});
|
||||
},
|
||||
async getEqpmKind() {
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: 'selectEqpmKindCodeList',
|
||||
// resKey: 'eqpmKindCodeLists',
|
||||
// sendParam: {},
|
||||
// });
|
||||
// if (res.length > 0) {
|
||||
// this.selectValueList01 = await res.map(item => {
|
||||
// return {
|
||||
// text: item.eqpmKindNm,
|
||||
// value: item.eqpmKindId,
|
||||
// };
|
||||
// });
|
||||
// this.selectValue01 = this.selectValueList01[0].value;
|
||||
// } else {
|
||||
// this.selectValueList01 = [];
|
||||
// this.selectValue01 = null;
|
||||
// }
|
||||
|
||||
this.selectValueList01 = [
|
||||
{ label: 'Etcher', value: 'EQK001' },
|
||||
{ label: 'Deposition', value: 'EQK002' },
|
||||
{ label: 'Inspection', value: 'EQK003' },
|
||||
];
|
||||
|
||||
this.selectValue01 = 'EQK001';
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmKindCodeList',
|
||||
resKey: 'eqpmKindCodeLists',
|
||||
sendParam: {},
|
||||
});
|
||||
if (res.length > 0) {
|
||||
this.selectValueList01 = await res.map(item => {
|
||||
return {
|
||||
text: item.eqpmKindNm,
|
||||
value: item.eqpmKindId,
|
||||
};
|
||||
});
|
||||
this.selectValue01 = this.selectValueList01[0].value;
|
||||
} else {
|
||||
this.selectValueList01 = [];
|
||||
this.selectValue01 = null;
|
||||
}
|
||||
this.setPageData({
|
||||
eqpmKindList: this.selectValueList01,
|
||||
eqpmKindId: this.selectValue01,
|
||||
});
|
||||
},
|
||||
async getEqpmGrp() {
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: 'selectEqpmGrpCodeList',
|
||||
// resKey: 'eqpmGrpCodeLists',
|
||||
// sendParam: { eqpmKindId: this.selectValue01 },
|
||||
// });
|
||||
// if (res.length > 0) {
|
||||
// this.selectValueList02 = await res.map(item => {
|
||||
// return {
|
||||
// text: item.eqpmGrpNm,
|
||||
// value: item.eqpmGrpId,
|
||||
// };
|
||||
// });
|
||||
// this.selectValue02 = this.selectValueList02[0].value;
|
||||
// } else {
|
||||
// this.selectValueList02 = [];
|
||||
// this.selectValue02 = null;
|
||||
// }
|
||||
this.selectValueList02 = [
|
||||
{ label: '냉동기고온', value: '냉동기고온' },
|
||||
{ label: '냉동기저온', value: '냉동기저온' },
|
||||
{ label: '공조기', value: '공조기' },
|
||||
{ label: '보일러', value: '보일러' }
|
||||
];
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmGrpCodeList',
|
||||
resKey: 'eqpmGrpCodeLists',
|
||||
sendParam: { eqpmKindId: this.selectValue01 },
|
||||
});
|
||||
if (res.length > 0) {
|
||||
this.selectValueList02 = await res.map(item => {
|
||||
return {
|
||||
text: item.eqpmGrpNm,
|
||||
value: item.eqpmGrpId,
|
||||
};
|
||||
});
|
||||
this.selectValue02 = this.selectValueList02[0].value;
|
||||
} else {
|
||||
this.selectValueList02 = [];
|
||||
this.selectValue02 = null;
|
||||
}
|
||||
|
||||
this.setPageData({
|
||||
eqpmGrpList: this.selectValueList02,
|
||||
@ -419,6 +405,10 @@ export default {
|
||||
columnOptions: {
|
||||
resizable: true,
|
||||
},
|
||||
header: {
|
||||
height: 37,
|
||||
},
|
||||
rowHeight: 'auto',
|
||||
};
|
||||
this.setGridOption({
|
||||
gridKey: this.gridName,
|
||||
@ -636,100 +626,100 @@ export default {
|
||||
async getRowGridData() {
|
||||
this.loadGrid = false;
|
||||
let res = [];
|
||||
const newRes = [
|
||||
{
|
||||
comId: 'COM001',
|
||||
gdIdxId: 'GD001',
|
||||
gdIdxNm: '온도 가이드',
|
||||
eqpmGrpId: 'EQ001',
|
||||
upTotMeth: 'AVG',
|
||||
sortSeq: 1,
|
||||
pysclQtyId1: 'TEMP',
|
||||
pysclQtyId2: null,
|
||||
pysclQtyId3: null,
|
||||
pysclQtyId4: null,
|
||||
ctgr1: '환경',
|
||||
ctgr2: '내부',
|
||||
careStndVal: 50,
|
||||
warnStndVal: 70,
|
||||
gdMeth: '자동',
|
||||
useFg: '1',
|
||||
alrmMsg: '온도가 기준치를 초과했습니다.',
|
||||
calcProc: 'PROC001',
|
||||
calcDesc: '평균 계산',
|
||||
calcMeth: '(A+B)/2',
|
||||
unit: 'C',
|
||||
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,
|
||||
// const newRes = [
|
||||
// {
|
||||
// comId: 'COM001',
|
||||
// gdIdxId: 'GD001',
|
||||
// gdIdxNm: '온도 가이드',
|
||||
// eqpmGrpId: 'EQ001',
|
||||
// upTotMeth: 'AVG',
|
||||
// sortSeq: 1,
|
||||
// pysclQtyId1: 'TEMP',
|
||||
// pysclQtyId2: null,
|
||||
// pysclQtyId3: null,
|
||||
// pysclQtyId4: null,
|
||||
// ctgr1: '환경',
|
||||
// ctgr2: '내부',
|
||||
// careStndVal: 50,
|
||||
// warnStndVal: 70,
|
||||
// gdMeth: '자동',
|
||||
// useFg: '1',
|
||||
// alrmMsg: '온도가 기준치를 초과했습니다.',
|
||||
// calcProc: 'PROC001',
|
||||
// calcDesc: '평균 계산',
|
||||
// calcMeth: '(A+B)/2',
|
||||
// unit: 'C',
|
||||
// argCnt: 2,
|
||||
// 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({
|
||||
gridKey: this.gridName,
|
||||
value: newRes,
|
||||
});
|
||||
//this.loadGrid = true;
|
||||
// this.$nextTick(() => {
|
||||
// if (newRes.length > 0) {
|
||||
// try {
|
||||
// this.$refs[this.gridName].focus({
|
||||
// //rowKey: 0,
|
||||
// rowKey:
|
||||
// this.pageData.rowGridSelectKey == '' ||
|
||||
// this.pageData.rowGridSelectKey == null
|
||||
// ? 0
|
||||
// : this.pageData.rowGridSelectKey ==
|
||||
// this.$refs[this.gridName].getData().length - 1
|
||||
// ? this.pageData.rowGridSelectKey
|
||||
// : 0,
|
||||
// columnName: 'gdIdxId',
|
||||
// setScroll: true,
|
||||
// });
|
||||
// } catch (error) { }
|
||||
// } else {
|
||||
// this.detailDataInit();
|
||||
// }
|
||||
// });
|
||||
this.$nextTick(() => {
|
||||
if (newRes.length > 0) {
|
||||
try {
|
||||
this.$refs[this.gridName].focus({
|
||||
//rowKey: 0,
|
||||
rowKey:
|
||||
this.pageData.rowGridSelectKey == '' ||
|
||||
this.pageData.rowGridSelectKey == null
|
||||
? 0
|
||||
: this.pageData.rowGridSelectKey ==
|
||||
this.$refs[this.gridName].getData().length - 1
|
||||
? this.pageData.rowGridSelectKey
|
||||
: 0,
|
||||
columnName: 'gdIdxId',
|
||||
setScroll: true,
|
||||
});
|
||||
} catch (error) { }
|
||||
} else {
|
||||
this.detailDataInit();
|
||||
}
|
||||
});
|
||||
this.loadGrid = true;
|
||||
},
|
||||
async getRowData(data) {
|
||||
|
@ -29,7 +29,7 @@
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row ref="contents" class="mt-4">
|
||||
<v-row ref="contents" class="mt-3">
|
||||
<v-col :cols="12" style="height: 100%">
|
||||
<!-- <v-card class="py-5"> -->
|
||||
<v-card style="height: 60%">
|
||||
@ -115,8 +115,8 @@
|
||||
|
||||
</v-card>
|
||||
|
||||
<v-row style="height: 40%" class="mt-4">
|
||||
<v-col :cols="6" style="height: 100%">
|
||||
<v-row style="height: 40%" class="mt-3">
|
||||
<v-col :cols="6" style="height: 100%" class="pr-2">
|
||||
<v-card class="pb-5">
|
||||
<div class="d-flex align-center justify-space-between pa-4">
|
||||
<v-card-title class="pa-0 custom-title-4 ">설비상세 리스트</v-card-title>
|
||||
@ -126,12 +126,12 @@
|
||||
<div ref="gridParent" class="w100 h100">
|
||||
<component :ref="gridName" :is="loadGrid ? 'Grid' : null" :gridName="gridName"
|
||||
:parentPrgmId="myPrgmId" @getRowsData="getRowData"
|
||||
:dataPath="dataPathExample" />
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</v-card>
|
||||
</v-col>
|
||||
<v-col :cols="6" style="height: 100%">
|
||||
<v-col :cols="6" style="height: 100%" class="pl-2">
|
||||
<v-card class="pb-5">
|
||||
<div class="d-flex align-center justify-space-between pa-4">
|
||||
<v-card-title class="pa-0 custom-title-4">설비가이드 기준 정보</v-card-title>
|
||||
@ -201,7 +201,7 @@ export default {
|
||||
readonlyFg: true,
|
||||
initedFlag: false,
|
||||
gridName: 'rowGrid',
|
||||
loadGrid: true,
|
||||
loadGrid: false,
|
||||
detailList: myDetail,
|
||||
selectValue01: null,
|
||||
selectValueList01: [],
|
||||
@ -209,62 +209,62 @@ export default {
|
||||
selectValueList02: [],
|
||||
selectValue03: null,
|
||||
selectValueList03: [],
|
||||
dataPathExample: {
|
||||
"rowGrid": {
|
||||
data: [
|
||||
// dataPathExample: {
|
||||
// "rowGrid": {
|
||||
// data: [
|
||||
|
||||
{
|
||||
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,
|
||||
},
|
||||
// {
|
||||
// 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,
|
||||
// },
|
||||
|
||||
],
|
||||
column: [
|
||||
{ header: '설비', name: 'eqpmId', align: 'left' },
|
||||
{
|
||||
header: 'origin설비',
|
||||
name: 'originEqpmId',
|
||||
align: 'center',
|
||||
hidden: true,
|
||||
},
|
||||
{ header: '설비명', name: 'eqpmNm', align: 'left' },
|
||||
{ header: '주의기준', name: 'careStndVal', align: 'right' },
|
||||
{ header: '심각기준', name: 'warnStndVal', align: 'right' },
|
||||
]
|
||||
// ],
|
||||
// column: [
|
||||
// { header: '설비', name: 'eqpmId', align: 'left' },
|
||||
// {
|
||||
// header: 'origin설비',
|
||||
// name: 'originEqpmId',
|
||||
// align: 'center',
|
||||
// hidden: true,
|
||||
// },
|
||||
// { header: '설비명', name: 'eqpmNm', align: 'left' },
|
||||
// { header: '주의기준', name: 'careStndVal', align: 'right' },
|
||||
// { header: '심각기준', name: 'warnStndVal', align: 'right' },
|
||||
// ]
|
||||
|
||||
}
|
||||
}
|
||||
// }
|
||||
// }
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
@ -408,6 +408,10 @@ export default {
|
||||
columnOptions: {
|
||||
resizable: true,
|
||||
},
|
||||
header: {
|
||||
height: 37,
|
||||
},
|
||||
rowHeight: 'auto',
|
||||
};
|
||||
this.setGridOption({
|
||||
gridKey: this.gridName,
|
||||
@ -511,69 +515,69 @@ export default {
|
||||
this.loadGrid = false;
|
||||
let res = [];
|
||||
|
||||
// if (this.selectValue01 && this.selectValue02 && this.selectValue03) {
|
||||
// res = await this.postApiReturn({
|
||||
// apiKey: 'selectEqpmGdDetl',
|
||||
// resKey: 'eqpmGdDetlData',
|
||||
// sendParam: {
|
||||
// gdIdxId: this.selectValue03,
|
||||
if (this.selectValue01 && this.selectValue02 && this.selectValue03) {
|
||||
res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmGdDetl',
|
||||
resKey: 'eqpmGdDetlData',
|
||||
sendParam: {
|
||||
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({
|
||||
gridKey: this.gridName,
|
||||
value: newRes,
|
||||
|
@ -195,28 +195,16 @@ export default {
|
||||
});
|
||||
},
|
||||
async getEqpmKind() {
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: "selectEqpmKindCodeList",
|
||||
// resKey: "eqpmKindCodeLists",
|
||||
// sendParam: {},
|
||||
// });
|
||||
|
||||
let res = [
|
||||
{
|
||||
eqpmKindId: "냉동기저온",
|
||||
eqpmKindNm: "냉동기저온",
|
||||
},
|
||||
{
|
||||
eqpmKindId: "냉동기고온",
|
||||
eqpmKindNm: "냉동기고온",
|
||||
},
|
||||
];
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEqpmKindCodeList',
|
||||
resKey: 'eqpmKindCodeLists',
|
||||
sendParam: {},
|
||||
});
|
||||
|
||||
if (res.length > 0) {
|
||||
this.selectValueList01 = await res.map((item) => {
|
||||
this.selectValueList01 = await res.map(item => {
|
||||
return {
|
||||
// text: item.eqpmKindNm,
|
||||
label: item.eqpmKindNm,
|
||||
text: item.eqpmKindNm,
|
||||
value: item.eqpmKindId,
|
||||
};
|
||||
});
|
||||
@ -233,29 +221,24 @@ export default {
|
||||
gridInit() {},
|
||||
getRowGridData() {},
|
||||
async getData() {
|
||||
// let res = await this.postApiReturn({
|
||||
// apiKey: "selectEnrgEffcTotSumm",
|
||||
// resKey: "totSummData",
|
||||
// sendParam: {
|
||||
// fromDt: this.pageData.fromDt,
|
||||
// eqpmKindId: this.selectValue01,
|
||||
// },
|
||||
// });
|
||||
let res = ["aaa", "bbb"];
|
||||
let res = await this.postApiReturn({
|
||||
apiKey: 'selectEnrgEffcTotSumm',
|
||||
resKey: 'totSummData',
|
||||
sendParam: {
|
||||
fromDt: this.pageData.fromDt,
|
||||
eqpmKindId: this.selectValue01,
|
||||
},
|
||||
});
|
||||
|
||||
await this.getChartData(res);
|
||||
|
||||
// this.selectData = res.filter((item, i) => {
|
||||
// return (
|
||||
// res.findIndex((item2, j) => {
|
||||
// return item.eqpmGrpId === item2.eqpmGrpId;
|
||||
// }) === i
|
||||
// );
|
||||
// });
|
||||
|
||||
this.selectData = [
|
||||
{ eqpmGrpId: "G001", eqpmGrpNm: "Group A", otherProp: "..." },
|
||||
{ eqpmGrpId: "G002", eqpmGrpNm: "Group B", otherProp: "..." },
|
||||
];
|
||||
this.selectData = res.filter((item, i) => {
|
||||
return (
|
||||
res.findIndex((item2, j) => {
|
||||
return item.eqpmGrpId === item2.eqpmGrpId;
|
||||
}) === i
|
||||
);
|
||||
});
|
||||
},
|
||||
barClick(event, chartName) {
|
||||
var data = {};
|
||||
@ -302,37 +285,25 @@ export default {
|
||||
// }
|
||||
// });
|
||||
|
||||
// data.map((item) => {
|
||||
// if (chartDataObj[item.eqpmGrpId] != null) {
|
||||
// chartDataObj[item.eqpmGrpId].push(item);
|
||||
// } else {
|
||||
// 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 },
|
||||
],
|
||||
};
|
||||
data.map(item => {
|
||||
if (chartDataObj[item.eqpmGrpId] != null) {
|
||||
chartDataObj[item.eqpmGrpId].push(item);
|
||||
} else {
|
||||
chartDataObj[item.eqpmGrpId] = [item];
|
||||
}
|
||||
});
|
||||
|
||||
// chartDataObj.keys()[0]
|
||||
var i = 0;
|
||||
for (var x of Object.keys(chartDataObj)) {
|
||||
this.loadChartList.push(false);
|
||||
i++;
|
||||
this.objList["chart_0" + i] = chartDataObj[x];
|
||||
this.chartNameList.push("chart_0" + i);
|
||||
this.objList['chart_0' + i] = chartDataObj[x];
|
||||
this.chartNameList.push('chart_0' + i);
|
||||
this.setPageData({
|
||||
[this.chartNameList[i - 1]]: Utility.defaultChartOption(true),
|
||||
});
|
||||
|
||||
this.setChartData(chartDataObj[x], i);
|
||||
}
|
||||
// this.setChartData(chartDataObj[Object.keys(chartDataObj)[0]]);
|
||||
|
@ -103,7 +103,6 @@
|
||||
<component
|
||||
:ref="gridName"
|
||||
class="tagTrndGrid"
|
||||
v-if="loadGrid"
|
||||
:is="loadGrid ? 'Grid' : null"
|
||||
:gridName="gridName"
|
||||
:parentPrgmId="myPrgmId"
|
||||
@ -199,7 +198,6 @@ export default {
|
||||
async asyncData(context) {
|
||||
const myState = context.store.state;
|
||||
myPrgmId = context.route.query.prgmId;
|
||||
console.log("menudata:", myState.menuData[myPrgmId]);
|
||||
await context.store.commit("setActiveMenuInfo", myState.menuData[myPrgmId]);
|
||||
myTitle = await myState.activeMenuInfo.menuNm;
|
||||
},
|
||||
@ -330,7 +328,6 @@ export default {
|
||||
} else {
|
||||
this.dumyChartFg = false;
|
||||
}
|
||||
this.dumyChartFg = true;
|
||||
if (this.initedFlag && this.tagList.length > 0) {
|
||||
this.search();
|
||||
}
|
||||
@ -409,12 +406,12 @@ export default {
|
||||
getAddInfoList: "modules/search/getAddInfoList",
|
||||
}),
|
||||
async init() {
|
||||
await this.setPageData({
|
||||
this.setPageData({
|
||||
rowGridSelectKey: 0,
|
||||
rowGridSelectData: null,
|
||||
});
|
||||
await this.gridInit();
|
||||
this.setChartNull2();
|
||||
this.gridInit();
|
||||
this.setChartNull();
|
||||
},
|
||||
async search() {
|
||||
// search가 2번 타는 경우:
|
||||
@ -513,12 +510,6 @@ export default {
|
||||
gridKey: this.gridName,
|
||||
value: myColumns,
|
||||
});
|
||||
|
||||
this.setGridData({
|
||||
gridKey: this.gridName,
|
||||
value: newRes,
|
||||
});
|
||||
|
||||
this.loadGrid = true;
|
||||
},
|
||||
getRowData(data) {
|
||||
@ -809,7 +800,6 @@ export default {
|
||||
// data SeriesData 추가
|
||||
chartDataDict[dataTagTitle]["seriesData"] = seriesData;
|
||||
// data legend 추가
|
||||
console.log("le dat:", legendData);
|
||||
chartDataDict[dataTagTitle]["legendList"] = legendData;
|
||||
//
|
||||
//rawData chart data 구성하기
|
||||
@ -1216,40 +1206,8 @@ const defaultData = {
|
||||
rowGridSelectData: null,
|
||||
/* Griddata 세팅 */
|
||||
rowGrid: {
|
||||
data: [
|
||||
{
|
||||
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 },
|
||||
],
|
||||
data: [],
|
||||
column: [],
|
||||
option: {},
|
||||
defaultRow: {
|
||||
eqpmGrpNm: null,
|
||||
|
Reference in New Issue
Block a user