TC 수정 반영

This commit is contained in:
kimre
2022-07-18 01:06:10 +09:00
parent e8328fef2c
commit 2bfa07c17f
30 changed files with 2446 additions and 2066 deletions

View File

@@ -96,7 +96,8 @@ httpClient.interceptors.response.use(
tokenSvc.removeToken(); tokenSvc.removeToken();
window.top.location.href = '/login'; window.top.location.href = '/login';
} else if (error.response.status == 418) { } else if (error.response.status == 418) {
tokenSvc.removeToken();
window.top.location.href = '/login';
}else if (error.response.status == 500) { }else if (error.response.status == 500) {
if (error.response.data != null && error.response.data.message == '511 NETWORK_AUTHENTICATION_REQUIRED') { if (error.response.data != null && error.response.data.message == '511 NETWORK_AUTHENTICATION_REQUIRED') {
alert('웹템플릿 IP가 브랜드포털에 등록이 필요합니다. 기술지원에 문의해주세요.'); alert('웹템플릿 IP가 브랜드포털에 등록이 필요합니다. 기술지원에 문의해주세요.');

View File

@@ -1,315 +1,326 @@
<template> <template>
<!-- <div class="wrap bg-wrap"> --> <!-- <div class="wrap bg-wrap"> -->
<div> <div>
<div class="dimmed memberUpdate" @click="memberUpdateModalClose();"></div> <div class="dimmed memberUpdate" @click="memberUpdateModalClose();"></div>
<div class="popup-wrap memberUpdate"> <div class="popup-wrap memberUpdate">
<div class="popup modal32 popup_form memberUpdate"> <div class="popup modal32 popup_form memberUpdate">
<div class="pop-head"> <div class="pop-head">
<h3 class="pop-tit">사용자 ID 수정</h3> <h3 class="pop-tit">사용자 ID 수정</h3>
</div> </div>
<table> <table>
<tbody> <tbody>
<tr> <tr>
<th>관리자 ID</th> <th>관리자 ID</th>
<td>{{adminId}}</td> <td>{{ adminId }}</td>
</tr> </tr>
<tr> <tr>
<th>ID</th> <th>ID</th>
<td>{{userId}}</td> <td>{{ userId }}</td>
</tr> </tr>
<tr> <tr>
<th>비밀번호</th> <th>비밀번호</th>
<td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8" maxlength="16" ref="_pwd1" v-model.trim="userPwd1"></td> <td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8"
</tr> maxlength="16" ref="_pwd1" v-model.trim="userPwd1"></td>
<tr> </tr>
<th>비밀번호 확인</th> <tr>
<td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8" maxlength="16" ref="_pwd2" v-model.trim="userPwd2"></td> <th>비밀번호 확인</th>
</tr> <td><input type="password" @keypress="onlyPassword" @input="onlyPassword" required minlength="8"
<tr> maxlength="16" ref="_pwd2" v-model.trim="userPwd2"></td>
<th>이름</th> </tr>
<td><input type="text" v-model.trim="userNm" ref="_userNm" @keypress="onlyRoleNm_Space" <tr>
<th>이름</th>
<td><input type="text" v-model.trim="userNm" ref="_userNm" @keypress="onlyRoleNm_Space"
@input="onlyRoleNm_Space" maxlength="100"></td> @input="onlyRoleNm_Space" maxlength="100"></td>
</tr> </tr>
<tr> <tr>
<th>휴대폰번호</th> <th>휴대폰번호</th>
<td><input type="text" placeholder="- 자 제외 숫자만 입력" v-model.trim="mdn" ref="_phone" @keypress="onlyNum" <td><input type="text" placeholder="- 자 제외 숫자만 입력" v-model.trim="mdn" ref="_phone" @keypress="onlyNum"
@input="onlyNum" minlength="10" maxlength="11"></td> @input="onlyNum" minlength="10" maxlength="11"></td>
</tr> </tr>
<tr> <tr>
<th>이메일</th> <th>이메일</th>
<td><input type="email" v-model.trim="email" ref="_email" @keypress="onlyEmail" @input="onlyEmail" <td><input type="email" v-model.trim="email" ref="_email" @keypress="onlyEmail" @input="onlyEmail"
maxlength="100"></td> maxlength="100"></td>
</tr> </tr>
<tr> <tr>
<th class="center">상태</th> <th class="center">상태</th>
<td> <td>
<input type="radio" name="userStateUpdate" value="01" id="user_popup_update_radio1" v-model="userStat"> <input type="radio" name="userStateUpdate" value="01" id="user_popup_update_radio1" v-model="userStat">
<label for="user_popup_update_radio1">사용</label> <label for="user_popup_update_radio1">사용</label>
<input type="radio" name="userStateUpdate" value="02" id="user_popup_update_radio2" v-model="userStat"> <input type="radio" name="userStateUpdate" value="02" id="user_popup_update_radio2" v-model="userStat">
<label for="user_popup_update_radio2">정지</label> <label for="user_popup_update_radio2">정지</label>
</td> </td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
<div class="popup-btn2"> <div class="popup-btn2">
<button class="btn-pcolor" @click="memberUpdateConfirm();">저장</button> <button class="btn-pcolor" @click="memberUpdateConfirm();">저장</button>
<button class="btn-default" @click="memberUpdateModalClose();">취소</button> <button class="btn-default" @click="memberUpdateModalClose();">취소</button>
</div> </div>
</div> </div>
<validation-confirm-pop ref="validationConfirmPopModal"> </validation-confirm-pop> <validation-confirm-pop ref="validationConfirmPopModal"></validation-confirm-pop>
<common-modal ref="commmonModal"></common-modal> <common-modal ref="commmonModal"></common-modal>
<validation-confirm-modalPop ref="validationConfirmModalPop"></validation-confirm-modalPop>
</div>
</div> </div>
</div>
</template> </template>
<script> <script>
import api from '@/service/api'; import api from '@/service/api';
import custMgtApi from "../service/custMgtApi.js"; import custMgtApi from "../service/custMgtApi.js";
import { utils_mixin, chkPattern2 } from '../service/mixins'; import {utils_mixin, chkPattern2} from '../service/mixins';
import ValidationConfirmPop from '../components/ValidationConfirmPop.vue'; import ValidationConfirmPop from '../components/ValidationConfirmPop.vue';
import lodash from "lodash"; import lodash from "lodash";
import commonModal from "../components/commonModal"; import commonModal from "../components/commonModal";
import validationConfirmModalPop from "@/modules/custMgt/components/ValidationConfirmModalPop";
export default { export default {
name: "memberModifyPop", name: "memberModifyPop",
mixins: [utils_mixin, chkPattern2], mixins: [utils_mixin, chkPattern2],
watch:{ watch: {
stat(){ stat() {
console.log('watch : ', this.stat) console.log('watch : ', this.stat)
}
},
components: {
ValidationConfirmPop,
commonModal,
},
model: {
//prop: 'sendData',
//event: 'event-data'
},
//props: ['sendData'],
created(){
// this.setAuthData();
// this.formReset();
},
data(){
return{
row:{},
madangId:'',
name:'',
mdn:'',
email:'',
auth:'',
stat: "",
userId: "",
adminId: "",
userNm:"",
userPwd1:"",
userPwd2:"",
code:"",
userStat:"",
} }
}, },
methods :{ components: {
//사용자ID 수정 모달 Open ValidationConfirmPop,
async memberUpdateModalOpen(props){ validationConfirmModalPop,
this.row.userId = props.userId; commonModal,
this.adminId = props.adminId; },
try { model: {
const response = await custMgtApi.memberDetail(this.row); //prop: 'sendData',
const result = response.data; //event: 'event-data'
console.log(result); },
if (result != null && result.retCode == "0000") { //props: ['sendData'],
this.userId = result.data.userId; created() {
this.userNm = result.data.userNm; // this.setAuthData();
this.email = result.data.email; // this.formReset();
this.mdn = result.data.mdn; },
this.userStat = result.data.userStat; data() {
} else { return {
this.row.title = '청약고객관리'; row: {},
this.row.msg1 = '실패 하였습니다.'; madangId: '',
this.$refs.commmonModal.alertModalOpen(this.row); name: '',
} mdn: '',
} catch(err) { email: '',
this.row.title = '청약고객관리'; auth: '',
this.row.msg1 = '실패 하였습니다.'; stat: "",
this.$refs.commmonModal.alertModalOpen(this.row); userId: "",
} adminId: "",
// 모달 오픈 userNm: "",
var dimmed = document.getElementsByClassName('memberUpdate'); userPwd1: "",
for(var i = 0; i < dimmed.length; i++){ userPwd2: "",
dimmed[i].style.display = 'block'; code: "",
} userStat: "",
}, }
//사용자ID 수정 Confirm },
memberUpdateConfirm(){ methods: {
// confirm 팝업 노출 //사용자ID 수정 모달 Open
if(this.doValidate()){ async memberUpdateModalOpen(props) {
this.$refs.validationConfirmPopModal.confirmUpdateOpen(); this.row.userId = props.userId;
} this.adminId = props.adminId;
}, try {
//사용자ID 수정 처리 const response = await custMgtApi.memberDetail(this.row);
async memberUpdate(){ const result = response.data;
this.row.userId = this.userId; console.log(result);
this.row.userPw = this.userPwd1; if (result != null && result.retCode == "0000") {
this.row.userNm = this.userNm; this.userId = result.data.userId;
this.row.userEmail = this.email; this.userNm = result.data.userNm;
this.row.mdn = this.mdn; this.email = result.data.email;
this.row.userStat = this.userStat; this.mdn = result.data.mdn;
try { this.userStat = result.data.userStat;
const response = await custMgtApi.updateUser(this.row); } else {
const result = response.data; this.row.title = '청약고객관리';
console.log(result); this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row);
}
} catch (err) {
this.row.title = '청약고객관리';
this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row);
}
// 모달 오픈
var dimmed = document.getElementsByClassName('memberUpdate');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//사용자ID 수정 Confirm
memberUpdateConfirm() {
// confirm 팝업 노출
if (this.doValidate()) {
this.$refs.validationConfirmModalPop.confirmUpdateOpen();
}
},
//사용자ID 수정 처리
async memberUpdate() {
this.row.userId = this.userId;
this.row.userPw = this.userPwd1;
this.row.userNm = this.userNm;
this.row.userEmail = this.email;
this.row.mdn = this.mdn;
this.row.userStat = this.userStat;
try {
const response = await custMgtApi.updateUser(this.row);
const result = response.data;
console.log(result);
this.row = {} this.row = {}
if (result != null && result.retCode == "0000") { if (result != null && result.retCode == "0000") {
// this.row.title = '청약고객관리'; // this.row.title = '청약고객관리';
// this.row.msg1 = '수정 완료하였습니다.'; // this.row.msg1 = '수정 완료하였습니다.';
// this.$refs.commmonModal.alertModalOpen(this.row); // this.$refs.commmonModal.alertModalOpen(this.row);
// this.memberUpdateModalClose(); // this.memberUpdateModalClose();
this.toComplete(); this.toComplete();
} else { } else {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '실패 하였습니다.'; this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
} }
} catch(err) { } catch (err) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '실패 하였습니다.'; this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
} }
}, },
//사용자ID 수정 모달 Close //사용자ID 수정 모달 Close
memberUpdateModalClose(){ memberUpdateModalClose() {
var dimmed = document.getElementsByClassName('memberUpdate'); var dimmed = document.getElementsByClassName('memberUpdate');
for(var i = 0; i < dimmed.length; i++){ for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none'; dimmed[i].style.display = 'none';
} }
this.formReset(); this.formReset();
}, },
formReset() { formReset() {
this.userPwd1 = ''; this.userPwd1 = '';
this.userPwd2 = ''; this.userPwd2 = '';
}, },
toComplete(){ toComplete() {
this.row.serviceId = this.adminId; this.row.serviceId = this.adminId;
this.memberUpdateModalClose(); this.memberUpdateModalClose();
this.$parent.memberDetail(this.adminId); this.$parent.memberDetail(this.adminId);
}, },
doPwdValidate(){ doPwdValidate() {
if(this.isNull(this.userPwd2)){ if (this.isNull(this.userPwd2)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '비밀번호 확인을 입력해 주세요.'; this.row.msg1 = '비밀번호 확인을 입력해 주세요.';
this.row.focusTaget = '2'; this.row.focusTaget = '2';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
if(!lodash.isEqual(this.userPwd1, this.userPwd2)){ if (!lodash.isEqual(this.userPwd1, this.userPwd2)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '비밀번호가 일치하지 않습니다.'; this.row.msg1 = '비밀번호가 일치하지 않습니다.';
this.row.focusTaget = '2'; this.row.focusTaget = '2';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
const pwdLen = this.bytes(this.userPwd1); const pwdLen = this.bytes(this.userPwd1);
if(!(pwdLen >= 8 && pwdLen <= 16)){ if (!(pwdLen >= 8 && pwdLen <= 16)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.'; this.row.msg1 = '비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.';
this.row.focusTaget = '1'; this.row.focusTaget = '1';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
const pEng = /[A-Za-z]/g; // 영문자 const pEng = /[A-Za-z]/g; // 영문자
const pNum = /[0-9]/g; // 숫자 const pNum = /[0-9]/g; // 숫자
const pSpc = /[!@$%^&*]/g; // 특수문자 const pSpc = /[!@$%^&*]/g; // 특수문자
if(!(pEng.test(this.userPwd1) && pNum.test(this.userPwd1) && pSpc.test(this.userPwd1))) { if (!(pEng.test(this.userPwd1) && pNum.test(this.userPwd1) && pSpc.test(this.userPwd1))) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.'; this.row.msg1 = '비밀번호는 8~16자의 영문, 숫자, 특수문자(!,@, $, %, ^, &, *) 조합이 필요합니다.';
this.row.focusTaget = '1'; this.row.focusTaget = '1';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
return true; return true;
}, },
doValidate(){ doValidate() {
if(!this.isNull(this.userPwd1)){ if (!this.isNull(this.userPwd1)) {
if(!this.doPwdValidate()){ if (!this.doPwdValidate()) {
return false; return false;
} }
} }
if(this.isNull(this.userPwd1) && !this.isNull(this.userPwd2)){ if (this.isNull(this.userPwd1) && !this.isNull(this.userPwd2)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '비밀번호를 입력해 주세요.'; this.row.msg1 = '비밀번호를 입력해 주세요.';
this.row.focusTaget = '1'; this.row.focusTaget = '1';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
if(this.isNull(this.userNm)){ if (this.isNull(this.userNm)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '이름을 입력해 주세요.'; this.row.msg1 = '이름을 입력해 주세요.';
this.row.focusTaget = '3'; this.row.focusTaget = '3';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
if(this.isNull(this.mdn)){ if (this.isNull(this.mdn)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '휴대폰번호를 입력해주세요.'; this.row.msg1 = '휴대폰번호를 입력해주세요.';
this.row.focusTaget = '4'; this.row.focusTaget = '4';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
const hp = this.mdn; const hp = this.mdn;
if(!this.isNull(hp) && !this.isMobile(hp)){ if (!this.isNull(hp) && !this.isMobile(hp)) {
this.$refs.validationConfirmPopModal.validationPhonenumberOpen(); this.row.title = '청약고객관리';
return false; this.row.msg1 = '휴대폰번호를 확인해 주세요.';
} this.row.focusTaget = '4';
this.$refs.commmonModal.alertModalOpen(this.row);
return false;
}
if(this.isNull(this.email)){ if (this.isNull(this.email)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '이메일을 입력해주세요.'; this.row.msg1 = '이메일을 입력해주세요.';
this.row.focusTaget = '5'; this.row.focusTaget = '5';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
const email = this.email; const email = this.email;
if(!this.isNull(email) && !lodash.isEqual(email,'@') && !this.emailCheck(email)){ if (!this.isNull(email) && !lodash.isEqual(email, '@') && !this.emailCheck(email)) {
this.$refs.validationConfirmPopModal.validationEmailOpen(); this.row.title = '청약고객관리';
return false; this.row.msg1 = 'E-mail 형식에 맞지 않습니다.';
} this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.';
this.row.focusTaget = '5';
this.$refs.commmonModal.alertModalOpen(this.row);
return false;
}
if(this.isNull(this.userStat)){ if (this.isNull(this.userStat)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '상태를 선택 해주세요.'; this.row.msg1 = '상태를 선택 해주세요.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
return true; return true;
}, },
checkPhoneFocus(){ checkPhoneFocus() {
this.$refs._phone.focus(); this.$refs._phone.focus();
}, },
checkEmailFocus(){ checkEmailFocus() {
this.$refs._email.focus(); this.$refs._email.focus();
}, },
checkFocus(){ checkFocus() {
if(this.row.focusTaget === '1'){ if (this.row.focusTaget === '1') {
this.$refs._pwd1.focus(); this.$refs._pwd1.focus();
} else if(this.row.focusTaget === '2'){ } else if (this.row.focusTaget === '2') {
this.$refs._pwd2.focus(); this.$refs._pwd2.focus();
} else if(this.row.focusTaget === '3'){ } else if (this.row.focusTaget === '3') {
this.$refs._userNm.focus(); this.$refs._userNm.focus();
} else if(this.row.focusTaget === '4'){ } else if (this.row.focusTaget === '4') {
this.$refs._phone.focus(); this.$refs._phone.focus();
} else if(this.row.focusTaget === '5'){ } else if (this.row.focusTaget === '5') {
this.$refs._email.focus(); this.$refs._email.focus();
} }
}, },
} }
} }
</script> </script>

View File

@@ -49,8 +49,8 @@
</div> </div>
</div> </div>
</div> </div>
<validation-confirm-pop ref="validationConfirmPopModal"></validation-confirm-pop> <validation-confirm-modalPop ref="validationConfirmModalPop"></validation-confirm-modalPop>
<common-modal ref="commmonModal"></common-modal> <!-- <common-modal ref="commmonModal"></common-modal>-->
</div> </div>
</template> </template>
@@ -58,9 +58,9 @@
import api from '@/service/api'; import api from '@/service/api';
import custMgtApi from "../service/custMgtApi.js"; import custMgtApi from "../service/custMgtApi.js";
import {utils_mixin, chkPattern2} from '../service/mixins'; import {utils_mixin, chkPattern2} from '../service/mixins';
import ValidationConfirmPop from '../components/ValidationConfirmPop.vue';
import lodash from "lodash"; import lodash from "lodash";
import commonModal from "../components/commonModal"; import validationConfirmModalPop from "@/modules/custMgt/components/ValidationConfirmModalPop";
// import commonModal from "../components/commonModal";
export default { export default {
name: "memberRegPop", name: "memberRegPop",
@@ -71,8 +71,8 @@ export default {
} }
}, },
components: { components: {
ValidationConfirmPop, validationConfirmModalPop,
commonModal, // commonModal,
}, },
model: { model: {
//prop: 'sendData', //prop: 'sendData',
@@ -101,7 +101,7 @@ export default {
}, },
methods: { methods: {
//사용자ID 생성 모달 Open //사용자ID 생성 모달 Open
async memberInsertModalOpen(props) { memberInsertModalOpen(props) {
this.adminId = props.adminId; this.adminId = props.adminId;
this.userTotalCnt = props.userTotalCnt; this.userTotalCnt = props.userTotalCnt;
@@ -115,15 +115,11 @@ export default {
memberInsertConfirm() { memberInsertConfirm() {
// confirm 팝업 노출 // confirm 팝업 노출
if (this.doValidate()) { if (this.doValidate()) {
this.$refs.validationConfirmPopModal.confirmInsertOpen(); this.$refs.validationConfirmModalPop.confirmInsertOpen()
} }
}, },
doMemberInsert(){
console.log("aaaaaaaa")
},
//사용자ID 수정 처리 //사용자ID 수정 처리
async memberInsert() { async memberInsert() {
console.log(123123)
this.row.adminId = this.adminId; this.row.adminId = this.adminId;
this.row.userId = this.userId; this.row.userId = this.userId;
this.row.userNm = this.userNm; this.row.userNm = this.userNm;
@@ -137,7 +133,7 @@ export default {
if (result != null && result.retCode == "0000") { if (result != null && result.retCode == "0000") {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '사용자 생성 완료하였습니다.'; this.row.msg1 = '사용자 생성 완료하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
this.toComplete(); this.toComplete();
} else if (result != null && result.retCode == "4018") { } else if (result != null && result.retCode == "4018") {
// 이미 사용중인 ID // 이미 사용중인 ID
@@ -145,12 +141,12 @@ export default {
} else { } else {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '실패 하였습니다.'; this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
} }
} catch (err) { } catch (err) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '실패 하였습니다.'; this.row.msg1 = '실패 하였습니다.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
} }
}, },
//사용자ID 생성 모달 Close //사용자ID 생성 모달 Close
@@ -181,7 +177,7 @@ export default {
console.log(this.userTotalCnt) console.log(this.userTotalCnt)
if (this.userTotalCnt >= 100) { if (this.userTotalCnt >= 100) {
// 사용자등록제한_최대100개까지 // 사용자등록제한_최대100개까지
this.$refs.validationConfirmPopModal.validationMaxlimitOpen(); this.$parent.$refs.validationConfirmPopModal.validationMaxlimitOpen();
return false; return false;
} }
@@ -190,7 +186,7 @@ export default {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = 'ID를 입력해 주세요.'; this.row.msg1 = 'ID를 입력해 주세요.';
this.row.focusTaget = '1'; this.row.focusTaget = '1';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
// 청약 ID 길이 체크 6~16 // 청약 ID 길이 체크 6~16
@@ -200,7 +196,7 @@ export default {
this.row.msg1 = 'ID 형식에 맞지 않습니다.'; this.row.msg1 = 'ID 형식에 맞지 않습니다.';
this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.'; this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.';
this.row.focusTaget = '1'; this.row.focusTaget = '1';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
@@ -208,7 +204,7 @@ export default {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '이름을 입력해 주세요.'; this.row.msg1 = '이름을 입력해 주세요.';
this.row.focusTaget = '2'; this.row.focusTaget = '2';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
@@ -216,7 +212,7 @@ export default {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '휴대폰번호를 입력해주세요.'; this.row.msg1 = '휴대폰번호를 입력해주세요.';
this.row.focusTaget = '3'; this.row.focusTaget = '3';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
const hp = this.mdn; const hp = this.mdn;
@@ -227,7 +223,7 @@ export default {
this.row.msg1 = '휴대폰번호 형식에 맞지 않습니다.'; this.row.msg1 = '휴대폰번호 형식에 맞지 않습니다.';
this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.'; this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.';
this.row.focusTaget = '3'; this.row.focusTaget = '3';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
@@ -235,7 +231,7 @@ export default {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '이메일을 입력해주세요.'; this.row.msg1 = '이메일을 입력해주세요.';
this.row.focusTaget = '4'; this.row.focusTaget = '4';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
const email = this.email; const email = this.email;
@@ -245,14 +241,14 @@ export default {
this.row.msg1 = 'E-mail 형식에 맞지 않습니다.'; this.row.msg1 = 'E-mail 형식에 맞지 않습니다.';
this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.'; this.row.msg2 = '확인하여 다시 등록 부탁 드립니다.';
this.row.focusTaget = '4'; this.row.focusTaget = '4';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
if (this.isNull(this.stat)) { if (this.isNull(this.stat)) {
this.row.title = '청약고객관리'; this.row.title = '청약고객관리';
this.row.msg1 = '상태를 선택 해주세요.'; this.row.msg1 = '상태를 선택 해주세요.';
this.$refs.commmonModal.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }

View File

@@ -0,0 +1,366 @@
<template>
<!-- <div class="wrap bg-wrap"> -->
<div>
<!-- 사용자 등록 - 최초 등록 -->
<div class="dimmed confirm-insert" @click="confirmInsertClose();"></div>
<div class="popup-wrap confirm-insert">
<div class="popup confirm-insert">
<div class="pop-head">
<h3 class="pop-tit">사용자 등록111111</h3>
</div>
<div class="pop-cont">
<p>해당 사용자를 등록하고 인증 메일을</p>
<p>발송하시겠습니까?</p>
<p>사용을 위해서는 등록된 이메일 인증 </p>
<p>서비스 이용이 가능합니다.</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmInsert();">확인</button>
<button class="btn-default" @click="confirmInsertClose();">취소</button>
</div>
</div>
</div>
<!-- 사용자 수정 확인 -->
<div class="dimmed confirm-update" @click="confirmUpdateClose();"></div>
<div class="popup-wrap confirm-update">
<div class="popup confirm-update">
<div class="pop-head">
<h3 class="pop-tit">사용자 수정 확인</h3>
</div>
<div class="pop-cont">
<p>변경된 내용을 저장하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmUpdate();">확인</button>
<button class="btn-default" @click="confirmUpdateClose();">취소</button>
</div>
</div>
</div>
<!-- 사용자 등록 - 이메일 형식 체크 -->
<div class="dimmed validation-email" @click="validationEmailClose();"></div>
<div class="popup-wrap validation-email">
<div class="popup validation-email ">
<div class="pop-head">
<h3 class="pop-tit">사용자 등록</h3>
</div>
<div class="pop-cont">
<p>E-mail 형식에 맞지 않습니다.</p>
<p>확인하여 다시 등록 부탁 드립니다.</p>
</div>
<div class="popup-btn1">
<button class="btn-pcolor" @click="validationEmailClose();">확인</button>
</div>
</div>
</div>
<!-- 사용자 등록 - 아이디 중복 체크 -->
<div class="dimmed validation-id-duplicate" @click="validationIdDuplicateClose();"></div>
<div class="popup-wrap validation-id-duplicate">
<div class="popup validation-id-duplicate">
<div class="pop-head">
<h3 class="pop-tit">사용자 등록</h3>
</div>
<div class="pop-cont">
<p>중복된 아이디가 있습니다.</p>
<p>아이디를 다시 확인하여 등록 부탁드립니다.</p>
</div>
<div class="pop-btn1">
<button class="btn-pcolor" @click="validationIdDuplicateClose();">확인</button>
</div>
</div>
</div>
<!-- 사용자 ID 생성 파일 업로드 - 성공 -->
<div class="dimmed success-fileupload" @click="successFileuploadClose();"></div>
<div class="popup-wrap success-fileupload">
<div class="popup success-fileupload">
<div class="pop-head">
<h3 class="pop-tit">사용자 ID 생성 파일 업로드</h3>
</div>
<div class="pop-cont">
<p>정상 업로드 되었습니다.</p>
</div>
<div class="popup-btn1">
<button class="btn-pcolor" @click="successFileuploadClose();">확인</button>
</div>
</div>
</div>
<div class="dimmed fail-fileupload" @click="failFileuploadClose();"></div>
<div class="popup-wrap fail-fileupload">
<!-- 사용자 ID 생성 파일 업로드 -->
<div class="popup fail-fileupload">
<div class="pop-head">
<h3 class="pop-tit">사용자 ID 생성 파일 업로드</h3>
</div>
<div class="pop-cont">
<p>파일 업로드 오류가 발생하여 정상건만</p>
<p>업로드 완료하였습니다.</p>
</div>
<ul class="pop-cont-detail">
<li> <span class="number">{{ totalCnt }}</span> ( 정상 <span class="number blue">{{ successCnt }}</span> 오류
<span class="number red">{{ failCnt }}</span> )
</li>
</ul>
<div class="pop-cont bottom">
<p>오류 건은 확인 재등록 부탁 드립니다.</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="failFileuploadOk();">확인</button>
<!-- <button class="btn-default" @click="failFileuploadClose();">취소</button>-->
</div>
</div>
</div>
</div>
</template>
<script>
export default {
name: "validationConfirmPop",
data() {
return {
row: {},
title: '',
msg: '',
failCnt: 0,
successCnt: 0,
totalCnt: 0,
}
},
methods: {
//사용자등록 - 최초등록 Open
confirmInsertOpen() {
var dimmed = document.getElementsByClassName('confirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//사용자등록 - 최초등록
confirmInsert() {
var dimmed = document.getElementsByClassName('confirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
console.log("this.$parent.memberInsert() ~~~~~~")
this.$parent.memberInsert();
},
//사용자등록 - 최초등록 Close
confirmInsertClose() {
var dimmed = document.getElementsByClassName('confirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
// 사용자 삭제 Open
confirmDeleteOpen() {
var dimmed = document.getElementsByClassName('confirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//사용자 삭제
confirmDelete() {
var dimmed = document.getElementsByClassName('confirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
//사용자 삭제 Close
confirmDeleteClose() {
var dimmed = document.getElementsByClassName('confirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
//사용자 수정 확인 Open
confirmUpdateOpen() {
var dimmed = document.getElementsByClassName('confirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//사용자 수정 확인
confirmUpdate() {
var dimmed = document.getElementsByClassName('confirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.memberUpdate();
},
// 사용자 수정 Close
confirmUpdateClose() {
var dimmed = document.getElementsByClassName('confirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
//사용자 수정(청약고객-sub) 확인 Open
confirmUpdateSubOpen() {
var dimmed = document.getElementsByClassName('confirm-update-sub');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//사용자 수정(청약고객-sub) 확인
confirmUpdateSub() {
var dimmed = document.getElementsByClassName('confirm-update-sub');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.updateAdminInfo();
},
// 사용자 수정(청약고객-sub) Close
confirmUpdateSubClose() {
var dimmed = document.getElementsByClassName('confirm-update-sub');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
// 이메일 형식 체크 Open
validationEmailOpen() {
var dimmed = document.getElementsByClassName('validation-email');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
// 이메일 형식 체크 Close
validationEmailClose() {
var dimmed = document.getElementsByClassName('validation-email');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.checkEmailFocus();
},
// 아이디 중복 체크 Open
validationIdDuplicateOpen() {
var dimmed = document.getElementsByClassName('validation-id-duplicate');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
// 아이디 중복 체크 Close
validationIdDuplicateClose() {
var dimmed = document.getElementsByClassName('validation-id-duplicate');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.checkIdDupFocus();
},
// 최대 등록 제한 Open
validationMaxlimitOpen() {
var dimmed = document.getElementsByClassName('validation-maxlimit');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
// 최대 등록 제한 Close
validationMaxlimitClose() {
var dimmed = document.getElementsByClassName('validation-maxlimit');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
// 휴대폰번호 형식 체크 Open
validationPhonenumberOpen() {
var dimmed = document.getElementsByClassName('valication-phonenumber');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
// 휴대폰번호 형식 체크 Close
validationPhonenumberClose() {
var dimmed = document.getElementsByClassName('valication-phonenumber');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.checkPhoneFocus();
},
// 사용자 ID 생성 파일 업로드 - 성공 Open
successFileuploadOpen() {
var dimmed = document.getElementsByClassName('success-fileupload');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
// 사용자 ID 생성 파일 업로드 - 성공 Close
successFileuploadClose() {
var dimmed = document.getElementsByClassName('success-fileupload');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
// 목록페이지 이동
this.$parent.toComplete();
},
// 정상완료 후 목록페이지 이동
toComplete() {
this.row.searchType1 = '';
this.row.searchType2 = '';
this.row.searchType3 = '';
this.row.searchText1 = '';
this.row.startDt = '';
this.row.endDt = '';
this.row.page = 1;
this.$router.push({name: 'subsList', params: this.row});
},
// 사용자 ID 생성 파일 업로드 - 성공 Open
failFileuploadOpen(props) {
var dimmed = document.getElementsByClassName('fail-fileupload');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
this.totalCnt = props.totalCnt
this.successCnt = props.successCnt
this.failCnt = props.failCnt
},
failFileuploadOk() {
var dimmed = document.getElementsByClassName('fail-fileupload');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.row.result = true;
// 부모 함수 호출.
this.$parent.failFileuploadOk(this.row);
},
// 사용자 ID 생성 파일 업로드 - 성공 Close
failFileuploadClose() {
var dimmed = document.getElementsByClassName('fail-fileupload');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
// 모달 오픈
confirmModalOpen(props) {
var dimmed = document.getElementsByClassName('confirm');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
this.title = props.title;
this.msg = props.msg;
},
// 모달 끄기(ok)
confirmModalClose() {
var dimmed = document.getElementsByClassName('confirm');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.row.result = true;
// 부모 함수 호출.
this.$parent.confirmCalbackFnc(this.row);
},
// 모달 끄기(취소)
confirmModalCancel() {
var dimmed = document.getElementsByClassName('confirm');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.row.result = false;
// 부모 함수 호출.
this.$parent.confirmCalbackFnc(this.row);
},
}
}
</script>

View File

@@ -18,26 +18,6 @@
</div> </div>
</div> </div>
<!-- 사용자 등록 - 최초 등록 -->
<div class="dimmed confirm-insert" @click="confirmInsertClose();"></div>
<div class="popup-wrap confirm-insert">
<div class="popup confirm-insert">
<div class="pop-head">
<h3 class="pop-tit">사용자 등록</h3>
</div>
<div class="pop-cont">
<p>해당 사용자를 등록하고 인증 메일을</p>
<p>발송하시겠습니까?</p>
<p>사용을 위해서는 등록된 이메일 인증 </p>
<p>서비스 이용이 가능합니다.</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmInsert();">확인</button>
<button class="btn-default" @click="confirmInsertClose();">취소</button>
</div>
</div>
</div>
<!-- 사용자 등록 - 이메일 형식 체크 --> <!-- 사용자 등록 - 이메일 형식 체크 -->
<div class="dimmed validation-email" @click="validationEmailClose();"></div> <div class="dimmed validation-email" @click="validationEmailClose();"></div>
<div class="popup-wrap validation-email"> <div class="popup-wrap validation-email">
@@ -121,22 +101,6 @@
</div> </div>
</div> </div>
<!-- 사용자 수정 확인 -->
<div class="dimmed confirm-update" @click="confirmUpdateClose();"></div>
<div class="popup-wrap confirm-update">
<div class="popup confirm-update">
<div class="pop-head">
<h3 class="pop-tit">사용자 수정 확인</h3>
</div>
<div class="pop-cont">
<p>변경된 내용을 저장하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmUpdate();">확인</button>
<button class="btn-default" @click="confirmUpdateClose();">취소</button>
</div>
</div>
</div>
<!-- 사용자 수정(청약고객:sub) 확인 --> <!-- 사용자 수정(청약고객:sub) 확인 -->
<div class="dimmed confirm-update-sub" @click="confirmUpdateSubClose();"></div> <div class="dimmed confirm-update-sub" @click="confirmUpdateSubClose();"></div>

View File

@@ -1,353 +1,358 @@
import lodash from "lodash"; import lodash from "lodash";
const utils_mixin = { const utils_mixin = {
methods:{ methods: {
/** * 이메일 형식 체크 * * @param 데이터 */ /** * 이메일 형식 체크 * * @param 데이터 */
emailCheck(email,rtnArrYn) { emailCheck(email, rtnArrYn) {
if(this.isNull(rtnArrYn)){ if (this.isNull(rtnArrYn)) {
rtnArrYn='N'; rtnArrYn = 'N';
} }
// var regExp = /(^[A-Za-z0-9_\.\-]+)@([A-Za-z0-9\-]+\.[A-Za-z0-9\-]+)/; // 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;//이메일 정규식 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 (regExp.test(email) == false) {
// 이메일 형식이 알파벳+숫자@알파벳+숫자.알파벳+숫자 형식이 아닐경우 // 이메일 형식이 알파벳+숫자@알파벳+숫자.알파벳+숫자 형식이 아닐경우
if(rtnArrYn == 'Y'){ if (rtnArrYn == 'Y') {
return email; return email;
} }
return false; return false;
}else{ } else {
var myArray = regExp.exec(email); var myArray = regExp.exec(email);
if(rtnArrYn == 'Y'){ if (rtnArrYn == 'Y') {
return myArray; return myArray;
} }
return true; return true;
} }
}, },
/** * 전화번호 포맷으로 변환 * * @param 데이터 */ /** * 전화번호 포맷으로 변환 * * @param 데이터 */
formatPhone(phoneNum,fmt,rtnArrYn) { formatPhone(phoneNum, fmt, rtnArrYn) {
if(this.isNull(fmt)){ if (this.isNull(fmt)) {
fmt=''; fmt = '';
} }
if(this.isNull(rtnArrYn)){ if (this.isNull(rtnArrYn)) {
fmt='N'; fmt = 'N';
} }
if(this.isPhone(phoneNum)) { if (this.isPhone(phoneNum)) {
var rtnNum; var rtnNum;
var regExp =/(02)([0-9]{3,4})([0-9]{4})$/; var regExp = /(02)([0-9]{3,4})([0-9]{4})$/;
var myArray; var myArray;
if(regExp.test(phoneNum)){ if (regExp.test(phoneNum)) {
myArray = regExp.exec(phoneNum); myArray = regExp.exec(phoneNum);
rtnNum = myArray[1]+fmt + myArray[2]+fmt+myArray[3]; rtnNum = myArray[1] + fmt + myArray[2] + fmt + myArray[3];
if(rtnArrYn == 'Y'){ if (rtnArrYn == 'Y') {
return myArray; return myArray;
} }
return rtnNum; return rtnNum;
} else { } else {
regExp =/(0[3-9]{1}[0-9]{1})([0-9]{3,4})([0-9]{4})$/; regExp = /(0[3-9]{1}[0-9]{1})([0-9]{3,4})([0-9]{4})$/;
if(regExp.test(phoneNum)){ if (regExp.test(phoneNum)) {
myArray = regExp.exec(phoneNum); myArray = regExp.exec(phoneNum);
rtnNum = myArray[1]+fmt+myArray[2]+fmt+myArray[3]; rtnNum = myArray[1] + fmt + myArray[2] + fmt + myArray[3];
if(rtnArrYn == 'Y'){ if (rtnArrYn == 'Y') {
return myArray; return myArray;
} }
return rtnNum; return rtnNum;
} else { } else {
return phoneNum; return phoneNum;
} }
}
} else {
return phoneNum;
} }
} else {
return phoneNum;
}
}, },
/** * 핸드폰번호 포맷으로 변환 * * @param 데이터 */ /** * 핸드폰번호 포맷으로 변환 * * @param 데이터 */
formatMobile(phoneNum,fmt,rtnArrYn) { formatMobile(phoneNum, fmt, rtnArrYn) {
if(this.isNull(fmt)){ if (this.isNull(fmt)) {
fmt=''; fmt = '';
} }
if(this.isNull(rtnArrYn)){ if (this.isNull(rtnArrYn)) {
fmt='N'; fmt = 'N';
} }
if(this.isMobile(phoneNum)) { if (this.isMobile(phoneNum)) {
var rtnNum; var rtnNum;
var regExp =/(01[016789])([0-9]{3,4})([0-9]{4})$/; var regExp = /(01[016789])([0-9]{3,4})([0-9]{4})$/;
var myArray; var myArray;
if(regExp.test(phoneNum)){ if (regExp.test(phoneNum)) {
myArray = regExp.exec(phoneNum); myArray = regExp.exec(phoneNum);
rtnNum = myArray[1]+fmt+myArray[2]+fmt+myArray[3]; rtnNum = myArray[1] + fmt + myArray[2] + fmt + myArray[3];
if(rtnArrYn == 'Y'){ if (rtnArrYn == 'Y') {
return myArray; return myArray;
} }
return rtnNum; return rtnNum;
} else { } else {
return phoneNum; return phoneNum;
}
} else {
return phoneNum;
} }
} else {
return phoneNum;
}
}, },
/** * 전화번호 형식 체크 * * @param 데이터 */ /** * 전화번호 형식 체크 * * @param 데이터 */
isPhone(phoneNum) { isPhone(phoneNum) {
var regExp =/(02)([0-9]{3,4})([0-9]{4})$/; var regExp = /(02)([0-9]{3,4})([0-9]{4})$/;
if(regExp.test(phoneNum)){ 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; return true;
} else { } else {
return false; 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 데이터 */ /** * 핸드폰번호 형식 체크 * * @param 데이터 */
isMobile(phoneNum) { isMobile(phoneNum) {
var regExp =/(01[016789])([0-9]{3,4})([0-9]{4})$/; var regExp = /(01[016789])([0-9]{3,4})([0-9]{4})$/;
var myArray; var myArray;
if(regExp.test(phoneNum)){ if (regExp.test(phoneNum)) {
myArray = regExp.exec(phoneNum); myArray = regExp.exec(phoneNum);
return true; return true;
} else { } else {
return false; return false;
} }
}, },
isMobile2(phoneNum) { isMobile2(phoneNum) {
var regExp =/(1[016789])([0-9]{3,4})([0-9]{4})$/; var regExp = /(1[016789])([0-9]{3,4})([0-9]{4})$/;
var myArray; var myArray;
if(regExp.test(phoneNum)){ if (regExp.test(phoneNum)) {
myArray = regExp.exec(phoneNum); myArray = regExp.exec(phoneNum);
return true; return true;
} else { } else {
return false; 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){ isNull(obj) {
if(this.isNull(keyList)){ if (lodash.isNil(obj) || lodash.trim(obj) == '') {
return null; return true;
} }
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; 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));
},
}
};
if($event.type === 'keypress'){ var chkPattern2 = {
//한글 처리 불가 data: function () {
if(regExp.test(String.fromCharCode($event.charCode))) { 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; return true;
}else{ },
$event.preventDefault(); setLenth: function (e, len) {
return false; 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(hanYn === 'N' && ( $event.type === 'keyup' || $event.type === 'input' || $event.type === 'change' || $event.type === 'blur')){ if (this.bytes(str) > max) {
$event.target.value = $event.target.value.replace(/[ㄱ-ㅎㅏ-ㅣ가-힣]/g,''); if (this.isNull(isValidChk)) {
$event.preventDefault(); e.value = this.cutBytes(str, max);
return false; }
} return false;
return true; }
}, return true;
setLenth: function (e, len) { },
this.cut(e, len); cutBytes: function (str, len) {
}, while (1 === 1) {
onlyCustom: function (e,strRegExp,hanYn) { if (this.bytes(str) <= len) {
var regExp_g = new RegExp(strRegExp,'g'); return str;
this.cut(e); }
return this.restrictChars(e,regExp_g,hanYn); str = str.slice(0, -1);
}, }
onlyCommon: function(strRegExp, e, len, isEventCall, hanYn) { },
var regExp_g = new RegExp(strRegExp,'g'); bytes: function (str) {
if(isEventCall === 'N'){ var length = ((s, b, i, c) => {
if(!this.cut(e, len, isEventCall)){ // for(b=i=0;c=s.charCodeAt(i++);b+=c>>11?3:c>>7?2:1); // 한글 3바이트
return false; // for(b=i=0;c=s.charCodeAt(i++);b+=c>>11?2:c>>7?1:1); //한글 2바이트
} b = 0, i = 0;
if(!regExp_g.test(e.value)){ while (1 === 1) {
return false; c = s.charCodeAt(i++);
} if (isNaN(c)) {
return true; break;
} }
this.cut(e, len); b += c >> 11 ? 2 : c >> 7 ? 1 : 1;
return this.restrictChars(e,regExp_g,hanYn); }
}, return b
onlyNum: function (e, len, isEventCall) { })(str);
var strRegExp = '^[0-9]*$'; return length;
return this.onlyCommon(strRegExp, e, len, isEventCall); },
}, checkPhone: function (str) {
onlyEng: function (e, len, isEventCall) { str = str.replace(/[-\s]+/g, '');
var strRegExp = '^[A-Za-z]*$'; if (str.charAt(0) != "0") {
return this.onlyCommon(strRegExp, e, len, isEventCall); str = "0" + str;
}, }
onlyLowerEng: function (e, len, isEventCall) { if (str.length < 10 || str.length > 12) {
var strRegExp = '^[a-z]*$'; return "";
return this.onlyCommon(strRegExp, e, len, isEventCall); }
}, if (isNaN(str)) {
onlyUpperEng: function (e, len, isEventCall) { return "";
var strRegExp = '^[A-Z]*$'; }
return this.onlyCommon(strRegExp, e, len, isEventCall); if (str.substr(0, 2) != "01" && str.substr(0, 3) != "070" && str.substr(0, 4) != "0505" && str.substr(0, 4) != "0503") {
}, return "";
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; 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 }; export {utils_mixin, chkPattern2};

View File

@@ -194,13 +194,13 @@ export default {
} }
} }
}, },
{name: 'custNm', header: '고객사명', align: 'center', width: 130}, {name: 'custNm', header: '고객사명', align: 'center', width: '4%'},
{name: 'regNo', header: '가입번호', align: 'center', width: 130}, {name: 'regNo', header: '가입번호', align: 'center', width: '12%'},
{name: 'regDt', header: '가입일', align: 'center', width: 130, cls: 'td_line'}, {name: 'regDt', header: '가입일', align: 'center', width: '12%', cls: 'td_line'},
{name: 'stat', header: '상태', align: 'center', width: 130}, {name: 'stat', header: '상태', align: 'center', width: '12%'},
{name: 'channel', header: '유치채널', align: 'center', width: 130}, {name: 'channel', header: '유치채널', align: 'center', width: '12%'},
{name: 'plan', header: '요금제', align: 'center', width: 130}, {name: 'plan', header: '요금제', align: 'center', width: '12%'},
{name: 'carryOver', header: '이월누적금액', align: 'center', width: 130} {name: 'carryOver', header: '이월누적금액', align: 'center', width: '12%'}
], ],
noDataStr: '검색 결과가 없습니다.', noDataStr: '검색 결과가 없습니다.',
params: { params: {

View File

@@ -21,7 +21,7 @@
<th>발송타입</th> <th>발송타입</th>
<td v-if="code === null || code === ''"> <td v-if="code === null || code === ''">
<div v:class="select_box"> <div v:class="select_box">
<select name="" id="right" v-model.trim="sndblckTpCd" ref="sndblckTpCd" @keyup.enter="search"> <select name="" id="right" v-model.trim="sndblckTpCd" ref="sndblckTpCd">
<option v-for="(option, i) in tpType" :value="option.code" v-bind:key="i"> <option v-for="(option, i) in tpType" :value="option.code" v-bind:key="i">
{{ option.codeNm }} {{ option.codeNm }}
</option> </option>
@@ -145,6 +145,11 @@ export default {
this.row.title = '발신번호 차단'; this.row.title = '발신번호 차단';
this.row.msg1 = '성공 하였습니다.'; this.row.msg1 = '성공 하였습니다.';
this.$parent.alertInsert(this.row); this.$parent.alertInsert(this.row);
}else if (result != null && result.retCode == "4018") {
this.row.title = '발신번호 차단';
this.row.msg1 = '이미등록된 발신번호입니다.';
this.$parent.alertInsert(this.row);
return false;
} }
this.toComplete(); this.toComplete();
} catch (err) { } catch (err) {
@@ -217,7 +222,7 @@ export default {
const character = characters[i] const character = characters[i]
const decimal = character.charCodeAt(0) const decimal = character.charCodeAt(0)
const byte = this.getByteLength(decimal) // 글자 한 개가 몇 바이트 길이인지 구해주기 const byte = this.getByteLength(decimal) // 글자 한 개가 몇 바이트 길이인지 구해주기
// console.log(byte)
// 현재까지의 바이트 길이와 더해 최대 바이트 길이를 넘지 않으면 // 현재까지의 바이트 길이와 더해 최대 바이트 길이를 넘지 않으면
if (totalByte + byte <= maxByte) { if (totalByte + byte <= maxByte) {
totalByte += byte // 바이트 길이 값을 더해 현재까지의 총 바이트 길이 값을 구함 totalByte += byte // 바이트 길이 값을 더해 현재까지의 총 바이트 길이 값을 구함
@@ -226,7 +231,6 @@ export default {
break // for 루프 종료 break // for 루프 종료
} }
} }
return validText return validText
}, },

View File

@@ -14,8 +14,8 @@
<tr> <tr>
<th>차단문구</th> <th>차단문구</th>
<td class="input_add"> <td class="input_add">
<input v-model="word" ref="_word" maxlength="50"> <input v-model="word" ref="_word" maxlength="10" @input="msgLimitByte()">
<button type="button" class="button white add" @click="doAdd"></button> <button type="button" class="button white add" @click="doAdd" ></button>
</td> </td>
</tr> </tr>
<tr> <tr>
@@ -53,7 +53,8 @@
</tr> </tr>
<tr> <tr>
<th>메모</th> <th>메모</th>
<td class="sender"><textarea class="memo_text" v-model.trim="memo" ref="memo"></textarea></td> <td class="sender"><textarea class="memo_text" v-model.trim="memo" ref="memo" maxlength="2000"
@input="memoLimitByte()"></textarea></td>
</tr> </tr>
</tbody> </tbody>
@@ -82,15 +83,9 @@ export default {
return { return {
row: {}, row: {},
// msgBlckword: { msgBlckwordList: [],
// word:'',
// },
msgBlckwordList: [
// { word : '스팸'},
],
rsnType: [], rsnType: [],
tpType: [], tpType: [],
// seqNo: '', // 일련번호
word: '', // 차단문구 word: '', // 차단문구
blckSndrno: '', blckSndrno: '',
sndblckTpCd: '', sndblckTpCd: '',
@@ -101,6 +96,7 @@ export default {
regId: '', regId: '',
regDt: '', regDt: '',
memo: '', // 메모 memo: '', // 메모
maxByte: 2000,
} }
}, },
@@ -139,9 +135,15 @@ export default {
}, },
async doInsert() { async doInsert() {
// if(this.doValidate() && window.confirm('등록 하시겠습니까?')){ this.row.blckRsnCd = this.blckRsnCd;
this.row.blckContCd = this.blckContCd;
this.row.memo = this.memo;
this.row.blckYn = this.blckYn;
this.row.list = this.msgBlckwordList
console.log(this.row)
// return false;
try { try {
const response = await riskMgtApi.msgIntrcpList(this.row); const response = await riskMgtApi.msgInsertIntrcp(this.row);
const result = response.data; const result = response.data;
if (result != null && result.retCode == "0000") { if (result != null && result.retCode == "0000") {
this.row.title = '메세지 차단'; this.row.title = '메세지 차단';
@@ -165,14 +167,7 @@ export default {
this.$refs._word.focus(); this.$refs._word.focus();
return false; return false;
} }
this.row.blckRsnCd = this.blckRsnCd;
this.row.blckContCd = this.blckContCd;
this.row.memo = this.memo;
this.row.blckYn = this.blckYn;
this.row.list = this.msgBlckwordList
return true; return true;
}, },
toComplete() { toComplete() {
@@ -210,8 +205,46 @@ export default {
if (this.doValidate()) { if (this.doValidate()) {
this.$refs.ValidationConfirmPopup.msgConfirmInsertOpen(); this.$refs.ValidationConfirmPopup.msgConfirmInsertOpen();
} }
} },
// 바이트길이 구하기
getByteLength: function (decimal) {
return (decimal >> 7) || (this.LINE_FEED === decimal) ? 2 : 1
},
getByte: function (str) {
return str
.split('')
.map((s) => s.charCodeAt(0))
.reduce((prev, unicodeDecimalValue) => prev + this.getByteLength(unicodeDecimalValue), 0)
},
getLimitedByteText: function (inputText, maxByte) {
const characters = inputText.split('')
let validText = ''
let totalByte = 0
for (let i = 0; i < characters.length; i += 1) {
const character = characters[i]
const decimal = character.charCodeAt(0)
const byte = this.getByteLength(decimal) // 글자 한 개가 몇 바이트 길이인지 구해주기
// console.log(byte)
// 현재까지의 바이트 길이와 더해 최대 바이트 길이를 넘지 않으면
if (totalByte + byte <= maxByte) {
totalByte += byte // 바이트 길이 값을 더해 현재까지의 총 바이트 길이 값을 구함
validText += character // 글자를 더해 현재까지의 총 문자열 값을 구함
} else { // 최대 바이트 길이를 넘으면
break // for 루프 종료
}
}
return validText
},
memoLimitByte() {
this.memo = this.getLimitedByteText(this.memo, this.maxByte);
}, //END 바이트길이 구하기
msgLimitByte(){
this.word = this.getLimitedByteText(this.word, 10);
}
} }

View File

@@ -1,288 +1,288 @@
<template> <template>
<div> <div>
<div class="dimmed confirm" @click="confirmModalCancel();"></div> <div class="dimmed confirm" @click="confirmModalCancel();"></div>
<div class="popup-wrap confirm"> <div class="popup-wrap confirm">
<!-- 수정 확인 --> <!-- 수정 확인 -->
<div class="popup confirm"> <div class="popup confirm">
<div class="pop-head"> <div class="pop-head">
<h3 class="pop-tit">{{title}}</h3> <h3 class="pop-tit">{{ title }}</h3>
</div>
<div class="pop-cont">
<p>{{msg}}</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmModalClose();">확인</button>
<button class="btn-default" @click="confirmModalCancel();">취소</button>
</div>
</div>
</div> </div>
<div class="pop-cont">
<!-- 발신번호차단 등록 - 최초 등록 --> <p>{{ msg }}</p>
<div class="dimmed confirm-insert" @click="confirmInsertClose();"></div>
<div class="popup-wrap confirm-insert">
<div class="popup confirm-insert">
<div class="pop-head">
<h3 class="pop-tit">발신번호차단 등록</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 등록 하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmInsert();">확인</button>
<button class="btn-default" @click="confirmInsertClose();">취소</button>
</div>
</div>
</div>
<!-- 발신번호차단 상세 - 수정 -->
<div class="dimmed confirm-update" @click="confirmUpdateClose();"></div>
<div class="popup-wrap confirm-update">
<div class="popup confirm-update">
<div class="pop-head">
<h3 class="pop-tit">발신번호 차단 상세</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 수정하겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmUpdate();">확인</button>
<button class="btn-default" @click="confirmUpdateClose();">취소</button>
</div>
</div>
</div>
<!-- 발신번호차단 상세 삭제-->
<div class="dimmed confirm-delete" @click="confirmDeleteClose();"></div>
<div class="popup-wrap confirm-delete">
<div class="popup confirm-delete">
<div class="pop-head">
<h3 class="pop-tit">발신번호 차단 상세</h3>
</div>
<div class="pop-cont">
<p>해당 발신번호를 차단리스트에서</p>
<p>삭제하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmDelete();">확인</button>
<button class="btn-default" @click="confirmDeleteClose();">취소</button>
</div>
</div>
</div>
<!-- 메세지 등록 - 최초 등록 -->
<div class="dimmed msgconfirm-insert" @click="msgConfirmInsertClose();"></div>
<div class="popup-wrap msgconfirm-insert">
<div class="popup msgconfirm-insert">
<div class="pop-head">
<h3 class="pop-tit">메세지차단 등록</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 등록 하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="msgConfirmInsert();">확인</button>
<button class="btn-default" @click="msgConfirmInsertClose();">취소</button>
</div>
</div>
</div>
<!-- 메세지차단 상세 - 수정 -->
<div class="dimmed msgconfirm-update" @click="msgConfirmUpdateClose();"></div>
<div class="popup-wrap msgconfirm-update">
<div class="popup msgconfirm-update">
<div class="pop-head">
<h3 class="pop-tit">메세지 차단 상세</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 수정하겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="msgConfirmUpdate();">확인</button>
<button class="btn-default" @click="msgConfirmUpdateClose();">취소</button>
</div>
</div>
</div>
<!-- 메세지차단 상세 삭제-->
<div class="dimmed msgconfirm-delete" @click="msgConfirmDeleteClose();"></div>
<div class="popup-wrap msgconfirm-delete">
<div class="popup msgconfirm-delete">
<div class="pop-head">
<h3 class="pop-tit">메세지 차단 상세</h3>
</div>
<div class="pop-cont">
<p>해당 메세지를 차단리스트에서</p>
<p>삭제하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="msgConfirmDelete();">확인</button>
<button class="btn-default" @click="msgConfirmDeleteClose();">취소</button>
</div>
</div>
</div>
</div> </div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmModalClose();">확인</button>
<button class="btn-default" @click="confirmModalCancel();">취소</button>
</div>
</div>
</div>
<!-- 발신번호차단 등록 - 최초 등록 -->
<div class="dimmed confirm-insert" @click="confirmInsertClose();"></div>
<div class="popup-wrap confirm-insert">
<div class="popup confirm-insert">
<div class="pop-head">
<h3 class="pop-tit">발신번호차단 등록</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 등록 하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmInsert();">확인</button>
<button class="btn-default" @click="confirmInsertClose();">취소</button>
</div>
</div>
</div>
<!-- 발신번호차단 상세 - 수정 -->
<div class="dimmed confirm-update" @click="confirmUpdateClose();"></div>
<div class="popup-wrap confirm-update">
<div class="popup confirm-update">
<div class="pop-head">
<h3 class="pop-tit">발신번호 차단 상세</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 수정하겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmUpdate();">확인</button>
<button class="btn-default" @click="confirmUpdateClose();">취소</button>
</div>
</div>
</div>
<!-- 발신번호차단 상세 삭제-->
<div class="dimmed confirm-delete" @click="confirmDeleteClose();"></div>
<div class="popup-wrap confirm-delete">
<div class="popup confirm-delete">
<div class="pop-head">
<h3 class="pop-tit">발신번호 차단 상세</h3>
</div>
<div class="pop-cont">
<p>해당 발신번호를 차단리스트에서</p>
<p>삭제하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="confirmDelete();">확인</button>
<button class="btn-default" @click="confirmDeleteClose();">취소</button>
</div>
</div>
</div>
<!-- 메세지 등록 - 최초 등록 -->
<div class="dimmed msgconfirm-insert" @click="msgConfirmInsertClose();"></div>
<div class="popup-wrap msgconfirm-insert">
<div class="popup msgconfirm-insert">
<div class="pop-head">
<h3 class="pop-tit">메세지차단 등록</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 등록 하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="msgConfirmInsert();">확인</button>
<button class="btn-default" @click="msgConfirmInsertClose();">취소</button>
</div>
</div>
</div>
<!-- 메세지차단 상세 - 수정 -->
<div class="dimmed msgconfirm-update" @click="msgConfirmUpdateClose();"></div>
<div class="popup-wrap msgconfirm-update">
<div class="popup msgconfirm-update">
<div class="pop-head">
<h3 class="pop-tit">메세지 차단 상세</h3>
</div>
<div class="pop-cont">
<p>작성된 내용으로 수정하겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="msgConfirmUpdate();">확인</button>
<button class="btn-default" @click="msgConfirmUpdateClose();">취소</button>
</div>
</div>
</div>
<!-- 메세지차단 상세 삭제-->
<div class="dimmed msgconfirm-delete" @click="msgConfirmDeleteClose();"></div>
<div class="popup-wrap msgconfirm-delete">
<div class="popup msgconfirm-delete">
<div class="pop-head">
<h3 class="pop-tit">메세지 차단 상세</h3>
</div>
<div class="pop-cont">
<p>해당 메세지를 차단리스트에서</p>
<p>삭제하시겠습니까?</p>
</div>
<div class="popup-btn2">
<button class="btn-pcolor" @click="msgConfirmDelete();">확인</button>
<button class="btn-default" @click="msgConfirmDeleteClose();">취소</button>
</div>
</div>
</div>
</div>
</template> </template>
<script> <script>
export default { export default {
name: "validationConfirmPopup", name: "validationConfirmPopup",
data(){ data() {
return{ return {
row:{}, row: {},
title:'', title: '',
msg:'', msg: '',
} }
},
methods: {
//발신번호차단등록 - 최초등록 Open
confirmInsertOpen() {
var dimmed = document.getElementsByClassName('confirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
}, },
methods :{ //사용자등록 - 최초등록
//발신번호차단등록 - 최초등록 Open confirmInsert() {
confirmInsertOpen(){ var dimmed = document.getElementsByClassName('confirm-insert');
var dimmed = document.getElementsByClassName('confirm-insert'); for (var i = 0; i < dimmed.length; i++) {
for(var i = 0; i < dimmed.length; i++){ dimmed[i].style.display = 'none';
dimmed[i].style.display = 'block'; }
}
}, this.$parent.doInsert();
//사용자등록 - 최초등록
confirmInsert(){
var dimmed = document.getElementsByClassName('confirm-insert');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
this.$parent.doInsert();
},
//발신번호차단등록 - 최초등록 Close
confirmInsertClose(){
var dimmed = document.getElementsByClassName('confirm-insert');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
},
// 발신번호차단 삭제 Open
confirmDeleteOpen(){
var dimmed = document.getElementsByClassName('confirm-delete');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'block';
}
},
//발신번호차단번호 삭제
confirmDelete(){
var dimmed = document.getElementsByClassName('confirm-delete');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
this.$parent.IntrcpDeleteModal();
},
//발신번호차단 삭제 Close
confirmDeleteClose(){
var dimmed = document.getElementsByClassName('confirm-delete');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
},
//발신번호차단 수정 확인 Open
confirmUpdateOpen(){
var dimmed = document.getElementsByClassName('confirm-update');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'block';
}
},
//발신번호차단 수정 확인
confirmUpdate(){
var dimmed = document.getElementsByClassName('confirm-update');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
this.$parent.IntrcpUpdateModal();
},
// 발신번호차단 수정 Close
confirmUpdateClose(){
var dimmed = document.getElementsByClassName('confirm-update');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
},
//메세지차단등록 - 최초등록 Open
msgConfirmInsertOpen(){
var dimmed = document.getElementsByClassName('msgconfirm-insert');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'block';
}
},
//메세지등록 - 최초등록
msgConfirmInsert(){
var dimmed = document.getElementsByClassName('msgconfirm-insert');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
this.$parent.doInsert();
},
//메세지차단등록 - 최초등록 Close
msgConfirmInsertClose(){
var dimmed = document.getElementsByClassName('msgconfirm-insert');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
},
// 메세지차단 삭제 Open
msgConfirmDeleteOpen(){
var dimmed = document.getElementsByClassName('msgconfirm-delete');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'block';
}
},
//메세지차단번호 삭제
msgConfirmDelete(){
var dimmed = document.getElementsByClassName('msgconfirm-delete');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
this.$parent.MsgIntrcpDeleteModal();
},
//메세지차단 삭제 Close
msgConfirmDeleteClose(){
var dimmed = document.getElementsByClassName('msgconfirm-delete');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
},
//메세지차단 수정 확인 Open
msgConfirmUpdateOpen(){
var dimmed = document.getElementsByClassName('msgconfirm-update');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'block';
}
},
//메세지차단 수정 확인
msgConfirmUpdate(){
var dimmed = document.getElementsByClassName('msgconfirm-update');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
this.$parent.MsgIntrcpUpdateModal();
},
// 메세지차단 수정 Close
msgConfirmUpdateClose(){
var dimmed = document.getElementsByClassName('msgconfirm-update');
for(var i = 0; i < dimmed.length; i++){
dimmed[i].style.display = 'none';
}
},
}, },
//발신번호차단등록 - 최초등록 Close
confirmInsertClose() {
var dimmed = document.getElementsByClassName('confirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
// 발신번호차단 삭제 Open
confirmDeleteOpen() {
var dimmed = document.getElementsByClassName('confirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//발신번호차단번호 삭제
confirmDelete() {
var dimmed = document.getElementsByClassName('confirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.IntrcpDeleteModal();
},
//발신번호차단 삭제 Close
confirmDeleteClose() {
var dimmed = document.getElementsByClassName('confirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
//발신번호차단 수정 확인 Open
confirmUpdateOpen() {
var dimmed = document.getElementsByClassName('confirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//발신번호차단 수정 확인
confirmUpdate() {
var dimmed = document.getElementsByClassName('confirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.IntrcpUpdateModal();
},
// 발신번호차단 수정 Close
confirmUpdateClose() {
var dimmed = document.getElementsByClassName('confirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
//메세지차단등록 - 최초등록 Open
msgConfirmInsertOpen() {
var dimmed = document.getElementsByClassName('msgconfirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//메세지등록 - 최초등록
msgConfirmInsert() {
var dimmed = document.getElementsByClassName('msgconfirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.doInsert();
},
//메세지차단등록 - 최초등록 Close
msgConfirmInsertClose() {
var dimmed = document.getElementsByClassName('msgconfirm-insert');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
// 메세지차단 삭제 Open
msgConfirmDeleteOpen() {
var dimmed = document.getElementsByClassName('msgconfirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//메세지차단번호 삭제
msgConfirmDelete() {
var dimmed = document.getElementsByClassName('msgconfirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.MsgIntrcpDeleteModal();
},
//메세지차단 삭제 Close
msgConfirmDeleteClose() {
var dimmed = document.getElementsByClassName('msgconfirm-delete');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
//메세지차단 수정 확인 Open
msgConfirmUpdateOpen() {
var dimmed = document.getElementsByClassName('msgconfirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'block';
}
},
//메세지차단 수정 확인
msgConfirmUpdate() {
var dimmed = document.getElementsByClassName('msgconfirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
this.$parent.MsgIntrcpUpdateModal();
},
// 메세지차단 수정 Close
msgConfirmUpdateClose() {
var dimmed = document.getElementsByClassName('msgconfirm-update');
for (var i = 0; i < dimmed.length; i++) {
dimmed[i].style.display = 'none';
}
},
},
} }
</script> </script>

View File

@@ -18,7 +18,7 @@ const deleteIntrcp = (params) => {
return httpClient.post('/api/v1/bo/riskMgt/sendNum/deleteIntrcp', params, { withCredentials: false }); return httpClient.post('/api/v1/bo/riskMgt/sendNum/deleteIntrcp', params, { withCredentials: false });
} }
const msgIntrcpList = (params) => { const msgInsertIntrcp = (params) => {
return httpClient.post('/api/v1/bo/riskMgt/msg/insertIntrcp', params, { withCredentials: false }); return httpClient.post('/api/v1/bo/riskMgt/msg/insertIntrcp', params, { withCredentials: false });
} }
@@ -39,7 +39,7 @@ export default {
intrcpDetail, intrcpDetail,
insertIntrcp, insertIntrcp,
deleteIntrcp, deleteIntrcp,
msgIntrcpList, msgInsertIntrcp,
msgIntrcpDetail, msgIntrcpDetail,
deleteMsgIntrcp, deleteMsgIntrcp,
updateMsgIntrcp updateMsgIntrcp

View File

@@ -21,7 +21,7 @@
</thead> </thead>
<tbody> <tbody>
<tr v-for="(item, idx) in list"> <tr v-for="(item, idx) in list">
<td>{{ item.custNm }}</td> <td>{{ item.adminId }}</td>
<td><a href="javascript:void(0)" @click="setAdminInfo(item)">{{ item.bregNo }}</a></td> <td><a href="javascript:void(0)" @click="setAdminInfo(item)">{{ item.bregNo }}</a></td>
</tr> </tr>
</tbody> </tbody>

View File

@@ -125,7 +125,7 @@
</div> </div>
<admin-list-pop ref="admnListPop" :send-data="childData" @event-data="setChildData"/> <admin-list-pop ref="admnListPop" :send-data="childData" @event-data="setChildData"/>
<common-modal ref="commmonModal2"></common-modal> <!-- <common-modal ref="commmonModal2"></common-modal>-->
</div> </div>
</div> </div>
</template> </template>
@@ -133,7 +133,7 @@
<script> <script>
import AdminListPop from "@/modules/sendNumMgt/components/AdminListPop"; import AdminListPop from "@/modules/sendNumMgt/components/AdminListPop";
import {utils_mixin, chkPattern2} from '../service/mixins'; import {utils_mixin, chkPattern2} from '../service/mixins';
import commonModal from "@/components/modal/commonModal"; // import commonModal from "@/components/modal/commonModal";
import sendNumMgtApi from "@/modules/sendNumMgt/service/sendNumMgtApi"; import sendNumMgtApi from "@/modules/sendNumMgt/service/sendNumMgtApi";
export default { export default {
@@ -171,7 +171,7 @@ export default {
}, },
components: { components: {
AdminListPop, AdminListPop,
commonModal, // commonModal,
}, },
model: { model: {
prop: 'sendData', prop: 'sendData',
@@ -421,8 +421,6 @@ export default {
this.otherBusinessFile = null; this.otherBusinessFile = null;
}, },
async saveSendNum() { async saveSendNum() {
this.saveSendNums = [] this.saveSendNums = []
this.saveSendNums.push({ this.saveSendNums.push({
sendNm: this.sendNm, sendNm: this.sendNm,
@@ -437,59 +435,114 @@ export default {
}) })
) )
} }
this.doValidate(); if(this.doValidate()){
// console.log(this.custSeq) if (this.bizrAuthYn !== 'Y') {
console.log(this.$data) if (this.nmineeDivCd === '01') {
if (this.bizrAuthYn !== 'Y') { // 사업자
if (this.nmineeDivCd === '01') { const response = await sendNumMgtApi.insertNumber1(this.tenureFile, this.businessFile, this.communicationFile, this.adminId, this.custNm, this.bRegNo, this.nmineeDivCd, this.saveSendNums, this.bizrAuthYn, this.custSeq)
// 사업자 const result = response.data;
const response = await sendNumMgtApi.insertNumber1(this.tenureFile, this.businessFile, this.communicationFile, this.adminId, this.custNm, this.bRegNo, this.nmineeDivCd, this.saveSendNums, this.bizrAuthYn, this.custSeq) console.log(result)
if (result != null && result.retCode == "0000") {
this.toComplete()
}
} else if (this.nmineeDivCd === '02') {
const response = await sendNumMgtApi.insertNumber2(this.trustFile, this.warrantFile, this.deputyFile, this.tenureFile, this.otherBusinessFile, this.businessFile, this.adminId, this.custNm, this.bRegNo, this.nmineeDivCd, this.saveSendNums, this.bizrAuthYn, this.custSeq)
const result = response.data;
console.log(result)
if (result != null && result.retCode == "0000") {
this.toComplete()
}
}
} else {
const response = await sendNumMgtApi.insertNumber(this.adminId, this.custNm, this.bRegNo, this.nmineeDivCd, this.saveSendNums, this.bizrAuthYn, this.custSeq)
const result = response.data; const result = response.data;
console.log(result) console.log(result)
if (result != null && result.retCode == "0000") { if (result != null && result.retCode == "0000") {
this.toComplete() this.toComplete()
} }
} else if (this.nmineeDivCd === '02') {
const response = await sendNumMgtApi.insertNumber2(this.trustFile, this.warrantFile, this.deputyFile, this.tenureFile, this.otherBusinessFile, this.businessFile, this.adminId, this.custNm, this.bRegNo, this.nmineeDivCd, this.saveSendNums, this.bizrAuthYn, this.custSeq)
const result = response.data;
console.log(result)
if (result != null && result.retCode == "0000") {
this.toComplete()
}
}
} else {
const response = await sendNumMgtApi.insertNumber(this.adminId, this.custNm, this.bRegNo, this.nmineeDivCd, this.saveSendNums, this.bizrAuthYn, this.custSeq)
const result = response.data;
console.log(result)
if (result != null && result.retCode == "0000") {
this.toComplete()
} }
} }
}, },
doValidate() { doValidate() {
if (this.isNull(this.adminId) || this.isNull(this.custNm) || this.isNull(this.bRegNo)) { if (this.isNull(this.adminId) || this.isNull(this.custNm) || this.isNull(this.bRegNo)) {
this.row.title = '발신번호 등록'; this.row.title = '발신번호 등록';
this.row.msg1 = '관리자ID를 조회 해주세요.'; this.row.msg1 = '관리자ID를 조회 해주세요.';
this.getParent('NumberList').commonModalOpen(this.row) // this.getParent('NumberList').commonModalOpen(this.row)
// this.$refs.commmonModal2.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
if (this.isNull(this.sendNm) || this.isNull(this.sendNum)) { if (this.isNull(this.sendNm) || this.isNull(this.sendNum)) {
this.row.title = '발신번호 등록'; this.row.title = '발신번호 등록';
this.row.msg1 = '발신번호명/발신번호를 입력해 주세요.'; this.row.msg1 = '발신번호명/발신번호를 입력해 주세요.';
this.$refs.commmonModal2.alertModalOpen(this.row); this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false; return false;
} }
// if(this.isNull(this.adminId)){ if(this.nmineeDivCd == '01'){
// this.row.title = '발신번호 등록'; if(this.communicationFile == null){
// this.row.msg1 = '관리자ID를 조회 해주세요..'; this.row.title = '발신번호 등록';
// this.$refs.commmonModal.alertModalOpen(this.row); this.row.msg1 = '통신서비스 이용증명원 파일을 업로드 하세요.';
// return false; this.$parent.$refs.commmonModal.alertModalOpen(this.row);
// } return false
}
if(this.tenureFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '재직증명서 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.businessFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '사업자등록증 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
}else{
if(this.trustFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '위임-수임관계 확인 서류 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.warrantFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '위임장 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.deputyFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '대리인 신분증 사본 인증 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.communicationFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '통신서비스 이용증명원 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.tenureFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '재직증명서 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.otherBusinessFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '사업자등록증 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
if(this.businessFile == null){
this.row.title = '발신번호 등록';
this.row.msg1 = '사업자등록증 파일을 업로드 하세요.';
this.$parent.$refs.commmonModal.alertModalOpen(this.row);
return false
}
}
return true;
}, },
toComplete() { toComplete() {
this.getParent('numberList').$refs.table.reloadData(); this.getParent('numberList').$refs.table.reloadData();

View File

@@ -87,7 +87,7 @@ const insertNumber2 = (trustFile, warrantFile, deputyFile, tenureFile, otherBusi
row.custNm = custNm row.custNm = custNm
row.bRegNo = bRegNo row.bRegNo = bRegNo
row.nmineeDivCd = nmineeDivCd row.nmineeDivCd = nmineeDivCd
row.numberInputs = numberInputs row.list = numberInputs
row.bizrAuthYn = bizrAuthYn row.bizrAuthYn = bizrAuthYn
row.custSeq = custSeq row.custSeq = custSeq

View File

@@ -52,7 +52,7 @@
<div class="info"> <div class="info">
<div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span> <div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span>
<div class="select_box NumberSe"> <div class="select_box NumberSe">
<select name="" id="perPage" v-model="perPageCnt" @keyup.enter="search"> <select name="" id="perPage" v-model="perPageCnt" @change="changePerPage()">
<option value="20">20</option> <option value="20">20</option>
<option value="50">50</option> <option value="50">50</option>
<option value="100">100</option> <option value="100">100</option>
@@ -93,7 +93,6 @@ import customGrid from '@/components/CustomGrid';
import commonModal from "@/components/modal/commonModal"; import commonModal from "@/components/modal/commonModal";
import NumberRegPop from '../components/NumberRegPop'; import NumberRegPop from '../components/NumberRegPop';
import NumberDetailPop from "@/modules/sendNumMgt/components/NumberDetailPop"; import NumberDetailPop from "@/modules/sendNumMgt/components/NumberDetailPop";
// import sendNumMgtApi from "@/modules/sysMgt/service/sendNumMgtApi";
import sendNumMgtApi from '../service/sendNumMgtApi'; import sendNumMgtApi from '../service/sendNumMgtApi';
@@ -128,17 +127,16 @@ export default {
statType: [], statType: [],
cate2Code: "", cate2Code: "",
totalItems: 0, totalItems: 0,
searchType5: '',
searchType4: 'regNo', searchType4: 'regNo',
searchType3: '', searchType3: '',
searchType2: '', searchType2: '',
searchType1: '', searchType1: '',
isFirst:true,
// 테이블 리스트 데이터 // 테이블 리스트 데이터
perPageCnt: 50, perPageCnt: 50,
grid: { grid: {
url: '/api/v1/bo/sendNumMgt/numberList', url: '/api/v1/bo/sendNumMgt/numberList',
perPage: 20, pagePerRows: 50,
pagination: true, pagination: true,
isCheckbox: true, isCheckbox: true,
initialRequest: false, initialRequest: false,
@@ -185,7 +183,6 @@ export default {
searchType2: '', searchType2: '',
searchType3: '', searchType3: '',
searchType4: '', searchType4: '',
searchType5: '',
searchText1: '', searchText1: '',
pagePerRows: '', pagePerRows: '',
page: '' page: ''
@@ -201,7 +198,8 @@ export default {
commonModal, commonModal,
}, },
created() { created() {
// const getCondition = this.$store.getters['searchcondition/getSearchCondition']; // this.grid.pagePerRows = 50
this.isFirst=true
}, },
destroyed() { destroyed() {
this.$store.commit('searchcondition/updateSearchCondition', { this.$store.commit('searchcondition/updateSearchCondition', {
@@ -212,9 +210,7 @@ export default {
searchType2: '', searchType2: '',
searchType3: '', searchType3: '',
searchType4: '', searchType4: '',
searchText1: '', searchText1: ''
pagePerRows: '',
page: ''
} }
}); });
}, },
@@ -222,6 +218,8 @@ export default {
let page = 1; let page = 1;
// 페이지 정보 및 검색 조건 // 페이지 정보 및 검색 조건
const getCondition = this.$store.getters['searchcondition/getSearchCondition']; const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
console.log('getCondition : ' + getCondition);
// store에 저장된 페이지 정보 및 검색 조건을 불러오기 // store에 저장된 페이지 정보 및 검색 조건을 불러오기
let isKeep = false; let isKeep = false;
if (getCondition) { if (getCondition) {
@@ -231,7 +229,6 @@ export default {
isKeep = true; isKeep = true;
} }
this.search(isKeep); this.search(isKeep);
}, },
methods: { methods: {
search: function (isKeep) { search: function (isKeep) {
@@ -240,10 +237,13 @@ export default {
this.grid.params.searchType2 = this.searchType2 this.grid.params.searchType2 = this.searchType2
this.grid.params.searchType3 = this.searchType3 this.grid.params.searchType3 = this.searchType3
this.grid.params.searchType4 = this.searchType4 this.grid.params.searchType4 = this.searchType4
this.grid.params.searchType5 = this.searchType5 console.log(this.$data)
this.grid.pagePerRows = this.perPageCnt if(this.isFirst){
this.grid.pagePerRows = 50
}
this.$refs.table.search(this.grid.params, isKeep); this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData(); this.sendStoreData();
this.isFirst=false
}, },
sendStoreData: function () { sendStoreData: function () {
const getP = this.$refs.table.getPagination(); const getP = this.$refs.table.getPagination();
@@ -254,7 +254,7 @@ export default {
params: this.grid.params params: this.grid.params
}); });
const getCondition = this.$store.getters['searchcondition/getSearchCondition']; // const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
}, },
numberRegPopOpen: function () { numberRegPopOpen: function () {
this.$refs.numberRegPop.numberRegPopopen(); this.$refs.numberRegPop.numberRegPopopen();
@@ -321,18 +321,21 @@ export default {
this.numberDelete(); this.numberDelete();
} }
}, },
changePerPage: function () { // 페이지당 조회할 개수
this.grid.pagePerRows = this.perPageCnt;
},
}, },
// beforeRouteLeave(to, from, next) { beforeRouteLeave(to, from, next) {
//
// const getP = this.$refs.table.getPagination(); const getP = this.$refs.table.getPagination();
// console.log("==========getP : " + getP._currentPage); console.log("==========getP : " + getP._currentPage);
// this.$store.commit('searchcondition/updateSearchCondition', { this.$store.commit('searchcondition/updateSearchCondition', {
// page: getP._currentPage, page: getP._currentPage,
// perPage: this.perPageCnt, perPage: this.perPageCnt,
// params: this.grid.params params: this.grid.params
// }); });
// // 라우트 하기전 실행 // 라우트 하기전 실행
// next(); next();
// } }
}; };
</script> </script>

View File

@@ -35,7 +35,7 @@
<div class="info"> <div class="info">
<div class="count"> <span> {{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }} </span> <div class="count"> <span> {{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }} </span>
<div class="select_box NumberSe"> <div class="select_box NumberSe">
<select name="" id="perpage" v-model="perPageCnt" @keyup.enter="search"> <select name="" id="perpage" v-model="perPageCnt" @change="changePerPage()">
<option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">{{ <option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">{{
option.text option.text
}} }}
@@ -79,7 +79,7 @@ export default {
searchType1: '', searchType1: '',
searchType2: 'custNm', searchType2: 'custNm',
// 테이블 리스트 데이터 // 테이블 리스트 데이터
perPageCnt: 20, perPageCnt: 50,
options: [ options: [
{text: '20', value: 20}, {text: '20', value: 20},
{text: '50', value: 50}, {text: '50', value: 50},
@@ -87,7 +87,7 @@ export default {
], ],
grid: { grid: {
url: '/api/v1/bo/sendNumMgt/profileList', url: '/api/v1/bo/sendNumMgt/profileList',
perPage: 20, pagePerRows: 50,
pagination: true, pagination: true,
isCheckbox: false, isCheckbox: false,
initialRequest: false, initialRequest: false,
@@ -105,13 +105,13 @@ export default {
], ],
columns: [ columns: [
{name: 'no', header: 'NO', align: 'center', width: 50}, {name: 'no', header: 'NO', align: 'center', width: '5%'},
{name: 'custNm', header: '고객사명', align: 'center', width: 200}, {name: 'custNm', header: '고객사명', align: 'center', width: '15%'},
{name: 'bregNo', header: '사업자번호', align: 'center', width: 100}, {name: 'bregNo', header: '사업자번호', align: 'center', width: '15%'},
{name: 'sendProfile', header: '발신프로필', align: 'center', width: 100}, {name: 'sendProfile', header: '발신프로필', align: 'center', width: '15%'},
{name: 'sendProfileKey', header: '발신프로필key', align: 'center', width: 100}, {name: 'sendProfileKey', header: '발신프로필key', align: 'center', width: '20%'},
{name: 'stat', header: '상태', width: 100, cls: 'td_line'}, {name: 'stat', header: '상태', width: '15%', cls: 'td_line'},
{name: 'regDt', header: '등록일', align: 'center', width: 150}, {name: 'regDt', header: '등록일', align: 'center', width: '15%'},
], ],
noDataStr: '검색 결과가 없습니다.', noDataStr: '검색 결과가 없습니다.',
params: { params: {
@@ -139,14 +139,16 @@ export default {
}, },
created() { created() {
}, },
mounted() { mounted() {
let page = 1; let page = 1;
// 페이지 정보 및 검색 조건
const getCondition = this.$store.getters['searchcondition/getSearchCondition']; const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
console.log('getCondition : ' + getCondition);
// store에 저장된 페이지 정보 및 검색 조건을 불러오기
let isKeep = false; let isKeep = false;
if (getCondition) { if (getCondition) {
this.grid.pagePerRows = 50; this.grid.pagePerRows = getCondition.perPage;
this.grid.params = getCondition.params; this.grid.params = getCondition.params;
page = getCondition.page; page = getCondition.page;
isKeep = true; isKeep = true;
@@ -155,17 +157,14 @@ export default {
}, },
methods: { methods: {
search: function (isKeep) { search: function (isKeep) {
console.log(this.grid.params);
this.grid.params.searchType1 = this.searchType1 this.grid.params.searchType1 = this.searchType1
this.grid.params.searchType2 = this.searchType2 this.grid.params.searchType2 = this.searchType2
// perPageCnt
this.grid.pagePerRows = this.perPageCnt;
this.$refs.table.search(this.grid.params, isKeep); this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData(); this.sendStoreData();
}, },
sendStoreData: function () { sendStoreData: function () {
const getP = this.$refs.table.getPagination(); const getP = this.$refs.table.getPagination();
console.log("==========getP : " + getP); console.log("==========getP : " + getP._currentPage);
this.$store.commit('searchcondition/updateSearchCondition', { this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage, page: getP._currentPage,
perPage: this.perPageCnt, perPage: this.perPageCnt,

View File

@@ -353,6 +353,10 @@ export default {
this.row.msg1 = '저장 하였습니다.'; this.row.msg1 = '저장 하였습니다.';
this.$refs.commmonSysModal.alertSysModalOpen(this.row); this.$refs.commmonSysModal.alertSysModalOpen(this.row);
this.toComplete(); this.toComplete();
}else if (result != null && result.retCode == "4018") {
this.row.title = '관리자/유치채널 관리';
this.row.msg1 = '이미 사용중인 아이디입니다.';
this.$refs.commmonSysModal.alertSysModalOpen(this.row);
} }
} catch (err) { } catch (err) {
this.row.title = '관리자/유치채널 관리'; this.row.title = '관리자/유치채널 관리';

View File

@@ -123,6 +123,11 @@ export default {
if (result != null && result.retCode == "0000") { if (result != null && result.retCode == "0000") {
this.getAuthList(); this.getAuthList();
return; return;
}else if(result != null && result.retCode == "4020"){
this.row = {}
this.row.title = '권한 관리';
this.row.msg1 = '해당 권한에 매핑된 사용자가 있습니다.';
this.$refs.commmonModal.alertModalOpen(this.row);
} else { } else {
this.row = {} this.row = {}
this.row.title = '권한 관리'; this.row.title = '권한 관리';

View File

@@ -106,6 +106,11 @@ public class RiskMgtService {
RiskMgtMapper riskMgtMapper = sqlSessionMaster.getMapper(RiskMgtMapper.class); RiskMgtMapper riskMgtMapper = sqlSessionMaster.getMapper(RiskMgtMapper.class);
SendNumIntrcpDetail sendNumIntrcpDetail = riskMgtMapper.selectSndrnoBlckDetail(insertIntrcpReqDto.getBlckSndrno());
if(sendNumIntrcpDetail != null){
return new SendNumInsertIntrcpResDto(ApiResponseCode.CE_DUPLICATE_ID);
}
try { try {
insertIntrcpReqDto.setBlckYn(Const.COMM_YES); insertIntrcpReqDto.setBlckYn(Const.COMM_YES);
// regId 들고오기 // regId 들고오기

View File

@@ -12,13 +12,17 @@ import org.mybatis.spring.SqlSessionTemplate;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.security.core.context.SecurityContextHolder;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest; import org.springframework.web.multipart.MultipartHttpServletRequest;
import java.io.File; import java.io.File;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.stream.Collectors;
@Service @Service
public class SendNumMgtService { public class SendNumMgtService {
@@ -46,28 +50,30 @@ public class SendNumMgtService {
int totalCnt = sendNumMgtMapper.selectProfileTotalCnt(profileListReqDto); int totalCnt = sendNumMgtMapper.selectProfileTotalCnt(profileListReqDto);
if(totalCnt == 0) { if(totalCnt == 0) {
ProfileListRes profileListRes = new ProfileListRes();
profileListRes.setList(new ArrayList<>());
Paging paging = new Paging(); Paging paging = new Paging();
paging.setPage(nowPage); paging.setPage(nowPage);
paging.setTotalCnt(String.valueOf(totalCnt)); paging.setTotalCnt(String.valueOf(totalCnt));
ProfileListRes profileListRes = new ProfileListRes();
profileListRes.setList(new ArrayList<>());
profileListRes.setPaging(paging); profileListRes.setPaging(paging);
return new ProfileListResDto(ApiResponseCode.CM_NOT_FOUND, profileListRes); return new ProfileListResDto(ApiResponseCode.CM_NOT_FOUND, profileListRes);
} }
int page = profileListReqDto.getPage(); int page = profileListReqDto.getPage();
int pagePerRows = profileListReqDto.getPage(); int pagePerRows = profileListReqDto.getPagePerRows();
page = (page - 1) * pagePerRows; page = (page - 1) * pagePerRows;
profileListReqDto.setPage(page); profileListReqDto.setPage(page);
List<ProfileInfo> profileInfos = sendNumMgtMapper.selectProfileList(profileListReqDto); List<ProfileInfo> profileInfos = sendNumMgtMapper.selectProfileList(profileListReqDto);
ProfileListRes profileListRes = new ProfileListRes();
profileListRes.setList(profileInfos);
Paging paging = new Paging(); Paging paging = new Paging();
paging.setPage(nowPage); paging.setPage(nowPage);
paging.setTotalCnt(String.valueOf(totalCnt)); paging.setTotalCnt(String.valueOf(totalCnt));
ProfileListRes profileListRes = new ProfileListRes();
profileListRes.setList(profileInfos);
profileListRes.setPaging(paging); profileListRes.setPaging(paging);
return new ProfileListResDto(ApiResponseCode.SUCCESS, profileListRes); return new ProfileListResDto(ApiResponseCode.SUCCESS, profileListRes);
@@ -88,28 +94,30 @@ public class SendNumMgtService {
int totalCnt = sendNumMgtMapper.selectSendNumberTotalCnt(sendNumberListReqDto); int totalCnt = sendNumMgtMapper.selectSendNumberTotalCnt(sendNumberListReqDto);
if(totalCnt == 0) { if(totalCnt == 0) {
SendNumberListRes sendNumberListRes = new SendNumberListRes();
sendNumberListRes.setList(new ArrayList<>());
Paging paging = new Paging(); Paging paging = new Paging();
paging.setPage(nowPage); paging.setPage(nowPage);
paging.setTotalCnt(String.valueOf(totalCnt)); paging.setTotalCnt(String.valueOf(totalCnt));
SendNumberListRes sendNumberListRes = new SendNumberListRes();
sendNumberListRes.setList(new ArrayList<>());
sendNumberListRes.setPaging(paging); sendNumberListRes.setPaging(paging);
return new SendNumberListResDto(ApiResponseCode.CM_NOT_FOUND, sendNumberListRes); return new SendNumberListResDto(ApiResponseCode.CM_NOT_FOUND, sendNumberListRes);
} }
int page = sendNumberListReqDto.getPage(); int page = sendNumberListReqDto.getPage();
int pagePerRows = sendNumberListReqDto.getPage(); int pagePerRows = sendNumberListReqDto.getPagePerRows();
page = (page - 1) * pagePerRows; page = (page - 1) * pagePerRows;
sendNumberListReqDto.setPage(page); sendNumberListReqDto.setPage(page);
List<SendNumberInfo> sendNumberInfos = sendNumMgtMapper.selectSendNumberList(sendNumberListReqDto); List<SendNumberInfo> sendNumberInfos = sendNumMgtMapper.selectSendNumberList(sendNumberListReqDto);
SendNumberListRes sendNumberListRes = new SendNumberListRes();
sendNumberListRes.setList(sendNumberInfos);
Paging paging = new Paging(); Paging paging = new Paging();
paging.setPage(nowPage); paging.setPage(nowPage);
paging.setTotalCnt(String.valueOf(totalCnt)); paging.setTotalCnt(String.valueOf(totalCnt));
SendNumberListRes sendNumberListRes = new SendNumberListRes();
sendNumberListRes.setList(sendNumberInfos);
sendNumberListRes.setPaging(paging); sendNumberListRes.setPaging(paging);
return new SendNumberListResDto(ApiResponseCode.SUCCESS, sendNumberListRes); return new SendNumberListResDto(ApiResponseCode.SUCCESS, sendNumberListRes);
@@ -142,32 +150,36 @@ public class SendNumMgtService {
* @param insertNumberReqDto * @param insertNumberReqDto
* @return * @return
*/ */
@Transactional(value="db1TransactionManager")
public InsertNumberResDto insertNumber(InsertNumberReqDto insertNumberReqDto, MultipartHttpServletRequest multipartRequest) { public InsertNumberResDto insertNumber(InsertNumberReqDto insertNumberReqDto, MultipartHttpServletRequest multipartRequest) {
SendNumMgtMapper sendNumMgtMapper = sqlSessionMaster.getMapper(SendNumMgtMapper.class); SendNumMgtMapper sendNumMgtMapper = sqlSessionMaster.getMapper(SendNumMgtMapper.class);
String adminId = insertNumberReqDto.getAdminId(); String adminId = insertNumberReqDto.getAdminId();
Object principal = SecurityContextHolder.getContext().getAuthentication().getPrincipal();
UserDetails userDetails = (UserDetails) principal;
String regId = userDetails.getUsername();
// 2. 중복 발신번호 체크를 위한 조회. // 2. 중복 발신번호 체크를 위한 조회.
List<InsertNumber> sendNumbers = sendNumMgtMapper.selectSndrnoList(insertNumberReqDto); List<InsertNumber> sendNumbers = sendNumMgtMapper.selectSndrnoList(insertNumberReqDto);
List<InsertNumber> resSendNumbers = new ArrayList<>(); List<InsertNumber> dbSendNumbers = insertNumberReqDto.getList();
List<InsertNumber> allSendNumbers = insertNumberReqDto.getList();
if(insertNumberReqDto.getList().size() == sendNumbers.size()){
// 중복건... 오류
}
// 실패 항목 응답. // 실패 항목 응답.
if(sendNumbers.size() > 0){ if(sendNumbers.size() > 0){
// 중복건의 대한 오류 응답. allSendNumbers.addAll(sendNumbers);
resSendNumbers.addAll(sendNumbers);
} }
dbSendNumbers = allSendNumbers.stream().distinct().collect(Collectors.toList());
// 1. 발신번호 SEQ 채번 // 1. 발신번호 SEQ 채번
String regReqNo = sendNumMgtMapper.selectRegReqNo(); String regReqNo = sendNumMgtMapper.selectRegReqNo();
String userSeq = sendNumMgtMapper.selectUserSeqByAdminId(adminId); String userSeq = sendNumMgtMapper.selectUserSeqByAdminId(adminId);
try { try {
insertNumberReqDto.setUserSeq(userSeq); insertNumberReqDto.setUserSeq(userSeq);
insertNumberReqDto.setReqCnt(insertNumberReqDto.getList().size()); insertNumberReqDto.setReqCnt(insertNumberReqDto.getList().size());
insertNumberReqDto.setRegId(adminId); insertNumberReqDto.setRegId(regId);
insertNumberReqDto.setRegReqNo(regReqNo); insertNumberReqDto.setRegReqNo(regReqNo);
// 2. 발신번호등록 테이블 저장. (EZ_SNDRNO_REG) // 2. 발신번호등록 테이블 저장. (EZ_SNDRNO_REG)
@@ -181,18 +193,7 @@ public class SendNumMgtService {
dir.mkdirs(); dir.mkdirs();
} }
// 3. 발신번호 테이블 저장. (EZ_SVC_SNDRNO) for (InsertNumber dbInsertNumber : dbSendNumbers){
List<InsertNumber> reqSendNumbers = insertNumberReqDto.getList();
List<InsertNumber> dbSendNumbers = new ArrayList<>();
for(InsertNumber insertNumber: reqSendNumbers){
for(InsertNumber insertNumber1: resSendNumbers){
if(StringUtils.equals(insertNumber.getSendNum(), insertNumber1.getSendNum())){
reqSendNumbers.remove(insertNumber1);
}
}
}
for (InsertNumber dbInsertNumber : reqSendNumbers){
dbInsertNumber.setCustSeq(insertNumberReqDto.getCustSeq()); dbInsertNumber.setCustSeq(insertNumberReqDto.getCustSeq());
dbInsertNumber.setRegReqNo(regReqNo); dbInsertNumber.setRegReqNo(regReqNo);
dbInsertNumber.setNmineeDivCd(insertNumberReqDto.getNmineeDivCd()); dbInsertNumber.setNmineeDivCd(insertNumberReqDto.getNmineeDivCd());
@@ -202,7 +203,7 @@ public class SendNumMgtService {
}else{ }else{
dbInsertNumber.setNmineeDivCd(insertNumberReqDto.getNmineeDivCd()); dbInsertNumber.setNmineeDivCd(insertNumberReqDto.getNmineeDivCd());
} }
dbInsertNumber.setRegId(adminId); dbInsertNumber.setRegId(regId);
sendNumMgtMapper.insertNumberList(dbInsertNumber); sendNumMgtMapper.insertNumberList(dbInsertNumber);
} }
@@ -211,7 +212,6 @@ public class SendNumMgtService {
// 4. 발신번호 등록 서류 테이블 저장. (EZ_SNDRNO_DOC) // 4. 발신번호 등록 서류 테이블 저장. (EZ_SNDRNO_DOC)
// DOC_NO 채번. // DOC_NO 채번.
String regId = insertNumberReqDto.getRegId();
List<MultipartFile> multipartFiles = new ArrayList<>(); List<MultipartFile> multipartFiles = new ArrayList<>();
List<String> docTpCd = new ArrayList<>(); List<String> docTpCd = new ArrayList<>();
@@ -225,12 +225,13 @@ public class SendNumMgtService {
MultipartFile tenureFile = multipartRequest.getFile("tenureFile"); MultipartFile tenureFile = multipartRequest.getFile("tenureFile");
multipartFiles.add(tenureFile); multipartFiles.add(tenureFile);
docTpCd.add(Const.SNDRNO_DOC_TP_CD_02); docTpCd.add(Const.SNDRNO_DOC_TP_CD_02);
// 사업자등록증 '06' // 사업자등록증 '06'
MultipartFile businessFile = multipartRequest.getFile("businessFile"); MultipartFile businessFile = multipartRequest.getFile("businessFile");
multipartFiles.add(businessFile); multipartFiles.add(businessFile);
docTpCd.add(Const.SNDRNO_DOC_TP_CD_06); docTpCd.add(Const.SNDRNO_DOC_TP_CD_06);
if(StringUtils.equals("02", insertNumberReqDto.getNmineeDivCd())){ if(StringUtils.equals(Const.SNDRNO_TP_CD_OTHER, insertNumberReqDto.getNmineeDivCd())){
// 위임-수임관계 확인 서류 '03' // 위임-수임관계 확인 서류 '03'
MultipartFile trustFile = multipartRequest.getFile("trustFile"); MultipartFile trustFile = multipartRequest.getFile("trustFile");
multipartFiles.add(trustFile); multipartFiles.add(trustFile);
@@ -257,6 +258,8 @@ public class SendNumMgtService {
String fileNm = regReqNo + "_" + docTpCd.get(j).substring(1,2) + "_" + docTpCd.get(j) + "." + ext; String fileNm = regReqNo + "_" + docTpCd.get(j).substring(1,2) + "_" + docTpCd.get(j) + "." + ext;
String titleNm = multipartFiles.get(j).getOriginalFilename(); String titleNm = multipartFiles.get(j).getOriginalFilename();
long fileSize = multipartFiles.get(j).getSize(); long fileSize = multipartFiles.get(j).getSize();
// File Upload.
FileUtil.upload(multipartFiles.get(j), fileNm, path); FileUtil.upload(multipartFiles.get(j), fileNm, path);
// 발신번호 등록 서류 테이블 저장 (EZ_SNDRNO_DOC). // 발신번호 등록 서류 테이블 저장 (EZ_SNDRNO_DOC).
@@ -277,9 +280,9 @@ public class SendNumMgtService {
} }
InsertNumberRes insertNumberRes = new InsertNumberRes(); InsertNumberRes insertNumberRes = new InsertNumberRes();
if(resSendNumbers.size() > 0){ if(sendNumbers.size() > 0){
// 발신번호 중복건 응답 처리. // 발신번호 중복건 응답 처리.
insertNumberRes.setList(resSendNumbers); insertNumberRes.setList(sendNumbers);
} }
return new InsertNumberResDto(ApiResponseCode.SUCCESS, insertNumberRes); return new InsertNumberResDto(ApiResponseCode.SUCCESS, insertNumberRes);
@@ -354,28 +357,30 @@ public class SendNumMgtService {
int totalCnt = sendNumMgtMapper.selectSvcSndrnoListTotalCnt(sendNumberApprListReqDto); int totalCnt = sendNumMgtMapper.selectSvcSndrnoListTotalCnt(sendNumberApprListReqDto);
if(totalCnt == 0) { if(totalCnt == 0) {
SendNumberApprListRes sendNumberApprListRes = new SendNumberApprListRes();
sendNumberApprListRes.setList(new ArrayList<>());
Paging paging = new Paging(); Paging paging = new Paging();
paging.setPage(nowPage); paging.setPage(nowPage);
paging.setTotalCnt(String.valueOf(totalCnt)); paging.setTotalCnt(String.valueOf(totalCnt));
SendNumberApprListRes sendNumberApprListRes = new SendNumberApprListRes();
sendNumberApprListRes.setList(new ArrayList<>());
sendNumberApprListRes.setPaging(paging); sendNumberApprListRes.setPaging(paging);
return new SendNumberApprListResDto(ApiResponseCode.CM_NOT_FOUND, sendNumberApprListRes); return new SendNumberApprListResDto(ApiResponseCode.CM_NOT_FOUND, sendNumberApprListRes);
} }
int page = sendNumberApprListReqDto.getPage(); int page = sendNumberApprListReqDto.getPage();
int pagePerRows = sendNumberApprListReqDto.getPage(); int pagePerRows = sendNumberApprListReqDto.getPagePerRows();
page = (page - 1) * pagePerRows; page = (page - 1) * pagePerRows;
sendNumberApprListReqDto.setPage(page); sendNumberApprListReqDto.setPage(page);
List<SendNumberApprInfo> sendNumberApprInfos = sendNumMgtMapper.selectSvcSndrnoList(sendNumberApprListReqDto); List<SendNumberApprInfo> sendNumberApprInfos = sendNumMgtMapper.selectSvcSndrnoList(sendNumberApprListReqDto);
SendNumberApprListRes sendNumberApprListRes = new SendNumberApprListRes();
sendNumberApprListRes.setList(sendNumberApprInfos);
Paging paging = new Paging(); Paging paging = new Paging();
paging.setPage(nowPage); paging.setPage(nowPage);
paging.setTotalCnt(String.valueOf(totalCnt)); paging.setTotalCnt(String.valueOf(totalCnt));
SendNumberApprListRes sendNumberApprListRes = new SendNumberApprListRes();
sendNumberApprListRes.setList(sendNumberApprInfos);
sendNumberApprListRes.setPaging(paging); sendNumberApprListRes.setPaging(paging);
return new SendNumberApprListResDto(ApiResponseCode.SUCCESS, sendNumberApprListRes); return new SendNumberApprListResDto(ApiResponseCode.SUCCESS, sendNumberApprListRes);

View File

@@ -1,27 +1,11 @@
package kr.co.uplus.ez.api.sysMgt; package kr.co.uplus.ez.api.sysMgt;
import kr.co.uplus.ez.api.sysMgt.dto.*;
import org.apache.ibatis.annotations.Mapper;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.ibatis.annotations.Mapper;
import kr.co.uplus.ez.api.sysMgt.dto.AdminDetail;
import kr.co.uplus.ez.api.sysMgt.dto.AdminDetailReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.AdminInfo;
import kr.co.uplus.ez.api.sysMgt.dto.AdminListReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.AuthDetail;
import kr.co.uplus.ez.api.sysMgt.dto.AuthDetailReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.AuthInfo;
import kr.co.uplus.ez.api.sysMgt.dto.AuthMenu;
import kr.co.uplus.ez.api.sysMgt.dto.DeleteAdmin;
import kr.co.uplus.ez.api.sysMgt.dto.DeleteAuthReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.InsertAdminReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.InsertAuthReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.SearchMadangId;
import kr.co.uplus.ez.api.sysMgt.dto.SearchMadangIdReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.UpdateAdminReqDto;
import kr.co.uplus.ez.api.sysMgt.dto.UpdateAuthReqDto;
@Mapper @Mapper
public interface SysMgtMapper { public interface SysMgtMapper {
@@ -58,4 +42,6 @@ public interface SysMgtMapper {
int deleteAuth(Map<String, Object> paramMap); // 권한 삭제 int deleteAuth(Map<String, Object> paramMap); // 권한 삭제
int deleteAuthMenu(Map<String, Object> paramMap); // 권한메뉴 삭제 int deleteAuthMenu(Map<String, Object> paramMap); // 권한메뉴 삭제
int checkAdmin(Map<String, Object> paramMap);
} }

View File

@@ -108,6 +108,15 @@ public class SysMgtService {
SysMgtMapper sysMgtMapper = sqlSessionMaster.getMapper(SysMgtMapper.class); SysMgtMapper sysMgtMapper = sqlSessionMaster.getMapper(SysMgtMapper.class);
// 관리자 ID 중복체크.
Map<String, Object> paramMap = new HashMap<>();
paramMap.put("searchType", "01");
paramMap.put("adminId", insertAdminReqDto.getMadangId());
int checkId = sysMgtMapper.checkAdmin(paramMap);
if(checkId > 0){
return new InsertAdminResDto(ApiResponseCode.CE_DUPLICATE_ID);
}
String encPw = EncryptionUtil.getCustomSHA512(insertAdminReqDto.getMadangId(), insertAdminReqDto.getAdminPw()); String encPw = EncryptionUtil.getCustomSHA512(insertAdminReqDto.getMadangId(), insertAdminReqDto.getAdminPw());
insertAdminReqDto.setAdminPw(encPw); insertAdminReqDto.setAdminPw(encPw);
@@ -232,9 +241,14 @@ public class SysMgtService {
public DeleteAuthResDto deleteAuth(DeleteAuthReqDto deleteAuthReqDto) { public DeleteAuthResDto deleteAuth(DeleteAuthReqDto deleteAuthReqDto) {
SysMgtMapper sysMgtMapper = sqlSessionMaster.getMapper(SysMgtMapper.class); SysMgtMapper sysMgtMapper = sqlSessionMaster.getMapper(SysMgtMapper.class);
Map<String, Object> authParamMap = new HashMap<String, Object>();
Map<String, Object> authParamMap = new HashMap<String, Object>();
authParamMap.put("searchType", "02");
authParamMap.put("authCd", deleteAuthReqDto.getAuthCd()); authParamMap.put("authCd", deleteAuthReqDto.getAuthCd());
int checkAdmin = sysMgtMapper.checkAdmin(authParamMap);
if(checkAdmin > 0){
return new DeleteAuthResDto(ApiResponseCode.CE_SYSMGT_AUTHCODE_EXISTS_USER);
}
try { try {
// 1.권한메뉴 삭제 // 1.권한메뉴 삭제

View File

@@ -57,7 +57,8 @@ public enum ApiResponseCode {
,CE_DUPLICATE_ID("4018", "이미 사용중인 아이디 입니다.") ,CE_DUPLICATE_ID("4018", "이미 사용중인 아이디 입니다.")
/** 발송한도금액이 정액한도금액보다 작습니다. */ /** 발송한도금액이 정액한도금액보다 작습니다. */
,CE_SENDINGLIMT_ERROR("4019", "발송한도금액이 정액한도금액보다 작습니다.") ,CE_SENDINGLIMT_ERROR("4019", "발송한도금액이 정액한도금액보다 작습니다.")
/** 해당 권한코드에 해당하는 어드민 사용자가 존재함. */
,CE_SYSMGT_AUTHCODE_EXISTS_USER("4020", "해당 권한코드에 해당하는 어드민 사용자가 존재함.")
// 시스템 // 시스템
/** 알 수 없는 에러. */ /** 알 수 없는 에러. */
,SE_UNKNOWN("9999", "알 수 없는 에러"); ,SE_UNKNOWN("9999", "알 수 없는 에러");

View File

@@ -95,6 +95,9 @@ public class Const {
public static final String SNDRNO_DOC_TP_CD_06 = "06"; public static final String SNDRNO_DOC_TP_CD_06 = "06";
public static final String SNDRNO_DOC_TP_CD_07 = "07"; public static final String SNDRNO_DOC_TP_CD_07 = "07";
public static final String SNDRNO_TP_CD_SELF = "01";
public static final String SNDRNO_TP_CD_OTHER = "02";
public static final String INCH_DIV_CD_HOME = "01"; public static final String INCH_DIV_CD_HOME = "01";
public static final String INCH_DIV_CD_ADM = "02"; public static final String INCH_DIV_CD_ADM = "02";

View File

@@ -4,177 +4,139 @@
<mapper namespace="kr.co.uplus.ez.api.calculate.CalculateMapper"> <mapper namespace="kr.co.uplus.ez.api.calculate.CalculateMapper">
<select id="selectCalculateListTotalCnt" parameterType="kr.co.uplus.ez.api.calculate.dto.CalcListReqDto" resultType="int"> <select id="selectCalculateListTotalCnt" parameterType="kr.co.uplus.ez.api.calculate.dto.CalcListReqDto" resultType="int">
SELECT COUNT(*) AS TOTALCNT /* calculate-mapper.xml(selectCalculateListTotalCnt) */
FROM SELECT count(*) AS TOTALCNT
(SELECT FROM (
eci.CUST_NM SELECT RAT_YM
,eci.BIZRNO , RAT_TMS
,esi.SUBS_ID , USE_YM
FROM hubez_common.EZ_SUBS_INFO esi , COLEC_TMS
JOIN hubez_common.EZ_CUST_INFO eci from hubez_admin.EZ_RAT_TXN
ON esi.CUST_SEQ = eci.CUST_SEQ where LAST_YN = 'Y'
WHERE 1=1 <![CDATA[
<if test="custNm != null and custNm != ''"> and RAT_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d')
AND eci.CUST_NM LIKE CONCAT('%',#{custNm},'%') AND RAT_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH)
</if> ]]>
<if test="bizrno != null and bizrno != ''"> ) tms
AND eci.BIZRNO LIKE CONCAT('%',#{bizrno},'%') inner join hubez_admin.EZ_UTXNCOLEC_DTL eud
</if> on eud.USE_YM = tms.USE_YM
) A and tms.COLEC_TMS = eud.COLEC_TMS
JOIN where 1 =1
(SELECT MAX(COLEC_TMS) AS COLEC_TMS <![CDATA[
,eud.USE_YM AS USE_YM and eud.USE_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d')
,eud.SUBS_ID AS SUBS_ID and eud.USE_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH)
FROM hubez_admin.EZ_UTXNCOLEC_DTL eud ]]>
WHERE 1=1 <if test="custNm != null and custNm != ''">
<![CDATA[ AND eud.CUST_NM LIKE CONCAT('%',#{custNm},'%')
AND eud.USE_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d') </if>
AND eud.USE_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH) <if test="bizrno != null and bizrno != ''">
]]> AND eud.BIZRNO LIKE CONCAT('%',#{bizrno},'%')
GROUP BY eud.USE_YM, eud.SUBS_ID) B </if>
ON A.SUBS_ID = B.SUBS_ID ORDER BY eud.USE_YM DESC, eud.CUST_NM DESC
</select> </select>
<select id="selectCalculateList" parameterType="kr.co.uplus.ez.api.calculate.dto.CalcListReqDto" resultType="kr.co.uplus.ez.api.calculate.dto.CalcList"> <select id="selectCalculateList" parameterType="kr.co.uplus.ez.api.calculate.dto.CalcListReqDto" resultType="kr.co.uplus.ez.api.calculate.dto.CalcList">
SELECT /* calculate-mapper.xml(selectCalculateList) */
A.CUST_NM SELECT eud.CUST_NM
,A.BIZRNO , eud.BIZRNO
,B.USE_YM , DATE_FORMAT(eud.USE_YM, '%Y-%m') AS USE_YM
,B.PROD_NM , eud.PROD_NM
,B.PROD_AMT , ROUND(IFNULL(eud.PROD_AMT,0), 1) AS PROD_AMT
,B.START_AMT , ROUND(IFNULL(eud.FX_LMT_AMT,0) + IFNULL(eud.CFWD_AMT,0), 1) AS START_AMT -- 시작금액 : 정액한도금액+이월금액
,B.USE_AMT , ROUND(IFNULL(eud.FX_USE_AMT,0) + IFNULL(eud.CFWD_USE_AMT,0) + IFNULL(eud.MRT_USE_AMT,0), 1) AS USE_AMT -- 사용금액 : 정액사용금액 + 이월사용금액 + 종량사용금액
,B.CFWD_AMT , ROUND(IFNULL(eud.CFWD_AMT,0), 1) AS CFWD_AMT -- 이월금액
,B.MRT_USE_AMT , ROUND(IFNULL(eud.MRT_USE_AMT,0), 1) AS MRT_USE_AMT -- 종량금액
,B.EXTNC_AMT , ROUND(IFNULL(eud.EXTNC_AMT,0), 1) AS EXTNC_AMT -- 소멸금액 : 소멸처리금액
,B.BILLING_AMT , ifnull((
,B.TOTAL_SND_CNT select RAT_AMT
,B.SMS_SND_CNT from hubez_admin.EZ_RATTXN_DTL
,B.LMS_SND_CNT where RAT_YM = tms.RAT_YM and RAT_TMS = tms. RAT_TMS and SUBS_ID = eud.SUBS_ID
,B.MMS_SND_CNT ) , 0) as BILLING_AMT
,B.ATLK_SND_CNT , (IFNULL(eud.SMS_USE_CNT,0) + IFNULL(eud.LMS_USE_CNT,0) + IFNULL(eud.MMS_USE_CNT,0) + IFNULL(eud.ATLK_USE_CNT,0)) AS TOTAL_SND_CNT
FROM , IFNULL(eud.SMS_USE_CNT,0) AS SMS_SND_CNT
(SELECT , IFNULL(eud.LMS_USE_CNT,0) AS LMS_SND_CNT
eci.CUST_NM , IFNULL(eud.MMS_USE_CNT,0) AS MMS_SND_CNT
,eci.BIZRNO , IFNULL(eud.ATLK_USE_CNT,0) AS ATLK_SND_CNT
,esi.SUBS_ID FROM (
FROM SELECT RAT_YM
hubez_common.EZ_SUBS_INFO esi , RAT_TMS
JOIN hubez_common.EZ_CUST_INFO eci , USE_YM
ON esi.CUST_SEQ = eci.CUST_SEQ , COLEC_TMS
WHERE 1=1 from hubez_admin.EZ_RAT_TXN
<if test="custNm != null and custNm != ''"> where LAST_YN = 'Y'
AND eci.CUST_NM LIKE CONCAT('%',#{custNm},'%')
</if>
<if test="bizrno != null and bizrno != ''">
AND eci.BIZRNO LIKE CONCAT('%',#{bizrno},'%')
</if>
) A
JOIN
(SELECT MAX(COLEC_TMS) AS COLEC_TMS
,DATE_FORMAT(eud.USE_YM, '%Y-%m') AS USE_YM
,eud.SUBS_ID AS SUBS_ID
,eud.PROD_NM AS PROD_NM
,ROUND(IFNULL(eud.PROD_AMT,0)) AS PROD_AMT
,ROUND(SUM(IFNULL(eud.FX_LMT_AMT,0) + IFNULL(eud.CFWD_AMT,0))) AS START_AMT -- 시작금액 : 정액한도금액+이월금액
,ROUND(SUM(IFNULL(eud.FX_USE_AMT,0) + IFNULL(eud.CFWD_USE_AMT,0) + IFNULL(eud.MRT_USE_AMT,0))) AS USE_AMT -- 사용금액 : 정액사용금액 + 이월사용금액 + 종량사용금액
,ROUND(IFNULL(eud.CFWD_AMT,0)) AS CFWD_AMT -- 이월금액
,ROUND(IFNULL(eud.MRT_USE_AMT,0)) AS MRT_USE_AMT -- 종량금액
,ROUND(IFNULL(eud.EXTNC_AMT,0)) AS EXTNC_AMT -- 소멸금액 : 소멸처리금액
,ROUND(IFNULL((SELECT IFNULL(t2.RAT_AMT,0)
FROM hubez_admin.EZ_RAT_TXN t1
JOIN hubez_admin.EZ_RATTXN_DTL t2
ON t1.RAT_YM = t2.RAT_YM
AND t1.RAT_TMS = t2.RAT_TMS
WHERE t1.USE_YM = eud.USE_YM
AND t1.COLEC_TMS = eud.COLEC_TMS
AND t2.SUBS_ID = eud.SUBS_ID ),0)) AS BILLING_AMT -- 청구금액 : 과금금액
,SUM(IFNULL(eud.SMS_USE_CNT,0) + IFNULL(eud.LMS_USE_CNT,0) + IFNULL(eud.MMS_USE_CNT,0) + IFNULL(eud.ATLK_USE_CNT,0)) AS TOTAL_SND_CNT
,IFNULL(eud.SMS_USE_CNT,0) AS SMS_SND_CNT
,IFNULL(eud.LMS_USE_CNT,0) AS LMS_SND_CNT
,IFNULL(eud.MMS_USE_CNT,0) AS MMS_SND_CNT
,IFNULL(eud.ATLK_USE_CNT,0) AS ATLK_SND_CNT
FROM hubez_admin.EZ_UTXNCOLEC_DTL eud
WHERE 1=1
<![CDATA[ <![CDATA[
AND eud.USE_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d') and RAT_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d')
AND eud.USE_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH) AND RAT_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH)
]]> ]]>
GROUP BY eud.USE_YM, eud.SUBS_ID) B ) tms
ON A.SUBS_ID = B.SUBS_ID inner join hubez_admin.EZ_UTXNCOLEC_DTL eud
ORDER BY B.USE_YM DESC, B.SUBS_ID DESC on eud.USE_YM = tms.USE_YM
LIMIT #{page}, #{pagePerRows} and tms.COLEC_TMS = eud.COLEC_TMS
where 1 =1
<![CDATA[
and eud.USE_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d')
and eud.USE_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH)
]]>
<if test="custNm != null and custNm != ''">
AND eud.CUST_NM LIKE CONCAT('%',#{custNm},'%')
</if>
<if test="bizrno != null and bizrno != ''">
AND eud.BIZRNO LIKE CONCAT('%',#{bizrno},'%')
</if>
ORDER BY eud.USE_YM DESC, eud.CUST_NM DESC
LIMIT #{page}, #{pagePerRows}
</select> </select>
<select id="selectCalculateExcelList" parameterType="kr.co.uplus.ez.api.calculate.dto.CalcListReqDto" resultType="kr.co.uplus.ez.api.calculate.dto.CalcList"> <select id="selectCalculateExcelList" parameterType="kr.co.uplus.ez.api.calculate.dto.CalcListReqDto" resultType="kr.co.uplus.ez.api.calculate.dto.CalcList">
SELECT /* calculate-mapper.xml(selectCalculateExcelList) */
A.CUST_NM SELECT eud.CUST_NM
,A.BIZRNO , eud.BIZRNO
,B.USE_YM , DATE_FORMAT(eud.USE_YM, '%Y-%m') AS USE_YM
,B.PROD_NM , eud.PROD_NM
,B.PROD_AMT , ROUND(IFNULL(eud.PROD_AMT,0), 1) AS PROD_AMT
,B.START_AMT , ROUND(IFNULL(eud.FX_LMT_AMT,0) + IFNULL(eud.CFWD_AMT,0), 1) AS START_AMT -- 시작금액 : 정액한도금액+이월금액
,B.USE_AMT , ROUND(IFNULL(eud.FX_USE_AMT,0) + IFNULL(eud.CFWD_USE_AMT,0) + IFNULL(eud.MRT_USE_AMT,0), 1) AS USE_AMT -- 사용금액 : 정액사용금액 + 이월사용금액 + 종량사용금액
,B.CFWD_AMT , ROUND(IFNULL(eud.CFWD_AMT,0), 1) AS CFWD_AMT -- 이월금액
,B.MRT_USE_AMT , ROUND(IFNULL(eud.MRT_USE_AMT,0), 1) AS MRT_USE_AMT -- 종량금액
,B.EXTNC_AMT , ROUND(IFNULL(eud.EXTNC_AMT,0), 1) AS EXTNC_AMT -- 소멸금액 : 소멸처리금액
,B.BILLING_AMT , ifnull((
,B.TOTAL_SND_CNT select RAT_AMT
,B.SMS_SND_CNT from hubez_admin.EZ_RATTXN_DTL
,B.LMS_SND_CNT where RAT_YM = tms.RAT_YM and RAT_TMS = tms. RAT_TMS and SUBS_ID = eud.SUBS_ID
,B.MMS_SND_CNT ) , 0) as BILLING_AMT
,B.ATLK_SND_CNT , (IFNULL(eud.SMS_USE_CNT,0) + IFNULL(eud.LMS_USE_CNT,0) + IFNULL(eud.MMS_USE_CNT,0) + IFNULL(eud.ATLK_USE_CNT,0)) AS TOTAL_SND_CNT
FROM , IFNULL(eud.SMS_USE_CNT,0) AS SMS_SND_CNT
(SELECT , IFNULL(eud.LMS_USE_CNT,0) AS LMS_SND_CNT
eci.CUST_NM , IFNULL(eud.MMS_USE_CNT,0) AS MMS_SND_CNT
,eci.BIZRNO , IFNULL(eud.ATLK_USE_CNT,0) AS ATLK_SND_CNT
,esi.SUBS_ID FROM (
FROM SELECT RAT_YM
hubez_common.EZ_SUBS_INFO esi , RAT_TMS
JOIN hubez_common.EZ_CUST_INFO eci , USE_YM
ON esi.CUST_SEQ = eci.CUST_SEQ , COLEC_TMS
WHERE 1=1 from hubez_admin.EZ_RAT_TXN
<if test="custNm != null and custNm != ''"> where LAST_YN = 'Y'
AND eci.CUST_NM LIKE CONCAT('%',#{custNm},'%')
</if>
<if test="bizrno != null and bizrno != ''">
AND eci.BIZRNO LIKE CONCAT('%',#{bizrno},'%')
</if>
) A
JOIN
(SELECT MAX(COLEC_TMS) AS COLEC_TMS
,DATE_FORMAT(eud.USE_YM, '%Y-%m') AS USE_YM
,eud.SUBS_ID AS SUBS_ID
,eud.PROD_NM AS PROD_NM
,ROUND(IFNULL(eud.PROD_AMT,0)) AS PROD_AMT
,ROUND(SUM(IFNULL(eud.FX_LMT_AMT,0) + IFNULL(eud.CFWD_AMT,0))) AS START_AMT -- 시작금액 : 정액한도금액+이월금액
,ROUND(SUM(IFNULL(eud.FX_USE_AMT,0) + IFNULL(eud.CFWD_USE_AMT,0) + IFNULL(eud.MRT_USE_AMT,0))) AS USE_AMT -- 사용금액 : 정액사용금액 + 이월사용금액 + 종량사용금액
,ROUND(IFNULL(eud.CFWD_AMT,0)) AS CFWD_AMT -- 이월금액
,ROUND(IFNULL(eud.MRT_USE_AMT,0)) AS MRT_USE_AMT -- 종량금액
,ROUND(IFNULL(eud.EXTNC_AMT,0)) AS EXTNC_AMT -- 소멸금액 : 소멸처리금액
,ROUND(IFNULL((SELECT IFNULL(t2.RAT_AMT,0)
FROM hubez_admin.EZ_RAT_TXN t1
JOIN hubez_admin.EZ_RATTXN_DTL t2
ON t1.RAT_YM = t2.RAT_YM
AND t1.RAT_TMS = t2.RAT_TMS
WHERE t1.USE_YM = eud.USE_YM
AND t1.COLEC_TMS = eud.COLEC_TMS
AND t2.SUBS_ID = eud.SUBS_ID ),0)) AS BILLING_AMT -- 청구금액 : 과금금액
,SUM(IFNULL(eud.SMS_USE_CNT,0) + IFNULL(eud.LMS_USE_CNT,0) + IFNULL(eud.MMS_USE_CNT,0) + IFNULL(eud.ATLK_USE_CNT,0)) AS TOTAL_SND_CNT
,IFNULL(eud.SMS_USE_CNT,0) AS SMS_SND_CNT
,IFNULL(eud.LMS_USE_CNT,0) AS LMS_SND_CNT
,IFNULL(eud.MMS_USE_CNT,0) AS MMS_SND_CNT
,IFNULL(eud.ATLK_USE_CNT,0) AS ATLK_SND_CNT
FROM hubez_admin.EZ_UTXNCOLEC_DTL eud
WHERE 1=1
<![CDATA[ <![CDATA[
AND eud.USE_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d') and RAT_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d')
AND eud.USE_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH) AND RAT_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH)
]]> ]]>
GROUP BY eud.USE_YM, eud.SUBS_ID) B ) tms
ON A.SUBS_ID = B.SUBS_ID inner join hubez_admin.EZ_UTXNCOLEC_DTL eud
ORDER BY B.USE_YM DESC, B.SUBS_ID DESC on eud.USE_YM = tms.USE_YM
and tms.COLEC_TMS = eud.COLEC_TMS
where 1 =1
<![CDATA[
and eud.USE_YM >= STR_TO_DATE(CONCAT(#{startMonth},'01'),'%Y%m%d')
and eud.USE_YM < DATE_ADD(STR_TO_DATE(CONCAT(#{endMonth},'01'),'%Y%m%d'), INTERVAL 1 MONTH)
]]>
<if test="custNm != null and custNm != ''">
AND eud.CUST_NM LIKE CONCAT('%',#{custNm},'%')
</if>
<if test="bizrno != null and bizrno != ''">
AND eud.BIZRNO LIKE CONCAT('%',#{bizrno},'%')
</if>
ORDER BY eud.USE_YM DESC, eud.CUST_NM DESC
</select> </select>
</mapper> </mapper>

View File

@@ -330,7 +330,7 @@
) VALUES ) VALUES
<foreach collection="list" item="item" index="i" <foreach collection="list" item="item" index="i"
separator=","> separator=",">
(#{item.seqNo},#{item.seqNm}, #{item.word}, #{item.regId}, NOW() ) (#{item.seqNo}, #{item.word}, #{item.regId}, NOW() )
</foreach> </foreach>
</insert> </insert>

View File

@@ -7,15 +7,12 @@
parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.ProfileListReqDto" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.ProfileListReqDto"
resultType="int"> resultType="int">
/* sysMgt-mapper.xml(selectAdmUserTotalCnt) */ /* sysMgt-mapper.xml(selectAdmUserTotalCnt) */
SELECT select count(*)
COUNT(*) from hubez_common.EZ_KKO_CHNL ekc
FROM hubez_common.EZ_SVC_USER esu inner join hubez_common.EZ_SVC_USER esu
INNER JOIN hubez_common.EZ_KKO_CHNL ekc on esu.USER_SEQ = ekc.USER_SEQ
ON esu.USER_SEQ = ekc.USER_SEQ inner join hubez_common.EZ_CUST_INFO eci
AND ekc.MSGHB_STTUS_CD IN ('A','D') on eci.CUST_SEQ = esu.CUST_SEQ
INNER JOIN hubez_common.EZ_CUST_INFO eci
ON eci.CUST_SEQ = esu.CUST_SEQ
WHERE esu.USER_TP_CD ='01'
<include refid="profileListCondition"></include> <include refid="profileListCondition"></include>
</select> </select>
@@ -24,32 +21,38 @@
resultType="kr.co.uplus.ez.api.sendNumMgt.dto.ProfileInfo"> resultType="kr.co.uplus.ez.api.sendNumMgt.dto.ProfileInfo">
/* sysMgt-mapper.xml(selectProfileList) */ /* sysMgt-mapper.xml(selectProfileList) */
SELECT SELECT
@ROWNUM := @ROWNUM + 1 AS NO, @ROWNUM := @ROWNUM + 1 AS NO
A.* , A.custNm
, bRegNo
, sendProfile
, sendProfileKey
, DORM_YN
, case when A.MSGHB_STTUS_CD = 'D' then '삭제'
when A.DORM_YN = 'Y' then '휴면'
when A.BLCK_YN = 'Y' then '미사용'
when A.MSGHB_STTUS_CD = 'A' then '사용'
else '미사용'
end as stat
, DATE_FORMAT(A.REG_DT, '%Y-%m-%d') AS regDt
FROM FROM
( (
select eci.CUST_NM as custNm select eci.CUST_NM as custNm
, eci.BIZRNO as bRegNo , eci.BIZRNO as bRegNo
, ekc.CHNL_ID as sendProfile , ekc.CHNL_ID as sendProfile
, ekc.SNDRPROF_KEY as sendProfileKey , ekc.SNDRPROF_KEY as sendProfileKey
, ekc.DORM_YN , ekc.DORM_YN
, case when ekc.DORM_YN = 'Y' then '휴면' , ekc.MSGHB_STTUS_CD
when ekc.MSGHB_STTUS_CD = 'A' then '사용' , ekc.BLCK_YN
when ekc.MSGHB_STTUS_CD = 'D' then '삭제' , ekc.REG_DT
else '미사용' from hubez_common.EZ_KKO_CHNL ekc
end as stat inner join hubez_common.EZ_SVC_USER esu
, DATE_FORMAT(ekc.REG_DT, '%Y-%m-%d') AS regDt on esu.USER_SEQ = ekc.USER_SEQ
from hubez_common.EZ_SVC_USER esu inner join hubez_common.EZ_CUST_INFO eci
inner join hubez_common.EZ_KKO_CHNL ekc on eci.CUST_SEQ = esu.CUST_SEQ
on esu.USER_SEQ = ekc.USER_SEQ <include refid="profileListCondition"></include>
and ekc.MSGHB_STTUS_CD in ('A','D') ORDER BY ekc.REG_DT DESC
inner join hubez_common.EZ_CUST_INFO eci LIMIT #{page}, #{pagePerRows}
on eci.CUST_SEQ = esu.CUST_SEQ ) A, ( SELECT @ROWNUM := #{page} ) AS R
where esu.USER_TP_CD ='01'
<include refid="profileListCondition"></include>
ORDER BY ekc.REG_DT DESC
LIMIT #{page}, #{pagePerRows}) A,
( SELECT @ROWNUM := #{page} ) AS R
</select> </select>
<sql id="profileListCondition"> <sql id="profileListCondition">
@@ -57,19 +60,21 @@
<if test="searchType1 != null and searchType1 != ''"> <if test="searchType1 != null and searchType1 != ''">
<choose> <choose>
<when test='searchType1 == "A"'> <!-- 상태 사용--> <when test='searchType1 == "A"'> <!-- 상태 사용-->
AND MSGHB_STTUS_CD = 'A' AND ekc.MSGHB_STTUS_CD = 'A'
AND BLCK_YN = 'N' AND ekc.BLCK_YN = 'N'
AND DORM_YN = 'N' AND ekc.DORM_YN = 'N'
</when> </when>
<when test='searchType1 == "N"'> <!-- 상태 미사용--> <when test='searchType1 == "N"'> <!-- 상태 미사용-->
AND MSGHB_STTUS_CD = 'A' AND ekc.BLCK_YN = 'Y'
AND (BLCK_YN = 'Y' OR DORM_YN = 'Y') AND MSGHB_STTUS_CD != 'D'
AND ekc.DORM_YN != 'Y'
</when> </when>
<when test='searchType1 == "D"'> <!-- 상태 삭제--> <when test='searchType1 == "D"'> <!-- 상태 삭제-->
AND MSGHB_STTUS_CD = 'D' AND MSGHB_STTUS_CD = 'D'
</when> </when>
<when test='searchType1 == "H"'> <!-- 상태 휴면--> <when test='searchType1 == "H"'> <!-- 상태 휴면-->
AND DORM_YN = 'Y' AND DORM_YN = 'Y'
AND MSGHB_STTUS_CD != 'D'
</when> </when>
</choose> </choose>
</if> </if>
@@ -77,13 +82,13 @@
<if test='searchType2 != null and searchType2 != ""'> <if test='searchType2 != null and searchType2 != ""'>
<choose> <choose>
<when test='searchType2 == "custNm"'><!-- 검색조건 - 고객사명 --> <when test='searchType2 == "custNm"'><!-- 검색조건 - 고객사명 -->
and UPPER(eci.CUST_NM) LIKE CONCAT('%' , UPPER(#{searchText1}), '%') and eci.CUST_NM LIKE CONCAT('%' , #{searchText1}, '%')
</when> </when>
<when test='searchType2 == "bregNo"'><!-- 검색조건 - 사업자번호 --> <when test='searchType2 == "bregNo"'><!-- 검색조건 - 사업자번호 -->
and eci.BIZRNO = #{searchText1} and eci.BIZRNO like CONCAT('%', #{searchText1}, '%')
</when> </when>
<when test='searchType2 == "sendProfile"'><!-- 검색조건 - 발신프로필 --> <when test='searchType2 == "sendProfile"'><!-- 검색조건 - 발신프로필 -->
and ekc.CHNL_ID = #{searchText1} and ekc.CHNL_ID like CONCAT('%', #{searchText1}, '%')
</when> </when>
</choose> </choose>
</if> </if>
@@ -91,76 +96,58 @@
</sql> </sql>
<select id="selectSendNumberTotalCnt" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.SendNumberListReqDto" resultType="int"> <select id="selectSendNumberTotalCnt" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.SendNumberListReqDto" resultType="int">
/* sendNumMgt-mapper.xml(selectSendNumberTotalCnt) */ /* sendNumMgt-mapper.xml(selectSendNumberTotalCnt) */
SELECT SELECT count(*)
COUNT(*) from hubez_common.EZ_SVC_SNDRNO ess
FROM inner join hubez_common.EZ_SNDRNO_REG esr
hubez_common.EZ_CUST_INFO eci on esr.REG_REQ_NO = ess.REG_REQ_NO
INNER JOIN hubez_common.EZ_SVC_USER esu inner join hubez_common.EZ_SVC_USER esu
ON on esu.USER_SEQ = esr.USER_SEQ
eci.CUST_SEQ = esu.CUST_SEQ inner join hubez_common.EZ_CUST_INFO eci
INNER JOIN hubez_common.EZ_SNDRNO_REG esr on eci.CUST_SEQ = esu.CUST_SEQ
ON WHERE 1=1
esr.USER_SEQ = esu.USER_SEQ <include refid="numberListCondition"></include>
INNER JOIN hubez_common.EZ_SVC_SNDRNO ess
ON
esr.REG_REQ_NO = ess.REG_REQ_NO
WHERE 1=1
<include refid="numberListCondition"></include>
</select> </select>
<select id="selectSendNumberList" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.SendNumberListReqDto" resultType="kr.co.uplus.ez.api.sendNumMgt.dto.SendNumberInfo"> <select id="selectSendNumberList" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.SendNumberListReqDto" resultType="kr.co.uplus.ez.api.sendNumMgt.dto.SendNumberInfo">
/* sendNumMgt-mapper.xml(selectSendNumberList) */ /* sendNumMgt-mapper.xml(selectSendNumberList) */
SELECT SELECT
@ROWNUM := @ROWNUM + 1 AS NO, @ROWNUM := @ROWNUM + 1 AS NO
A.* , A.CUST_NM
FROM , REG_REQ_NO
( , A.USER_ID as ADMIN_ID
, A.RQTR_ID AS register
, A.BIZRNO AS bRegNo
, (SELECT DTL_CD_NM FROM hubez_common.EZ_CD_DTL WHERE GRP_CD = 'NMINEE_DIV_CD' AND DTL_CD = A.NMINEE_DIV_CD) AS NMINEE_DIV_CD
, (SELECT DTL_CD_NM FROM hubez_common.EZ_CD_DTL WHERE GRP_CD = 'INCH_DIV_CD' AND DTL_CD = A.INCH_DIV_CD) AS INCH_DIV_CD
, (SELECT DTL_CD_NM FROM hubez_common.EZ_CD_DTL WHERE GRP_CD = 'SNDRNO_STTUS_CD' AND DTL_CD = A.STTUS_CD) AS sttusCd
, A.SNDRNO AS SNDRNO
, A.SEQ_NO
, DATE_FORMAT(A.REG_DT, '%Y-%m-%d') AS REG_DT
FROM
(
SELECT SELECT
eci.CUST_NM , eci.CUST_NM
esr.REG_REQ_NO, , esr.REG_REQ_NO
(SELECT esu2.USER_ID FROM hubez_common.EZ_SVC_USER esu2 WHERE esu2.USER_SEQ = esu.PRNTS_USER_SEQ)AS ADMIN_ID, , esu.USER_ID
esr.REG_ID AS register, , esr.RQTR_ID
eci.BIZRNO AS bRegNo, , eci.BIZRNO
(SELECT , ess.NMINEE_DIV_CD
ecd.DTL_CD_NM , ess.INCH_DIV_CD
FROM , ess.STTUS_CD
hubez_common.EZ_CD_DTL ecd , ess.SNDRNO
WHERE , ess.SEQ_NO
ecd.GRP_CD = 'NMINEE_DIV_CD' , esr.REG_DT
AND ecd.DTL_CD = ess.NMINEE_DIV_CD) AS NMINEE_DIV_CD, from hubez_common.EZ_SVC_SNDRNO ess
(SELECT inner join hubez_common.EZ_SNDRNO_REG esr
ecd.DTL_CD_NM on esr.REG_REQ_NO = ess.REG_REQ_NO
FROM inner join hubez_common.EZ_SVC_USER esu
hubez_common.EZ_CD_DTL ecd on esu.USER_SEQ = esr.USER_SEQ
WHERE inner join hubez_common.EZ_CUST_INFO eci
ecd.GRP_CD = 'INCH_DIV_CD' on eci.CUST_SEQ = esu.CUST_SEQ
AND ecd.DTL_CD = ess.INCH_DIV_CD) AS INCH_DIV_CD,
(SELECT
ecd.DTL_CD_NM
FROM
hubez_common.EZ_CD_DTL ecd
WHERE
ecd.GRP_CD = 'SNDRNO_STTUS_CD'
AND ecd.DTL_CD = ess.STTUS_CD) AS sttusCd,
ess.SNDRNO AS SNDRNO,
ess.SEQ_NO,
DATE_FORMAT(esr.REG_DT, '%Y-%m-%d') AS REG_DT
FROM
hubez_common.EZ_CUST_INFO eci
INNER JOIN hubez_common.EZ_SVC_USER esu
ON
eci.CUST_SEQ = esu.CUST_SEQ
INNER JOIN hubez_common.EZ_SNDRNO_REG esr
ON
esr.USER_SEQ = esu.USER_SEQ
INNER JOIN hubez_common.EZ_SVC_SNDRNO ess
ON
esr.REG_REQ_NO = ess.REG_REQ_NO
WHERE 1=1 WHERE 1=1
<include refid="numberListCondition"></include> <include refid="numberListCondition"></include>
ORDER BY eci.BIZRNO ORDER BY ess.REG_DT , ess.REG_REQ_NO DESC
LIMIT #{page}, #{pagePerRows}) A, LIMIT #{page}, #{pagePerRows}) A, ( SELECT @ROWNUM := #{page} ) AS R
( SELECT @ROWNUM := #{page} ) AS R
</select> </select>
<sql id="numberListCondition"> <sql id="numberListCondition">
@@ -180,13 +167,13 @@
<if test='searchType4 != null and searchType4 != ""'> <if test='searchType4 != null and searchType4 != ""'>
<choose> <choose>
<when test='searchType4 == "bregNo"'><!-- 검색조건 - 사업자번호 --> <when test='searchType4 == "bregNo"'><!-- 검색조건 - 사업자번호 -->
AND eci.BIZRNO = #{searchText1} AND eci.BIZRNO like CONCAT('%', #{searchText1}, '%')
</when> </when>
<when test='searchType4 == "regNo"'><!-- 검색조건 - 발신번호 --> <when test='searchType4 == "regNo"'><!-- 검색조건 - 발신번호 -->
AND ess.SNDRNO = #{searchText1} AND ess.SNDRNO like CONCAT('%', #{searchText1}, '%')
</when> </when>
<when test='searchType4 == "custNm"'><!-- 검색조건 - 고객사명 --> <when test='searchType4 == "custNm"'><!-- 검색조건 - 고객사명 -->
AND UPPER(eci.CUST_NM) LIKE CONCAT('%' , UPPER(#{searchText1}), '%') AND eci.CUST_NM LIKE CONCAT('%' , #{searchText1}, '%')
</when> </when>
</choose> </choose>
</if> </if>
@@ -201,7 +188,8 @@
hubez_common.EZ_SVC_USER esu, hubez_common.EZ_CUST_INFO eci hubez_common.EZ_SVC_USER esu, hubez_common.EZ_CUST_INFO eci
WHERE WHERE
esu.CUST_SEQ = eci.CUST_SEQ esu.CUST_SEQ = eci.CUST_SEQ
AND esu.USER_ID = #{searchText1} AND esu.USER_TP_CD IN ('01', '03')
AND esu.USER_ID LIKE CONCAT('%' , #{searchText1}, '%')
</select> </select>
<select id="selectAdminList" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.SendAdminListReqDto" resultType="kr.co.uplus.ez.api.sendNumMgt.dto.SendAdminInfo"> <select id="selectAdminList" parameterType="kr.co.uplus.ez.api.sendNumMgt.dto.SendAdminListReqDto" resultType="kr.co.uplus.ez.api.sendNumMgt.dto.SendAdminInfo">
@@ -216,7 +204,8 @@
hubez_common.EZ_SVC_USER esu, hubez_common.EZ_CUST_INFO eci hubez_common.EZ_SVC_USER esu, hubez_common.EZ_CUST_INFO eci
WHERE WHERE
esu.CUST_SEQ = eci.CUST_SEQ esu.CUST_SEQ = eci.CUST_SEQ
AND esu.USER_ID = #{searchText1} AND esu.USER_TP_CD IN ('01', '03')
AND esu.USER_ID LIKE CONCAT('%' , #{searchText1}, '%')
</select> </select>
<select id="selectUserSeqByAdminId" parameterType="String" resultType="String"> <select id="selectUserSeqByAdminId" parameterType="String" resultType="String">

View File

@@ -68,10 +68,10 @@ SELECT
and UPPER(eci.CUST_NM) LIKE CONCAT('%' , UPPER(#{searchText1}) , '%') and UPPER(eci.CUST_NM) LIKE CONCAT('%' , UPPER(#{searchText1}) , '%')
</when> </when>
<when test='searchType2 == "bizNo"'><!-- 검색조건 - 사업자번호 --> <when test='searchType2 == "bizNo"'><!-- 검색조건 - 사업자번호 -->
and eci.BIZRNO = #{searchText1} AND eci.BIZRNO like CONCAT('%', #{searchText1}, '%')
</when> </when>
<when test='searchType2 == "authCd"'><!-- 검색조건 - 인증코드 --> <when test='searchType2 == "authCd"'><!-- 검색조건 - 인증코드 -->
and esu.AUTHCD_080 = #{searchText1} AND esu.AUTHCD_080 like CONCAT('%', #{searchText1}, '%')
</when> </when>
</choose> </choose>
</if> </if>

File diff suppressed because it is too large Load Diff

View File

@@ -323,6 +323,7 @@
<select id="selectAuthDetail" <select id="selectAuthDetail"
parameterType="kr.co.uplus.ez.api.sysMgt.dto.AuthDetailReqDto" parameterType="kr.co.uplus.ez.api.sysMgt.dto.AuthDetailReqDto"
resultType="kr.co.uplus.ez.api.sysMgt.dto.AuthDetail"> resultType="kr.co.uplus.ez.api.sysMgt.dto.AuthDetail">
/* sysMgt-mapper.xml(selectAuthDetail) */
SELECT SELECT
AUT_CD AS authCd AUT_CD AS authCd
,AUT_NM AS authNm ,AUT_NM AS authNm
@@ -338,6 +339,7 @@
<select id="selectAuthMemuList" <select id="selectAuthMemuList"
parameterType="kr.co.uplus.ez.api.sysMgt.dto.AuthDetailReqDto" parameterType="kr.co.uplus.ez.api.sysMgt.dto.AuthDetailReqDto"
resultType="kr.co.uplus.ez.api.sysMgt.dto.AuthMenu"> resultType="kr.co.uplus.ez.api.sysMgt.dto.AuthMenu">
/* sysMgt-mapper.xml(selectAuthMemuList) */
SELECT SELECT
T2.MENU_NO AS menuNo T2.MENU_NO AS menuNo
,T3.PRNTS_MENU_NO AS upperMenuNo ,T3.PRNTS_MENU_NO AS upperMenuNo
@@ -352,6 +354,23 @@
WHERE T2.AUT_CD = #{authCd} WHERE T2.AUT_CD = #{authCd}
</select> </select>
<select id="checkAdmin" parameterType="hashMap" resultType="int">
/* sysMgt-mapper.xml(checkAdminId) */
SELECT
COUNT(*)
FROM
hubez_admin.EZ_ADM_USER eau
WHERE 1=1
<if test="searchType != null and searchType != ''">
<if test="searchType == '01' ">
AND OPRTR_ID = #{adminId}
</if>
<if test="searchType == '02' ">
AND AUT_CD = #{authCd}
</if>
</if>
</select>
</mapper> </mapper>