update code

This commit is contained in:
Nguyen Van Luan/(Nguyen Van Luan)/현장대리인/SK
2025-07-29 18:30:25 +09:00
parent 8963a92475
commit 00a183b9de
5 changed files with 31 additions and 106 deletions

View File

@ -64,7 +64,6 @@
:gridName="gridName"
:parentPrgmId="myPrgmId"
@getRowsData="getRowData"
:dataPath="dataPathMock"
/>
</div>
</div>
@ -137,24 +136,10 @@ export default {
return {
myPrgmId: myPrgmId,
gridName: 'rowGrid',
loadGrid: true,
loadGrid: false,
tab: null,
detailList: myDetail,
initedFlag: false,
dataPathMock : {
'rowGrid': {
column: [
{ header: '추가 정보 그룹', name: 'addGrpId', align: 'left' },
{ header: '추가 정보 ID', name: 'addInfoId', align: 'left' },
{ header: '추가 정보 명', name: 'addInfoNm', align: 'left' },
{ header: 'Data 형식', name: 'addInfoDataKind', align: 'center' },
{ header: '사용여부', name: 'useFg', align: 'center' },
],
data: dataMockExample,
defaultRow: dataMockExample,
option: {},
},
},
};
},
computed: {
@ -351,8 +336,7 @@ export default {
this.search();
},
async search() {
//process
this.loadGrid = true;
this.loadGrid = false;
await this.getRowGridData();
await this.setPageData({
isFind: false,
@ -642,43 +626,7 @@ const myDetail = [
placeholder: '시스템 자동입력',
},
];
const dataMockExample = [
{
addGrpId: 'GRP001',
addInfoId: 'INFO001',
addInfoNm: '온도 센서',
addInfoDataKind: 'DATA01',
useFg: true,
},
{
addGrpId: 'GRP002',
addInfoId: 'INFO002',
addInfoNm: '압력 센서',
addInfoDataKind: 'DATA02',
useFg: false,
},
{
addGrpId: 'GRP003',
addInfoId: 'INFO003',
addInfoNm: '압력 센서',
addInfoDataKind: 'DATA03',
useFg: false,
},
{
addGrpId: 'GRP004',
addInfoId: 'INFO004',
addInfoNm: '압력 센서',
addInfoDataKind: 'DATA04',
useFg: false,
},
{
addGrpId: 'GRP005',
addInfoId: 'INFO005',
addInfoNm: '압력 센서',
addInfoDataKind: 'DATA05',
useFg: false,
},
];
</script>
<style lang="scss">
@import '@/assets/scss/common.scss';
</style>

View File

@ -60,7 +60,8 @@
/>
</div>
<div class="h100 px-5" style="height:calc(100% - 70px)">
<div ref="gridParent" class="w100 h100">
<!-- <div ref="gridParent" class="w100 h100">
</div> -->
<component
:ref="gridName"
:is="loadGrid ? 'Grid' : null"
@ -71,7 +72,6 @@
:selectedRowDataWatchFlag="true"
/>
</div>
</div>
</v-card>
</v-col>
<v-col :cols="7" class="h100">
@ -407,8 +407,6 @@ export default {
value: myColumns,
});
this.loadGrid = true;
this.search();
},
async getRowGridData() {
@ -437,8 +435,9 @@ export default {
gridKey: this.gridName,
value: newRes,
});
console.log('-------DEBUG-----newRes: ', newRes);
this.$nextTick(() => {
this.loadGrid = true;
if (newRes.length > 0) {
try {
this.$refs[this.gridName].focus({