From a6e8e6cf86cc32cdb736f4f102e91a16e657a353 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tran=20Van=20Dung/=28Tran=20Van=20Dung=29/=ED=98=84?= =?UTF-8?q?=EC=9E=A5=EB=8C=80=EB=A6=AC=EC=9D=B8/SK?= <20074470@skcc.com> Date: Thu, 31 Jul 2025 13:52:28 +0700 Subject: [PATCH 01/15] fixbug screen 20 --- components/common/Grid.vue | 16 +++-- components/common/modal/FtnPlcFormPop.vue | 65 ++++++++----------- .../pages/ems/EqpmInfo/EqpmConstTab.vue | 1 - components/pages/ems/EqpmInfo/EqpmIaoTab.vue | 45 +++++++++---- nuxt.config.js | 2 +- pages/comm/auth/MenuRoleMngPage.vue | 14 ++-- pages/comm/base/PrgmMngPage.vue | 1 + pages/ems/base/EquipmentMasterMngPage.vue | 3 +- 8 files changed, 77 insertions(+), 70 deletions(-) diff --git a/components/common/Grid.vue b/components/common/Grid.vue index 4efae23..e2b607d 100644 --- a/components/common/Grid.vue +++ b/components/common/Grid.vue @@ -4,12 +4,12 @@ :data="chkGridData" :columns="chkGridColumns" :options="chkGridOptions" - @mousedown="onMousedown" @click="startEditing" @editingFinish="editingFinish" @dblclick="dblClick" @mouseover="mouseoverEvent" @mouseout="mouseoutEvent" + @mousedown="onMousedown" @focusChange="focusChangeEvt" /> @@ -271,11 +271,17 @@ export default { }); }, onMousedown(evt) { - // console.log("------------------DEBUG-------onMousedown:", evt); - this.focusChangeEvt(evt); + console.log("------------------DEBUG-------onMousedown:", evt); + this.handleSelectedRow(evt); }, focusChangeEvt(e) { - // console.log("------------------DEBUG-------focusChangeEvt:", e); + console.log("------------------DEBUG-------focusChangeEvt:", e); + if(e.rowKey === 0) { + this.handleSelectedRow(e); + } + }, + handleSelectedRow(e) { + console.log("------------------DEBUG-------handleSelectedRow:", e); // console.log('focusChangeEvt1...') if (this.preventFocusChangeEvent(e)) { // console.log('prevent focusChangeEvt') @@ -283,7 +289,7 @@ export default { } // console.log('focusChangeEvt2...') // cell 선택시 row 선택 method - if (e.rowKey >= 0) { + if (e.rowKey > -1) { this.$emit( 'getRowsData', this.gridInstance.invoke('getRow', e.rowKey), diff --git a/components/common/modal/FtnPlcFormPop.vue b/components/common/modal/FtnPlcFormPop.vue index 7ccbe47..f577a6e 100644 --- a/components/common/modal/FtnPlcFormPop.vue +++ b/components/common/modal/FtnPlcFormPop.vue @@ -280,52 +280,41 @@ export default { modalKey: this.myModalKey, gridKey: this.grid_01, modalDataKey: this.modalDataKey, - value: [{ header: '위치정보', name: 'eccNm' }], + value: [ + { + align: 'center', + width: 30, + minWidth: 60, + formatter: (props) => { + return ``; + } + }, + { header: '위치정보', name: 'eccNm' } + ], }); }, async getGridData() { - // this.loadGrid = false; + this.loadGrid = false; - // const res = await this.postApiReturn({ - // apiKey: 'selectEccBaseInfo', - // resKey: 'eccBaseInfoData', - // sendParam: { - // blocId: this.myBindingData.blocId, - // eqpmYn: '0', - // search: this.searchWord, - // }, - // }); + const res = await this.postApiReturn({ + apiKey: 'selectEccBaseInfo', + resKey: 'eccBaseInfoData', + sendParam: { + blocId: this.myBindingData.blocId, + eqpmYn: '0', + search: this.searchWord, + }, + }); - // const setTreeData = await this.setTree({ - // gridKey: this.gridNameTree, - // treeKey: 'ECC_ID', - // value: res.map(item => ({ - // ...item, - // eccNm: item.eccNm, - // })), - // }); - - //mockdata eccNm - - - let res = [ - { ECC_ID: 'ECC001', eccNm: '서울 본사', iconShow: false, align: 'center' }, - { ECC_ID: 'ECC002', eccNm: '부산 지사', useIcon: false, align: 'center' }, - { ECC_ID: 'ECC003', eccNm: '대구 센터', useIcon: false, align: 'center' }, - { ECC_ID: 'ECC004', eccNm: '광주 사무소' , useIcon: false, align: 'center'}, - { ECC_ID: 'ECC005', eccNm: '인천 물류창고' , useIcon: false, align: 'center'}, - ]; - - - const setTreeData = { - ROOT: res.map(item => ({ + const setTreeData = await this.setTree({ + gridKey: this.gridNameTree, + treeKey: 'ECC_ID', + value: res.map(item => ({ ...item, eccNm: item.eccNm, - })) - }; + })), + }); - // console.log(res); - this.setModalGridData({ modalKey: this.myModalKey, gridKey: this.grid_01, diff --git a/components/pages/ems/EqpmInfo/EqpmConstTab.vue b/components/pages/ems/EqpmInfo/EqpmConstTab.vue index 892b426..69f1615 100644 --- a/components/pages/ems/EqpmInfo/EqpmConstTab.vue +++ b/components/pages/ems/EqpmInfo/EqpmConstTab.vue @@ -358,7 +358,6 @@ const myEqpmConstDetail = [ { type: 'SelectBox', label: '대상 유형', - disabled: true, cols: 6, class: 'py-3 pr-4', list: 'emMapDivList2', diff --git a/components/pages/ems/EqpmInfo/EqpmIaoTab.vue b/components/pages/ems/EqpmInfo/EqpmIaoTab.vue index 688214a..5be2e9b 100644 --- a/components/pages/ems/EqpmInfo/EqpmIaoTab.vue +++ b/components/pages/ems/EqpmInfo/EqpmIaoTab.vue @@ -18,7 +18,7 @@ :innerTabGridInfo="innerTabGridInfo" /> -
+
{ - return ` - - `; + return ``; } }, { @@ -421,14 +418,11 @@ export default { ]; const myTreeColumns2 = [ { - header: '', - name: '', align: 'center', width: 30, + minWidth: 60, formatter: (props) => { - return ` - - `; + return ``; } }, { header: '역할ID', name: 'roleId', hidden: true }, diff --git a/pages/comm/base/PrgmMngPage.vue b/pages/comm/base/PrgmMngPage.vue index e6d4479..9532ceb 100644 --- a/pages/comm/base/PrgmMngPage.vue +++ b/pages/comm/base/PrgmMngPage.vue @@ -1,5 +1,6 @@