어드민 메뉴명, 브래드크럼 수정 및 위치 변경

This commit is contained in:
kimjhjjang
2022-11-17 10:15:08 +09:00
parent f80d307b0d
commit 69aec986af
6 changed files with 485 additions and 464 deletions

View File

@@ -1,10 +1,9 @@
<template>
<div class="contents">
<div class="contents_wrap">
<div class="top_wrap">
<h3 class="title">알림톡 템플릿 관리</h3>
<p class="breadcrumb">채널관리 &gt; 알림톡 템플릿 관리</p>
<p class="breadcrumb">카카오 채널관리 &gt; 알림톡 템플릿 관리</p>
</div>
<div class="search_wrap">
<div class="select_box id">
@@ -25,18 +24,26 @@
</select>
</div>
<div class="input_box">
<input class="search-box" type="text" id="id1" placeholder="검색어 입력" v-model.trim="grid.params.searchText1"
@keyup.enter="search" maxlength="100"/>
<input
class="search-box"
type="text"
id="id1"
placeholder="검색어 입력"
v-model.trim="grid.params.searchText1"
@keyup.enter="search"
maxlength="100"
/>
</div>
<button type="button" class="button grey" @click="search">조회</button>
</div>
<div class="info">
<div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span>
<div class="count">
<span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span
>
<div class="select_box NumberSe">
<select name="" id="perPage" v-model="perPageCnt" @change="changePerPage()">
<option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">{{
option.text
}}
<option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">
{{ option.text }}
</option>
</select>
</div>
@@ -44,21 +51,20 @@
</div>
<div class="table">
<custom-grid
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
></custom-grid>
<common-modal ref="commmonModal"></common-modal>
</div>
</div>
</div>
@@ -69,8 +75,8 @@ import customGrid from '@/components/CustomGrid';
import channelMgtApi from '../service/channelMgtApi';
import xlsx from '@/common/excel';
import moment from 'moment';
import commonModal from "@/components/modal/commonModal";
import api from "@/service/api";
import commonModal from '@/components/modal/commonModal';
import api from '@/service/api';
export default {
name: 'temltList',
@@ -79,7 +85,7 @@ export default {
row: {},
authType: [],
statType: [],
cate2Code: "",
cate2Code: '',
totalItems: 0,
pageType: 'CHANN',
searchType1: '',
@@ -87,9 +93,9 @@ export default {
// 테이블 리스트 데이터
perPageCnt: 50,
options: [
{text: '20', value: 20},
{text: '50', value: 50},
{text: '100', value: 100}
{ text: '20', value: 20 },
{ text: '50', value: 50 },
{ text: '100', value: 100 },
],
grid: {
url: '/api/v1/bo/channelMgt/tmpltList',
@@ -99,40 +105,39 @@ export default {
initialRequest: false,
addCls: 'box_OFvis',
header: [
[
{header: 'No', childNames: []},
{header: '고객사명', childNames: []},
{header: '사업자번호', childNames: []},
{header: '템플릿코드', childNames: []},
{header: '템플릿명', childNames: []},
{header: '템플릿 유형', childNames: []},
{header: '상태', childNames: []},
{header: '발신프로필', childNames: []},
{header: '마지막 수정일', childNames: []}
]
{ header: 'No', childNames: [] },
{ header: '고객사명', childNames: [] },
{ header: '사업자번호', childNames: [] },
{ header: '템플릿코드', childNames: [] },
{ header: '템플릿명', childNames: [] },
{ header: '템플릿 유형', childNames: [] },
{ header: '상태', childNames: [] },
{ header: '발신프로필', childNames: [] },
{ header: '마지막 수정일', childNames: [] },
],
],
columns: [
{name: 'no', header: 'No', align: 'center', width: '4%'},
{name: 'custNm', header: '고객사명', align: 'center', width: '12%'},
{name: 'bregNo', header: '사업자번호', align: 'center', width: '10%'},
{name: 'tmpltCd', header: '템플릿코드', align: 'center', width: '12%'},
{name: 'tmpltNm', header: '템플릿명', align: 'center', width: '18%'},
{name: 'tmpltType', header: '템플릿 유형', align: 'center', width: '8%'},
{name: 'stat', header: '상태', align: 'center', width: '8%'},
{name: 'sendProfile', header: '발신프로필', align: 'center', width: '18%'},
{name: 'lastChgDt', header: '마지막 수정일', width: '10%', cls: 'td_line'}
{ name: 'no', header: 'No', align: 'center', width: '4%' },
{ name: 'custNm', header: '고객사명', align: 'center', width: '12%' },
{ name: 'bregNo', header: '사업자번호', align: 'center', width: '10%' },
{ name: 'tmpltCd', header: '템플릿코드', align: 'center', width: '12%' },
{ name: 'tmpltNm', header: '템플릿명', align: 'center', width: '18%' },
{ name: 'tmpltType', header: '템플릿 유형', align: 'center', width: '8%' },
{ name: 'stat', header: '상태', align: 'center', width: '8%' },
{ name: 'sendProfile', header: '발신프로필', align: 'center', width: '18%' },
{ name: 'lastChgDt', header: '마지막 수정일', width: '10%', cls: 'td_line' },
],
noDataStr: '검색 결과가 없습니다.',
params: {
searchType1: '',
searchType2: 'custNm',
searchText1: ''
searchText1: '',
},
excelHeader: []
}
excelHeader: [],
},
};
},
components: {
@@ -151,13 +156,11 @@ export default {
params: {
searchType1: '',
searchType2: 'custNm',
searchText1: ''
}
searchText1: '',
},
});
},
mounted() {
let page = 1;
// 페이지 정보 및 검색 조건
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
@@ -187,7 +190,7 @@ export default {
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
},
async getExcelDataDown() {
@@ -196,7 +199,7 @@ export default {
const params = {
searchType1: this.grid.params.searchType1,
searchType2: this.grid.params.searchType2,
searchText1: this.grid.params.searchText1
searchText1: this.grid.params.searchText1,
};
response = await channelMgtApi.tmpltListExcel(params);
@@ -206,10 +209,10 @@ export default {
result.data.list = result.data.list.map((item) => {
return {
...item,
custNm: this.fromHtmlEntities(item.custNm)
}
custNm: this.fromHtmlEntities(item.custNm),
};
});
if (result != null && result.retCode == "0000") {
if (result != null && result.retCode == '0000') {
return result.data;
} else {
return false;
@@ -232,24 +235,24 @@ export default {
const data = await this.getExcelDataDown();
let options = {
header: this.excelHeader,
dataOrder: 'header'
dataOrder: 'header',
};
xlsx.export(data.list, saveFileName, options).then(() => {
});
xlsx.export(data.list, saveFileName, options).then(() => {});
},
getExcelHeader() {
// 헤더를 mockup으로 관리한다.
channelMgtApi.getExcelHeader(this.pageType).then(res => {
channelMgtApi.getExcelHeader(this.pageType).then((res) => {
this.excelHeader = res;
});
},
setCodeData() {
// 상태 옵션 셋팅.
api.commCode({'grpCd': 'TMPLT_STTUS_CD'}).then(response => {
api.commCode({ grpCd: 'TMPLT_STTUS_CD' }).then((response) => {
this.statType = response.data.data.list;
});
},
changePerPage: function () { // 페이지당 조회할 개수
changePerPage: function () {
// 페이지당 조회할 개수
this.grid.pagePerRows = this.perPageCnt;
this.search(true);
},
@@ -261,15 +264,14 @@ export default {
},
beforeRouteLeave(to, from, next) {
const getP = this.$refs.table.getPagination();
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
// 라우트 하기전 실행
next();
}
},
};
</script>

View File

@@ -1,10 +1,9 @@
<template>
<div class="contents">
<div class="contents_wrap">
<div class="top_wrap">
<h3 class="title">청약정보조회</h3>
<p class="breadcrumb">고객관리 &gt; 청약정보조회 &gt; 청약고객관리</p>
<h3 class="title">청약고객관리</h3>
<p class="breadcrumb">고객관리 &gt; 청약고객관리 &gt; 청약고객관리</p>
</div>
<div class="top_tab">
@@ -12,109 +11,115 @@
<a href="javascript:void(0);" @click="toMove('memberList')">회원관리</a>
</div>
<!-- <div class="search_form">-->
<div class="search_wrap">
<div class="group">
<div class="input_box cal">
<label for="right" class="label">조회기간</label>
<div class="term">
<span class="custom_input icon_date">
<vuejs-datepicker
:language="ko"
:format="customFormatter"
:disabled-dates="disabledSDate"
v-model="startDate"
@selected="selectedStartDate(0)"
@closed="closeDate('start')"
></vuejs-datepicker>
</span>~
<span class="custom_input icon_date">
<vuejs-datepicker
:language="ko"
:format="customFormatter"
:disabled-dates="disabledEDate"
v-model="endDate"
@selected="selectedEndDate(0)"
@closed="closeDate('end')"
></vuejs-datepicker>
</span>
</div>
<!-- <div class="search_form">-->
<div class="search_wrap">
<div class="group">
<div class="input_box cal">
<label for="right" class="label">조회기간</label>
<div class="term">
<span class="custom_input icon_date">
<vuejs-datepicker
:language="ko"
:format="customFormatter"
:disabled-dates="disabledSDate"
v-model="startDate"
@selected="selectedStartDate(0)"
@closed="closeDate('start')"
></vuejs-datepicker> </span
>~
<span class="custom_input icon_date">
<vuejs-datepicker
:language="ko"
:format="customFormatter"
:disabled-dates="disabledEDate"
v-model="endDate"
@selected="selectedEndDate(0)"
@closed="closeDate('end')"
></vuejs-datepicker>
</span>
</div>
<div class="select_box id">
<label for="right" class="label">상태</label>
<select name="" id="" v-model="searchType1" @keyup.enter="search">
<option value="" selected>전체</option>
<option v-for="(option, i) in statType" v-bind:value="option.code" v-bind:key="i">
{{ option.codeNm }}
</option>
</select>
</div>
<div class="select_box">
<label for="right" class="label">유치채널</label>
<select name="" id="" v-model="searchType2" @keyup.enter="search">
<option value="" selected>전체</option>
<option value="01">고객셀프가입</option>
<option value="02">대리점</option>
<option value="03">고객센터</option>
<option value="04">직접영업</option>
<!-- <option v-for="(option, i) in userType" v-bind:value="option.code" v-bind:key="i">
</div>
<div class="select_box id">
<label for="right" class="label">상태</label>
<select name="" id="" v-model="searchType1" @keyup.enter="search">
<option value="" selected>전체</option>
<option v-for="(option, i) in statType" v-bind:value="option.code" v-bind:key="i">
{{ option.codeNm }}
</option>
</select>
</div>
<div class="select_box">
<label for="right" class="label">유치채널</label>
<select name="" id="" v-model="searchType2" @keyup.enter="search">
<option value="" selected>전체</option>
<option value="01">고객셀프가입</option>
<option value="02">대리점</option>
<option value="03">고객센터</option>
<option value="04">직접영업</option>
<!-- <option v-for="(option, i) in userType" v-bind:value="option.code" v-bind:key="i">
{{ option.codeNm }}
</option> -->
</select>
</div>
</div>
<div class="group">
<div class="select_box">
<label for="right" class="label">상세검색</label>
<select name="" id="" v-model="searchType3" @keyup.enter="search">
<option value="01">고객사명</option>
<option value="02">가입번호</option>
<option value="03">서비스ID</option>
</select>
</div>
<div class="input_box">
<input class="search-box" type="text" id="search" placeholder="검색어 입력" v-model.trim="grid.params.searchText1"
maxlength="100" @keyup.enter="search"/>
</div>
<button type="button" class="button grey" @click="search">조회</button>
</select>
</div>
</div>
<!-- </div>-->
<div class="group">
<div class="select_box">
<label for="right" class="label">상세검색</label>
<select name="" id="" v-model="searchType3" @keyup.enter="search">
<option value="01">고객사명</option>
<option value="02">가입번호</option>
<option value="03">서비스ID</option>
</select>
</div>
<div class="input_box">
<input
class="search-box"
type="text"
id="search"
placeholder="검색어 입력"
v-model.trim="grid.params.searchText1"
maxlength="100"
@keyup.enter="search"
/>
</div>
<button type="button" class="button grey" @click="search">조회</button>
</div>
</div>
<!-- </div>-->
<div class="info">
<div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span>
<div class="count">
<span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span
>
<div class="select_box NumberSe">
<select name="" id="" v-model="perPageCnt" @change="changePerPage()">
<option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">{{
option.text
}}
<option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">
{{ option.text }}
</option>
</select>
</div>
</div>
<div class="button_group">
<button type="button" class="button blue download" @click="excelDown();">엑셀 다운로드</button>
<button type="button" class="button blue download" @click="excelDown()">엑셀 다운로드</button>
</div>
</div>
<div class="table">
<custom-grid
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
></custom-grid>
</div>
<common-modal ref="commmonModal"></common-modal>
</div>
</div>
</template>
@@ -123,9 +128,9 @@
import customGrid from '@/components/CustomGrid';
import moment from 'moment';
import api from '@/service/api.js';
import custMgtApi from "../service/custMgtApi.js";
import custMgtApi from '../service/custMgtApi.js';
import xlsx from '@/common/excel';
import commonModal from "@/components/modal/commonModal";
import commonModal from '@/components/modal/commonModal';
class CustomATagRenderer {
constructor(props) {
@@ -133,7 +138,7 @@ class CustomATagRenderer {
const el = document.createElement('a');
el.href = 'javascript:void(0);';
el.className = 'btn_text';
el.innerText = String(props.colValue)
el.innerText = String(props.colValue);
this.el = el;
}
@@ -142,8 +147,8 @@ class CustomATagRenderer {
}
addEvent(selEl) {
selEl.addEventListener("click", () => {
const {callback} = this.props["cgrido" + this.props.colName].options;
selEl.addEventListener('click', () => {
const { callback } = this.props['cgrido' + this.props.colName].options;
callback(this.props);
});
}
@@ -171,36 +176,40 @@ export default {
// 테이블 리스트 데이터
perPageCnt: 50,
options: [
{text: '20', value: 20},
{text: '50', value: 50},
{text: '100', value: 100}
{ text: '20', value: 20 },
{ text: '50', value: 50 },
{ text: '100', value: 100 },
],
totalItems: 0,
grid: {
url: '/api/v1/bo/custMgt/subsList',
pagePerRows: 20,
pagination: true,
isCheckbox: false, // true:첫번째 컬럼 앞에 체크박스 생성 / false:체크박스 제거
isCheckbox: false, // true:첫번째 컬럼 앞에 체크박스 생성 / false:체크박스 제거
initialRequest: false,
addCls: 'box_OFvis',
columns: [
{name: 'no', header: 'No', align: 'center', width: '4%'},
{ name: 'no', header: 'No', align: 'center', width: '4%' },
{
name: 'serviceId', header: '서비스 ID\n(관리자 ID)', align: 'center', width: '12%', renderer: {
type: CustomATagRenderer
, options: {
name: 'serviceId',
header: '서비스 ID\n(관리자 ID)',
align: 'center',
width: '12%',
renderer: {
type: CustomATagRenderer,
options: {
callback: this.custDetail,
}
}
},
},
},
{name: 'custNm', header: '고객사명', align: 'center', width: '12%'},
{name: 'regNo', header: '가입번호', align: 'center', width: '12%'},
{name: 'regDt', header: '가입일', align: 'center', width: '12%', cls: 'td_line'},
{name: 'stat', header: '상태', align: 'center', width: '12%'},
{name: 'channel', header: '유치채널', align: 'center', width: '12%'},
{name: 'plan', header: '요금제', align: 'center', width: '12%'},
{name: 'carryOver', header: '이월누적금액', align: 'center', width: '12%'}
{ name: 'custNm', header: '고객사명', align: 'center', width: '12%' },
{ name: 'regNo', header: '가입번호', align: 'center', width: '12%' },
{ name: 'regDt', header: '가입일', align: 'center', width: '12%', cls: 'td_line' },
{ name: 'stat', header: '상태', align: 'center', width: '12%' },
{ name: 'channel', header: '유치채널', align: 'center', width: '12%' },
{ name: 'plan', header: '요금제', align: 'center', width: '12%' },
{ name: 'carryOver', header: '이월누적금액', align: 'center', width: '12%' },
],
noDataStr: '검색 결과가 없습니다.',
params: {
@@ -209,10 +218,10 @@ export default {
searchType3: '',
searchText1: '',
startDt: '',
endDt: ''
endDt: '',
},
excelHeader: []
}
excelHeader: [],
},
};
},
components: {
@@ -221,11 +230,9 @@ export default {
vuejsDatepicker,
},
created() {
this.setCodeData();
this.getExcelHeader();
this.setPeriodDay(0);
},
destroyed() {
this.$store.commit('searchcondition/updateSearchCondition', {
@@ -237,10 +244,9 @@ export default {
searchType3: '',
searchText1: '',
startDt: '',
endDt: ''
}
endDt: '',
},
});
},
mounted() {
// 달력 세팅
@@ -260,12 +266,11 @@ export default {
this.search(isKeep);
},
beforeRouteLeave(to, from, next) {
const getP = this.$refs.table.getPagination();
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
// 라우트 하기전 실행
next();
@@ -275,21 +280,22 @@ export default {
this.grid.params.startDt = moment(this.startDate).format('YYYYMMDD');
this.grid.params.endDt = moment(this.endDate).format('YYYYMMDD');
this.grid.params.searchType1 = this.searchType1
this.grid.params.searchType2 = this.searchType2
this.grid.params.searchType3 = this.searchType3
this.grid.params.searchType1 = this.searchType1;
this.grid.params.searchType2 = this.searchType2;
this.grid.params.searchType3 = this.searchType3;
this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData();
},
toMove(routeName) {
this.$router.push({name: routeName, params: {page: 1, searchText: ''}});
this.$router.push({ name: routeName, params: { page: 1, searchText: '' } });
},
custDetail(props) {
this.row.serviceId = props.serviceId;
this.$router.push({name: 'subsDetail', params: this.row});
this.$router.push({ name: 'subsDetail', params: this.row });
},
changePerPage: function () { // 페이지당 조회할 개수
changePerPage: function () {
// 페이지당 조회할 개수
this.grid.pagePerRows = this.perPageCnt;
this.search(true);
},
@@ -298,18 +304,18 @@ export default {
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
},
setCodeData() {
// 상태 옵션 셋팅.
api.commCode({'grpCd': 'SUBS_STTUS_CD'}).then(response => {
api.commCode({ grpCd: 'SUBS_STTUS_CD' }).then((response) => {
this.statType = response.data.data.list;
});
//
api.commCode({'grpCd': 'SVCUSER_TP_CD'}).then(response => {
api.commCode({ grpCd: 'SVCUSER_TP_CD' }).then((response) => {
this.userType = response.data.data.list;
});
},
@@ -322,7 +328,7 @@ export default {
searchType1: this.grid.params.searchType1,
searchType2: this.grid.params.searchType2,
searchType3: this.grid.params.searchType3,
searchText1: this.grid.params.searchText1
searchText1: this.grid.params.searchText1,
};
response = await custMgtApi.subsListExcel(params);
@@ -332,10 +338,10 @@ export default {
result.data.list = result.data.list.map((item) => {
return {
...item,
custNm: this.fromHtmlEntities(item.custNm)
}
custNm: this.fromHtmlEntities(item.custNm),
};
});
if (result != null && result.retCode == "0000") {
if (result != null && result.retCode == '0000') {
return result.data;
} else {
return false;
@@ -365,14 +371,13 @@ export default {
let options = {
header: this.excelHeader,
dataOrder: 'header'
dataOrder: 'header',
};
xlsx.export(data.list, saveFileName, options).then(() => {
});
xlsx.export(data.list, saveFileName, options).then(() => {});
},
getExcelHeader() {
// 헤더를 mockup으로 관리한다.
custMgtApi.getExcelHeader(this.pageType).then(res => {
custMgtApi.getExcelHeader(this.pageType).then((res) => {
this.excelHeader = res;
});
},
@@ -392,7 +397,6 @@ export default {
if (this.startDate > this.endDate) {
this.startDate = this.endDate;
}
},
selectedEndDate(day) {
if (day != undefined && day != null) {
@@ -402,11 +406,11 @@ export default {
closeDate(type) {
if (type != undefined && type != null) {
if (type == 'start') {
this.disabledSDate = {from: this.endDate};
this.disabledEDate = {to: this.startDate, from: this.endDate};
this.disabledSDate = { from: this.endDate };
this.disabledEDate = { to: this.startDate, from: this.endDate };
} else if (type == 'end') {
this.disabledSDate = {from: this.endDate};
this.disabledEDate = {to: this.startDate, from: new Date()};
this.disabledSDate = { from: this.endDate };
this.disabledEDate = { to: this.startDate, from: new Date() };
}
}
},

View File

@@ -1,10 +1,9 @@
<template>
<div class="contents">
<div class="contents_wrap">
<div class="top_wrap">
<h3 class="title">문자 발신번호 관리</h3>
<p class="breadcrumb">발신번호관리 &gt; 문자 발신번호 관리</p>
<h3 class="title">발신번호 관리</h3>
<p class="breadcrumb">발신번호관리 &gt; 발신번호 관리</p>
</div>
<div class="search_wrap">
<div class="group">
@@ -42,15 +41,23 @@
</select>
</div>
<div class="input_box">
<input class="search-box" type="text" id="search" placeholder="검색어 입력"
v-model.trim="grid.params.searchText1"
maxlength="100" @keyup.enter="search"/>
<input
class="search-box"
type="text"
id="search"
placeholder="검색어 입력"
v-model.trim="grid.params.searchText1"
maxlength="100"
@keyup.enter="search"
/>
</div>
<button type="button" class="button grey" @click="search">조회</button>
</div>
</div>
<div class="info">
<div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span>
<div class="count">
<span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span
>
<div class="select_box NumberSe">
<select name="" id="perPage" v-model="perPageCnt" @change="changePerPage()">
<option value="20">20</option>
@@ -60,50 +67,48 @@
</div>
</div>
<div class="button_group">
<button type="button" class="button blue add" @click="numberRegPopOpen();">등록</button>
<button type="button" class="button blue add" @click="numberRegPopOpen()">등록</button>
<button type="button" class="button white del" @click="deleteNumber()">삭제</button>
</div>
</div>
<div class="table">
<custom-grid
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
:pageRange="grid.pageRange"
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
:pageRange="grid.pageRange"
></custom-grid>
</div>
<number-reg-pop ref="numberRegPop"></number-reg-pop>
<number-detail-pop ref="numberDetailPop"/>
<number-detail-pop ref="numberDetailPop" />
<common-modal ref="commmonModal"></common-modal>
</div>
</div>
</template>
<script>
import customGrid from '@/components/CustomGrid';
import commonModal from "@/components/modal/commonModal";
import commonModal from '@/components/modal/commonModal';
import NumberRegPop from '../components/NumberRegPop';
import NumberDetailPop from "@/modules/sendNumMgt/components/NumberDetailPop";
import NumberDetailPop from '@/modules/sendNumMgt/components/NumberDetailPop';
import sendNumMgtApi from '../service/sendNumMgtApi';
class CustomATagRenderer {
constructor(props) {
this.props = props;
const el = document.createElement('a');
el.href = 'javascript:void(0);';
el.className = 'btn_text';
el.innerText = String(props.colValue)
el.innerText = String(props.colValue);
this.el = el;
}
@@ -112,8 +117,8 @@ class CustomATagRenderer {
}
addEvent(selEl) {
selEl.addEventListener("click", () => {
const {callback} = this.props["cgrido" + this.props.colName].options;
selEl.addEventListener('click', () => {
const { callback } = this.props['cgrido' + this.props.colName].options;
callback(this.props);
});
}
@@ -126,13 +131,13 @@ export default {
row: {},
authType: [],
statType: [],
cate2Code: "",
cate2Code: '',
totalItems: 0,
searchType4: 'regNo',
searchType3: '',
searchType2: '',
searchType1: '',
isFirst:true,
isFirst: true,
// 테이블 리스트 데이터
perPageCnt: 50,
grid: {
@@ -145,39 +150,43 @@ export default {
pageRange: 1,
header: [
[
{header: 'No', childNames: []},
{header: '고객사명', childNames: []},
{header: '관리자ID', childNames: []},
{header: '등록자ID', childNames: []},
{header: '사업자번호', childNames: []},
{header: '명의자 구분', childNames: []},
{header: '인입채널', childNames: []},
{header: '발신번호', childNames: []},
{header: '승인상태', childNames: []},
{header: '등록일자', childNames: []}
]
{ header: 'No', childNames: [] },
{ header: '고객사명', childNames: [] },
{ header: '관리자ID', childNames: [] },
{ header: '등록자ID', childNames: [] },
{ header: '사업자번호', childNames: [] },
{ header: '명의자 구분', childNames: [] },
{ header: '인입채널', childNames: [] },
{ header: '발신번호', childNames: [] },
{ header: '승인상태', childNames: [] },
{ header: '등록일자', childNames: [] },
],
],
columns: [
{name: 'no', header: 'No', align: 'center', width: '5%'},
{name: 'regReqNo', hidden: true},
{name: 'bizrAuthYn', hidden: true},
{name: 'custNm', header: '고객사명', align: 'center', width: '5%'},
{name: 'adminId', header: '관리자ID', align: 'center', width: '10%'},
{name: 'register', header: '등록자ID', align: 'center', width: '10%'},
{name: 'bregNo', header: '사업자번호', align: 'center', width: '10%'},
{name: 'nmineeDivCd', header: '명의자 구분', align: 'center', width: '10%'},
{name: 'inchDivCd', header: '인입채널', align: 'center', width: '10%'},
{ name: 'no', header: 'No', align: 'center', width: '5%' },
{ name: 'regReqNo', hidden: true },
{ name: 'bizrAuthYn', hidden: true },
{ name: 'custNm', header: '고객사명', align: 'center', width: '5%' },
{ name: 'adminId', header: '관리자ID', align: 'center', width: '10%' },
{ name: 'register', header: '등록자ID', align: 'center', width: '10%' },
{ name: 'bregNo', header: '사업자번호', align: 'center', width: '10%' },
{ name: 'nmineeDivCd', header: '명의자 구분', align: 'center', width: '10%' },
{ name: 'inchDivCd', header: '인입채널', align: 'center', width: '10%' },
{
name: 'sndrno', header: '발신번호', align: 'center', width: '10%', renderer: {
type: CustomATagRenderer
, options: {
name: 'sndrno',
header: '발신번호',
align: 'center',
width: '10%',
renderer: {
type: CustomATagRenderer,
options: {
callback: this.numberDetail,
}
}
},
},
},
{name: 'sttusCd', header: '승인상태', align: 'center', width: '10%'},
{name: 'regDt', header: '등록일자', width: '10%', cls: 'td_line'}
{ name: 'sttusCd', header: '승인상태', align: 'center', width: '10%' },
{ name: 'regDt', header: '등록일자', width: '10%', cls: 'td_line' },
],
noDataStr: '검색 결과가 없습니다.',
params: {
@@ -187,10 +196,10 @@ export default {
searchType4: '',
searchText1: '',
pagePerRows: '',
page: ''
page: '',
},
excelHeader: []
}
excelHeader: [],
},
};
},
components: {
@@ -201,7 +210,7 @@ export default {
},
created() {
// this.grid.pagePerRows = 50
this.isFirst=true
this.isFirst = true;
},
destroyed() {
this.$store.commit('searchcondition/updateSearchCondition', {
@@ -212,8 +221,8 @@ export default {
searchType2: '',
searchType3: '',
searchType4: '',
searchText1: ''
}
searchText1: '',
},
});
},
mounted() {
@@ -233,25 +242,24 @@ export default {
},
methods: {
search: function (isKeep) {
this.grid.params.searchType1 = this.searchType1
this.grid.params.searchType2 = this.searchType2
this.grid.params.searchType3 = this.searchType3
this.grid.params.searchType4 = this.searchType4
if(this.isFirst){
this.grid.pagePerRows = 50
this.grid.params.searchType1 = this.searchType1;
this.grid.params.searchType2 = this.searchType2;
this.grid.params.searchType3 = this.searchType3;
this.grid.params.searchType4 = this.searchType4;
if (this.isFirst) {
this.grid.pagePerRows = 50;
}
this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData();
this.isFirst=false
this.isFirst = false;
},
sendStoreData: function () {
const getP = this.$refs.table.getPagination();
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
},
numberRegPopOpen: function () {
this.$refs.numberRegPop.numberRegPopopen();
@@ -265,16 +273,15 @@ export default {
deleteNumber() {
if (this.doValidate()) {
this.row.title = '문자발신번호 관리';
this.row.msg1 = '삭제 하시겠습니까?'
this.row.msg1 = '삭제 하시겠습니까?';
this.$refs.commmonModal.confirmModalOpen2(this.row);
}
},
async numberDelete() {
try {
let response = await sendNumMgtApi.deleteNumber(this.row);
const result = response.data;
if (result != null && result.retCode == "0000") {
if (result != null && result.retCode == '0000') {
this.$refs.table.reloadData();
return;
} else {
@@ -288,7 +295,8 @@ export default {
this.$refs.commmonModal.alertModalOpen(this.row);
}
},
doValidate() { //로우데이터 삭제하도록 수정
doValidate() {
//로우데이터 삭제하도록 수정
if (this.totalItems == 0) {
this.row.title = '문자발신번호 관리';
@@ -304,7 +312,7 @@ export default {
return false;
}
//const param = chkList.map((row)=>({regReqNo:row.regReqNo} ));
const param = chkList.map((row) => ({seqNo: row.seqNo}));
const param = chkList.map((row) => ({ seqNo: row.seqNo }));
this.row.list = param;
return true;
},
@@ -313,20 +321,20 @@ export default {
this.numberDelete();
}
},
changePerPage: function () { // 페이지당 조회할 개수
changePerPage: function () {
// 페이지당 조회할 개수
this.grid.pagePerRows = this.perPageCnt;
},
},
beforeRouteLeave(to, from, next) {
const getP = this.$refs.table.getPagination();
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
// 라우트 하기전 실행
next();
}
},
};
</script>

View File

@@ -3,7 +3,7 @@
<div class="contents_wrap">
<div class="top_wrap">
<h3 class="title">관리자/유치채널 관리</h3>
<p class="breadcrumb">시스템관리 &gt; 관리자/유치채널 관리</p>
<p class="breadcrumb">운영 관리 &gt; 관리자/유치채널 관리</p>
</div>
<div class="search_wrap">
<div class="select_box">
@@ -26,37 +26,58 @@
</div>
<div class="input_box id">
<label for="id1" class="label">ID</label>
<input class="search-box" type="text" id="id1" placeholder="검색어 입력" v-model.trim="grid.params.searchText1"
@keyup.enter="search" :readonly="!isFocused" @focus="isFocused = true" @blur="isFocused = false"/>
<input
class="search-box"
type="text"
id="id1"
placeholder="검색어 입력"
v-model.trim="grid.params.searchText1"
@keyup.enter="search"
:readonly="!isFocused"
@focus="isFocused = true"
@blur="isFocused = false"
/>
</div>
<div class="input_box">
<label for="name" class="label">이름(대리점명)</label>
<input class="search-box" type="text" id="name" placeholder="검색어 입력" v-model.trim="grid.params.searchText2"
@keyup.enter="search" :readonly="!isFocused" @focus="isFocused = true" @blur="isFocused = false"/>
<input
class="search-box"
type="text"
id="name"
placeholder="검색어 입력"
v-model.trim="grid.params.searchText2"
@keyup.enter="search"
:readonly="!isFocused"
@focus="isFocused = true"
@blur="isFocused = false"
/>
</div>
<button type="button" class="button grey" @click="search">조회</button>
</div>
<div class="info">
<div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span></div>
<div class="count">
<span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span
>
</div>
<div class="button_group">
<button type="button" class="button blue admin add" @click="adminRegPopOpen();">관리자 등록</button>
<button type="button" class="button blue channel add" @click="adminReg2PopOpen();">유치채널 등록</button>
<button type="button" class="button white delete del" @click="rowDelete();">삭제</button>
<button type="button" class="button blue admin add" @click="adminRegPopOpen()">관리자 등록</button>
<button type="button" class="button blue channel add" @click="adminReg2PopOpen()">유치채널 등록</button>
<button type="button" class="button white delete del" @click="rowDelete()">삭제</button>
</div>
</div>
<div class="table">
<custom-grid
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
ref="table"
:totalItems="'totalItems'"
:url="grid.url"
:pagePerRows="grid.pagePerRows"
:initialRequest="grid.initialRequest"
:pagination="grid.pagination"
:isCheckbox="grid.isCheckbox"
:columns="grid.columns"
:noDataStr="grid.noDataStr"
:addCls="grid.addCls"
:header="grid.headder"
></custom-grid>
</div>
<admin-reg-pop ref="adminRegModal"></admin-reg-pop>
@@ -69,11 +90,10 @@
<script>
import customGrid from '@/components/CustomGrid';
import AdminRegPop from '../components/AdminRegPop';
import commonModal from "@/components/modal/commonModal";
import commonModal from '@/components/modal/commonModal';
import AdminDetailPop from '../components/AdminDetailPop';
import api from '@/service/api.js';
import sysMgtApi from "../service/sysMgtApi.js";
import sysMgtApi from '../service/sysMgtApi.js';
class CustomATagRenderer {
constructor(props) {
@@ -81,7 +101,7 @@ class CustomATagRenderer {
const el = document.createElement('a');
el.href = 'javascript:void(0);';
el.className = 'btn_text';
el.innerText = String(props.colValue)
el.innerText = String(props.colValue);
this.el = el;
}
@@ -90,8 +110,8 @@ class CustomATagRenderer {
}
addEvent(selEl) {
selEl.addEventListener("click", () => {
const {callback} = this.props["cgrido" + this.props.colName].options;
selEl.addEventListener('click', () => {
const { callback } = this.props['cgrido' + this.props.colName].options;
callback(this.props);
});
}
@@ -105,7 +125,7 @@ export default {
row: {},
authType: [],
statType: [],
cate2Code: "",
cate2Code: '',
totalItems: 0,
// 테이블 리스트 데이터
perPageCnt: 20,
@@ -115,34 +135,38 @@ export default {
url: '/api/v1/bo/sysMgt/adminList',
pagePerRows: 20,
pagination: true,
isCheckbox: true, // true:첫번째 컬럼 앞에 체크박스 생성 / false:체크박스 제거
isCheckbox: true, // true:첫번째 컬럼 앞에 체크박스 생성 / false:체크박스 제거
initialRequest: false,
addCls: 'box_OFvis',
columns: [
{name: 'no', header: 'No', align: 'center', width: '6%'},
{name: 'auth', header: '권한', align: 'center', width: '18%'},
{name: 'name', header: '이름(대리점명)', align: 'center', width: '18%'},
{ name: 'no', header: 'No', align: 'center', width: '6%' },
{ name: 'auth', header: '권한', align: 'center', width: '18%' },
{ name: 'name', header: '이름(대리점명)', align: 'center', width: '18%' },
{
name: 'adminId', header: 'ID', align: 'center', width: '18%', renderer: {
type: CustomATagRenderer
, options: {
name: 'adminId',
header: 'ID',
align: 'center',
width: '18%',
renderer: {
type: CustomATagRenderer,
options: {
callback: this.detailPop,
}
}
},
},
},
{name: 'adminStat', header: '상태', align: 'center', width: '18%', cls: 'td_line'},
{name: 'regDt', header: '등록일', align: 'center', width: '18%'}
{ name: 'adminStat', header: '상태', align: 'center', width: '18%', cls: 'td_line' },
{ name: 'regDt', header: '등록일', align: 'center', width: '18%' },
],
noDataStr: '검색 결과가 없습니다.',
params: {
searchType1: '',
searchType2: '',
searchText1: '',
searchText2: ''
searchText2: '',
},
excelHeader: []
}
excelHeader: [],
},
};
},
components: {
@@ -157,9 +181,7 @@ export default {
//let cont = document.querySelector(".wrap");
//cont.classList.add("main_wrap");
},
destroyed() {
},
destroyed() {},
mounted() {
let page = 1;
// 페이지 정보 및 검색 조건
@@ -173,29 +195,26 @@ export default {
isKeep = true;
}
this.search(isKeep);
},
methods: {
search: function (isKeep) {
this.grid.params.searchType1 = this.searchType1
this.grid.params.searchType2 = this.searchType2
this.grid.params.searchType1 = this.searchType1;
this.grid.params.searchType2 = this.searchType2;
this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData();
},
detailPop(props) {
this.$refs.adminDetailModal.adminDetailModalOpen(props);
},
ModalOpen: function (target) {
},
ModalOpen: function (target) {},
adminRegPopOpen: function () {
this.$refs.adminRegModal.ModalOpen(1);
},
adminReg2PopOpen: function () {
this.$refs.adminRegModal.ModalOpen(2);
},
doValidate() { //로우데이터 삭제하도록 수정
doValidate() {
//로우데이터 삭제하도록 수정
if (this.totalItems == 0) {
this.row.title = '관리자/유치채널 관리';
@@ -211,7 +230,7 @@ export default {
return false;
}
const param = chkList.map((row) => ({adminId: row.adminId}));
const param = chkList.map((row) => ({ adminId: row.adminId }));
this.row.list = param;
return true;
},
@@ -220,7 +239,7 @@ export default {
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
@@ -228,27 +247,23 @@ export default {
async setCodeData() {
// 상태
try {
const res = await api.commCode({'grpCd': 'ADM_STTUS_CD'});
if(res.data.retCode == '0000'){
this.statType = res.data.data.list;
}
}catch(err){
}
const res = await api.commCode({ grpCd: 'ADM_STTUS_CD' });
if (res.data.retCode == '0000') {
this.statType = res.data.data.list;
}
} catch (err) {}
// 권한
try {
const response = await api.commAuth();
if(response.data.retCode == '0000'){
this.authType = response.data.data.list;
}
}catch(err){
}
const response = await api.commAuth();
if (response.data.retCode == '0000') {
this.authType = response.data.data.list;
}
} catch (err) {}
},
rowDelete() {
if (this.doValidate()) {
this.row.title = '관리자/유치채널 관리';
this.row.msg1 = '삭제 하시겠습니까?'
this.row.msg1 = '삭제 하시겠습니까?';
this.$refs.commmonModal.confirmModalOpen2(this.row);
}
},
@@ -256,7 +271,7 @@ export default {
try {
let response = await sysMgtApi.deleteAdmin(this.row);
const result = response.data;
if (result != null && result.retCode == "0000") {
if (result != null && result.retCode == '0000') {
this.$refs.table.reloadData();
return;
}
@@ -277,15 +292,14 @@ export default {
},
beforeRouteLeave(to, from, next) {
const getP = this.$refs.table.getPagination();
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
// 라우트 하기전 실행
next();
}
},
};
</script>

View File

@@ -3,10 +3,13 @@
<div class="contents_wrap">
<div class="top_wrap">
<h3 class="title">권한 관리</h3>
<p class="breadcrumb">시스템관리 &gt; 권한 관리</p>
<p class="breadcrumb">운영 관리 &gt; 권한 관리</p>
</div>
<div class="info">
<div class="count"> <span>{{ totalCnt }}</span></div>
<div class="count">
<span>{{ totalCnt }}</span
>
</div>
<div class="button_group">
<button type="button" class="button blue add" @click="insertAuth()">권한 추가</button>
</div>
@@ -14,37 +17,36 @@
<div class="table">
<table>
<colgroup>
<col width="10%"/>
<col width="20%"/>
<col width="20%"/>
<col width="15%"/>
<col width="20%"/>
<col width="15%"/>
<col width="10%" />
<col width="20%" />
<col width="20%" />
<col width="15%" />
<col width="20%" />
<col width="15%" />
</colgroup>
<thead>
<tr>
<th>NO</th>
<th>코드</th>
<th>권한명</th>
<th>상태</th>
<th>등록일</th>
<th></th>
</tr>
<tr>
<th>NO</th>
<th>코드</th>
<th>권한명</th>
<th>상태</th>
<th>등록일</th>
<th></th>
</tr>
</thead>
<tbody>
<tr v-for="(option, i) in list" v-bind:key="i">
<td>{{ option.no }}</td>
<td>{{ option.authCd }}</td>
<td>{{ option.authNm }}</td>
<td>{{ option.authStat }}</td>
<td>{{ option.regDt }}</td>
<td v-if="option.authCd === '1001' || option.authCd === '1002'" class="two_btn_group">
</td>
<td v-else class="two_btn_group">
<button type="button" class="button grey" @click="updateAuth(option.authCd)">수정</button>
<button type="button" class="button white delete" @click="authDelete(option.authCd)">삭제</button>
</td>
</tr>
<tr v-for="(option, i) in list" v-bind:key="i">
<td>{{ option.no }}</td>
<td>{{ option.authCd }}</td>
<td>{{ option.authNm }}</td>
<td>{{ option.authStat }}</td>
<td>{{ option.regDt }}</td>
<td v-if="option.authCd === '1001' || option.authCd === '1002'" class="two_btn_group"></td>
<td v-else class="two_btn_group">
<button type="button" class="button grey" @click="updateAuth(option.authCd)">수정</button>
<button type="button" class="button white delete" @click="authDelete(option.authCd)">삭제</button>
</td>
</tr>
</tbody>
</table>
</div>
@@ -54,8 +56,8 @@
</template>
<script>
import sysMgtApi from "../service/sysMgtApi.js";
import commonModal from "@/components/modal/commonModal";
import sysMgtApi from '../service/sysMgtApi.js';
import commonModal from '@/components/modal/commonModal';
export default {
name: 'authList',
@@ -72,23 +74,19 @@ export default {
created() {
this.getAuthList();
},
destroyed() {
},
mounted() {
},
destroyed() {},
mounted() {},
methods: {
async getAuthList() {
try {
const response = await sysMgtApi.authList(this.row);
const result = response.data;
if (result != null && result.retCode == "0000") {
if (result != null && result.retCode == '0000') {
this.list = result.data.list;
this.totalCnt = result.data.list.length;
} else {
this.row.title = '권한 관리';
this.row.msg1 = '조회정보가 없습니다.'
this.row.msg1 = '조회정보가 없습니다.';
this.$refs.commmonModal.alertModalOpen(this.row);
}
} catch (err) {
@@ -98,31 +96,31 @@ export default {
}
},
insertAuth() {
this.$router.push({name: 'authAdd'});
this.$router.push({ name: 'authAdd' });
},
updateAuth(target) {
this.$router.push({name: 'authModify', params: {targetAuthCd: target}});
this.$router.push({ name: 'authModify', params: { targetAuthCd: target } });
},
authDelete(target) {
this.row.authCd = target;
this.row.title = '권한 관리';
this.row.msg1 = '삭제 하시겠습니까?'
this.row.msg1 = '삭제 하시겠습니까?';
this.$refs.commmonModal.confirmModalOpen2(this.row);
},
async deleteAuth() {
try {
let response = await sysMgtApi.deleteAuth(this.row);
const result = response.data;
if (result != null && result.retCode == "0000") {
if (result != null && result.retCode == '0000') {
this.getAuthList();
return;
}else if(result != null && result.retCode == "4020"){
this.row = {}
} else if (result != null && result.retCode == '4020') {
this.row = {};
this.row.title = '권한 관리';
this.row.msg1 = '해당 권한에 매핑된 사용자가 있습니다.';
this.$refs.commmonModal.alertModalOpen(this.row);
} else {
this.row = {}
this.row = {};
this.row.title = '권한 관리';
this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row);
@@ -139,6 +137,6 @@ export default {
this.deleteAuth();
}
},
}
},
};
</script>

View File

@@ -1,18 +1,12 @@
<template>
<div class="contents">
<div class="contents_wrap">
<div class="top_wrap">
<h3 class="title">배치 모니터링</h3>
<p class="breadcrumb">모니터링 &gt; 배치 모니터링</p>
<p class="breadcrumb">운영 관리 &gt; 배치 모니터링</p>
</div>
<div class= "table">
<custom-grid
ref="table"
:url="grid.url"
:columns="grid.columns"
></custom-grid>
<div class="table">
<custom-grid ref="table" :url="grid.url" :columns="grid.columns"></custom-grid>
</div>
</div>
</div>
@@ -27,7 +21,7 @@ class CustomATagRenderer {
const el = document.createElement('a');
el.href = 'javascript:void(0);';
el.className = 'btn_text';
el.innerText = String(props.colValue)
el.innerText = String(props.colValue);
this.el = el;
}
@@ -36,8 +30,8 @@ class CustomATagRenderer {
}
addEvent(selEl) {
selEl.addEventListener("click", () => {
const {callback} = this.props["cgrido" + this.props.colName].options;
selEl.addEventListener('click', () => {
const { callback } = this.props['cgrido' + this.props.colName].options;
callback(this.props);
});
}
@@ -53,33 +47,38 @@ export default {
url: '/api/v1/bo/sysMgt/batchList',
header: [
[
{header: '배치ID', childNames: {}},
{header: '배치명', childNames: {}},
]
{ header: '배치ID', childNames: {} },
{ header: '배치명', childNames: {} },
],
],
columns: [
{name: 'batchType', header: '배치유형', align: 'center', width: '4%'},
{name: 'batchId', header:'배치ID', align:'center', width:'10%'},
{ name: 'batchType', header: '배치유형', align: 'center', width: '4%' },
{ name: 'batchId', header: '배치ID', align: 'center', width: '10%' },
{
name: 'batchNm', header:'배치명',align:'left', width:'15%', renderer: {
type: CustomATagRenderer
, options: {
callback: this.batchDetail,
}
}},
{name: 'batchCycle', header:'실행일자',align:'center', width:'7%'},
{name: 'batchTime', header:'실행시간',align:'center', width:'6%'},
{name: 'regDt', header:'배치 수행시간',align:'center', width:'13%'},
{name: 'sttusCd', header:'상태',align:'center', width:'5%'},
{name: 'errMsg', header:'메시지',align:'left', width:'40%'}
]
}
name: 'batchNm',
header: '배치명',
align: 'left',
width: '15%',
renderer: {
type: CustomATagRenderer,
options: {
callback: this.batchDetail,
},
},
},
{ name: 'batchCycle', header: '실행일자', align: 'center', width: '7%' },
{ name: 'batchTime', header: '실행시간', align: 'center', width: '6%' },
{ name: 'regDt', header: '배치 수행시간', align: 'center', width: '13%' },
{ name: 'sttusCd', header: '상태', align: 'center', width: '5%' },
{ name: 'errMsg', header: '메시지', align: 'left', width: '40%' },
],
},
};
},
components: {
customGrid: customGrid,
},
created(){
created() {
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
},
destroyed() {
@@ -89,21 +88,20 @@ export default {
perPage: 50,
params: {
startDt: '',
endDt: ''
}
endDt: '',
},
});
},
mounted(){
mounted() {
let page = 1;
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
let isKeep = false;
if(getCondition){
if (getCondition) {
this.grid.params = getCondition.params;
page = getCondition.page;
isKeep = true;
}
this.search(isKeep);
},
methods: {
@@ -111,23 +109,20 @@ export default {
this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData();
},
batchDetail(props){
batchDetail(props) {
this.row.batchId = props.batchId;
this.$router.push({path: `/sysMgt/batchDetail/${props.batchId}`, params: this.row});
this.$router.push({ path: `/sysMgt/batchDetail/${props.batchId}`, params: this.row });
},
sendStoreData: function () {
const getP = this.$refs.table.getPagination();
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
params: this.grid.params,
});
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
},
},
};
</script>