updatenew-code-new
This commit is contained in:
@ -351,25 +351,25 @@ export default {
|
||||
tmpChrtOp.color = light_Col;
|
||||
}
|
||||
}
|
||||
console.log('ops11:',tmpChrtOp)
|
||||
// console.log('ops11:',tmpChrtOp)
|
||||
return tmpChrtOp;
|
||||
},
|
||||
}),
|
||||
},
|
||||
created() {
|
||||
console.log('wd data:',this.widgetData)
|
||||
// console.log('wd data:',this.widgetData)
|
||||
},
|
||||
methods: {
|
||||
onClick(event, instance, ECharts) {
|
||||
console.log('onClick : ', event);
|
||||
// console.log('onClick : ', event);
|
||||
this.$emit('click', event);
|
||||
},
|
||||
onDblClick(event, instance, ECharts) {
|
||||
console.log('onDblClick : ', event);
|
||||
// console.log('onDblClick : ', event);
|
||||
this.$emit('dblclick', event);
|
||||
},
|
||||
onRightClick(event, instance, ECharts) {
|
||||
console.log('onRightClick : ', event);
|
||||
// console.log('onRightClick : ', event);
|
||||
this.$emit('rclick', event);
|
||||
},
|
||||
onLegendSelect(params) {
|
||||
|
@ -30,7 +30,7 @@
|
||||
<img :src="arrowIcon" alt="">
|
||||
</div>
|
||||
<v-text-field
|
||||
v-if="isRange"
|
||||
v-show="isRange"
|
||||
id="endpicker"
|
||||
ref="endpicker"
|
||||
v-model="toDtValue"
|
||||
@ -47,9 +47,6 @@
|
||||
</template>
|
||||
</v-text-field>
|
||||
</div>
|
||||
<!-- test -->
|
||||
<!-- <a-button @click="onOpenDatepicker()">Open</a-button> -->
|
||||
<!-- end test -->
|
||||
</v-col>
|
||||
</v-row>
|
||||
</template>
|
||||
|
@ -163,7 +163,7 @@ export default {
|
||||
},
|
||||
created() {},
|
||||
async mounted() {
|
||||
console.log('--------------DEBUG----gridData: ', this.gridData);
|
||||
// console.log('--------------DEBUG----gridData: ', this.gridData);
|
||||
if (this.gridName) {
|
||||
this.gridInstance = this.$refs['tuigrid' + this.gridName];
|
||||
|
||||
@ -666,6 +666,8 @@ export default {
|
||||
store.dimension.offsetLeft = offsetLeft;
|
||||
},
|
||||
setHeight(_a,height){
|
||||
return; // setting auto height
|
||||
|
||||
// console.log("setHeight");
|
||||
var dimension = _a.dimension;
|
||||
var headerHeight = dimension.headerHeight, summaryHeight = dimension.summaryHeight, tableBorderWidth = dimension.tableBorderWidth;
|
||||
|
@ -3,8 +3,7 @@
|
||||
<!--<v-btn icon tile :ripple="false" @click="btnActionsFnc('addLeftToRight')">
|
||||
<v-icon>mdi-chevron-right</v-icon>
|
||||
</v-btn> -->
|
||||
<a-button type="default" @click="btnActionsFnc('addLeftToRight')">
|
||||
<RightOutlines/>
|
||||
<a-button @click="btnActionsFnc('addLeftToRight')" type="primary" ghost icon="right" >
|
||||
</a-button>
|
||||
|
||||
<!--<v-btn
|
||||
@ -16,8 +15,7 @@
|
||||
>
|
||||
<v-icon>mdi-chevron-left</v-icon>
|
||||
</v-btn> -->
|
||||
<a-button class="mt-2" type="default" @click="btnActionsFnc('removeRightToLeft')">
|
||||
<LeftOutlines/>
|
||||
<a-button class="mt-2" @click="btnActionsFnc('removeRightToLeft')" type="primary" ghost icon="left">
|
||||
</a-button>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -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%',
|
||||
|
@ -318,7 +318,7 @@ export default {
|
||||
// }
|
||||
},
|
||||
mounted(){
|
||||
this.initTest(); return;
|
||||
// this.initTest(); return;
|
||||
},
|
||||
methods: {
|
||||
...mapMutations({
|
||||
@ -478,10 +478,6 @@ export default {
|
||||
// })
|
||||
},
|
||||
async setChart(){
|
||||
// test
|
||||
this.initTestChart(); return;
|
||||
// end test
|
||||
|
||||
this.loadChart = false;
|
||||
let xAxisData = [];
|
||||
let seriesData = [];
|
||||
|
@ -7,12 +7,15 @@
|
||||
{{ option.labelContent }}
|
||||
</label>
|
||||
</v-col>
|
||||
<v-col :cols="option.textCols">
|
||||
<v-text-field readonly v-model="selectValue" append-icon="mdi-magnify"
|
||||
:class="['v-select__custom', customClass]"
|
||||
@click="dialogOpenCloseEvent(dialog)" outlined :hide-details="true"
|
||||
:required="item.required || false"></v-text-field>
|
||||
<!-- :disabled="item.disabled || false" -->
|
||||
<v-col :cols="option.textCols" class="py-0">
|
||||
<v-text-field readonly append-icon="" class="v-input__custom" outlined :hide-details="true"
|
||||
v-model="searchWord" @keyup.enter="typeEnterKey" @click="dialogOpenCloseEvent(dialog)"
|
||||
:required="item.required || false"><template v-slot:append>
|
||||
<!-- Custom SVG icon -->
|
||||
<v-icon>$icoSearch</v-icon>
|
||||
|
||||
|
||||
</template></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<v-dialog v-model="dialog" scrollable width="1000px">
|
||||
@ -21,10 +24,10 @@
|
||||
<span class="custom-title-4">{{ option.modalTitle }}</span>
|
||||
<v-icon @click="dialogOpenCloseEvent(dialog)">mdi-close</v-icon>
|
||||
</v-card-title>
|
||||
<v-row align="end" class="pa-5" no-gutters>
|
||||
<v-row align="end" class="px-5 pb-3" no-gutters>
|
||||
<v-col :cols="2.5" class="mr-2">
|
||||
<v-row>
|
||||
<v-col :cols="2">
|
||||
<v-col :cols="12" class="py-0">
|
||||
<label for="" class="search-box-label">
|
||||
<!-- <v-icon small
|
||||
:class="['mr-1', item.required ? 'icon-orange' : 'icon-blue']"
|
||||
@ -32,28 +35,30 @@
|
||||
검색
|
||||
</label>
|
||||
</v-col>
|
||||
<v-col :cols="12">
|
||||
<v-text-field append-icon="mdi-magnify" class="v-input__custom" outlined :hide-details="true"
|
||||
v-model="searchWord" @keyup.enter="search"></v-text-field>
|
||||
<v-col :cols="11" class="py-0 pr-3">
|
||||
<v-text-field append-icon="mdi-magnify" class="v-input__custom" outlined
|
||||
:hide-details="true" v-model="searchWord" @keyup.enter="search"></v-text-field>
|
||||
</v-col>
|
||||
<a-button icon="search" :ripple="false" type="primary" @click="search()"
|
||||
class="search-button">조회</a-button>
|
||||
</v-row>
|
||||
</v-col>
|
||||
<a-button type="primary" :ripple="false" @click="search()">
|
||||
조회
|
||||
</a-button>
|
||||
|
||||
|
||||
</v-row>
|
||||
<!-- <div :style="'height: calc(65vh)'"> -->
|
||||
<div :style="'height: 600px'">
|
||||
<div :style="'height: 600px'" class="px-5">
|
||||
<!-- <div :style="{ height: 'calc(100% - 213px)' }"> -->
|
||||
<div ref="modalGridParent" class="h100 py-3">
|
||||
<!-- :is="loadGrid && dialog ? 'Grid' : null" -->
|
||||
<component :is="loadGrid && dialog ? 'Grid' : null" :gridName="grid_01"
|
||||
:dataPath="searchParam.modalData2.evtObjPop" :parentPrgmId="parentPrgmId" @getRowsData="getRowData"
|
||||
@dblClick="setUpdate($event)" />
|
||||
:dataPath="searchParam.modalData2.evtObjPop" :parentPrgmId="parentPrgmId"
|
||||
@getRowsData="getRowData" @dblClick="setUpdate($event)" />
|
||||
</div>
|
||||
</div>
|
||||
<v-card-actions class="pa-5 d-flex align-center justify-end">
|
||||
<a-button type="default" class="mr-2" :ripple="false" @click="dialogOpenCloseEvent(dialog)">닫기</a-button>
|
||||
<a-button type="default" class="mr-2" :ripple="false"
|
||||
@click="dialogOpenCloseEvent(dialog)">닫기</a-button>
|
||||
<a-button type="primary" class="mr-2" :ripple="false" @click="setUpdate('init')">초기화</a-button>
|
||||
<a-button type="primary" :ripple="false" @click="setUpdate($event)">확인</a-button>
|
||||
</v-card-actions>
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<v-row class="search-box" align="center" >
|
||||
<v-row class="search-box" align="center">
|
||||
<!-- <v-col v-if="label" cols="2"> -->
|
||||
<v-col v-if="item.label" :cols="item.labelCols" class="py-0">
|
||||
<label for="" class="search-box-label">
|
||||
@ -37,12 +37,11 @@
|
||||
<v-row align="center">
|
||||
<v-col v-if="label" cols="12" class="py-0">
|
||||
<label for="" class="search-box-label">
|
||||
<v-icon small
|
||||
:class="['mr-1', 'icon-blue']">$icoBulletPoint</v-icon>
|
||||
<v-icon small :class="['mr-1', 'icon-blue']">$icoBulletPoint</v-icon>
|
||||
{{ item.label }}
|
||||
</label>
|
||||
</v-col>
|
||||
<v-col :cols="label ? 6 : ''" class="py-0">
|
||||
<v-col :cols="label ? 8 : ''" class="py-0">
|
||||
<!-- :value="textfield" -->
|
||||
<v-text-field append-icon="" class="v-input__custom" outlined :hide-details="true"
|
||||
v-model="searchWord" @keyup.enter="typeEnterKey"><template v-slot:append>
|
||||
@ -52,13 +51,10 @@
|
||||
|
||||
</template></v-text-field>
|
||||
</v-col>
|
||||
<v-spacer></v-spacer>
|
||||
<v-col cols="3" class="text-right">
|
||||
<v-btn :ripple="false" icon tile @click="btnTreeExpand()">
|
||||
<!-- {{ treeExpand }} -->
|
||||
<v-icon size="30"
|
||||
v-text="treeExpandAll ? 'mdi-chevron-up' : 'mdi-chevron-down'"></v-icon>
|
||||
</v-btn>
|
||||
<!-- <v-spacer></v-spacer> -->
|
||||
<v-col cols="2" class="text-right">
|
||||
<a-button icon="search" type="primary" @click="search()" class="search-button">조회</a-button>
|
||||
|
||||
<!-- <v-btn color="primary" dark>펼치기</v-btn> -->
|
||||
<!-- <v-btn color="primary" dark>접기</v-btn> -->
|
||||
<!-- <v-btn :ripple="false">초기화</v-btn> -->
|
||||
@ -66,6 +62,10 @@
|
||||
<v-btn v-if="!searchParam.isMulti" :ripple="false" @click="search()">검색</v-btn> -->
|
||||
<!-- as-is 롤 봐도 초기화가 하는 기능을 모르겠음.. -->
|
||||
</v-col>
|
||||
<v-col cols="2" class="text-right"><a-button class="expand-btn" :ripple="false" @click="btnTreeExpand()">
|
||||
<v-icon small>$icoExpandAlt</v-icon>
|
||||
Expand All
|
||||
</a-button></v-col>
|
||||
</v-row>
|
||||
|
||||
<!-- <v-btn color="primary" dark @click="btnTreeExpand()">{{
|
||||
@ -78,7 +78,7 @@
|
||||
</div>
|
||||
|
||||
<v-card-text>
|
||||
<div ref="treeGridParent" style="height: 500px">
|
||||
<div ref="treeGridParent" style="height: 450px">
|
||||
<component :ref="'treeGrid' + parentPrgmId" :is="loadGrid && dialog ? 'Grid' : null"
|
||||
:gridName="gridNameTree" :dataPath="searchParam.modalData.selectReadObjListTree"
|
||||
:parentPrgmId="parentPrgmId" :bindingData="bindingData" @getRowsData="getRowData"
|
||||
@ -89,10 +89,10 @@
|
||||
:tree-data="ftnPlcListTreeData"
|
||||
/> -->
|
||||
</v-card-text>
|
||||
<v-divider></v-divider>
|
||||
|
||||
<v-card-actions class="px-6 py-4 d-flex align-center justify-end">
|
||||
<a-button :ripple="false" @click="setUpdate()" class="mr-2">확인</a-button>
|
||||
<a-button :ripple="false" type="primary" @click="dialog = false" class="mr-2">닫기</a-button>
|
||||
<a-button :ripple="false" @click="dialog = false" class="mr-2">닫기</a-button>
|
||||
<a-button :ripple="false" type="primary" @click="setUpdate($event)">확인</a-button>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
@ -155,7 +155,7 @@ export default {
|
||||
|
||||
myModalKey: 'selectReadObjListTree',
|
||||
gridNameTree: 'treeGrid',
|
||||
loadGrid: true,
|
||||
loadGrid: false,
|
||||
|
||||
dialog: false,
|
||||
treeData: [], // 리턴받은 원본 트리 데이터
|
||||
@ -278,7 +278,7 @@ export default {
|
||||
{
|
||||
header: '검침개소명',
|
||||
name: 'readPlcNm',
|
||||
width: 370,
|
||||
width: 300,
|
||||
align: 'left',
|
||||
},
|
||||
{ header: '검침개소', name: 'name', align: 'center' },
|
||||
@ -289,73 +289,31 @@ export default {
|
||||
async getTreeData() {
|
||||
this.loadGrid = false;
|
||||
|
||||
// const res = await this.postApiReturn({
|
||||
// apiKey: 'selectReadPlcBaseInfo',
|
||||
// resKey: 'readPlcBaseInfoData',
|
||||
// sendParam: {
|
||||
// blocId:
|
||||
// this.searchParam.blocMstrList.length > 0
|
||||
// ? this.searchParam.blocMstrList[this.searchParam.blocId].blocId
|
||||
// : this.searchParam.blocId, //"BL0001",
|
||||
// // readObjId: this.searchParam.readObj, // "MTT00001" // 전력 코드 고정
|
||||
// readObjId: this.searchParam.searchReadObj, // "MTT00001" // 전력 코드 고정
|
||||
const res = await this.postApiReturn({
|
||||
apiKey: 'selectReadPlcBaseInfo',
|
||||
resKey: 'readPlcBaseInfoData',
|
||||
sendParam: {
|
||||
blocId:
|
||||
this.searchParam.blocMstrList.length > 0
|
||||
? this.searchParam.blocMstrList[this.searchParam.blocId].blocId
|
||||
: this.searchParam.blocId, //"BL0001",
|
||||
// readObjId: this.searchParam.readObj, // "MTT00001" // 전력 코드 고정
|
||||
readObjId: this.searchParam.searchReadObj, // "MTT00001" // 전력 코드 고정
|
||||
|
||||
// useFg: '1',
|
||||
// readPlcNmLike: this.searchWord,
|
||||
// },
|
||||
// });
|
||||
|
||||
const treeData = [
|
||||
{
|
||||
readPlcNm: '서울 본사',
|
||||
name: '본사',
|
||||
_children: [
|
||||
{
|
||||
readPlcNm: '서울 본사 - 1층',
|
||||
name: '1층',
|
||||
},
|
||||
{
|
||||
readPlcNm: '서울 본사 - 2층',
|
||||
name: '2층',
|
||||
},
|
||||
],
|
||||
useFg: '1',
|
||||
readPlcNmLike: this.searchWord,
|
||||
},
|
||||
{
|
||||
readPlcNm: '부산 지사',
|
||||
name: '지사',
|
||||
_children: [
|
||||
{
|
||||
readPlcNm: '부산 지사 - A동',
|
||||
name: 'A동',
|
||||
_children: [
|
||||
{
|
||||
readPlcNm: '부산 지사 - A동 1층',
|
||||
name: '1층',
|
||||
},
|
||||
{
|
||||
readPlcNm: '부산 지사 - A동 2층',
|
||||
name: '2층',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
readPlcNm: '부산 지사 - B동',
|
||||
name: 'B동',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
readPlcNm: '대전 창고',
|
||||
name: '창고',
|
||||
},
|
||||
];
|
||||
});
|
||||
|
||||
|
||||
// // console.log("treeData", res)
|
||||
// console.log("treeData", res)
|
||||
let myOptionsTree = {
|
||||
treeColumnOptions: {
|
||||
name: 'readPlcNm',
|
||||
},
|
||||
header: {
|
||||
height: 37,
|
||||
},
|
||||
rowHeight: 'auto',
|
||||
};
|
||||
if (this.searchParam.isMulti) {
|
||||
myOptionsTree['rowHeaders'] = [{ type: 'checkbox' }];
|
||||
@ -373,26 +331,26 @@ export default {
|
||||
|
||||
// this.treeData = res;
|
||||
// const ROOT = res[0].plcCd;
|
||||
// const setTreeData = await this.setTree({
|
||||
// gridKey: this.gridNameTree,
|
||||
// treeKey: 'READ_PLC_ID',
|
||||
// value: res.map(item => ({
|
||||
// ...item,
|
||||
// rowStat: null,
|
||||
// readPlcId: item.readPlcId,
|
||||
// readPlcIdNm: item.readPlcId,
|
||||
// upReadPlcId:
|
||||
// item.upReadPlcId == null || item.upReadPlcId == ''
|
||||
// ? ''
|
||||
// : item.upReadPlcId,
|
||||
// upReadPlcNm:
|
||||
// item.upReadPlcNm == null || item.upReadPlcNm == ''
|
||||
// ? ''
|
||||
// : item.upReadPlcNm,
|
||||
// blocId: item.blocId,
|
||||
// useFg: item.useFg === '1' ? true : false,
|
||||
// })),
|
||||
// });
|
||||
const setTreeData = await this.setTree({
|
||||
gridKey: this.gridNameTree,
|
||||
treeKey: 'READ_PLC_ID',
|
||||
value: res.map(item => ({
|
||||
...item,
|
||||
rowStat: null,
|
||||
readPlcId: item.readPlcId,
|
||||
readPlcIdNm: item.readPlcId,
|
||||
upReadPlcId:
|
||||
item.upReadPlcId == null || item.upReadPlcId == ''
|
||||
? ''
|
||||
: item.upReadPlcId,
|
||||
upReadPlcNm:
|
||||
item.upReadPlcNm == null || item.upReadPlcNm == ''
|
||||
? ''
|
||||
: item.upReadPlcNm,
|
||||
blocId: item.blocId,
|
||||
useFg: item.useFg === '1' ? true : false,
|
||||
})),
|
||||
});
|
||||
// this.treeData = setTreeData;
|
||||
|
||||
|
||||
@ -400,7 +358,7 @@ export default {
|
||||
modalKey: this.myModalKey,
|
||||
gridKey: this.gridNameTree,
|
||||
modalDataKey: this.modalDataKey,
|
||||
value: treeData,
|
||||
value: setTreeData.ROOT || [],
|
||||
});
|
||||
this.loadGrid = true;
|
||||
|
||||
@ -540,22 +498,4 @@ const selectReadObjListTree = {
|
||||
}
|
||||
}
|
||||
|
||||
@each $theme in dark, light {
|
||||
.v-application.#{$theme}-mode {
|
||||
.v-dialog {
|
||||
.v-card {
|
||||
&__title {
|
||||
|
||||
@if $theme ==dark {
|
||||
background-color: #2d3355;
|
||||
|
||||
.v-btn {
|
||||
background-color: #2d3355;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
@ -2,22 +2,15 @@
|
||||
<v-row class="search-box" align="center" no-gutters>
|
||||
<v-col v-if="label" :cols="labelCols">
|
||||
<label for="" class="search-box-label">
|
||||
<v-icon
|
||||
v-if="iconShow"
|
||||
small
|
||||
:class="['mr-1', required ? 'icon-orange' : 'icon-blue']"
|
||||
>$icoBulletPoint</v-icon
|
||||
>
|
||||
<v-icon v-if="iconShow" small :class="['mr-1', required ? 'icon-orange' : 'icon-blue']">$icoBulletPoint</v-icon>
|
||||
{{ label }}
|
||||
</label>
|
||||
</v-col>
|
||||
<v-col :cols="label ? textCols : ''">
|
||||
<v-select v-model="selectValue" :items="searchParam[parentPrgmId].blocMstrList" label="사업장을 선택하세요"
|
||||
item-text="blocNm" item-value="idx" append-icon="" class="v-select__custom" outlined
|
||||
<v-select v-model="selectValue" :items="searchParam[parentPrgmId].blocMstrList"
|
||||
item-text="blocNm" item-value="idx" append-icon="" outlined
|
||||
:hide-details="true" :class="['v-select__custom', customClass]">
|
||||
<template v-slot:append>
|
||||
<v-icon>$icoChevronDown</v-icon>
|
||||
</template>
|
||||
<template v-slot:append><v-icon>$icoChevronDown</v-icon></template>
|
||||
</v-select>
|
||||
</v-col>
|
||||
</v-row>
|
||||
|
@ -85,6 +85,11 @@ export default {
|
||||
type: String,
|
||||
require: false,
|
||||
},
|
||||
required: {
|
||||
type: Boolean,
|
||||
require: false,
|
||||
default: false
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
|
@ -11,9 +11,11 @@
|
||||
<v-col :cols="label ? textCols : ''">
|
||||
<v-select v-model="selectValue" :items="searchParam[parentPrgmId][dataKey + 'List']" item-text="commCdNm"
|
||||
item-value="commCd" outlined :hide-details="true" append-icon=""
|
||||
:class="['v-select__custom', customClass]"><template v-slot:append>
|
||||
:class="['v-select__custom', customClass]">
|
||||
<template v-slot:append>
|
||||
<v-icon>$icoChevronDown</v-icon>
|
||||
</template></v-select>
|
||||
</template>
|
||||
</v-select>
|
||||
<!-- @change="updateBlocCode($event)" -->
|
||||
</v-col>
|
||||
</v-row>
|
||||
|
Reference in New Issue
Block a user