mirror of
http://git.mhez-qa.uplus.co.kr/hubez/hubez-admin.git
synced 2026-01-28 05:54:55 +09:00
- 시스템관리 > 관리자목록조회, 관리자등록, 관리자수정, 관리자삭제, 관리자상세조회
This commit is contained in:
@@ -1,33 +1,33 @@
|
||||
import CustList from '../views/CustList'
|
||||
import MemberList from '../views/MemberList'
|
||||
import SubsDetail from '../views/SubsDetail'
|
||||
import MemberDetail from '../views/MemberDetail'
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/custMgt/subsList',
|
||||
component: CustList,
|
||||
name: 'subsList',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/custMgt/memberList',
|
||||
component: MemberList,
|
||||
name: 'memberList',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/custMgt/subsDetail',
|
||||
component: SubsDetail,
|
||||
name: 'subsDetail',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/custMgt/memberDetail',
|
||||
component: MemberDetail,
|
||||
name: 'memberDetail',
|
||||
meta: { public: true }
|
||||
},
|
||||
|
||||
]
|
||||
|
||||
import CustList from '../views/CustList'
|
||||
import MemberList from '../views/MemberList'
|
||||
import SubsDetail from '../views/SubsDetail'
|
||||
import MemberDetail from '../views/MemberDetail'
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/custMgt/subsList',
|
||||
component: CustList,
|
||||
name: 'subsList',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/custMgt/memberList',
|
||||
component: MemberList,
|
||||
name: 'memberList',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/custMgt/subsDetail',
|
||||
component: SubsDetail,
|
||||
name: 'subsDetail',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/custMgt/memberDetail',
|
||||
component: MemberDetail,
|
||||
name: 'memberDetail',
|
||||
meta: { public: true }
|
||||
},
|
||||
|
||||
]
|
||||
|
||||
|
||||
@@ -1,211 +1,285 @@
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">청약고객정보목록조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<!-- <form autocomplete="off" class="search_form"> -->
|
||||
<div class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right" v-model="grid.params.searchType1">
|
||||
<option value="">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right" v-model="grid.params.searchType2">
|
||||
<option value="">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력" v-model="grid.params.searchText1"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력" v-model="grid.params.searchText2"/>
|
||||
</div>
|
||||
<button type="button" class="button grey" v-on:click="search">조회</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- </form> -->
|
||||
<div class="info">
|
||||
<!-- <div class="count">총 <span>100</span>건</div> -->
|
||||
<div class="count">총 <span>{{ totalItems }}</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin" @click="ModalOpen('modal20')">관리자 등록</button>
|
||||
<button type="button" class="button blue channel" @click="ModalOpen('modal23')">유지채널 등록</button>
|
||||
<button type="button" class="button white delete" @click="deleteRow()">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="grid.url"
|
||||
:perPage="grid.perPage"
|
||||
:initialRequest="grid.initialRequest"
|
||||
:pagination="grid.pagination"
|
||||
:isCheckbox="grid.isCheckbox"
|
||||
:columns="grid.columns"
|
||||
:noDataStr="grid.noDataStr"
|
||||
:addCls="grid.addCls"
|
||||
:header="grid.headder"
|
||||
></custom-grid>
|
||||
</div>
|
||||
<system-popup ref="systemModal"></system-popup>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
import SystemPopup from '@/components/SystemPopup.vue';
|
||||
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
totalItems: 0,
|
||||
grid: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60},
|
||||
{ name: 'auth', header: '권한', align: 'center', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
params: {
|
||||
searchType1: '',
|
||||
searchType2: '',
|
||||
searchText1: '',
|
||||
searchText2: ''
|
||||
},
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid,
|
||||
SystemPopup
|
||||
},
|
||||
created(){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
//let cont = document.querySelector(".wrap");
|
||||
//cont.classList.add("main_wrap");
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let page = 1;
|
||||
// 페이지 정보 및 검색 조건
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
let isKeep = false;
|
||||
if (getCondition) {
|
||||
this.grid.perPage = getCondition.perPage;
|
||||
this.grid.params = getCondition.params;
|
||||
if (getCondition.sort != undefined && getCondition.sort != null) {
|
||||
this.grid.params.sort = getCondition.sort;
|
||||
}
|
||||
page = getCondition.page;
|
||||
isKeep = true;
|
||||
}
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.grid.params);
|
||||
this.$refs.table.search(this.grid.params, isKeep);
|
||||
},
|
||||
ModalOpen: function(target){
|
||||
this.$refs.systemModal.ModalOpen(target);
|
||||
},
|
||||
deleteRow: function(){ //로우데이터 삭제하도록 수정
|
||||
var checkTest = this.$refs.table.checkedElementDatas();
|
||||
if(checkTest.length == 0){
|
||||
alert('체크박스에 체크를 해주세요.')
|
||||
}
|
||||
for(var i = 0; i < checkTest.length; i++){
|
||||
alert(checkTest[i].adminId);
|
||||
}
|
||||
},
|
||||
memberDetail: function(data) {
|
||||
if(data.adminId == 'free'){
|
||||
this.$router.push({
|
||||
path: `./views/MemberDetail`
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">청약고객관리</h3>
|
||||
<p class="breadcrumb">고객관리 > 청약고객관리 > 회원관리</p>
|
||||
</div>
|
||||
|
||||
<div class="top_tab">
|
||||
<a href="customer_01_list.html" class="on">청약고객관리</a><a href="customer_02_list.html">회원관리</a>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="group">
|
||||
<div class="input_box cal">
|
||||
<label for="right" class="label">조회기간</label>
|
||||
<input class="" type="text" id="" v-model="grid.params.startDt"/>
|
||||
<input class="" type="text" id="" v-model="grid.params.endDt"/>
|
||||
</div>
|
||||
<div class="select_box id">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="" v-model="grid.params.searchType1">
|
||||
<option value="">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="정지">정지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">구분</label>
|
||||
<select name="" id="" v-model="grid.params.searchType2">
|
||||
<option value="">전체</option>
|
||||
<option value="관리자">관리자</option>
|
||||
<option value="사용자">사용자</option>
|
||||
<option value="테스트">테스트</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="group">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상세검색</label>
|
||||
<select name="" id="" v-model="grid.params.searchType3">
|
||||
<option value="">전체</option>
|
||||
<option value="ID">ID</option>
|
||||
<option value="이름">이름</option>
|
||||
<option value="관리자ID">관리자ID</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<input class="search-box" type="text" id="search" placeholder="검색어 입력" v-model="grid.params.searchText1"/>
|
||||
</div>
|
||||
<button type="button" class="button grey" @click="search">조회</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="info">
|
||||
<div class="count">총 <span>{{ totalItems }}</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>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue">테스트 ID 생성</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"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
import moment from 'moment';
|
||||
//import api from '../service/api';
|
||||
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
// 달력 데이터
|
||||
sDateDiv: 'day',
|
||||
eDateDiv: 'year',
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
disabledSDate: { from: new Date()},
|
||||
disabledEDate: { to: new Date()},
|
||||
|
||||
// 테이블 리스트 데이터
|
||||
perPageCnt: 20,
|
||||
options: [
|
||||
{ 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:체크박스 제거
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
/*
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '서비스 ID\n(관리자 ID)', childNames: [] },
|
||||
{ header: '고객사명', childNames: [] },
|
||||
{ header: '가입번호', childNames: [] },
|
||||
{ header: '가입일', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '유치채널', childNames: [] },
|
||||
{ header: '요금제', childNames: [] },
|
||||
{ header: '이월누적금액', childNames: [] }
|
||||
]
|
||||
],
|
||||
*/
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'No', align: 'center', width: 60},
|
||||
{ name: 'serviceId', header: '서비스 ID\n(관리자 ID)', align: 'center', width: 160 },
|
||||
{ name: 'custNm', header: '고객사명', align: 'center', width: 130},
|
||||
{ name: 'regNo', header: '가입번호', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '가입일', align: 'center', width: 130, cls: 'td_line'},
|
||||
{ name: 'stat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'channel', header: '유치채널', align: 'center', width: 130},
|
||||
{ name: 'plan', header: '요금제', align: 'center', width: 130},
|
||||
{ name: 'carryOver', header: '이월누적금액', align: 'center', width: 130}
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
params: {
|
||||
searchType1: '',
|
||||
searchType2: '',
|
||||
searchType3: '',
|
||||
searchText1: '',
|
||||
startDt: '',
|
||||
endDt: ''
|
||||
},
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid,
|
||||
},
|
||||
created(){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
//let cont = document.querySelector(".wrap");
|
||||
//cont.classList.add("main_wrap");
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
// 달력 세팅
|
||||
this.grid.params.startDt = this.customFormatter(new Date());
|
||||
this.grid.params.endDt = this.customFormatter(new Date());
|
||||
|
||||
let page = 1;
|
||||
// 페이지 정보 및 검색 조건
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
console.log('getCondition : '+getCondition);
|
||||
|
||||
// store에 저장된 페이지 정보 및 검색 조건을 불러오기
|
||||
let isKeep = false;
|
||||
if (getCondition) {
|
||||
this.grid.pagePerRows = getCondition.perPage;
|
||||
this.grid.params = getCondition.params;
|
||||
page = getCondition.page;
|
||||
isKeep = true;
|
||||
}
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log('this.perPageCnt'+this.perPageCnt);
|
||||
//console.log(this.grid.params);
|
||||
this.$refs.table.search(this.grid.params, isKeep);
|
||||
this.sendStoreData();
|
||||
},
|
||||
ModalOpen: function(target){
|
||||
this.$refs.systemModal.ModalOpen(target);
|
||||
},
|
||||
deleteRow: function(){ //로우데이터 삭제하도록 수정
|
||||
var checkTest = this.$refs.table.checkedElementDatas();
|
||||
if(checkTest.length == 0){
|
||||
alert('체크박스에 체크를 해주세요.')
|
||||
}
|
||||
for(var i = 0; i < checkTest.length; i++){
|
||||
alert(checkTest[i].adminId);
|
||||
}
|
||||
},
|
||||
memberDetail: function(data) {
|
||||
if(data.adminId == 'free'){
|
||||
this.$router.push({
|
||||
path: `./views/MemberDetail`
|
||||
});
|
||||
}
|
||||
},
|
||||
changePerPage: function(){ // 페이지당 조회할 개수
|
||||
this.grid.pagePerRows = this.perPageCnt;
|
||||
this.search(true);
|
||||
},
|
||||
sendStoreData: function() {
|
||||
const getP = this.$refs.table.getPagination();
|
||||
console.log("==========getP : " + getP._currentPage);
|
||||
this.$store.commit('searchcondition/updateSearchCondition', {
|
||||
page: getP._currentPage,
|
||||
perPage: this.perPageCnt,
|
||||
params: this.grid.params
|
||||
});
|
||||
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
console.log("getCondition : "+ getCondition.perPage);
|
||||
},
|
||||
|
||||
customFormatter: function(date) {
|
||||
// 달력 관련
|
||||
if (this.sDateDiv == 'month') {
|
||||
return moment(date).format('YYYY-MM');
|
||||
} else if (this.sDateDiv == 'year') {
|
||||
return moment(date).format('YYYY');
|
||||
} else {
|
||||
return moment(date).format('YYYY-MM-DD');
|
||||
}
|
||||
},
|
||||
selectedStartDate(day) {
|
||||
if (this.startDate > this.endDate) {
|
||||
this.startDate = this.endDate;
|
||||
}
|
||||
},
|
||||
selectedEndDate(day) {
|
||||
if (day != undefined && day != null) {
|
||||
this.periodDay = day;
|
||||
}
|
||||
},
|
||||
closeDate(type) {
|
||||
if (type != undefined && type != null) {
|
||||
if (type == 'start') {
|
||||
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() };
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
beforeRouteLeave(to, from, next) {
|
||||
|
||||
const getP = this.$refs.table.getPagination();
|
||||
console.log("==========getP : " + getP._currentPage);
|
||||
this.$store.commit('searchcondition/updateSearchCondition', {
|
||||
page: getP._currentPage,
|
||||
perPage: this.perPageCnt,
|
||||
params: this.grid.params
|
||||
});
|
||||
// 라우트 하기전 실행
|
||||
next();
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -1,165 +1,165 @@
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">회원 정보 상세 조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<button type="button" class="button grey">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>100</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin">관리자 등록</button>
|
||||
<button type="button" class="button blue channel">유지채널 등록</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="testList.url"
|
||||
:perPage="testList.perPage"
|
||||
:initialRequest="testList.initialRequest"
|
||||
:pagination="testList.pagination"
|
||||
:isCheckbox="testList.isCheckbox"
|
||||
:columns="testList.columns"
|
||||
:noDataStr="testList.noDataStr"
|
||||
:addCls="testList.addCls"
|
||||
:header="testList.header"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
testList: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60 },
|
||||
{ name: 'auth', header: '권한', align: 'left', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
// params: {
|
||||
// apprResult: '',
|
||||
// searchType: '',
|
||||
// searchText: '',
|
||||
// startDate: '',
|
||||
// endDate: ''
|
||||
// },
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let isKeep = false;
|
||||
isKeep = true;
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.testList.params);
|
||||
this.$refs.table.search(this.testList.params, isKeep);
|
||||
},
|
||||
}
|
||||
};
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">회원 정보 상세 조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<button type="button" class="button grey">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>100</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin">관리자 등록</button>
|
||||
<button type="button" class="button blue channel">유지채널 등록</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="testList.url"
|
||||
:perPage="testList.perPage"
|
||||
:initialRequest="testList.initialRequest"
|
||||
:pagination="testList.pagination"
|
||||
:isCheckbox="testList.isCheckbox"
|
||||
:columns="testList.columns"
|
||||
:noDataStr="testList.noDataStr"
|
||||
:addCls="testList.addCls"
|
||||
:header="testList.header"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
testList: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60 },
|
||||
{ name: 'auth', header: '권한', align: 'left', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
// params: {
|
||||
// apprResult: '',
|
||||
// searchType: '',
|
||||
// searchText: '',
|
||||
// startDate: '',
|
||||
// endDate: ''
|
||||
// },
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let isKeep = false;
|
||||
isKeep = true;
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.testList.params);
|
||||
this.$refs.table.search(this.testList.params, isKeep);
|
||||
},
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -1,165 +1,165 @@
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">회원목록조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<button type="button" class="button grey">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>100</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin">관리자 등록</button>
|
||||
<button type="button" class="button blue channel">유지채널 등록</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="testList.url"
|
||||
:perPage="testList.perPage"
|
||||
:initialRequest="testList.initialRequest"
|
||||
:pagination="testList.pagination"
|
||||
:isCheckbox="testList.isCheckbox"
|
||||
:columns="testList.columns"
|
||||
:noDataStr="testList.noDataStr"
|
||||
:addCls="testList.addCls"
|
||||
:header="testList.header"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
testList: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60 },
|
||||
{ name: 'auth', header: '권한', align: 'left', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
// params: {
|
||||
// apprResult: '',
|
||||
// searchType: '',
|
||||
// searchText: '',
|
||||
// startDate: '',
|
||||
// endDate: ''
|
||||
// },
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let isKeep = false;
|
||||
isKeep = true;
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.testList.params);
|
||||
this.$refs.table.search(this.testList.params, isKeep);
|
||||
},
|
||||
}
|
||||
};
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">회원목록조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<button type="button" class="button grey">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>100</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin">관리자 등록</button>
|
||||
<button type="button" class="button blue channel">유지채널 등록</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="testList.url"
|
||||
:perPage="testList.perPage"
|
||||
:initialRequest="testList.initialRequest"
|
||||
:pagination="testList.pagination"
|
||||
:isCheckbox="testList.isCheckbox"
|
||||
:columns="testList.columns"
|
||||
:noDataStr="testList.noDataStr"
|
||||
:addCls="testList.addCls"
|
||||
:header="testList.header"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
testList: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60 },
|
||||
{ name: 'auth', header: '권한', align: 'left', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
// params: {
|
||||
// apprResult: '',
|
||||
// searchType: '',
|
||||
// searchText: '',
|
||||
// startDate: '',
|
||||
// endDate: ''
|
||||
// },
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let isKeep = false;
|
||||
isKeep = true;
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.testList.params);
|
||||
this.$refs.table.search(this.testList.params, isKeep);
|
||||
},
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -1,165 +1,165 @@
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">청약 정보 상세 조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<button type="button" class="button grey">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>100</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin">관리자 등록</button>
|
||||
<button type="button" class="button blue channel">유지채널 등록</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="testList.url"
|
||||
:perPage="testList.perPage"
|
||||
:initialRequest="testList.initialRequest"
|
||||
:pagination="testList.pagination"
|
||||
:isCheckbox="testList.isCheckbox"
|
||||
:columns="testList.columns"
|
||||
:noDataStr="testList.noDataStr"
|
||||
:addCls="testList.addCls"
|
||||
:header="testList.header"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
testList: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60 },
|
||||
{ name: 'auth', header: '권한', align: 'left', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
// params: {
|
||||
// apprResult: '',
|
||||
// searchType: '',
|
||||
// searchText: '',
|
||||
// startDate: '',
|
||||
// endDate: ''
|
||||
// },
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let isKeep = false;
|
||||
isKeep = true;
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.testList.params);
|
||||
this.$refs.table.search(this.testList.params, isKeep);
|
||||
},
|
||||
}
|
||||
};
|
||||
<template>
|
||||
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">청약 정보 상세 조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="대리점">대리점</option>
|
||||
<option value="운영자">운영자</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="right">
|
||||
<option value="전체">전체</option>
|
||||
<option value="사용">사용</option>
|
||||
<option value="중지">중지</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력"/>
|
||||
</div>
|
||||
<button type="button" class="button grey">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>100</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue admin">관리자 등록</button>
|
||||
<button type="button" class="button blue channel">유지채널 등록</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="5%"/>
|
||||
<col width="15%"/>
|
||||
<col width="15%"/>
|
||||
<col width="20%"/>
|
||||
<col width="20%"/>
|
||||
<col width="5%"/>
|
||||
<col width="20%"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="admin_check1"><label for="admin_check1"></label></th>
|
||||
<th>NO</th>
|
||||
<th>권한</th>
|
||||
<th>이름(대리점명)</th>
|
||||
<th>ID</th>
|
||||
<th>상태</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" checked id="admin_check2"><label for="admin_check2"></label></td>
|
||||
<td>10</td>
|
||||
<td>대리점</td>
|
||||
<td>유플러스</td>
|
||||
<td><a href="javascript:void(0)">uplus1</a></td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div> -->
|
||||
<div class="table">
|
||||
<custom-grid
|
||||
ref="table"
|
||||
:totalItems="'totalItems'"
|
||||
:url="testList.url"
|
||||
:perPage="testList.perPage"
|
||||
:initialRequest="testList.initialRequest"
|
||||
:pagination="testList.pagination"
|
||||
:isCheckbox="testList.isCheckbox"
|
||||
:columns="testList.columns"
|
||||
:noDataStr="testList.noDataStr"
|
||||
:addCls="testList.addCls"
|
||||
:header="testList.header"
|
||||
></custom-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
//import api from '../service/api';
|
||||
export default {
|
||||
name: 'custList',
|
||||
data() {
|
||||
return {
|
||||
testList: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
perPage: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true,
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
|
||||
header: [
|
||||
[
|
||||
{ header: 'NO', childNames: [] },
|
||||
{ header: '권한', childNames: [] },
|
||||
{ header: '이름(대리점명)', childNames: [] },
|
||||
{ header: 'ID', childNames: [] },
|
||||
{ header: '상태', childNames: [] },
|
||||
{ header: '등록일', childNames: [] }
|
||||
]
|
||||
],
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'NO', align: 'center', width: 60 },
|
||||
{ name: 'auth', header: '권한', align: 'left', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130},
|
||||
{ name: 'regDt', header: '등록일', width: 90, cls: 'td_line' }
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
// params: {
|
||||
// apprResult: '',
|
||||
// searchType: '',
|
||||
// searchText: '',
|
||||
// startDate: '',
|
||||
// endDate: ''
|
||||
// },
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let isKeep = false;
|
||||
isKeep = true;
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log(this.testList.params);
|
||||
this.$refs.table.search(this.testList.params, isKeep);
|
||||
},
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -1,24 +1,31 @@
|
||||
import LoginMain from '../views/LoginMain'
|
||||
import LoginAuth from '../views/LoginAuth'
|
||||
import ResetPassword from '../views/ResetPassword'
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/login',
|
||||
name: 'login',
|
||||
component: LoginMain,
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/view/login/auth',
|
||||
name: 'loginAuth',
|
||||
component: LoginAuth,
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/view/login/resetPassword',
|
||||
name: 'resetPassword',
|
||||
component: ResetPassword,
|
||||
meta: { public: true }
|
||||
},
|
||||
import LoginMain from '../views/LoginMain'
|
||||
import LoginAuth from '../views/LoginAuth'
|
||||
import ResetPassword from '../views/ResetPassword'
|
||||
import UpdatePassword from '../views/UpdatePassword'
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/login',
|
||||
name: 'login',
|
||||
component: LoginMain,
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/view/login/auth',
|
||||
name: 'loginAuth',
|
||||
component: LoginAuth,
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/view/login/resetPassword',
|
||||
name: 'resetPassword',
|
||||
component: ResetPassword,
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/view/login/updatePassword',
|
||||
name: 'updatePassword',
|
||||
component: UpdatePassword,
|
||||
meta: { public: true }
|
||||
},
|
||||
]
|
||||
@@ -1,53 +1,63 @@
|
||||
import httpClient from '@/common/http-client';
|
||||
|
||||
const login = (params) => {
|
||||
return httpClient.post('api/v1/bo/login/login', params, { headers: {"show-layer": "Yes"} },{ withCredentials: false });
|
||||
};
|
||||
|
||||
const chgpwd = (params) => {
|
||||
return httpClient.post('/api/oper/user/chgpwd', params);
|
||||
};
|
||||
|
||||
const myphone = () => {
|
||||
return httpClient.get('/api/oper/user/phone/self');
|
||||
};
|
||||
|
||||
const phone = (params) => {
|
||||
return httpClient.get('/api/public/auth/phone', { params: params });
|
||||
};
|
||||
|
||||
// 삭제 예정
|
||||
const reqnum = (params) => {
|
||||
return httpClient.get('/api/public/auth/reqnum', { params: params });
|
||||
};
|
||||
|
||||
const authNum = (params) => {
|
||||
return httpClient.post('/api/v1/bo/login/authNum', params);
|
||||
};
|
||||
|
||||
const confirmNum = (params) => {
|
||||
//return httpClient.get('/api/public/auth/chknum', { params: params });
|
||||
return httpClient.post('/api/v1/bo/login/confirmNum', params);
|
||||
};
|
||||
|
||||
|
||||
const newpwd = (params) => {
|
||||
return httpClient.post('/api/public/auth/newpwd', params);
|
||||
};
|
||||
|
||||
const logout = () => {
|
||||
//return httpClient.get('/api/auth/logout', {headers: {"show-layer": "Yes"}});
|
||||
return httpClient.post('/api/v1/bo/login/logout', {headers: {"show-layer": "Yes"}});
|
||||
};
|
||||
|
||||
export default {
|
||||
login,
|
||||
logout,
|
||||
chgpwd,
|
||||
myphone,
|
||||
phone,
|
||||
reqnum,
|
||||
confirmNum,
|
||||
newpwd,
|
||||
authNum
|
||||
import httpClient from '@/common/http-client';
|
||||
|
||||
const login = (params) => {
|
||||
return httpClient.post('api/v1/bo/login/login', params, { headers: {"show-layer": "Yes"} },{ withCredentials: false });
|
||||
};
|
||||
|
||||
const chgpwd = (params) => {
|
||||
return httpClient.post('/api/oper/user/chgpwd', params);
|
||||
};
|
||||
|
||||
const myphone = () => {
|
||||
return httpClient.get('/api/oper/user/phone/self');
|
||||
};
|
||||
|
||||
const phone = (params) => {
|
||||
return httpClient.get('/api/public/auth/phone', { params: params });
|
||||
};
|
||||
|
||||
// 삭제 예정
|
||||
const reqnum = (params) => {
|
||||
return httpClient.get('/api/public/auth/reqnum', { params: params });
|
||||
};
|
||||
|
||||
const authNum = (params) => {
|
||||
return httpClient.post('/api/v1/bo/login/authNum', params);
|
||||
};
|
||||
|
||||
const confirmNum = (params) => {
|
||||
//return httpClient.get('/api/public/auth/chknum', { params: params });
|
||||
return httpClient.post('/api/v1/bo/login/confirmNum', params);
|
||||
};
|
||||
|
||||
const resetPassword = (params) => {
|
||||
return httpClient.post('/api/v1/bo/login/resetPassword', params);
|
||||
};
|
||||
|
||||
const updatePassword = (params) => {
|
||||
return httpClient.post('/api/v1/bo/login/updatePassword', params);
|
||||
};
|
||||
|
||||
|
||||
const newpwd = (params) => {
|
||||
return httpClient.post('/api/public/auth/newpwd', params);
|
||||
};
|
||||
|
||||
const logout = () => {
|
||||
//return httpClient.get('/api/auth/logout', {headers: {"show-layer": "Yes"}});
|
||||
return httpClient.post('/api/v1/bo/login/logout', {headers: {"show-layer": "Yes"}});
|
||||
};
|
||||
|
||||
export default {
|
||||
login,
|
||||
logout,
|
||||
chgpwd,
|
||||
myphone,
|
||||
phone,
|
||||
reqnum,
|
||||
confirmNum,
|
||||
newpwd,
|
||||
authNum,
|
||||
resetPassword,
|
||||
updatePassword
|
||||
};
|
||||
@@ -1,257 +1,258 @@
|
||||
var commonPwdView = {
|
||||
data: function() {
|
||||
return {
|
||||
err_msg: null,
|
||||
message: {
|
||||
curPwd: '', newPwd: '', cfmPwd: ''
|
||||
},
|
||||
param: {
|
||||
userId: null, phone: null
|
||||
},
|
||||
curPwd: '', newPwd: '', cfmPwd: ''
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
verifyNewPwd: function (evt) {
|
||||
var valid = this.checkPassword(evt.target.value);
|
||||
if (valid) {
|
||||
this.err_msg = '';
|
||||
}
|
||||
this.message.newPwd = this.err_msg;
|
||||
},
|
||||
verifyCfmPwd: function() {
|
||||
this.message.cfmPwd = '';
|
||||
if (this.newPwd != this.cfmPwd) {
|
||||
this.message.cfmPwd = this.cfmPwdFailMsg();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var validation = {
|
||||
methods: {
|
||||
checkId: function (id) {
|
||||
if (id == null || id.trim() == "") {
|
||||
this.err_msg = "아이디를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if (id.length < 4 || id.length > 15) {
|
||||
this.err_msg = "아이디는 영문, 숫자를 이용하여 4자리 이상 15자리 이하이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
if (!id.match(/^[0-9a-zA-Z]+$/)) {
|
||||
this.err_msg = "아이디는 영문, 숫자를 이용하여야 합니다.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkPassword: function (pw) {
|
||||
if (pw == null || pw.trim() == "") {
|
||||
this.err_msg = "비밀번호를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (typeof this.param.userId != "undefined") {
|
||||
if (pw.indexOf(this.param.userId) >= 0) {
|
||||
this.err_msg = "아이디가 포함된 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
for (var i = 0; i < pw.length; i++) {
|
||||
var ch1 = pw.charAt(i);
|
||||
var ch2 = pw.charAt(i + 1);
|
||||
var ch3 = pw.charAt(i + 2);
|
||||
var ch4 = pw.charAt(i + 3);
|
||||
if (ch1 == ch2 && ch2 == ch3 && ch3 == ch4) {
|
||||
//console.log(ch1 + "" + ch2 + "" + ch3 + ch4 + " is equality");
|
||||
this.err_msg = "연속적인 숫자 또는 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
if (ch1.charCodeAt(0) - ch2.charCodeAt(0) == 1 && ch2.charCodeAt(0) - ch3.charCodeAt(0) == 1 && ch3.charCodeAt(0) - ch4.charCodeAt(0) == 1) {
|
||||
//console.log(ch1 + "" + ch2 + "" + ch3 + ch4 + " is continuity");
|
||||
this.err_msg = "연속적인 숫자 또는 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
if (ch1.charCodeAt(0) - ch2.charCodeAt(0) == -1 && ch2.charCodeAt(0) - ch3.charCodeAt(0) == -1 && ch3.charCodeAt(0) - ch4.charCodeAt(0) == -1) {
|
||||
//console.log(ch1 + "" + ch2 + "" + ch3 + ch4 + " is continuity");
|
||||
this.err_msg = "연속적인 숫자 또는 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof this.param.phone != "undefined" && this.param.phone != null) {
|
||||
var phone = this.param.phone;
|
||||
phone = phone.substring(3, phone.length); // 앞 3자리 제거
|
||||
|
||||
var last = phone.substring(phone.length - 4, phone.length); // 뒤 4자리 추출
|
||||
var middle = phone.substring(0, phone.length - 4); // 뒤 4자리 제거 == 국번
|
||||
|
||||
if (pw.indexOf(middle) >= 0 || pw.indexOf(last) >= 0) {
|
||||
this.err_msg = "휴대폰번호가 포함된 문자열은 사용할 수 없습니다.";
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
if (pw.length >= 10) {
|
||||
if (pw.match(/^(?=.*[0-9])(?=.*[a-zA-Z])(?=.*[!@#$%^&*])([a-zA-Z0-9!@#$%^&*]+)$/)) {
|
||||
return true;
|
||||
} else if (!pw.match(/^(?=.*[0-9])(?=.*[a-zA-Z])([a-zA-Z0-9]+)$/)
|
||||
&& !pw.match(/^(?=.*[0-9])(?=.*[!@#$%^&*])([0-9!@#$%^&*]+)$/)
|
||||
&& !pw.match(/^(?=.*[a-zA-Z])(?=.*[!@#$%^&*])([a-zA-Z!@#$%^&*]+)$/)) {
|
||||
this.err_msg = "영문, 숫자, 특수문자 중 2가지 이상 조합하여 10자리 이상 또는 3가지 이상 조합하여 8자리 이상이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
} else if (pw.length >= 8) {
|
||||
if (!pw.match(/^(?=.*[0-9])(?=.*[a-zA-Z])(?=.*[!@#$%^&*])([a-zA-Z0-9!@#$%^&*]+)$/)) {
|
||||
this.err_msg = "영문, 숫자, 특수문자 중 2가지 이상 조합하여 10자리 이상 또는 3가지 이상 조합하여 8자리 이상이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
this.err_msg = "영문, 숫자, 특수문자 중 2가지 이상 조합하여 10자리 이상 또는 3가지 이상 조합하여 8자리 이상이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
},
|
||||
checkName: function (name) {
|
||||
if (name == null || name.trim() == "") {
|
||||
this.err_msg = "이름을 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkDeptNm: function (dept) {
|
||||
if (dept == null || dept.trim() == "") {
|
||||
this.err_msg = "부서명을 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkPhone: function (phone) {
|
||||
if (phone == null || phone.trim() == "") {
|
||||
this.err_msg = "휴대폰번호를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if (phone.length < 10) {
|
||||
this.err_msg = "휴대폰번호를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkEmail: function (email) {
|
||||
if (email == null || email.trim() == "") {
|
||||
this.err_msg = "이메일을 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
// eslint-disable-next-line
|
||||
if (!email.match(/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/)) {
|
||||
this.err_msg = "이메일을 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkIp: function (param) {
|
||||
if ((param.ip1 == null || param.ip1 == "") && (param.ip2 == null || param.ip2 == "") && (param.ip3 == null || param.ip3 == "") && (param.ip4 == null || param.ip4 == "")) {
|
||||
this.err_msg = "접근허용 IP를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if ((param.ip1 == null || param.ip1 == "")
|
||||
|| (param.ip2 == null || param.ip2 == "")
|
||||
|| (param.ip3 == null || param.ip3 == "")
|
||||
|| (param.ip4 == null || param.ip4 == "")) {
|
||||
this.err_msg = "IP 주소를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkIpEach: function (ip, msg) {
|
||||
if (ip == null || ip == "") {
|
||||
this.err_msg = typeof msg != "undefined" ? msg : "접근허용 IP를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if (!ip.match(/^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/)) {
|
||||
this.err_msg = "IP 주소를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkIpWithAsterisk: function (ip, msg) {
|
||||
if (ip == null || ip == "") {
|
||||
this.err_msg = typeof msg != "undefined" ? msg : "접근허용 IP를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
// 3레벨 이후 * 허용... 2레벨 이후 시 {2,3} 1레벨 이후시 {1,3} 필요 시 구문 추가
|
||||
if (!ip.match(/^((((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}\*))$/)) {
|
||||
this.err_msg = "IP 주소를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkRole: function (role) {
|
||||
if (role == null || role == "") {
|
||||
this.err_msg = "권한을 선택해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
//리스크관리
|
||||
checkSpamCliId: function (comnId, spamCliId) {
|
||||
if (comnId == "N") {
|
||||
if (spamCliId == null || spamCliId.trim() == "") {
|
||||
this.err_msg = "SMID를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkReqType: function (reqType) {
|
||||
if (reqType == null || reqType.trim() == "") {
|
||||
this.err_msg = "요청자를 선택해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkSpamType: function (spamType) {
|
||||
if (spamType == null || spamType.trim() == "") {
|
||||
this.err_msg = "차단사유를 선택해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkSpamContents: function (blockType) {
|
||||
var str = "";
|
||||
for (var k in this.callBacks) {
|
||||
str = this.callBacks[k].spamContent;
|
||||
|
||||
|
||||
if (blockType == "CLB") {
|
||||
if (str == null || str.trim() == "") {
|
||||
this.err_msg = "발신번호를 입력해 주세요.";
|
||||
return false;
|
||||
} else {
|
||||
if (this.bytes(str) < 8) {
|
||||
this.err_msg = "발신번호가 8자리 미만입니다.";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (this.bytes(str) > 11) {
|
||||
this.err_msg = "발신번호가 11자리 초과입니다.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (str == null || str.trim() == "") {
|
||||
this.err_msg = "차단메시지를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var commonPwdView = {
|
||||
data: function() {
|
||||
return {
|
||||
err_msg: null,
|
||||
message: {
|
||||
oldPw: '', newPw: '',
|
||||
},
|
||||
param: {
|
||||
userId: null,
|
||||
},
|
||||
oldPw: '', newPw: '',
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
verifyNewPw: function (evt) {
|
||||
var valid = this.checkPassword(evt.target.value);
|
||||
if (valid) {
|
||||
this.err_msg = '';
|
||||
}
|
||||
this.message.newPw = this.err_msg;
|
||||
},
|
||||
|
||||
verifyCfmPwd: function() {
|
||||
this.message.cfmPw = '';
|
||||
if (this.newPw != this.cfmPw) {
|
||||
this.message.cfmPw = this.cfmPwdFailMsg();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var validation = {
|
||||
methods: {
|
||||
checkId: function (id) {
|
||||
if (id == null || id.trim() == "") {
|
||||
this.err_msg = "아이디를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if (id.length < 8 || id.length > 16) {
|
||||
this.err_msg = "아이디는 영문, 숫자를 이용하여 4자리 이상 15자리 이하이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
if (!id.match(/^[0-9a-zA-Z]+$/)) {
|
||||
this.err_msg = "아이디는 영문, 숫자를 이용하여야 합니다.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkPassword: function (pw) {
|
||||
if (pw == null || pw.trim() == "") {
|
||||
this.err_msg = "비밀번호를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (typeof this.param.userId != "undefined") {
|
||||
if (pw.indexOf(this.param.userId) >= 0) {
|
||||
this.err_msg = "아이디가 포함된 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
for (var i = 0; i < pw.length; i++) {
|
||||
var ch1 = pw.charAt(i);
|
||||
var ch2 = pw.charAt(i + 1);
|
||||
var ch3 = pw.charAt(i + 2);
|
||||
var ch4 = pw.charAt(i + 3);
|
||||
if (ch1 == ch2 && ch2 == ch3 && ch3 == ch4) {
|
||||
//console.log(ch1 + "" + ch2 + "" + ch3 + ch4 + " is equality");
|
||||
this.err_msg = "연속적인 숫자 또는 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
if (ch1.charCodeAt(0) - ch2.charCodeAt(0) == 1 && ch2.charCodeAt(0) - ch3.charCodeAt(0) == 1 && ch3.charCodeAt(0) - ch4.charCodeAt(0) == 1) {
|
||||
//console.log(ch1 + "" + ch2 + "" + ch3 + ch4 + " is continuity");
|
||||
this.err_msg = "연속적인 숫자 또는 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
if (ch1.charCodeAt(0) - ch2.charCodeAt(0) == -1 && ch2.charCodeAt(0) - ch3.charCodeAt(0) == -1 && ch3.charCodeAt(0) - ch4.charCodeAt(0) == -1) {
|
||||
//console.log(ch1 + "" + ch2 + "" + ch3 + ch4 + " is continuity");
|
||||
this.err_msg = "연속적인 숫자 또는 문자열은 사용할 수 없습니다.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof this.param.phone != "undefined" && this.param.phone != null) {
|
||||
var phone = this.param.phone;
|
||||
phone = phone.substring(3, phone.length); // 앞 3자리 제거
|
||||
|
||||
var last = phone.substring(phone.length - 4, phone.length); // 뒤 4자리 추출
|
||||
var middle = phone.substring(0, phone.length - 4); // 뒤 4자리 제거 == 국번
|
||||
|
||||
if (pw.indexOf(middle) >= 0 || pw.indexOf(last) >= 0) {
|
||||
this.err_msg = "휴대폰번호가 포함된 문자열은 사용할 수 없습니다.";
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
if (pw.length >= 10) {
|
||||
if (pw.match(/^(?=.*[0-9])(?=.*[a-zA-Z])(?=.*[!@#$%^&*])([a-zA-Z0-9!@#$%^&*]+)$/)) {
|
||||
return true;
|
||||
} else if (!pw.match(/^(?=.*[0-9])(?=.*[a-zA-Z])([a-zA-Z0-9]+)$/)
|
||||
&& !pw.match(/^(?=.*[0-9])(?=.*[!@#$%^&*])([0-9!@#$%^&*]+)$/)
|
||||
&& !pw.match(/^(?=.*[a-zA-Z])(?=.*[!@#$%^&*])([a-zA-Z!@#$%^&*]+)$/)) {
|
||||
this.err_msg = "영문, 숫자, 특수문자 중 2가지 이상 조합하여 10자리 이상 또는 3가지 이상 조합하여 8자리 이상이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
} else if (pw.length >= 8) {
|
||||
if (!pw.match(/^(?=.*[0-9])(?=.*[a-zA-Z])(?=.*[!@#$%^&*])([a-zA-Z0-9!@#$%^&*]+)$/)) {
|
||||
this.err_msg = "영문, 숫자, 특수문자 중 2가지 이상 조합하여 10자리 이상 또는 3가지 이상 조합하여 8자리 이상이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
this.err_msg = "영문, 숫자, 특수문자 중 2가지 이상 조합하여 10자리 이상 또는 3가지 이상 조합하여 8자리 이상이어야 합니다.";
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
},
|
||||
checkName: function (name) {
|
||||
if (name == null || name.trim() == "") {
|
||||
this.err_msg = "이름을 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkDeptNm: function (dept) {
|
||||
if (dept == null || dept.trim() == "") {
|
||||
this.err_msg = "부서명을 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkPhone: function (phone) {
|
||||
if (phone == null || phone.trim() == "") {
|
||||
this.err_msg = "휴대폰번호를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if (phone.length < 10) {
|
||||
this.err_msg = "휴대폰번호를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkEmail: function (email) {
|
||||
if (email == null || email.trim() == "") {
|
||||
this.err_msg = "이메일을 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
// eslint-disable-next-line
|
||||
if (!email.match(/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/)) {
|
||||
this.err_msg = "이메일을 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkIp: function (param) {
|
||||
if ((param.ip1 == null || param.ip1 == "") && (param.ip2 == null || param.ip2 == "") && (param.ip3 == null || param.ip3 == "") && (param.ip4 == null || param.ip4 == "")) {
|
||||
this.err_msg = "접근허용 IP를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if ((param.ip1 == null || param.ip1 == "")
|
||||
|| (param.ip2 == null || param.ip2 == "")
|
||||
|| (param.ip3 == null || param.ip3 == "")
|
||||
|| (param.ip4 == null || param.ip4 == "")) {
|
||||
this.err_msg = "IP 주소를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkIpEach: function (ip, msg) {
|
||||
if (ip == null || ip == "") {
|
||||
this.err_msg = typeof msg != "undefined" ? msg : "접근허용 IP를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
if (!ip.match(/^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/)) {
|
||||
this.err_msg = "IP 주소를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkIpWithAsterisk: function (ip, msg) {
|
||||
if (ip == null || ip == "") {
|
||||
this.err_msg = typeof msg != "undefined" ? msg : "접근허용 IP를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
// 3레벨 이후 * 허용... 2레벨 이후 시 {2,3} 1레벨 이후시 {1,3} 필요 시 구문 추가
|
||||
if (!ip.match(/^((((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}\*))$/)) {
|
||||
this.err_msg = "IP 주소를 정확히 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkRole: function (role) {
|
||||
if (role == null || role == "") {
|
||||
this.err_msg = "권한을 선택해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
//리스크관리
|
||||
checkSpamCliId: function (comnId, spamCliId) {
|
||||
if (comnId == "N") {
|
||||
if (spamCliId == null || spamCliId.trim() == "") {
|
||||
this.err_msg = "SMID를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkReqType: function (reqType) {
|
||||
if (reqType == null || reqType.trim() == "") {
|
||||
this.err_msg = "요청자를 선택해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkSpamType: function (spamType) {
|
||||
if (spamType == null || spamType.trim() == "") {
|
||||
this.err_msg = "차단사유를 선택해 주세요.";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
checkSpamContents: function (blockType) {
|
||||
var str = "";
|
||||
for (var k in this.callBacks) {
|
||||
str = this.callBacks[k].spamContent;
|
||||
|
||||
|
||||
if (blockType == "CLB") {
|
||||
if (str == null || str.trim() == "") {
|
||||
this.err_msg = "발신번호를 입력해 주세요.";
|
||||
return false;
|
||||
} else {
|
||||
if (this.bytes(str) < 8) {
|
||||
this.err_msg = "발신번호가 8자리 미만입니다.";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (this.bytes(str) > 11) {
|
||||
this.err_msg = "발신번호가 11자리 초과입니다.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (str == null || str.trim() == "") {
|
||||
this.err_msg = "차단메시지를 입력해 주세요.";
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export { commonPwdView, validation };
|
||||
@@ -1,52 +1,52 @@
|
||||
const state = {
|
||||
token: null,
|
||||
isLogin: false,
|
||||
isErrorPage: false,
|
||||
isAuthChk: false,
|
||||
pwd: null
|
||||
};
|
||||
|
||||
const getters = {
|
||||
getToken: state => state.token,
|
||||
isLogin: state => state.isLogin,
|
||||
isErrorPage: state => state.isErrorPage,
|
||||
isAuthChk: state => state.isAuthChk,
|
||||
getPwd: state => state.pwd,
|
||||
};
|
||||
|
||||
const mutations = {
|
||||
saveToken: (state, token) => {
|
||||
console.log('saveToken:', token);
|
||||
state.token = token;
|
||||
},
|
||||
removeToken: (state) => {
|
||||
console.log('removeToken:');
|
||||
state.token = null;
|
||||
},
|
||||
isLogin: (state, value) => {
|
||||
console.log("isLogin mutation : " + value);
|
||||
state.isLogin = value;
|
||||
},
|
||||
isErrorPage: (state, value) => {
|
||||
console.log("isErrorPage mutation : " + value);
|
||||
state.isErrorPage = value;
|
||||
},
|
||||
isAuthChk: (state, value) => {
|
||||
console.log("isAuthChk mutation : "+ value);
|
||||
state.isAuthChk = value;
|
||||
},
|
||||
savePwd: (state, value) => {
|
||||
state.pwd = value;
|
||||
},
|
||||
};
|
||||
|
||||
const actions = {
|
||||
};
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state,
|
||||
getters,
|
||||
mutations,
|
||||
actions
|
||||
};
|
||||
const state = {
|
||||
token: null,
|
||||
isLogin: false,
|
||||
isErrorPage: false,
|
||||
isAuthChk: false,
|
||||
pwd: null
|
||||
};
|
||||
|
||||
const getters = {
|
||||
getToken: state => state.token,
|
||||
isLogin: state => state.isLogin,
|
||||
isErrorPage: state => state.isErrorPage,
|
||||
isAuthChk: state => state.isAuthChk,
|
||||
getPwd: state => state.pwd,
|
||||
};
|
||||
|
||||
const mutations = {
|
||||
saveToken: (state, token) => {
|
||||
console.log('saveToken:', token);
|
||||
state.token = token;
|
||||
},
|
||||
removeToken: (state) => {
|
||||
console.log('removeToken:');
|
||||
state.token = null;
|
||||
},
|
||||
isLogin: (state, value) => {
|
||||
console.log("isLogin mutation : " + value);
|
||||
state.isLogin = value;
|
||||
},
|
||||
isErrorPage: (state, value) => {
|
||||
console.log("isErrorPage mutation : " + value);
|
||||
state.isErrorPage = value;
|
||||
},
|
||||
isAuthChk: (state, value) => {
|
||||
console.log("isAuthChk mutation : "+ value);
|
||||
state.isAuthChk = value;
|
||||
},
|
||||
savePwd: (state, value) => {
|
||||
state.pwd = value;
|
||||
},
|
||||
};
|
||||
|
||||
const actions = {
|
||||
};
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state,
|
||||
getters,
|
||||
mutations,
|
||||
actions
|
||||
};
|
||||
|
||||
@@ -1,263 +1,268 @@
|
||||
<template>
|
||||
<!-- s: 문자인증 -->
|
||||
<div class="wrap bg-wrap">
|
||||
<div class="login-box text-auth">
|
||||
<div class="logo"></div>
|
||||
<div class="wbox">
|
||||
<h3 class="title">2차 휴대폰 문자 인증</h3>
|
||||
<p class="desc">아이디에 등록된 휴대폰번호를 입력해 주세요.</p>
|
||||
<!-- <form action=""> -->
|
||||
<ul class="pw-form">
|
||||
<div>
|
||||
<li><input type="text"
|
||||
placeholder="휴대폰번호를 입력하세요 (숫자만 입력하세요.)"
|
||||
v-model="mdn"
|
||||
:maxlength="11"
|
||||
oninput="javascript: this.value = this.value.replace(/[^0-9]/g, '');"
|
||||
>
|
||||
<button class="btn-p2color" v-on:click="authNum">인증번호 받기</button></li>
|
||||
</div>
|
||||
<div>
|
||||
<li class="bg-g">
|
||||
<input type="text"
|
||||
placeholder="인증번호를 입력하세요"
|
||||
v-model="confirmNum"
|
||||
:maxlength="6"
|
||||
oninput="javascript: this.value = this.value.replace(/[^0-9]/g, '');"
|
||||
>
|
||||
<span class="time"> {{ TimerStr }}</span></li>
|
||||
</div>
|
||||
<li>
|
||||
<button class="btn-default" @click="clickMenu('/login')">취소</button>
|
||||
<button class="btn-pcolor" v-on:click="ajaxAuth">확인</button>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- </form> -->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
import api from '../service/api';
|
||||
import tokenSvc from '@/common/token-service';
|
||||
import LoginPopup from '@/components/LoginPopup.vue'
|
||||
//import * as utils from '@/common/utils';
|
||||
|
||||
export default {
|
||||
data: function() {
|
||||
return {
|
||||
errors: [],
|
||||
mdn: '',
|
||||
confirmNum: '',
|
||||
userId: '',
|
||||
isAuthNum: false,
|
||||
isLogin: true,
|
||||
pwd: '',
|
||||
text: '',
|
||||
number: '',
|
||||
Timer: null,
|
||||
TimeCounter: 180,
|
||||
TimerStr: "03:00"
|
||||
};
|
||||
},
|
||||
components: {
|
||||
LoginPopup : LoginPopup
|
||||
},
|
||||
created() {
|
||||
if(!!tokenSvc.getToken()){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.$router.push({ path: '/' });
|
||||
}else{
|
||||
if(!this.getLogin){
|
||||
this.$router.push({ path: '/login' });
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if (localStorage.hubwebUserId) {
|
||||
this.userId = localStorage.hubwebUserId;
|
||||
}
|
||||
this.isLogin = this.getLogin;
|
||||
this.pwd = this.getPwd;
|
||||
},
|
||||
computed: {
|
||||
...mapGetters({
|
||||
getLogin: 'login/isLogin',
|
||||
getErrorPage: 'login/isErrorPage',
|
||||
getAuthChk: 'login/isAuthChk',
|
||||
getPwd: 'login/getPwd'
|
||||
}),
|
||||
},
|
||||
watch: {
|
||||
getLogin(data) {
|
||||
if (data != null && data != '' && data == true) {
|
||||
this.isLogin = true;
|
||||
} else {
|
||||
this.isLogin = false;
|
||||
}
|
||||
},
|
||||
getPwd(data) {
|
||||
if(data != null && data != ''){
|
||||
this.pwd = data;
|
||||
}
|
||||
}
|
||||
},
|
||||
destroyed() {
|
||||
let cont = document.querySelector(".wrap");
|
||||
cont.classList.remove("bg-wrap");
|
||||
},
|
||||
methods: {
|
||||
// 2차 인증번호 요청
|
||||
authNum(){
|
||||
var vm = this;
|
||||
if(!this.isLogin){
|
||||
var vm = this;
|
||||
vm.$store.commit("login/isLogin", false);
|
||||
vm.$store.commit("login/isAuthChk", false);
|
||||
vm.$router.push({ path: '/'});
|
||||
return;
|
||||
}
|
||||
if (vm.mdn == null || vm.mdn.trim() == ""){
|
||||
vm.ModalOpen('modal08');
|
||||
return false;
|
||||
} else if (vm.mdn.length < 11 || !vm.mdn) {
|
||||
vm.ModalOpen('modal06');
|
||||
}
|
||||
var params = {
|
||||
"oprtrId": this.userId,
|
||||
"hpNo": this.mdn,
|
||||
"isLogin" : this.isLogin
|
||||
}
|
||||
api.authNum(params).then(response => {
|
||||
console.log(response);
|
||||
var rsp = response.data;
|
||||
if(rsp.retCode == '0000'){
|
||||
this.Timer = this.timerStart();
|
||||
vm.ModalOpen('modal07');
|
||||
// console.log('시간 3:00 카운트 하기');
|
||||
this.isAuthNum = true;
|
||||
}else if (!this.Timer) {
|
||||
this.timerStop(this.Timer);
|
||||
this.Timer = null;
|
||||
// 실패 -> 실패 코드에 따라 실패 팝업 보여주기
|
||||
//인증시간 초과 후 “시간초과!” 문구로 변경
|
||||
}
|
||||
}).catch(response =>{
|
||||
|
||||
console.log(response);
|
||||
});
|
||||
},
|
||||
|
||||
// 2차 인증 확인
|
||||
ajaxAuth: function(){
|
||||
var vm = this;
|
||||
|
||||
if (!vm.formCheck()){
|
||||
alert(vm.errors[0]);
|
||||
return false;
|
||||
}
|
||||
if(vm.TimeCounter==0){
|
||||
alert("시간초과");
|
||||
return false;
|
||||
}
|
||||
|
||||
var params = {
|
||||
"oprtrId": this.userId,
|
||||
"hpNo": this.mdn,
|
||||
"chrVal": this.confirmNum,
|
||||
"isLogin": this.isLogin,
|
||||
"oprtrPw": this.pwd
|
||||
}
|
||||
|
||||
//인증번호 확인
|
||||
api.confirmNum(params).then(function(response){
|
||||
var rsp = response.data;
|
||||
console.log("RESULT_CODE : "+rsp.retCode);
|
||||
if(rsp.retCode == '0000'){
|
||||
vm.$store.commit("login/isLogin", true);
|
||||
//var nextUrl = rsp.data.nextUrl;
|
||||
//vm.$router.push({ path: nextUrl});
|
||||
vm.$router.push({ path: '/'});
|
||||
}else if(rsp.retCode == '4008') { //휴대폰번호 확인
|
||||
vm.ModalOpen('modal06');
|
||||
} else if(rsp.retCode == '404') { //인증번호: 입력
|
||||
vm.ModalOpen('modal08');
|
||||
} else if(rsp.retCode == '4009') { //인증실패: 시간초과
|
||||
vm.ModalOpen('modal10');
|
||||
} else if(rsp.retCode == '4010') { //인증실패: 인증번호
|
||||
vm.ModalOpen('modal09');
|
||||
} else if(rsp.retCode == '4011') { //인증실패: 5회
|
||||
vm.ModalOpen('modal11');
|
||||
} else{
|
||||
return;
|
||||
}
|
||||
});
|
||||
},
|
||||
formCheck: function() {
|
||||
this.errors = [];
|
||||
if(!this.isAuthNum){
|
||||
this.errors.push('인증요청을 먼저 해주세요.');
|
||||
}
|
||||
if(!this.mdn){
|
||||
this.errors.push('휴대폰 번호를 확인해주세요.');
|
||||
}
|
||||
if(!this.confirmNum){
|
||||
this.errors.push('인증번호를 입력하세요.');
|
||||
}
|
||||
return this.errors.length == 0;
|
||||
},
|
||||
|
||||
clickMenu(link){
|
||||
this.$router.push({
|
||||
path: link
|
||||
});
|
||||
},
|
||||
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
},
|
||||
timerStart: function() {
|
||||
// 1초에 한번씩 start 호출
|
||||
this.TimeCounter = 180;
|
||||
var interval = setInterval(() => {
|
||||
this.TimeCounter--;
|
||||
//1초씩 감소
|
||||
this.TimerStr = this.prettyTime();
|
||||
if (this.TimeCounter <= 0)
|
||||
{
|
||||
this.timerStop(interval);
|
||||
// this.ModalOpen('modal10');
|
||||
}
|
||||
}, 100);
|
||||
|
||||
return interval;
|
||||
},
|
||||
|
||||
timerStop: function(Timer)
|
||||
{
|
||||
clearInterval(Timer);
|
||||
this.TimeCounter = 0;
|
||||
},
|
||||
|
||||
prettyTime: function() {
|
||||
// 시간 형식으로 변환 리턴
|
||||
let time = this.TimeCounter / 60;
|
||||
let minutes = parseInt(time);
|
||||
let secondes = Math.round((time - minutes) * 60);
|
||||
|
||||
return (
|
||||
minutes.toString().padStart(2, "0") +
|
||||
":"
|
||||
+ secondes.toString().padStart(2, "0")
|
||||
);
|
||||
},
|
||||
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<template>
|
||||
<!-- s: 문자인증 -->
|
||||
<div class="wrap bg-wrap">
|
||||
<div class="login-box text-auth">
|
||||
<div class="logo"></div>
|
||||
<div class="wbox">
|
||||
<h3 class="title">2차 휴대폰 문자 인증</h3>
|
||||
<p class="desc">아이디에 등록된 휴대폰번호를 입력해 주세요.</p>
|
||||
<!-- <form action=""> -->
|
||||
<ul class="pw-form">
|
||||
<div>
|
||||
<li><input type="text"
|
||||
placeholder="휴대폰번호를 입력하세요 (숫자만 입력하세요.)"
|
||||
v-model="mdn"
|
||||
:maxlength="11"
|
||||
oninput="javascript: this.value = this.value.replace(/[^0-9]/g, '');"
|
||||
@keyup.enter="authNum">
|
||||
<button class="btn-p2color" v-on:click="authNum">인증번호 받기</button></li>
|
||||
</div>
|
||||
<div>
|
||||
<li class="bg-g">
|
||||
<input type="text"
|
||||
placeholder="인증번호를 입력하세요"
|
||||
v-model="confirmNum"
|
||||
:maxlength="6"
|
||||
oninput="javascript: this.value = this.value.replace(/[^0-9]/g, '');"
|
||||
@keyup.enter="ajaxAuth">
|
||||
<span class="time"> {{ timerStr }}</span></li>
|
||||
</div>
|
||||
<li>
|
||||
<button class="btn-default" @click="clickMenu('/login')">취소</button>
|
||||
<button class="btn-pcolor" v-on:click="ajaxAuth">확인</button>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- </form> -->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
import api from '../service/api';
|
||||
import tokenSvc from '@/common/token-service';
|
||||
import LoginPopup from '@/components/LoginPopup.vue'
|
||||
//import * as utils from '@/common/utils';
|
||||
|
||||
export default {
|
||||
data: function() {
|
||||
return {
|
||||
errors: [],
|
||||
mdn: '01012341234',
|
||||
confirmNum: '',
|
||||
userId: '',
|
||||
isAuthNum: false,
|
||||
isLogin: true,
|
||||
pwd: '',
|
||||
text: '',
|
||||
number: '',
|
||||
timer: null,
|
||||
timeCounter: 180,
|
||||
timerStr: "03:00"
|
||||
};
|
||||
},
|
||||
components: {
|
||||
LoginPopup : LoginPopup
|
||||
},
|
||||
created() {
|
||||
if(!!tokenSvc.getToken()){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.$router.push({ path: '/' });
|
||||
}else{
|
||||
if(!this.getLogin){
|
||||
this.$router.push({ path: '/login' });
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if (localStorage.hubwebUserId) {
|
||||
this.userId = localStorage.hubwebUserId;
|
||||
}
|
||||
this.isLogin = this.getLogin;
|
||||
this.pwd = this.getPwd;
|
||||
},
|
||||
computed: {
|
||||
...mapGetters({
|
||||
getLogin: 'login/isLogin',
|
||||
getErrorPage: 'login/isErrorPage',
|
||||
getAuthChk: 'login/isAuthChk',
|
||||
getPwd: 'login/getPwd'
|
||||
}),
|
||||
},
|
||||
watch: {
|
||||
getLogin(data) {
|
||||
if (data != null && data != '' && data == true) {
|
||||
this.isLogin = true;
|
||||
} else {
|
||||
this.isLogin = false;
|
||||
}
|
||||
},
|
||||
getPwd(data) {
|
||||
if(data != null && data != ''){
|
||||
this.pwd = data;
|
||||
}
|
||||
}
|
||||
},
|
||||
destroyed() {
|
||||
let cont = document.querySelector(".wrap");
|
||||
cont.classList.remove("bg-wrap");
|
||||
},
|
||||
methods: {
|
||||
// 2차 인증번호 요청
|
||||
authNum(){
|
||||
var vm = this;
|
||||
if(!this.isLogin){
|
||||
vm.$store.commit("login/isLogin", false);
|
||||
vm.$store.commit("login/isAuthChk", false);
|
||||
vm.$router.push({ path: '/'});
|
||||
return;
|
||||
}
|
||||
if (vm.mdn == null || vm.mdn.trim() == "" || vm.mdn.length < 11 || !vm.mdn){
|
||||
vm.ModalOpen('modal06');
|
||||
return false;
|
||||
}
|
||||
var params = {
|
||||
"oprtrId": this.userId,
|
||||
"hpNo": this.mdn,
|
||||
"isLogin" : this.isLogin
|
||||
}
|
||||
api.authNum(params).then(response => {
|
||||
console.log(response);
|
||||
var rsp = response.data;
|
||||
if(rsp.retCode == '0000'){
|
||||
this.timerStop(this.timer);
|
||||
this.timer = this.timerStart();
|
||||
vm.ModalOpen('modal07');
|
||||
// console.log('시간 3:00 카운트 하기');
|
||||
this.isAuthNum = true;
|
||||
}else if (!this.timer) {
|
||||
this.timerStop(this.timer);
|
||||
this.timer = null;
|
||||
vm.ModalOpen('modal06');
|
||||
// 실패 -> 실패 코드에 따라 실패 팝업 보여주기
|
||||
//인증시간 초과 후 “시간초과!” 문구로 변경
|
||||
}
|
||||
}).catch(response =>{
|
||||
|
||||
console.log(response);
|
||||
});
|
||||
},
|
||||
|
||||
// 2차 인증 확인
|
||||
ajaxAuth: function(){
|
||||
var vm = this;
|
||||
if (!vm.formCheck()){
|
||||
alert(vm.errors[0]);
|
||||
return false;
|
||||
}
|
||||
|
||||
if(this.timeCounter == 0){
|
||||
this.ModalOpen('modal10');
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
var params = {
|
||||
"oprtrId": this.userId,
|
||||
"hpNo": this.mdn,
|
||||
"chrVal": this.confirmNum,
|
||||
"isLogin": this.isLogin,
|
||||
"oprtrPw": this.pwd
|
||||
}
|
||||
|
||||
//인증번호 확인
|
||||
api.confirmNum(params).then(function(response){
|
||||
var rsp = response.data;
|
||||
console.log("RESULT_CODE : "+rsp.retCode);
|
||||
if(rsp.retCode == '0000'){
|
||||
vm.$store.commit("login/isLogin", true);
|
||||
//var nextUrl = rsp.data.nextUrl;
|
||||
//vm.$router.push({ path: nextUrl});
|
||||
vm.$router.push({ path: '/'});
|
||||
}else if(rsp.retCode == '4008') { //휴대폰번호 확인
|
||||
vm.ModalOpen('modal06');
|
||||
|
||||
}
|
||||
// else if(rsp.retCode == '4009') { //인증실패: 시간초과
|
||||
// vm.ModalOpen('modal10');
|
||||
// }
|
||||
else{
|
||||
if(rsp.retCode == '4010') { //인증실패: 인증번호
|
||||
vm.ModalOpen('modal09');
|
||||
}
|
||||
else if(rsp.retCode == '4011') { //인증실패: 5회
|
||||
vm.ModalOpen('modal11');
|
||||
// vm.$router.go(-1)
|
||||
}
|
||||
return;
|
||||
|
||||
}
|
||||
// else{
|
||||
// }
|
||||
});
|
||||
},
|
||||
formCheck: function() {
|
||||
this.errors = [];
|
||||
if(!this.mdn){
|
||||
this.ModalOpen('modal06');
|
||||
} else if(!this.isAuthNum){
|
||||
this.errors.push('인증요청을 먼저 해주세요.');
|
||||
}else if(!this.confirmNum){
|
||||
this.ModalOpen('modal08');
|
||||
}
|
||||
|
||||
return this.errors.length == 0;
|
||||
},
|
||||
|
||||
clickMenu(link){
|
||||
this.$router.push({
|
||||
path: link
|
||||
});
|
||||
},
|
||||
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
},
|
||||
timerStart: function() {
|
||||
// 1초에 한번씩 start 호출
|
||||
this.timeCounter = 180;
|
||||
var interval = setInterval(() => {
|
||||
this.timeCounter--;
|
||||
//1초씩 감소
|
||||
this.timerStr = this.prettyTime();
|
||||
if (this.timeCounter <= 0)
|
||||
{
|
||||
this.timerStop(interval);
|
||||
}
|
||||
}, 1000);
|
||||
|
||||
return interval;
|
||||
},
|
||||
|
||||
timerStop: function(Timer)
|
||||
{
|
||||
clearInterval(Timer);
|
||||
this.timeCounter = 0;
|
||||
},
|
||||
|
||||
prettyTime: function() {
|
||||
// 시간 형식으로 변환 리턴
|
||||
let time = this.timeCounter / 60;
|
||||
let minutes = parseInt(time);
|
||||
let secondes = Math.round((time - minutes) * 60);
|
||||
|
||||
return (
|
||||
minutes.toString().padStart(2, "0") +
|
||||
":"
|
||||
+ secondes.toString().padStart(2, "0")
|
||||
);
|
||||
},
|
||||
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -1,153 +1,154 @@
|
||||
<template>
|
||||
<div class="wrap bg-wrap">
|
||||
<div class="login-box adm-login">
|
||||
<div class="wbox">
|
||||
<div class="logo"></div>
|
||||
<h3 class="title">관리자 로그인</h3>
|
||||
<!-- <form action=""> -->
|
||||
<div class="login-form">
|
||||
<li><input type="text" placeholder="아이디" v-model="userId"></li>
|
||||
<li><input type="password" placeholder="비밀번호" v-model="userPwd"></li>
|
||||
<li>
|
||||
<span class="lcont"><input type="checkbox" id="id-remember" ref="chkSaveId" checked><label for="id-remember">아이디 저장</label></span>
|
||||
<span class="rcont"><button class="btn-pwreset" @click="clickMenu('/view/login/resetPassword')">비밀번호 초기화</button></span>
|
||||
</li>
|
||||
<li><button class="btn-pcolor" v-on:click="ajaxlogin">로그인</button></li>
|
||||
</div>
|
||||
<!-- </form> -->
|
||||
<div class="login-notice">
|
||||
<div>
|
||||
<li>비밀번호 분실 시 비밀번호 초기화를 이용해주세요.</li>
|
||||
<li>비밀번호는 90일이내 변경하여 안전히 관리해주세요.</li>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import api from '../service/api';
|
||||
import LoginPopup from '@/components/LoginPopup.vue';
|
||||
import tokenSvc from '@/common/token-service';
|
||||
//import * as utils from '@/common/utils';
|
||||
|
||||
export default {
|
||||
data: function() {
|
||||
return {
|
||||
errors: [],
|
||||
corpId: '',
|
||||
userId: '',
|
||||
userPwd: ''
|
||||
};
|
||||
},
|
||||
created() {
|
||||
// 로그인 페이지 진입시
|
||||
if(!!tokenSvc.getToken()){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.$router.push({ path: '/' });
|
||||
}else{
|
||||
this.$store.commit("login/isLogin", false);
|
||||
this.$store.commit("login/isAuthChk", false);
|
||||
this.$store.commit("login/isErrorPage", false);
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.$refs.chkSaveId.checked = true;
|
||||
|
||||
if (localStorage.hubwebUserId) {
|
||||
this.userId = localStorage.hubwebUserId;
|
||||
}
|
||||
},
|
||||
destroyed() {
|
||||
let cont = document.querySelector(".wrap");
|
||||
cont.classList.remove("login-wrap");
|
||||
},
|
||||
components: {
|
||||
LoginPopup : LoginPopup
|
||||
},
|
||||
methods: {
|
||||
chgChkUserId() {
|
||||
if (this.$refs.chkSaveId.checked == true) {
|
||||
localStorage.hubwebUserId = this.userId;
|
||||
} else {
|
||||
delete localStorage.hubwebUserId;
|
||||
}
|
||||
},
|
||||
toRegister(){
|
||||
this.$router.push({ name: 'register'});
|
||||
},
|
||||
formCheck: function() {
|
||||
this.errors = [];
|
||||
|
||||
|
||||
if (!this.userId) this.errors.push('아이디를 입력해 주세요.');
|
||||
if (!this.userPwd) this.errors.push('비밀번호를 입력해 주세요.');
|
||||
|
||||
return this.errors.length == 0;
|
||||
},
|
||||
ajaxlogin: function() {
|
||||
|
||||
var vm = this;
|
||||
vm.errmsg = null;
|
||||
|
||||
if (!vm.formCheck()) return false;
|
||||
|
||||
let oprtrPw = this.userPwd;
|
||||
|
||||
// FormData 객체를 파라미터로 넘기면 Content-Type: multipart/form-data; 요청을 한다.
|
||||
// 일반 Object를 파라미터로 넘기면 Content-Type: application/json;charset=UTF-8 요청을 한다.
|
||||
var params = {
|
||||
"oprtrId": this.userId,
|
||||
"oprtrPw": this.userPwd,
|
||||
}
|
||||
//로그인버튼을 누를시 상황
|
||||
api.login(params).then(function(response) {
|
||||
|
||||
var rsp = response.data;
|
||||
|
||||
if(rsp.retCode == '0000'){
|
||||
var path = rsp.data.nextUrl;
|
||||
console.log(path);
|
||||
vm.chgChkUserId();
|
||||
vm.$store.commit("login/isLogin", true);
|
||||
vm.$store.commit("login/savePwd", oprtrPw);
|
||||
vm.$router.push({ path: '/view/login/auth'});
|
||||
} else if(rsp.retCode == '4004') { // ID/PWD 불일치
|
||||
vm.errors.push('로그인 실패하였습니다. (5회 실패 시 계정 잠김)');
|
||||
vm.ModalOpen('modal01');
|
||||
} else if(rsp.retCode == '4005') { // ID/PWD 불일치 횟수초과로 계정 잠김
|
||||
// msg = '5회 이상 로그인 실패하여 해당 아이디에 대한 계정이 잠금처리되었습니다.\n관리자에게 문의하세요.';
|
||||
vm.ModalOpen('modal02');
|
||||
} else if(rsp.retCode == '4006') {
|
||||
// msg = '비밀번호를 변경하신지 90일이 지났습니다.\n비밀번호 변경 화면으로 이동합니다.';
|
||||
vm.ModalOpen('modal04');
|
||||
} else if(rsp.retCode == '4007') {
|
||||
// msg = '관리자 승인 후 이용할 수 있습니다.';
|
||||
vm.ModalOpen('modal03');
|
||||
} else {
|
||||
vm.$store.commit("login/isLogin", false);
|
||||
return;
|
||||
}
|
||||
});
|
||||
|
||||
},
|
||||
|
||||
|
||||
clickMenu(link){
|
||||
|
||||
this.$router.push({
|
||||
path: link
|
||||
});
|
||||
},
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
},
|
||||
|
||||
} //method 끝
|
||||
};
|
||||
|
||||
</script>
|
||||
<template>
|
||||
<div class="wrap bg-wrap">
|
||||
<div class="login-box adm-login">
|
||||
<div class="wbox">
|
||||
<div class="logo"></div>
|
||||
<h3 class="title">관리자 로그인</h3>
|
||||
<!-- <form action=""> -->
|
||||
<div class="login-form">
|
||||
<li><input type="text" placeholder="아이디" v-model="userId"></li>
|
||||
<li><input type="password" placeholder="비밀번호" v-model="userPwd" @keyup.enter="ajaxlogin"></li>
|
||||
<li>
|
||||
<span class="lcont"><input type="checkbox" id="id-remember" ref="chkSaveId" checked><label for="id-remember">아이디 저장</label></span>
|
||||
<span class="rcont"><button class="btn-pwreset" @click="clickMenu('/view/login/resetPassword')">비밀번호 초기화</button></span>
|
||||
</li>
|
||||
<li><button class="btn-pcolor" v-on:click="ajaxlogin">로그인</button></li>
|
||||
</div>
|
||||
<!-- </form> -->
|
||||
<div class="login-notice">
|
||||
<div>
|
||||
<li>비밀번호 분실 시 비밀번호 초기화를 이용해주세요.</li>
|
||||
<li>비밀번호는 90일이내 변경하여 안전히 관리해주세요.</li>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import api from '../service/api';
|
||||
import LoginPopup from '@/components/LoginPopup.vue';
|
||||
import tokenSvc from '@/common/token-service';
|
||||
//import * as utils from '@/common/utils';
|
||||
|
||||
export default {
|
||||
data: function() {
|
||||
return {
|
||||
errors: [],
|
||||
corpId: '',
|
||||
userId: '',
|
||||
userPwd: ''
|
||||
};
|
||||
},
|
||||
created() {
|
||||
// 로그인 페이지 진입시
|
||||
if(!!tokenSvc.getToken()){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.$router.push({ path: '/' });
|
||||
}else{
|
||||
this.$store.commit("login/isLogin", false);
|
||||
this.$store.commit("login/isAuthChk", false);
|
||||
this.$store.commit("login/isErrorPage", false);
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.$refs.chkSaveId.checked = true;
|
||||
|
||||
if (localStorage.hubwebUserId) {
|
||||
this.userId = localStorage.hubwebUserId;
|
||||
}
|
||||
},
|
||||
destroyed() {
|
||||
let cont = document.querySelector(".wrap");
|
||||
cont.classList.remove("login-wrap");
|
||||
},
|
||||
components: {
|
||||
LoginPopup : LoginPopup
|
||||
},
|
||||
methods: {
|
||||
chgChkUserId() {
|
||||
if (this.$refs.chkSaveId.checked == true) {
|
||||
localStorage.hubwebUserId = this.userId;
|
||||
} else {
|
||||
delete localStorage.hubwebUserId;
|
||||
}
|
||||
},
|
||||
toRegister(){
|
||||
this.$router.push({ name: 'register'});
|
||||
},
|
||||
formCheck: function() {
|
||||
this.errors = [];
|
||||
|
||||
|
||||
if (!this.userId) this.errors.push('아이디를 입력해 주세요.');
|
||||
if (!this.userPwd) this.errors.push('비밀번호를 입력해 주세요.');
|
||||
|
||||
return this.errors.length == 0;
|
||||
},
|
||||
ajaxlogin: function() {
|
||||
|
||||
var vm = this;
|
||||
vm.errmsg = null;
|
||||
|
||||
if (!vm.formCheck()) return false;
|
||||
|
||||
let oprtrPw = this.userPwd;
|
||||
|
||||
// FormData 객체를 파라미터로 넘기면 Content-Type: multipart/form-data; 요청을 한다.
|
||||
// 일반 Object를 파라미터로 넘기면 Content-Type: application/json;charset=UTF-8 요청을 한다.
|
||||
var params = {
|
||||
"oprtrId": this.userId,
|
||||
"oprtrPw": this.userPwd,
|
||||
}
|
||||
//로그인버튼을 누를시 상황
|
||||
api.login(params).then(function(response) {
|
||||
|
||||
var rsp = response.data;
|
||||
|
||||
if(rsp.retCode == '0000'){
|
||||
var path = rsp.data.nextUrl;
|
||||
console.log(path);
|
||||
vm.chgChkUserId();
|
||||
vm.$store.commit("login/isLogin", true);
|
||||
vm.$store.commit("login/savePwd", oprtrPw);
|
||||
vm.$router.push({ path: '/view/login/auth'});
|
||||
} else if(rsp.retCode == '4004') { // ID/PWD 불일치
|
||||
vm.errors.push('로그인 실패하였습니다. (5회 실패 시 계정 잠김)');
|
||||
vm.ModalOpen('modal01');
|
||||
} else if(rsp.retCode == '4005') { // ID/PWD 불일치 횟수초과로 계정 잠김
|
||||
// msg = '5회 이상 로그인 실패하여 해당 아이디에 대한 계정이 잠금처리되었습니다.\n관리자에게 문의하세요.';
|
||||
vm.ModalOpen('modal02');
|
||||
} else if(rsp.retCode == '4006') {
|
||||
// msg = '비밀번호를 변경하신지 90일이 지났습니다.\n비밀번호 변경 화면으로 이동합니다.';
|
||||
vm.chgChkUserId();
|
||||
vm.ModalOpen('modal04');
|
||||
} else if(rsp.retCode == '4007') {
|
||||
// msg = '관리자 승인 후 이용할 수 있습니다.';
|
||||
vm.ModalOpen('modal03');
|
||||
} else {
|
||||
vm.$store.commit("login/isLogin", false);
|
||||
return;
|
||||
}
|
||||
});
|
||||
|
||||
},
|
||||
|
||||
|
||||
clickMenu(link){
|
||||
|
||||
this.$router.push({
|
||||
path: link
|
||||
});
|
||||
},
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
},
|
||||
|
||||
} //method 끝
|
||||
};
|
||||
|
||||
</script>
|
||||
|
||||
@@ -1,97 +1,112 @@
|
||||
<template>
|
||||
|
||||
<div class="wrap bg-wrap">
|
||||
|
||||
<!-- s: 패스워드초기화 -->
|
||||
<div class="login-box pw-reset">
|
||||
<div class="logo"></div>
|
||||
<div class="wbox">
|
||||
<h3 class="title">비밀번호 초기화</h3>
|
||||
<!-- <form action=""> -->
|
||||
<div class="login-form">
|
||||
<div>
|
||||
|
||||
<input type="text" placeholder="아이디를 입력하세요"></div>
|
||||
<div class="button_group">
|
||||
<button class="btn-default" @click="clickMenu('/login')">취소</button>
|
||||
<button class="btn-pcolor">비밀번호 초기화 문자 발송하기</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- </form> -->
|
||||
<div class="login-notice">
|
||||
<div>
|
||||
<li>초기화된 비밀번호는 등록된 휴대폰 문자메시지로 발송됩니다.</li>
|
||||
<li>휴대폰 번호 변경 시 관리자로 문의해주세요.</li>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import api from '../service/api';
|
||||
import LoginPopup from '@/components/LoginPopup.vue';
|
||||
|
||||
export default {
|
||||
name: 'resetPassword',
|
||||
data() {
|
||||
return {}
|
||||
},
|
||||
created() {
|
||||
this.$store.commit("login/isLogin", false);
|
||||
this.$store.commit("login/isAuthChk", false);
|
||||
},
|
||||
components: {
|
||||
LoginPopup
|
||||
},
|
||||
methods: {
|
||||
// ajaxReset: function(){
|
||||
// var vm = this;
|
||||
// vm.errmsg = null;
|
||||
// // if (!vm.formCheck()) return false;
|
||||
|
||||
// var params = {
|
||||
// //"corpId": this.corpId,
|
||||
// // "userPwd": this.userPwd,
|
||||
|
||||
// } // 주석으로 인한
|
||||
// api.newpwd(params).then(function(response){
|
||||
// var rsp = response.data;
|
||||
// console.log("RESULT_CODE : "+rsp.retCode);
|
||||
// if(rsp.retCode == '000'){
|
||||
// // vm.$store.commit("login/isLogin", true);
|
||||
// //vm.$store.commit("login/isAuthChk", true);
|
||||
|
||||
// vm.ModalOpen('modal12');
|
||||
// // vm.$router.push({ path : 'view/login'});
|
||||
// } else {
|
||||
// return;
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
// ,
|
||||
clickMenu(link) {
|
||||
|
||||
this
|
||||
.$router
|
||||
.push({path: link});
|
||||
},
|
||||
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
<div class="wrap bg-wrap">
|
||||
|
||||
<!-- s: 패스워드초기화 -->
|
||||
<div class="login-box pw-reset">
|
||||
<div class="logo"></div>
|
||||
<div class="wbox">
|
||||
<h3 class="title">비밀번호 초기화</h3>
|
||||
<!-- <form action=""> -->
|
||||
<div class="login-form">
|
||||
<div>
|
||||
|
||||
<input type="text" placeholder="아이디를 입력하세요" v-model="userId"></div>
|
||||
<div class="button_group">
|
||||
<button class="btn-pcolor" @click="ajaxReset">비밀번호 초기화 문자 발송하기</button>
|
||||
<button class="btn-default" @click="clickMenu('/login')">취소</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- </form> -->
|
||||
<div class="login-notice">
|
||||
<div>
|
||||
<li>초기화된 비밀번호는 등록된 휴대폰 문자메시지로 발송됩니다.</li>
|
||||
<li>휴대폰 번호 변경 시 관리자로 문의해주세요.</li>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import api from '../service/api';
|
||||
import LoginPopup from '@/components/LoginPopup.vue';
|
||||
export default {
|
||||
name: 'resetPassword',
|
||||
data: function() {
|
||||
return {
|
||||
errors: [],
|
||||
userId: '',
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$store.commit("login/isLogin", false);
|
||||
this.$store.commit("login/isAuthChk", false);
|
||||
},
|
||||
components: {
|
||||
LoginPopup
|
||||
},
|
||||
methods: {
|
||||
formCheck: function()
|
||||
{
|
||||
this.errors = [];
|
||||
if (!this.userId) {
|
||||
this.errors.push('아이디를 입력해 주세요.');
|
||||
}
|
||||
|
||||
return this.errors.length == 0;
|
||||
},
|
||||
|
||||
ajaxReset: function(){
|
||||
var vm = this;
|
||||
//vm.errmsg = null;
|
||||
if (!vm.formCheck()) return false;
|
||||
|
||||
var params =
|
||||
{
|
||||
"userId": this.userId,
|
||||
//"userPwd": this.userPwd,
|
||||
}
|
||||
api.resetPassword(params).then(function(response){
|
||||
var rsp = response.data;
|
||||
console.log("RESULT_CODE : "+rsp.retCode);
|
||||
|
||||
if(rsp.retCode == '0000'){
|
||||
// vm.$store.commit("login/isLogin", true);
|
||||
//vm.$store.commit("login/isAuthChk", true);
|
||||
|
||||
vm.ModalOpen('modal12');
|
||||
// vm.$router.push({ path : 'view/login'});
|
||||
} else if(rsp.retCode == '4003') {
|
||||
vm.ModalOpen('modal13');
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
});
|
||||
}
|
||||
,
|
||||
clickMenu(link) {
|
||||
|
||||
this
|
||||
.$router
|
||||
.push({path: link});
|
||||
},
|
||||
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style></style>
|
||||
163
frontend/src/modules/login/views/UpdatePassword.vue
Normal file
163
frontend/src/modules/login/views/UpdatePassword.vue
Normal file
@@ -0,0 +1,163 @@
|
||||
<template>
|
||||
<div class="wrap bg-wrap">
|
||||
<!-- s: 비밀번호변경 -->
|
||||
<div id="cpf" class="login-box pw-change">
|
||||
<div class="logo"></div>
|
||||
<div class="wbox">
|
||||
<h3 class="title">비밀번호 변경</h3>
|
||||
<p class="desc">임시비밀번호로 로그인할 경우 비밀번호를 변경 후<br>서비스 이용이 가능합니다.</p>
|
||||
<form @submit.prevent="changedPwd">
|
||||
<ul class="pw-form">
|
||||
<div><input id="oldPw" type="text" placeholder="기존 비밀번호를 입력하세요" v-model="oldPw" ref="oldPw"></div>
|
||||
<div>
|
||||
<input id="newPw" type="text" placeholder="새로운 비밀번호를 입력하세요" v-model="newPw" ref="newPw" maxlength="16">
|
||||
</div>
|
||||
<div><input type="text" placeholder="새로운 비밀번호를 다시 한 번 입력하세요" ></div>
|
||||
<div><button class="btn-pcolor" @click="changedPwd()">비밀번호 변경하기</button></div>
|
||||
</ul>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
<login-popup ref="LoginPopup"> </login-popup>
|
||||
</div>
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import api from '../service/api';
|
||||
import { mapGetters } from 'vuex';
|
||||
import LoginPopup from '@/components/LoginPopup.vue';
|
||||
import tokenSvc from '@/common/token-service';
|
||||
import { commonPwdView, validation } from '../service/mixins';
|
||||
// import { chkPattern } from '@/common/vue-mixins';
|
||||
// import * as utils from '@/common/utils';
|
||||
export default {
|
||||
mixins: [commonPwdView, validation],
|
||||
data: function() {
|
||||
return {
|
||||
userId: '',
|
||||
oldPw: '',
|
||||
newPw: '',
|
||||
passwordValidFlag: true,
|
||||
};
|
||||
},
|
||||
|
||||
created: function() {
|
||||
if(!!tokenSvc.getToken()){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.$router.push({ path: '/' });
|
||||
}else{
|
||||
// if(!this.getLogin){
|
||||
// this.$router.push({ path: '/login' });
|
||||
// }
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// this.$refs.chkSaveId.checked = true;
|
||||
|
||||
if (localStorage.hubwebUserId) {
|
||||
this.userId = localStorage.hubwebUserId;
|
||||
}
|
||||
this.isLogin = this.getLogin;
|
||||
this.oldPw = this.getPwd;
|
||||
},
|
||||
|
||||
computed: {
|
||||
...mapGetters({
|
||||
getLogin: 'login/isLogin',
|
||||
getPwd: 'login/getPwd'
|
||||
}),
|
||||
},
|
||||
|
||||
watch: {
|
||||
getLogin(data) {
|
||||
if (data != null && data != '' && data == true) {
|
||||
this.isLogin = true;
|
||||
} else {
|
||||
this.isLogin = false;
|
||||
}
|
||||
},
|
||||
getPwd(data) {
|
||||
if(data != null && data != ''){
|
||||
this.pwd = data;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
components: {
|
||||
LoginPopup : LoginPopup
|
||||
},
|
||||
|
||||
methods: {
|
||||
verifyNewPw: function() {
|
||||
this.message.newPw = '';
|
||||
},
|
||||
|
||||
formCheck: function() {
|
||||
this.errors = [];
|
||||
|
||||
|
||||
if (!this.oldPw) this.errors.push('기존비밀번호');
|
||||
if (!this.newPw) this.errors.push('새로운비밀번호');
|
||||
|
||||
return this.errors.length == 0;
|
||||
},
|
||||
|
||||
|
||||
changedPwd: function() {
|
||||
|
||||
var vm = this;
|
||||
|
||||
var params = {
|
||||
|
||||
"userId": this.userId,
|
||||
"oldPw": this.oldPw,
|
||||
"newPw": this.newPw
|
||||
}
|
||||
|
||||
api.updatePassword(params).then(function(response) {
|
||||
var rsp = response.data;
|
||||
// var pofo = document.getElementById('oldPw');
|
||||
|
||||
if(rsp.retCode == '0000') {
|
||||
// vm.chgChkUserId();
|
||||
|
||||
if(vm.ModalOpen('modal16')){
|
||||
vm.$router.push({ path: '/login' });
|
||||
}
|
||||
} else if(rsp.retCode == '4016') {
|
||||
vm.ModalOpen('modal14')
|
||||
} else if(rsp.retCode == '4017') {
|
||||
vm.ModalOpen('modal15')
|
||||
} else if(rsp.retCode == '4003') {
|
||||
if(vm.ModalOpen('modal14')) {
|
||||
//수정사항 : 모달오픈 -> 기존비밀번호 포커스
|
||||
alert('1');
|
||||
}
|
||||
|
||||
// //this.$refs.oldPw.focus();
|
||||
// alert('비밀번호 유효성체크');
|
||||
// vm.$refs.oldPw.focus();
|
||||
}
|
||||
else {
|
||||
return;
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
ModalOpen: function(target){
|
||||
this.$refs.LoginPopup.ModalOpen(target);
|
||||
// this.$refs.oldPw.focus(target);
|
||||
},
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
273
frontend/src/modules/sysMgt/AdminList.vue
Normal file
273
frontend/src/modules/sysMgt/AdminList.vue
Normal file
@@ -0,0 +1,273 @@
|
||||
<template>
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">관리자/유치채널 관리</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right" v-model="grid.params.searchType1" @keyup.enter="search">
|
||||
<option value="">전체</option>
|
||||
<option v-for="(option, i) in authType" v-bind:value="option.autCd" v-bind:key="i">
|
||||
{{ option.autNm }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="" v-model="grid.params.searchType2" @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="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력" v-model="grid.params.searchText1" @keyup.enter="search"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력" v-model="grid.params.searchText2" @keyup.enter="search"/>
|
||||
</div>
|
||||
<button type="button" class="button grey" @click="search">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>{{ totalItems }}</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="deleteRow();">삭제</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"
|
||||
></custom-grid>
|
||||
</div>
|
||||
<admin-reg-pop ref="adminRegModal"> </admin-reg-pop>
|
||||
<!-- <admin-reg2-pop ref="adminReg2Modal"> </admin-reg2-pop> -->
|
||||
<admin-detail-pop ref="adminDetailModal"> </admin-detail-pop>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
import AdminRegPop from '../components/AdminRegPop';
|
||||
//import AdminReg2Pop from '../components/AdminReg2Pop';
|
||||
import AdminDetailPop from '../components/AdminDetailPop';
|
||||
import api from '@/service/api.js';
|
||||
import sysMgtApi from "../service/sysMgtApi.js";
|
||||
|
||||
|
||||
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)
|
||||
this.el = el;
|
||||
}
|
||||
|
||||
getElement() {
|
||||
return this.el;
|
||||
}
|
||||
|
||||
addEvent(selEl) {
|
||||
selEl.addEventListener("click", () => {
|
||||
const { callback } = this.props["cgrido" + this.props.colName].options;
|
||||
callback(this.props);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
export default {
|
||||
name: 'adminList',
|
||||
data() {
|
||||
return {
|
||||
row: {},
|
||||
authType: [],
|
||||
statType: [],
|
||||
cate2Code: "",
|
||||
totalItems: 0,
|
||||
// 테이블 리스트 데이터
|
||||
perPageCnt: 20,
|
||||
grid: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
pagePerRows: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true, // true:첫번째 컬럼 앞에 체크박스 생성 / false:체크박스 제거
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'No', align: 'center', width: 60},
|
||||
{ name: 'auth', header: '권한', align: 'center', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130, renderer: {
|
||||
type: CustomATagRenderer
|
||||
, options: {
|
||||
callback: this.detailPop,
|
||||
}
|
||||
}
|
||||
},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130, cls: 'td_line'},
|
||||
{ name: 'regDt', header: '등록일', align: 'center', width: 130}
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
params: {
|
||||
searchType1: '',
|
||||
searchType2: '',
|
||||
searchText1: '',
|
||||
searchText2: ''
|
||||
},
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid,
|
||||
// SystemPopup,
|
||||
AdminRegPop,
|
||||
//AdminReg2Pop,
|
||||
AdminDetailPop
|
||||
},
|
||||
created(){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.setCodeData();
|
||||
//let cont = document.querySelector(".wrap");
|
||||
//cont.classList.add("main_wrap");
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let page = 1;
|
||||
// 페이지 정보 및 검색 조건
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
console.log('getCondition : '+getCondition);
|
||||
|
||||
// store에 저장된 페이지 정보 및 검색 조건을 불러오기
|
||||
let isKeep = false;
|
||||
if (getCondition) {
|
||||
this.grid.pagePerRows = getCondition.perPage;
|
||||
this.grid.params = getCondition.params;
|
||||
page = getCondition.page;
|
||||
isKeep = true;
|
||||
}
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log('this.perPageCnt'+this.perPageCnt);
|
||||
//console.log(this.grid.params);
|
||||
this.$refs.table.search(this.grid.params, isKeep);
|
||||
this.sendStoreData();
|
||||
},
|
||||
detailPop(props) {
|
||||
// this.getMainSlot().popupView(4);
|
||||
// this.setDtlPpPrm(props);
|
||||
this.$refs.adminDetailModal.adminDetailModalOpen(props);
|
||||
},
|
||||
ModalOpen: function(target){
|
||||
//this.$refs.systemModal.ModalOpen(target);
|
||||
},
|
||||
adminRegPopOpen: function(){
|
||||
this.$refs.adminRegModal.ModalOpen(1);
|
||||
},
|
||||
adminReg2PopOpen: function(){
|
||||
this.$refs.adminRegModal.ModalOpen(2);
|
||||
//this.$refs.adminReg2Modal.adminReg2ModalOpen();//
|
||||
},
|
||||
doValidate(){ //로우데이터 삭제하도록 수정
|
||||
|
||||
console.log("totalItems >> " + this.totalItems);
|
||||
if(this.totalItems == 0){
|
||||
alert('검색 결과가 없습니다.');
|
||||
return false;
|
||||
}
|
||||
var chkList = this.$refs.table.checkedElementDatas();
|
||||
if(chkList.length == 0){
|
||||
alert('체크박스에 체크를 해주세요.');
|
||||
return false;
|
||||
}
|
||||
// for(var i = 0; i < chkList.length; i++){
|
||||
// alert(chkList[i].adminId);
|
||||
// }
|
||||
const param = chkList.map((row)=>({adminId:row.adminId}));
|
||||
this.row.list = param;
|
||||
console.log(this.row);
|
||||
return true;
|
||||
},
|
||||
sendStoreData: function() {
|
||||
const getP = this.$refs.table.getPagination();
|
||||
console.log("==========getP : " + getP);
|
||||
this.$store.commit('searchcondition/updateSearchCondition', {
|
||||
page: getP._currentPage,
|
||||
perPage: this.perPageCnt,
|
||||
params: this.grid.params
|
||||
});
|
||||
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
//console.log("getCondition : "+ getCondition.perPage);
|
||||
},
|
||||
setCodeData() {
|
||||
|
||||
// 상태 옵션 셋팅.
|
||||
api.commCode({'grpCd' : 'ADM_STTUS_CD'}).then(response => {
|
||||
this.statType = response.data.data.list;
|
||||
});
|
||||
api.commAuth().then(response => {
|
||||
this.authType = response.data.data.list;
|
||||
});
|
||||
},
|
||||
async deleteRow(){
|
||||
if(this.doValidate() && window.confirm('삭제 하시겠습니까?')){
|
||||
try {
|
||||
let response = await sysMgtApi.deleteAdmin(this.row);
|
||||
const result = response.data;
|
||||
if (result != null && result.retCode == "0000") {
|
||||
alert('삭제 하였습니다.');
|
||||
// grid.reloadData();
|
||||
this.$refs.table.reloadData();
|
||||
return;
|
||||
}
|
||||
alert("실패 하였습니다.");
|
||||
} catch(err) {
|
||||
alert("실패 하였습니다.");
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
beforeRouteLeave(to, from, next) {
|
||||
|
||||
const getP = this.$refs.table.getPagination();
|
||||
console.log("==========getP : " + getP._currentPage);
|
||||
this.$store.commit('searchcondition/updateSearchCondition', {
|
||||
page: getP._currentPage,
|
||||
perPage: this.perPageCnt,
|
||||
params: this.grid.params
|
||||
});
|
||||
// 라우트 하기전 실행
|
||||
next();
|
||||
}
|
||||
};
|
||||
</script>
|
||||
107
frontend/src/modules/sysMgt/AuthList.vue
Normal file
107
frontend/src/modules/sysMgt/AuthList.vue
Normal file
@@ -0,0 +1,107 @@
|
||||
<template>
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">권한 관리</h3>
|
||||
<p class="breadcrumb">시스템관리 > 권한 관리</p>
|
||||
</div>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>4</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue add" onclick="location.href='system_right_add.html';">권한 추가</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<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>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>4</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey" onclick="location.href='system_right_modify.html';">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>3</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>2</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>1</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'authList',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
},
|
||||
components: {
|
||||
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
};
|
||||
</script>
|
||||
237
frontend/src/modules/sysMgt/components/AdminDetailPop.vue
Normal file
237
frontend/src/modules/sysMgt/components/AdminDetailPop.vue
Normal file
@@ -0,0 +1,237 @@
|
||||
<template>
|
||||
|
||||
<div>
|
||||
<div class="dimmed modal21" @click="adminDetailModalClose();"></div>
|
||||
<div class="popup-wrap modal21">
|
||||
<!-- 관리자/유치채널 상세정보 -->
|
||||
<div class="popup modal21 popup_form">
|
||||
<div class="pop-head">
|
||||
<h3 class="pop-tit" v-if="code === null || code === ''">관리자 상세정보</h3>
|
||||
<h3 class="pop-tit" v-else>유치채널 상세정보</h3>
|
||||
</div>
|
||||
<form autocomplete="off" ref="adminDetailForm">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
<td><input type="text" disabled v-model.trim="madangId" ref="_madangId2"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>비밀번호</th>
|
||||
<td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8" maxlength="16" ref="_pwd1" v-model.trim="userPwd1"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>비밀번호 확인</th>
|
||||
<td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8" maxlength="16" ref="_pwd2" v-model.trim="userPwd2"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>이름</th>
|
||||
<td><input type="text" disabled v-model.trim="userNm" ref="_userNm"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>휴대폰번호</th>
|
||||
<td><input type="number" disabled v-model.trim="mdn" ref="_phone"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>이메일</th>
|
||||
<td><input type="email" disabled v-model.trim="email" ref="_email"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>권한</th>
|
||||
<td v-if="code === null || code === ''">
|
||||
<div v:class="select_box">
|
||||
<select name="" id="right" v-model="auth" ref="_auth">
|
||||
<option value="">선택</option>
|
||||
<option
|
||||
v-for="(option, i) in authType"
|
||||
v-bind:value="option.autCd"
|
||||
v-bind:key="i"
|
||||
:selected="auth === option.autCd">
|
||||
{{ option.autNm }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
</td>
|
||||
<td v-else><input type="text" disabled value="대리점"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="center">상태</th>
|
||||
<td>
|
||||
<input type="radio" name="state" value="01" id="popup_radio1"
|
||||
v-model="stat"
|
||||
:checked="stat == '1'">
|
||||
<label for="popup_radio1">사용</label>
|
||||
<input type="radio" name="state" value="02" id="popup_radio2"
|
||||
v-model="stat"
|
||||
:checked="stat == '02'">
|
||||
<label for="popup_radio2">정지</label>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</form>
|
||||
<div class="pop-btn2">
|
||||
<button class="btn-default" @click="adminDetailModalClose();">취소</button>
|
||||
<button class="btn-pcolor" @click="doInsert">저장</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 관리자 상세정보 팝업 끝-->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
<script>
|
||||
import api from '@/service/api';
|
||||
import sysMgtApi from "../service/sysMgtApi.js";
|
||||
import { utils_mixin, chkPattern2 } from '../service/mixins';
|
||||
import lodash from "lodash";
|
||||
|
||||
export default {
|
||||
name: "adminDetailPop",
|
||||
mixins: [utils_mixin, chkPattern2],
|
||||
watch:{
|
||||
stat(){
|
||||
console.log('watch : ', this.stat)
|
||||
}
|
||||
},
|
||||
data(){
|
||||
return{
|
||||
row: {},
|
||||
authType: [],
|
||||
|
||||
madangId:'',
|
||||
name:'',
|
||||
mdn:'',
|
||||
email:'',
|
||||
auth:'',
|
||||
stat: '',
|
||||
userNm:"",
|
||||
userPwd1:"",
|
||||
userPwd2:"",
|
||||
code:"",
|
||||
}
|
||||
},
|
||||
model: {
|
||||
prop: 'sendData',
|
||||
event: 'event-data'
|
||||
},
|
||||
props: ['sendData'],
|
||||
created(){
|
||||
//this.formReset();
|
||||
this.setAuthData();
|
||||
},
|
||||
methods :{
|
||||
doPwdValidate(){
|
||||
if(this.isNull(this.userPwd2)){
|
||||
alert("비밀번호 확인을 입력해 주세요.");
|
||||
this.$refs._pwd2.focus();
|
||||
return false;
|
||||
}
|
||||
if(!lodash.isEqual(this.userPwd1, this.userPwd2)){
|
||||
alert("비밀번호가 일치하지 않습니다.");
|
||||
this.$refs._pwd2.focus();
|
||||
return false;
|
||||
}
|
||||
const pwdLen = this.bytes(this.userPwd1);
|
||||
if(!(pwdLen >= 8 && pwdLen <= 16)){
|
||||
alert("비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.");
|
||||
this.$refs._pwd1.focus();
|
||||
return false;
|
||||
}
|
||||
const pEng = /[A-Za-z]/g; // 영문자
|
||||
const pNum = /[0-9]/g; // 숫자
|
||||
const pSpc = /[!@$%^&*]/g; // 특수문자
|
||||
if(!(pEng.test(this.userPwd1) && pNum.test(this.userPwd1) && pSpc.test(this.userPwd1))) {
|
||||
alert("비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.");
|
||||
this.$refs._pwd1.focus();
|
||||
return;
|
||||
}
|
||||
this.row.adminPw=this.userPwd1;
|
||||
return true;
|
||||
},
|
||||
doValidate(){
|
||||
if(!this.isNull(this.userPwd1)){
|
||||
if(!this.doPwdValidate()){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if(!this.isNull(this.auth)){
|
||||
if(this.code == ''){
|
||||
this.row.auth = this.auth;
|
||||
}else{
|
||||
this.row.auth=this.auth;
|
||||
}
|
||||
}
|
||||
if(!this.isNull(this.stat)){
|
||||
this.row.stat=this.stat;
|
||||
}
|
||||
this.row.adminId=this.madangId;
|
||||
return true;
|
||||
},
|
||||
// 모달 띄우기
|
||||
async adminDetailModalOpen(props){
|
||||
this.row.adminId = props.adminId;
|
||||
try {
|
||||
const response = await sysMgtApi.adminDetail(this.row);
|
||||
const result = response.data;
|
||||
console.log(result);
|
||||
if (result != null && result.retCode == "0000") {
|
||||
this.madangId = result.data.adminId;
|
||||
this.auth = result.data.auth;
|
||||
this.userNm = result.data.name;
|
||||
this.email = result.data.email;
|
||||
this.mdn = result.data.mdn;
|
||||
this.stat = result.data.stat;
|
||||
}
|
||||
} catch(err) {
|
||||
alert("실패 하였습니다.");
|
||||
}
|
||||
var dimmed = document.getElementsByClassName('modal21');
|
||||
for(var i = 0; i < dimmed.length; i++){
|
||||
dimmed[i].style.display = 'block';
|
||||
}
|
||||
},
|
||||
// 모달 끄기
|
||||
adminDetailModalClose(){
|
||||
this.formReset();
|
||||
var dimmed = document.getElementsByClassName('modal21');
|
||||
for(var i = 0; i < dimmed.length; i++){
|
||||
dimmed[i].style.display = 'none';
|
||||
}
|
||||
},
|
||||
toComplete(){
|
||||
this.getParent('adminList').$refs.table.reloadData();
|
||||
this.adminDetailModalClose();
|
||||
},
|
||||
async doInsert(){
|
||||
if(this.doValidate() && window.confirm('등록 하시겠습니까?')){
|
||||
try {
|
||||
const response = await sysMgtApi.updateAdmin(this.row);
|
||||
const result = response.data;
|
||||
if (result != null && result.retCode == "0000") {
|
||||
alert('저장 하였습니다.');
|
||||
this.toComplete();
|
||||
}
|
||||
} catch(err) {
|
||||
alert("실패 하였습니다.");
|
||||
}
|
||||
}
|
||||
},
|
||||
setAuthData() {
|
||||
// 권한 옵션.
|
||||
api.commAuth().then(response => {
|
||||
this.authType = response.data.data.list;
|
||||
});
|
||||
},
|
||||
formReset(){
|
||||
this.$refs.adminDetailForm.reset();
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style>
|
||||
.popup-btn-wrap {width: 500px; margin: auto; padding: 100px 0;}
|
||||
.popup-btn-wrap button {width: 100%; margin-bottom: 10px; height: 50px; border-radius: 5px; box-shadow: none; border: 1px solid #000; }
|
||||
.popup-btn-wrap button:hover {background: #000; color: #fff;}
|
||||
</style>
|
||||
265
frontend/src/modules/sysMgt/components/AdminRegPop.vue
Normal file
265
frontend/src/modules/sysMgt/components/AdminRegPop.vue
Normal file
@@ -0,0 +1,265 @@
|
||||
<template>
|
||||
<!-- <div class="wrap bg-wrap"> -->
|
||||
<div>
|
||||
<div class="dimmed" @click="ModalClose();"></div>
|
||||
<div class="popup-wrap">
|
||||
<!-- 관리자/유치채널 등록 -->
|
||||
<div class="popup modal20 popup_form">
|
||||
<div class="pop-head">
|
||||
<h3 class="pop-tit" v-if="insertType === 1">관리자 등록</h3>
|
||||
<h3 class="pop-tit" v-else>유치채널 사용자 등록</h3>
|
||||
</div>
|
||||
<form autocomplete="off" ref="adminRegForm">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>마당 ID</th>
|
||||
<td class="input_search">
|
||||
<input type="text" placeholder="아이디 입력" v-model.trim="madangId" ref="madangId">
|
||||
<button type="button" class="button grey" >조회</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>비밀번호</th>
|
||||
<td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8" maxlength="16" ref="_pwd1" v-model.trim="userPwd1"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>비밀번호 확인</th>
|
||||
<td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8" maxlength="16" ref="_pwd2" v-model.trim="userPwd2"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>이름</th>
|
||||
<td><input type="text" @keypress="onlyName" @input="onlyName" v-model.trim="userNm" ref="_userNm" required maxlength="40"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>휴대폰번호</th>
|
||||
<td><input type="number" placeholder="- 자 제외 숫자만 입력" v-model.trim="mdn" v-on:keyup="onlyNum" @input="onlyNum" minlength="10" maxlength="11" ref="_phone"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>이메일</th>
|
||||
<td><input type="email" v-model.trim="email" @keypress="onlyEmail" @input="onlyEmail" maxlength="20" ref="_email"></td>
|
||||
</tr>
|
||||
<tr v-if="insertType === 2">
|
||||
<th>코드</th>
|
||||
<td><input type="text" disabled ref="_code" v-model.trim="code"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>권한</th>
|
||||
<td v-if="insertType === 1">
|
||||
<div v:class="select_box">
|
||||
<select name="" id="right" v-model="auth" ref="_auth">
|
||||
<option value="">선택</option>
|
||||
<option v-for="(option, i) in authType" v-bind:value="option.autCd" v-bind:key="i">
|
||||
{{ option.autNm }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
</td>
|
||||
<td v-else><input type="text" disabled value="대리점"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="center">상태</th>
|
||||
<td>
|
||||
<input type="radio" name="state" value="01" id="popup_radio1" v-model="stat">
|
||||
<label for="popup_radio1">사용</label>
|
||||
<input type="radio" name="state" value="02" id="popup_radio2" v-model="stat">
|
||||
<label for="popup_radio2">정지</label>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</form>
|
||||
<div class="pop-btn2">
|
||||
<button class="btn-default" @click="ModalClose();">취소</button>
|
||||
<button class="btn-pcolor" @click="doInsert">저장</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import api from '@/service/api';
|
||||
import sysMgtApi from "../service/sysMgtApi.js";
|
||||
import { utils_mixin, chkPattern2 } from '../service/mixins';
|
||||
import lodash from "lodash";
|
||||
|
||||
export default {
|
||||
name: "adminRegPop",
|
||||
mixins: [utils_mixin, chkPattern2],
|
||||
watch:{
|
||||
stat(){
|
||||
console.log('watch : ', this.stat)
|
||||
}
|
||||
},
|
||||
data(){
|
||||
return{
|
||||
row: {},
|
||||
authType: [],
|
||||
insertType:0,
|
||||
madangId:'',
|
||||
name:'',
|
||||
mdn:'',
|
||||
email:'',
|
||||
auth:'',
|
||||
stat: '',
|
||||
userNm:"",
|
||||
userPwd1:"",
|
||||
userPwd2:"",
|
||||
code:"",
|
||||
}
|
||||
},
|
||||
model: {
|
||||
prop: 'sendData',
|
||||
event: 'event-data'
|
||||
},
|
||||
props: ['sendData'],
|
||||
created(){
|
||||
this.formReset();
|
||||
this.setAuthData();
|
||||
},
|
||||
methods :{
|
||||
doPwdValidate(){
|
||||
if(this.isNull(this.userPwd1)){
|
||||
alert("비밀번호를 입력해 주세요.");
|
||||
this.$refs._pwd1.focus();
|
||||
return false;
|
||||
}
|
||||
if(this.isNull(this.userPwd2)){
|
||||
alert("비밀번호 확인을 입력해 주세요.");
|
||||
this.$refs._pwd2.focus();
|
||||
return false;
|
||||
}
|
||||
if(!lodash.isEqual(this.userPwd1, this.userPwd2)){
|
||||
alert("비밀번호가 일치하지 않습니다.");
|
||||
this.$refs._pwd2.focus();
|
||||
return false;
|
||||
}
|
||||
const pwdLen = this.bytes(this.userPwd1);
|
||||
if(!(pwdLen >= 8 && pwdLen <= 16)){
|
||||
alert("비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.");
|
||||
this.$refs._pwd1.focus();
|
||||
return false;
|
||||
}
|
||||
const pEng = /[A-Za-z]/g; // 영문자
|
||||
const pNum = /[0-9]/g; // 숫자
|
||||
const pSpc = /[!@$%^&*]/g; // 특수문자
|
||||
if(!(pEng.test(this.userPwd1) && pNum.test(this.userPwd1) && pSpc.test(this.userPwd1))) {
|
||||
alert("비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.");
|
||||
this.$refs._pwd1.focus();
|
||||
return;
|
||||
}
|
||||
this.row.adminPw=this.userPwd1;
|
||||
return true;
|
||||
},
|
||||
doValidate(){
|
||||
if(!this.doPwdValidate()){
|
||||
return false;
|
||||
}
|
||||
if(this.isNull(this.userNm)){
|
||||
alert("이름을 입력해 주세요");
|
||||
this.$refs._userNm.focus();
|
||||
return false;
|
||||
}
|
||||
if(this.isNull(this.mdn)){
|
||||
alert('휴대폰번호를 입력해주세요.');
|
||||
this.$refs._phone.focus();
|
||||
return false;
|
||||
}
|
||||
const hp = this.mdn;
|
||||
if(!this.isNull(hp) && !this.isMobile(hp)){
|
||||
alert("휴대폰 번호 형식이 잘못되었습니다. 확인해 주세요");
|
||||
this.$refs._phone.focus();
|
||||
return false;
|
||||
}
|
||||
if(this.isNull(this.email)){
|
||||
alert('이메일을 입력해주세요.');
|
||||
this.$refs._email.focus();
|
||||
return false;
|
||||
}
|
||||
const email = this.email;
|
||||
if(!this.isNull(email) && !lodash.isEqual(email,'@') && !this.emailCheck(email)){
|
||||
alert("이메일 형식이 잘못되었습니다. 확인해 주세요");
|
||||
this.$refs._email.focus();
|
||||
return false;
|
||||
}
|
||||
if(this.isNull(this.auth)){
|
||||
alert('권한을 선택 해주세요.');
|
||||
this.$refs._auth.focus();
|
||||
return false;
|
||||
}
|
||||
if(this.isNull(this.stat)){
|
||||
alert('상태를 선택 해주세요.');
|
||||
// this.$refs._auth.focus();
|
||||
return false;
|
||||
}
|
||||
this.row.madangId=this.madangId;
|
||||
this.row.name=this.userNm;
|
||||
this.row.mdn=hp;
|
||||
this.row.email=email;
|
||||
if(this.insertType == 2){
|
||||
this.row.auth='1003';
|
||||
}else{
|
||||
this.row.auth=this.auth;
|
||||
}
|
||||
this.row.stat=this.stat;
|
||||
return true;
|
||||
},
|
||||
// 모달 띄우기
|
||||
ModalOpen(insertType){
|
||||
this.insertType=insertType;
|
||||
var dimmed = document.getElementsByClassName('dimmed');
|
||||
dimmed[0].style.display = 'block';
|
||||
var wrap = document.getElementsByClassName('popup-wrap');
|
||||
wrap[0].style.display = 'block';
|
||||
var obj = document.getElementsByClassName('modal20');
|
||||
obj[0].style.display = 'block';
|
||||
},
|
||||
// 모달 끄기
|
||||
ModalClose(){
|
||||
this.formReset();
|
||||
var dimmed = document.getElementsByClassName('dimmed');
|
||||
dimmed[0].style.display = 'none';
|
||||
var wrap = document.getElementsByClassName('popup-wrap');
|
||||
wrap[0].style.display = 'none';
|
||||
var popup = document.getElementsByClassName('modal20');
|
||||
popup[0].style.display = 'none';
|
||||
|
||||
},
|
||||
// 저장 후 부모창 호출.
|
||||
toComplete(){
|
||||
this.getParent('adminList').$refs.table.reloadData();
|
||||
this.ModalClose();
|
||||
},
|
||||
async doInsert(){
|
||||
if(this.doValidate() && window.confirm('등록 하시겠습니까?')){
|
||||
try {
|
||||
const response = await sysMgtApi.insertAdmin(this.row);
|
||||
const result = response.data;
|
||||
if (result != null && result.retCode == "0000") {
|
||||
alert('저장 하였습니다.');
|
||||
this.toComplete();
|
||||
}
|
||||
} catch(err) {
|
||||
alert("실패 하였습니다.");
|
||||
}
|
||||
}
|
||||
},
|
||||
setAuthData() {
|
||||
// 권한 옵션.
|
||||
api.commAuth().then(response => {
|
||||
this.authType = response.data.data.list;
|
||||
});
|
||||
},
|
||||
formReset(){
|
||||
this.$refs.adminRegForm.reset();
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.popup-btn-wrap {width: 500px; margin: auto; padding: 100px 0;}
|
||||
.popup-btn-wrap button {width: 100%; margin-bottom: 10px; height: 50px; border-radius: 5px; box-shadow: none; border: 1px solid #000; }
|
||||
.popup-btn-wrap button:hover {background: #000; color: #fff;}
|
||||
</style>
|
||||
@@ -1,18 +1,18 @@
|
||||
import AustList from '../views/AuthList'
|
||||
import AdminList from '../views/AdminList'
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/sysMgt/authList',
|
||||
component: AustList,
|
||||
name: 'authList',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/sysMgt/adminList',
|
||||
component: AdminList,
|
||||
name: 'adminList',
|
||||
meta: { public: true }
|
||||
}
|
||||
]
|
||||
|
||||
import AustList from '../views/AuthList'
|
||||
import AdminList from '../views/AdminList'
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/sysMgt/authList',
|
||||
component: AustList,
|
||||
name: 'authList',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/sysMgt/adminList',
|
||||
component: AdminList,
|
||||
name: 'adminList',
|
||||
meta: { public: true }
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
353
frontend/src/modules/sysMgt/service/mixins.js
Normal file
353
frontend/src/modules/sysMgt/service/mixins.js
Normal file
@@ -0,0 +1,353 @@
|
||||
import lodash from "lodash";
|
||||
|
||||
const utils_mixin = {
|
||||
methods:{
|
||||
/** * 이메일 형식 체크 * * @param 데이터 */
|
||||
emailCheck(email,rtnArrYn) {
|
||||
if(this.isNull(rtnArrYn)){
|
||||
rtnArrYn='N';
|
||||
}
|
||||
// var regExp = /(^[A-Za-z0-9_\.\-]+)@([A-Za-z0-9\-]+\.[A-Za-z0-9\-]+)/;
|
||||
var regExp = /^([0-9a-zA-Z_\.\-]([-_.]?[0-9a-zA-Z_\.\-])*)@([0-9a-zA-Z]([-_.]?[0-9a-zA-Z])*.[a-zA-Z]{2,3}$)/i;//이메일 정규식
|
||||
|
||||
if(regExp.test(email) == false) {
|
||||
// 이메일 형식이 알파벳+숫자@알파벳+숫자.알파벳+숫자 형식이 아닐경우
|
||||
if(rtnArrYn == 'Y'){
|
||||
return email;
|
||||
}
|
||||
return false;
|
||||
}else{
|
||||
var myArray = regExp.exec(email);
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
},
|
||||
/** * 전화번호 포맷으로 변환 * * @param 데이터 */
|
||||
formatPhone(phoneNum,fmt,rtnArrYn) {
|
||||
if(this.isNull(fmt)){
|
||||
fmt='';
|
||||
}
|
||||
if(this.isNull(rtnArrYn)){
|
||||
fmt='N';
|
||||
}
|
||||
if(this.isPhone(phoneNum)) {
|
||||
var rtnNum;
|
||||
var regExp =/(02)([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
rtnNum = myArray[1]+fmt + myArray[2]+fmt+myArray[3];
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return rtnNum;
|
||||
} else {
|
||||
regExp =/(0[3-9]{1}[0-9]{1})([0-9]{3,4})([0-9]{4})$/;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
rtnNum = myArray[1]+fmt+myArray[2]+fmt+myArray[3];
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return rtnNum;
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
},
|
||||
/** * 핸드폰번호 포맷으로 변환 * * @param 데이터 */
|
||||
formatMobile(phoneNum,fmt,rtnArrYn) {
|
||||
|
||||
if(this.isNull(fmt)){
|
||||
fmt='';
|
||||
}
|
||||
if(this.isNull(rtnArrYn)){
|
||||
fmt='N';
|
||||
}
|
||||
if(this.isMobile(phoneNum)) {
|
||||
|
||||
var rtnNum;
|
||||
var regExp =/(01[016789])([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
|
||||
if(regExp.test(phoneNum)){
|
||||
|
||||
myArray = regExp.exec(phoneNum);
|
||||
rtnNum = myArray[1]+fmt+myArray[2]+fmt+myArray[3];
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return rtnNum;
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
},
|
||||
|
||||
/** * 전화번호 형식 체크 * * @param 데이터 */
|
||||
isPhone(phoneNum) {
|
||||
var regExp =/(02)([0-9]{3,4})([0-9]{4})$/;
|
||||
if(regExp.test(phoneNum)){
|
||||
return true;
|
||||
} else {
|
||||
regExp =/(0[3-9]{1}[0-9]{1})([0-9]{3,4})([0-9]{4})$/;
|
||||
if(regExp.test(phoneNum)){
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/** * 핸드폰번호 형식 체크 * * @param 데이터 */
|
||||
isMobile(phoneNum) {
|
||||
var regExp =/(01[016789])([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
isMobile2(phoneNum) {
|
||||
var regExp =/(1[016789])([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
|
||||
isNull(obj){
|
||||
if(lodash.isNil(obj) || lodash.trim(obj) == ''){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
},
|
||||
getParent(name){
|
||||
let p = this.$parent;
|
||||
while(typeof p !== 'undefined'){
|
||||
if(p.$options.name == name) {
|
||||
return p;
|
||||
}else {
|
||||
p = p.$parent;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
},
|
||||
getJsonObj(str){
|
||||
return JSON.parse(JSON.stringify(str));
|
||||
},
|
||||
}
|
||||
};
|
||||
|
||||
var chkPattern2 = {
|
||||
data: function () {
|
||||
return {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
selSesStorage(keyLike){
|
||||
if(this.isNull(keyLike)){
|
||||
return null;
|
||||
}
|
||||
if(sessionStorage.length > 0){
|
||||
let keyList = [];
|
||||
for(let i=0;i<sessionStorage.length;i++){
|
||||
const keyNm = sessionStorage.key(i);
|
||||
if(keyNm.indexOf(keyLike) > -1){
|
||||
keyList.push({name : keyNm, value : sessionStorage.getItem(keyNm)});
|
||||
}
|
||||
}
|
||||
if(keyList.length > 0){
|
||||
return keyList;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
return null;
|
||||
},
|
||||
|
||||
delSesStorage(keyList){
|
||||
if(this.isNull(keyList)){
|
||||
return null;
|
||||
}
|
||||
if(keyList.length > 0){
|
||||
keyList.map((o) => (sessionStorage.removeItem(o.name)));
|
||||
return true;
|
||||
}
|
||||
},
|
||||
|
||||
setGridMouseDownActive(){
|
||||
const ele = document.querySelector(`div.tui-grid-container.tui-grid-show-lside-area`);
|
||||
if(window.getEventListeners(ele).mousedown){
|
||||
ele.removeEventListener('mousedown',window.getEventListeners(ele).mousedown[0].listener);
|
||||
}
|
||||
},
|
||||
restrictChars : function($event,regExp,hanYn){
|
||||
|
||||
if(this.isNull(hanYn)){
|
||||
hanYn='N';
|
||||
}
|
||||
if(hanYn === 'N' && $event.type === 'keydown'){
|
||||
if($event.keyCode === 229){
|
||||
$event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if($event.type === 'keypress'){
|
||||
//한글 처리 불가
|
||||
if(regExp.test(String.fromCharCode($event.charCode))) {
|
||||
return true;
|
||||
}else{
|
||||
$event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if(hanYn === 'N' && ( $event.type === 'keyup' || $event.type === 'input' || $event.type === 'change' || $event.type === 'blur')){
|
||||
$event.target.value = $event.target.value.replace(/[ㄱ-ㅎㅏ-ㅣ가-힣]/g,'');
|
||||
$event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
setLenth: function (e, len) {
|
||||
this.cut(e, len);
|
||||
},
|
||||
onlyCustom: function (e,strRegExp,hanYn) {
|
||||
var regExp_g = new RegExp(strRegExp,'g');
|
||||
this.cut(e);
|
||||
return this.restrictChars(e,regExp_g,hanYn);
|
||||
},
|
||||
onlyCommon: function(strRegExp, e, len, isEventCall, hanYn) {
|
||||
var regExp_g = new RegExp(strRegExp,'g');
|
||||
if(isEventCall === 'N'){
|
||||
if(!this.cut(e, len, isEventCall)){
|
||||
return false;
|
||||
}
|
||||
if(!regExp_g.test(e.value)){
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
this.cut(e, len);
|
||||
return this.restrictChars(e,regExp_g,hanYn);
|
||||
},
|
||||
onlyNum: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[0-9]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyEng: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Za-z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyLowerEng: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[a-z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyUpperEng: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyEmail: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[a-zA-Z0-9_\.\-@._-]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyName: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyTitle: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z0-9]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyText: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z0-9_-]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyPassword: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Za-z0-9!@#$%^&*]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyId: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Za-z0-9_\.\-]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyIp: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[0-9,.*]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyRoleNm_Space: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z0-9]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyRoleId_UnderBar: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[a-zA-Z0-9_]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
cut: function (ele, len, isValidChk) {
|
||||
let e=ele;
|
||||
if (typeof ele.target != "undefined") {
|
||||
e=ele.target;
|
||||
}
|
||||
let max = this.isNull(len) ? e.attributes.maxlength.value : len;
|
||||
let str = e.value;
|
||||
|
||||
if (this.bytes(str) > max) {
|
||||
if(this.isNull(isValidChk)){
|
||||
e.value = this.cutBytes(str, max);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
cutBytes: function (str, len) {
|
||||
while(1 === 1){
|
||||
if(this.bytes(str) <= len){
|
||||
return str;
|
||||
}
|
||||
str = str.slice(0,-1);
|
||||
}
|
||||
},
|
||||
bytes: function (str) {
|
||||
var length = ((s,b,i,c) => {
|
||||
// for(b=i=0;c=s.charCodeAt(i++);b+=c>>11?3:c>>7?2:1); // 한글 3바이트
|
||||
// for(b=i=0;c=s.charCodeAt(i++);b+=c>>11?2:c>>7?1:1); //한글 2바이트
|
||||
b=0,i=0;
|
||||
while(1 === 1){
|
||||
c = s.charCodeAt(i++);
|
||||
if (isNaN(c)) {
|
||||
break;
|
||||
}
|
||||
b += c >> 11 ? 2 : c >> 7 ? 1 : 1;
|
||||
}
|
||||
return b
|
||||
})(str);
|
||||
return length;
|
||||
},
|
||||
checkPhone: function(str) {
|
||||
str = str.replace(/[-\s]+/g, '');
|
||||
if (str.charAt(0)!="0"){
|
||||
str = "0"+str;
|
||||
}
|
||||
if (str.length<10||str.length>12){return "";}
|
||||
if (isNaN(str)){return ""; }
|
||||
if (str.substr(0,2)!="01" && str.substr(0,3)!="070" && str.substr(0,4)!="0505" && str.substr(0,4)!="0503"){return ""; }
|
||||
return str;
|
||||
|
||||
},
|
||||
}
|
||||
};
|
||||
export { utils_mixin, chkPattern2 };
|
||||
28
frontend/src/modules/sysMgt/service/sysMgtApi.js
Normal file
28
frontend/src/modules/sysMgt/service/sysMgtApi.js
Normal file
@@ -0,0 +1,28 @@
|
||||
import httpClient from '@/common/http-client';
|
||||
|
||||
// HUBEZ_BO_API_4003 - 관리자 등록.
|
||||
const insertAdmin = (params) => {
|
||||
return httpClient.post('/api/v1/bo/sysMgt/insertAdmin', params, { withCredentials: false });
|
||||
}
|
||||
|
||||
// HUBEZ_BO_API_4004 - 관리자 수정.
|
||||
const updateAdmin = (params) => {
|
||||
return httpClient.post('/api/v1/bo/sysMgt/updateAdmin', params, { withCredentials: false });
|
||||
}
|
||||
|
||||
// HUBEZ_BO_API_4005 - 관리자 삭제
|
||||
const deleteAdmin = (params) => {
|
||||
return httpClient.post('/api/v1/bo/sysMgt/deleteAdmin', params, { withCredentials: false });
|
||||
}
|
||||
|
||||
// HUBEZ_BO_API_4006 - 관리자 정보 상세 조회.
|
||||
const adminDetail = (params) => {
|
||||
return httpClient.post('/api/v1/bo/sysMgt/adminDetail', params, { withCredentials: false });
|
||||
}
|
||||
|
||||
export default {
|
||||
insertAdmin,
|
||||
updateAdmin,
|
||||
deleteAdmin,
|
||||
adminDetail
|
||||
}
|
||||
373
frontend/src/modules/sysMgt/service/utils_mixin.js
Normal file
373
frontend/src/modules/sysMgt/service/utils_mixin.js
Normal file
@@ -0,0 +1,373 @@
|
||||
import lodash from "lodash";
|
||||
import moment from "moment";
|
||||
import '@/modules/mgt/components/eventlisteners.js';
|
||||
|
||||
const filter_mixin = {
|
||||
filters: {
|
||||
_yyyy_mm_dd(val){
|
||||
if(lodash.isNil(val) || lodash.trim(val) == '') return '';
|
||||
const orgin = val;
|
||||
if(orgin.length < 8) {
|
||||
return orgin;
|
||||
}
|
||||
if(!Number(orgin)) return orgin;
|
||||
const date = orgin.substring(0,8);
|
||||
if(moment(date).isValid()){
|
||||
return moment(date).format('YYYY[-]MM[-]DD');
|
||||
}
|
||||
return orgin;
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
const utils_mixin = {
|
||||
methods:{
|
||||
/** * 이메일 형식 체크 * * @param 데이터 */
|
||||
emailCheck(email,rtnArrYn) {
|
||||
if(this.isNull(rtnArrYn)){
|
||||
rtnArrYn='N';
|
||||
}
|
||||
// var regExp = /(^[A-Za-z0-9_\.\-]+)@([A-Za-z0-9\-]+\.[A-Za-z0-9\-]+)/;
|
||||
var regExp = /^([0-9a-zA-Z_\.\-]([-_.]?[0-9a-zA-Z_\.\-])*)@([0-9a-zA-Z]([-_.]?[0-9a-zA-Z])*.[a-zA-Z]{2,3}$)/i;//이메일 정규식
|
||||
|
||||
if(regExp.test(email) == false) {
|
||||
// 이메일 형식이 알파벳+숫자@알파벳+숫자.알파벳+숫자 형식이 아닐경우
|
||||
if(rtnArrYn == 'Y'){
|
||||
return email;
|
||||
}
|
||||
return false;
|
||||
}else{
|
||||
var myArray = regExp.exec(email);
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
},
|
||||
/** * 전화번호 포맷으로 변환 * * @param 데이터 */
|
||||
formatPhone(phoneNum,fmt,rtnArrYn) {
|
||||
if(this.isNull(fmt)){
|
||||
fmt='';
|
||||
}
|
||||
if(this.isNull(rtnArrYn)){
|
||||
fmt='N';
|
||||
}
|
||||
if(this.isPhone(phoneNum)) {
|
||||
var rtnNum;
|
||||
var regExp =/(02)([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
rtnNum = myArray[1]+fmt + myArray[2]+fmt+myArray[3];
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return rtnNum;
|
||||
} else {
|
||||
regExp =/(0[3-9]{1}[0-9]{1})([0-9]{3,4})([0-9]{4})$/;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
rtnNum = myArray[1]+fmt+myArray[2]+fmt+myArray[3];
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return rtnNum;
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
},
|
||||
/** * 핸드폰번호 포맷으로 변환 * * @param 데이터 */
|
||||
formatMobile(phoneNum,fmt,rtnArrYn) {
|
||||
|
||||
if(this.isNull(fmt)){
|
||||
fmt='';
|
||||
}
|
||||
if(this.isNull(rtnArrYn)){
|
||||
fmt='N';
|
||||
}
|
||||
if(this.isMobile(phoneNum)) {
|
||||
|
||||
var rtnNum;
|
||||
var regExp =/(01[016789])([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
|
||||
if(regExp.test(phoneNum)){
|
||||
|
||||
myArray = regExp.exec(phoneNum);
|
||||
rtnNum = myArray[1]+fmt+myArray[2]+fmt+myArray[3];
|
||||
if(rtnArrYn == 'Y'){
|
||||
return myArray;
|
||||
}
|
||||
return rtnNum;
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
} else {
|
||||
return phoneNum;
|
||||
}
|
||||
},
|
||||
|
||||
/** * 전화번호 형식 체크 * * @param 데이터 */
|
||||
isPhone(phoneNum) {
|
||||
var regExp =/(02)([0-9]{3,4})([0-9]{4})$/;
|
||||
if(regExp.test(phoneNum)){
|
||||
return true;
|
||||
} else {
|
||||
regExp =/(0[3-9]{1}[0-9]{1})([0-9]{3,4})([0-9]{4})$/;
|
||||
if(regExp.test(phoneNum)){
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/** * 핸드폰번호 형식 체크 * * @param 데이터 */
|
||||
isMobile(phoneNum) {
|
||||
var regExp =/(01[016789])([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
isMobile2(phoneNum) {
|
||||
var regExp =/(1[016789])([0-9]{3,4})([0-9]{4})$/;
|
||||
var myArray;
|
||||
if(regExp.test(phoneNum)){
|
||||
myArray = regExp.exec(phoneNum);
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
|
||||
isNull(obj){
|
||||
if(lodash.isNil(obj) || lodash.trim(obj) == ''){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
},
|
||||
getParent(name){
|
||||
let p = this.$parent;
|
||||
while(typeof p !== 'undefined'){
|
||||
if(p.$options.name == name) {
|
||||
return p;
|
||||
}else {
|
||||
p = p.$parent;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
},
|
||||
getJsonObj(str){
|
||||
return JSON.parse(JSON.stringify(str));
|
||||
},
|
||||
}
|
||||
};
|
||||
|
||||
var chkPattern2 = {
|
||||
data: function () {
|
||||
return {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
selSesStorage(keyLike){
|
||||
if(this.isNull(keyLike)){
|
||||
return null;
|
||||
}
|
||||
if(sessionStorage.length > 0){
|
||||
let keyList = [];
|
||||
for(let i=0;i<sessionStorage.length;i++){
|
||||
const keyNm = sessionStorage.key(i);
|
||||
if(keyNm.indexOf(keyLike) > -1){
|
||||
keyList.push({name : keyNm, value : sessionStorage.getItem(keyNm)});
|
||||
}
|
||||
}
|
||||
if(keyList.length > 0){
|
||||
return keyList;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
return null;
|
||||
},
|
||||
|
||||
delSesStorage(keyList){
|
||||
if(this.isNull(keyList)){
|
||||
return null;
|
||||
}
|
||||
if(keyList.length > 0){
|
||||
keyList.map((o) => (sessionStorage.removeItem(o.name)));
|
||||
return true;
|
||||
}
|
||||
},
|
||||
|
||||
setGridMouseDownActive(){
|
||||
const ele = document.querySelector(`div.tui-grid-container.tui-grid-show-lside-area`);
|
||||
if(window.getEventListeners(ele).mousedown){
|
||||
ele.removeEventListener('mousedown',window.getEventListeners(ele).mousedown[0].listener);
|
||||
}
|
||||
},
|
||||
restrictChars : function($event,regExp,hanYn){
|
||||
|
||||
if(this.isNull(hanYn)){
|
||||
hanYn='N';
|
||||
}
|
||||
if(hanYn === 'N' && $event.type === 'keydown'){
|
||||
if($event.keyCode === 229){
|
||||
$event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if($event.type === 'keypress'){
|
||||
//한글 처리 불가
|
||||
if(regExp.test(String.fromCharCode($event.charCode))) {
|
||||
return true;
|
||||
}else{
|
||||
$event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if(hanYn === 'N' && ( $event.type === 'keyup' || $event.type === 'input' || $event.type === 'change' || $event.type === 'blur')){
|
||||
$event.target.value = $event.target.value.replace(/[ㄱ-ㅎㅏ-ㅣ가-힣]/g,'');
|
||||
$event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
setLenth: function (e, len) {
|
||||
this.cut(e, len);
|
||||
},
|
||||
onlyCustom: function (e,strRegExp,hanYn) {
|
||||
var regExp_g = new RegExp(strRegExp,'g');
|
||||
this.cut(e);
|
||||
return this.restrictChars(e,regExp_g,hanYn);
|
||||
},
|
||||
onlyCommon: function(strRegExp, e, len, isEventCall, hanYn) {
|
||||
var regExp_g = new RegExp(strRegExp,'g');
|
||||
if(isEventCall === 'N'){
|
||||
if(!this.cut(e, len, isEventCall)){
|
||||
return false;
|
||||
}
|
||||
if(!regExp_g.test(e.value)){
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
this.cut(e, len);
|
||||
return this.restrictChars(e,regExp_g,hanYn);
|
||||
},
|
||||
onlyNum: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[0-9]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyEng: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Za-z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyLowerEng: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[a-z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyUpperEng: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyEmail: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[a-zA-Z0-9_\.\-@._-]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyName: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyTitle: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z0-9]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyText: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z0-9_-]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyPassword: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Za-z0-9!@#$%^&*]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyId: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[A-Za-z0-9_\.\-]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyIp: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[0-9,.*]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
onlyRoleNm_Space: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[ㄱ-ㅎㅏ-ㅣ가-힣a-zA-Z0-9]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall,'Y');
|
||||
},
|
||||
onlyRoleId_UnderBar: function (e, len, isEventCall) {
|
||||
var strRegExp = '^[a-zA-Z0-9_]*$';
|
||||
return this.onlyCommon(strRegExp, e, len, isEventCall);
|
||||
},
|
||||
cut: function (ele, len, isValidChk) {
|
||||
let e=ele;
|
||||
if (typeof ele.target != "undefined") {
|
||||
e=ele.target;
|
||||
}
|
||||
let max = this.isNull(len) ? e.attributes.maxlength.value : len;
|
||||
let str = e.value;
|
||||
|
||||
if (this.bytes(str) > max) {
|
||||
if(this.isNull(isValidChk)){
|
||||
e.value = this.cutBytes(str, max);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
cutBytes: function (str, len) {
|
||||
while(1 === 1){
|
||||
if(this.bytes(str) <= len){
|
||||
return str;
|
||||
}
|
||||
str = str.slice(0,-1);
|
||||
}
|
||||
},
|
||||
bytes: function (str) {
|
||||
var length = ((s,b,i,c) => {
|
||||
// for(b=i=0;c=s.charCodeAt(i++);b+=c>>11?3:c>>7?2:1); // 한글 3바이트
|
||||
// for(b=i=0;c=s.charCodeAt(i++);b+=c>>11?2:c>>7?1:1); //한글 2바이트
|
||||
b=0,i=0;
|
||||
while(1 === 1){
|
||||
c = s.charCodeAt(i++);
|
||||
if (isNaN(c)) {
|
||||
break;
|
||||
}
|
||||
b += c >> 11 ? 2 : c >> 7 ? 1 : 1;
|
||||
}
|
||||
return b
|
||||
})(str);
|
||||
return length;
|
||||
},
|
||||
checkPhone: function(str) {
|
||||
str = str.replace(/[-\s]+/g, '');
|
||||
if (str.charAt(0)!="0"){
|
||||
str = "0"+str;
|
||||
}
|
||||
if (str.length<10||str.length>12){return "";}
|
||||
if (isNaN(str)){return ""; }
|
||||
if (str.substr(0,2)!="01" && str.substr(0,3)!="070" && str.substr(0,4)!="0505" && str.substr(0,4)!="0503"){return ""; }
|
||||
return str;
|
||||
|
||||
},
|
||||
}
|
||||
};
|
||||
export { utils_mixin, chkPattern2, filter_mixin };
|
||||
@@ -1,107 +1,273 @@
|
||||
<template>
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">관리자 목록 조회</h3>
|
||||
<p class="breadcrumb">시스템관리 > 권한 관리</p>
|
||||
</div>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>4</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue add" onclick="location.href='system_right_add.html';">권한 추가</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<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>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>4</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey" onclick="location.href='system_right_modify.html';">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>3</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>2</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>1</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'authList',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
},
|
||||
components: {
|
||||
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
};
|
||||
<template>
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">관리자/유치채널 관리</h3>
|
||||
<p class="breadcrumb">시스템관리 > 관리자/유치채널 관리</p>
|
||||
</div>
|
||||
<form autocomplete="off" class="search_form">
|
||||
<div class="search_wrap">
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">권한</label>
|
||||
<select name="" id="right" v-model="grid.params.searchType1" @keyup.enter="search">
|
||||
<option value="">전체</option>
|
||||
<option v-for="(option, i) in authType" v-bind:value="option.autCd" v-bind:key="i">
|
||||
{{ option.autNm }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="select_box">
|
||||
<label for="right" class="label">상태</label>
|
||||
<select name="" id="" v-model="grid.params.searchType2" @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="input_box id">
|
||||
<label for="id1" class="label">ID</label>
|
||||
<input type="text" id="id1" placeholder="검색어 입력" v-model="grid.params.searchText1" @keyup.enter="search"/>
|
||||
</div>
|
||||
<div class="input_box">
|
||||
<label for="name" class="label">이름(대리점명)</label>
|
||||
<input type="text" id="name" placeholder="검색어 입력" v-model="grid.params.searchText2" @keyup.enter="search"/>
|
||||
</div>
|
||||
<button type="button" class="button grey" @click="search">조회</button>
|
||||
</div>
|
||||
</form>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>{{ totalItems }}</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="deleteRow();">삭제</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"
|
||||
></custom-grid>
|
||||
</div>
|
||||
<admin-reg-pop ref="adminRegModal"> </admin-reg-pop>
|
||||
<!-- <admin-reg2-pop ref="adminReg2Modal"> </admin-reg2-pop> -->
|
||||
<admin-detail-pop ref="adminDetailModal"> </admin-detail-pop>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import customGrid from '@/components/CustomGrid';
|
||||
import AdminRegPop from '../components/AdminRegPop';
|
||||
//import AdminReg2Pop from '../components/AdminReg2Pop';
|
||||
import AdminDetailPop from '../components/AdminDetailPop';
|
||||
import api from '@/service/api.js';
|
||||
import sysMgtApi from "../service/sysMgtApi.js";
|
||||
|
||||
|
||||
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)
|
||||
this.el = el;
|
||||
}
|
||||
|
||||
getElement() {
|
||||
return this.el;
|
||||
}
|
||||
|
||||
addEvent(selEl) {
|
||||
selEl.addEventListener("click", () => {
|
||||
const { callback } = this.props["cgrido" + this.props.colName].options;
|
||||
callback(this.props);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
export default {
|
||||
name: 'adminList',
|
||||
data() {
|
||||
return {
|
||||
row: {},
|
||||
authType: [],
|
||||
statType: [],
|
||||
cate2Code: "",
|
||||
totalItems: 0,
|
||||
// 테이블 리스트 데이터
|
||||
perPageCnt: 20,
|
||||
grid: {
|
||||
url: '/api/v1/bo/sysMgt/adminList',
|
||||
pagePerRows: 20,
|
||||
pagination: true,
|
||||
isCheckbox: true, // true:첫번째 컬럼 앞에 체크박스 생성 / false:체크박스 제거
|
||||
initialRequest: false,
|
||||
addCls: 'box_OFvis',
|
||||
|
||||
columns: [
|
||||
{ name: 'no', header: 'No', align: 'center', width: 60},
|
||||
{ name: 'auth', header: '권한', align: 'center', width: 160 },
|
||||
{ name: 'name', header: '이름(대리점명)', align: 'center', width: 130, renderer: {
|
||||
type: CustomATagRenderer
|
||||
, options: {
|
||||
callback: this.detailPop,
|
||||
}
|
||||
}
|
||||
},
|
||||
{ name: 'adminId', header: 'ID', align: 'center', width: 130},
|
||||
{ name: 'adminStat', header: '상태', align: 'center', width: 130, cls: 'td_line'},
|
||||
{ name: 'regDt', header: '등록일', align: 'center', width: 130}
|
||||
],
|
||||
noDataStr: '검색 결과가 없습니다.',
|
||||
params: {
|
||||
searchType1: '',
|
||||
searchType2: '',
|
||||
searchText1: '',
|
||||
searchText2: ''
|
||||
},
|
||||
excelHeader: []
|
||||
}
|
||||
};
|
||||
},
|
||||
components: {
|
||||
customGrid: customGrid,
|
||||
// SystemPopup,
|
||||
AdminRegPop,
|
||||
//AdminReg2Pop,
|
||||
AdminDetailPop
|
||||
},
|
||||
created(){
|
||||
this.$store.commit("login/isLogin", true);
|
||||
this.$store.commit("login/isAuthChk", true);
|
||||
this.setCodeData();
|
||||
//let cont = document.querySelector(".wrap");
|
||||
//cont.classList.add("main_wrap");
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
let page = 1;
|
||||
// 페이지 정보 및 검색 조건
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
console.log('getCondition : '+getCondition);
|
||||
|
||||
// store에 저장된 페이지 정보 및 검색 조건을 불러오기
|
||||
let isKeep = false;
|
||||
if (getCondition) {
|
||||
this.grid.pagePerRows = getCondition.perPage;
|
||||
this.grid.params = getCondition.params;
|
||||
page = getCondition.page;
|
||||
isKeep = true;
|
||||
}
|
||||
this.search(isKeep);
|
||||
},
|
||||
methods: {
|
||||
search: function(isKeep) {
|
||||
console.log('this.perPageCnt'+this.perPageCnt);
|
||||
//console.log(this.grid.params);
|
||||
this.$refs.table.search(this.grid.params, isKeep);
|
||||
this.sendStoreData();
|
||||
},
|
||||
detailPop(props) {
|
||||
// this.getMainSlot().popupView(4);
|
||||
// this.setDtlPpPrm(props);
|
||||
this.$refs.adminDetailModal.adminDetailModalOpen(props);
|
||||
},
|
||||
ModalOpen: function(target){
|
||||
//this.$refs.systemModal.ModalOpen(target);
|
||||
},
|
||||
adminRegPopOpen: function(){
|
||||
this.$refs.adminRegModal.ModalOpen(1);
|
||||
},
|
||||
adminReg2PopOpen: function(){
|
||||
this.$refs.adminRegModal.ModalOpen(2);
|
||||
//this.$refs.adminReg2Modal.adminReg2ModalOpen();//
|
||||
},
|
||||
doValidate(){ //로우데이터 삭제하도록 수정
|
||||
|
||||
console.log("totalItems >> " + this.totalItems);
|
||||
if(this.totalItems == 0){
|
||||
alert('검색 결과가 없습니다.');
|
||||
return false;
|
||||
}
|
||||
var chkList = this.$refs.table.checkedElementDatas();
|
||||
if(chkList.length == 0){
|
||||
alert('체크박스에 체크를 해주세요.');
|
||||
return false;
|
||||
}
|
||||
// for(var i = 0; i < chkList.length; i++){
|
||||
// alert(chkList[i].adminId);
|
||||
// }
|
||||
const param = chkList.map((row)=>({adminId:row.adminId}));
|
||||
this.row.list = param;
|
||||
console.log(this.row);
|
||||
return true;
|
||||
},
|
||||
sendStoreData: function() {
|
||||
const getP = this.$refs.table.getPagination();
|
||||
console.log("==========getP : " + getP);
|
||||
this.$store.commit('searchcondition/updateSearchCondition', {
|
||||
page: getP._currentPage,
|
||||
perPage: this.perPageCnt,
|
||||
params: this.grid.params
|
||||
});
|
||||
|
||||
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
|
||||
//console.log("getCondition : "+ getCondition.perPage);
|
||||
},
|
||||
setCodeData() {
|
||||
|
||||
// 상태 옵션 셋팅.
|
||||
api.commCode({'grpCd' : 'ADM_STTUS_CD'}).then(response => {
|
||||
this.statType = response.data.data.list;
|
||||
});
|
||||
api.commAuth().then(response => {
|
||||
this.authType = response.data.data.list;
|
||||
});
|
||||
},
|
||||
async deleteRow(){
|
||||
if(this.doValidate() && window.confirm('삭제 하시겠습니까?')){
|
||||
try {
|
||||
let response = await sysMgtApi.deleteAdmin(this.row);
|
||||
const result = response.data;
|
||||
if (result != null && result.retCode == "0000") {
|
||||
alert('삭제 하였습니다.');
|
||||
// grid.reloadData();
|
||||
this.$refs.table.reloadData();
|
||||
return;
|
||||
}
|
||||
alert("실패 하였습니다.");
|
||||
} catch(err) {
|
||||
alert("실패 하였습니다.");
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
beforeRouteLeave(to, from, next) {
|
||||
|
||||
const getP = this.$refs.table.getPagination();
|
||||
console.log("==========getP : " + getP._currentPage);
|
||||
this.$store.commit('searchcondition/updateSearchCondition', {
|
||||
page: getP._currentPage,
|
||||
perPage: this.perPageCnt,
|
||||
params: this.grid.params
|
||||
});
|
||||
// 라우트 하기전 실행
|
||||
next();
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@@ -1,107 +1,107 @@
|
||||
<template>
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">권한 관리</h3>
|
||||
<p class="breadcrumb">시스템관리 > 권한 관리</p>
|
||||
</div>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>4</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue add" onclick="location.href='system_right_add.html';">권한 추가</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<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>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>4</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey" onclick="location.href='system_right_modify.html';">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>3</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>2</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>1</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'authList',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
},
|
||||
components: {
|
||||
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
};
|
||||
<template>
|
||||
<div class="contents">
|
||||
<div class="contents_wrap">
|
||||
<div class="top_wrap">
|
||||
<h3 class="title">권한 관리</h3>
|
||||
<p class="breadcrumb">시스템관리 > 권한 관리</p>
|
||||
</div>
|
||||
<div class="info">
|
||||
<div class="count">총 <span>4</span>건</div>
|
||||
<div class="button_group">
|
||||
<button type="button" class="button blue add" onclick="location.href='system_right_add.html';">권한 추가</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="table">
|
||||
<table>
|
||||
<colgroup>
|
||||
<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>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>4</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey" onclick="location.href='system_right_modify.html';">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>3</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>2</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>1</td>
|
||||
<td>Admin_01</td>
|
||||
<td>슈퍼관리자</td>
|
||||
<td>사용</td>
|
||||
<td>2022-03-10</td>
|
||||
<td class="two_btn_group">
|
||||
<button type="button" class="button grey">수정</button>
|
||||
<button type="button" class="button white delete">삭제</button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'authList',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
},
|
||||
components: {
|
||||
|
||||
},
|
||||
destroyed() {
|
||||
|
||||
},
|
||||
mounted() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
};
|
||||
</script>
|
||||
Reference in New Issue
Block a user