발송내역 수정

This commit is contained in:
USER
2022-07-28 17:16:59 +09:00
parent d5bf4444a3
commit f3fb920b35
7 changed files with 191 additions and 180 deletions

View File

@@ -7,7 +7,7 @@
</div>
<div class="table table_form">
<form action="" target="_blank" method="post" ref="form">
<form action="" target="_blank" method="get" ref="form">
<input type="hidden" name="svcUserId" id="svcUserId" v-model="svcUserId" />
<input type="hidden" name="ezSvcUserAuthKey" id="ezSvcUserAuthKey" v-model="ezSvcUserAuthKey" />
</form>
@@ -235,7 +235,7 @@ export default {
svcUserId: '',
ezSvcUserAuthKey: '',
homePageUrl: '',
isActive: true,
isActive: true
//applyTbStyle: 'cursor: default;',
};
},
@@ -256,10 +256,12 @@ export default {
created() {
if(this.$route.params.serviceId != null){
this.$store.commit('dataStore/updateUserId', this.$route.params.serviceId);
this.memberDetail(this.$route.params.serviceId);
this.userId = this.$route.params.serviceId;
this.memberDetail(this.$route.params.serviceId);
}else{
var userId = this.$store.getters["dataStore/getUserId"];
this.memberDetail(userId);
var userId2 = this.$store.getters["dataStore/getUserId"];
this.userId = userId2;
this.memberDetail(this.userId);
}
},
destroyed() {
@@ -302,7 +304,7 @@ export default {
valConfirm(props) {
this.$refs.commmonModal.confirmModalOpen(props);
},
async memberDetail(serviceId) {
async memberDetail(serviceId) {
this.row.userId = serviceId;
try {
const response = await custMgtApi.memberAdminDetail(this.row);
@@ -331,7 +333,7 @@ export default {
console.log('userTotalCnt:' + result.data.list.length);
this.totalItems = result.data.paging.totalCnt;
this.homePageUrl = result.data.homePageUrl;
this.ezSvcUserAuthKey = result.data.authKey;
this.ezSvcUserAuthKey = result.data.authKey;
}
} catch (error) {
console.log(error);
@@ -454,9 +456,9 @@ export default {
formReset() {
Object.assign(this.$data, this.$options.data());
},
homeLogin() {
homeLogin() {
this.$refs.form.action = this.homePageUrl;
this.svcUserId = this.userId;
this.svcUserId = this.userId;
this.$refs.form.submit();
},
confirmCalbackFnc(props) {

View File

@@ -135,13 +135,13 @@ export default {
this.$router.push({ name: 'updatePassword',params: {userId : this.userId}});
}else if(rsp.retCode == '4003') { // ID 조회 없음.
this.row.title = '로그인 실패';
this.row.msg1 = '등록되지 않은 아이디입니다.';
this.row.msg2 = '아이디를 다시 확인하세요';
this.row.msg1 = '아이디, 비밀번호를 확인해 주세요.';
this.$refs.commonModal.alertModalOpen(this.row);
} else if(rsp.retCode == '4004') { // ID/PWD 불일치
this.row.title = '비밀번호 오류';
this.row.msg1 = '비밀번호를 확인해주세요.';
//this.row.title = '비밀번호 오류';
//this.row.msg1 = '비밀번호를 확인해주세요.';
this.row.title = '로그인 실패';
this.row.msg1 = '아이디, 비밀번호를 확인해 주세요.';
this.$refs.commonModal.alertModalOpen(this.row);
} else if(rsp.retCode == '4005') { // ID/PWD 불일치 횟수초과로 계정 잠김 4005
this.row.title = '로그인 실패';

View File

@@ -9,8 +9,7 @@
<div class="search_wrap">
<div class="group">
<div class="input_box cal one essential">
<label for="right" class="label"><span>*</span>발송일</label>
<div class="term">
<label for="right" class="label"><span>*</span>발송일</label>
<span class="custom_input icon_date">
<vuejs-datepicker
:language="ko"
@@ -20,8 +19,7 @@
@selected="selectedStartDate(0)"
@closed="closeDate('start')"
></vuejs-datepicker>
</span>
</div>
</span>
</div>
<div class="select_box id">
<label for="right" class="label">요청채널</label>
@@ -50,7 +48,7 @@
<div class="input_box">
<label for="right" class="label">고객사명</label>
<input class="search-box" type="text" id="search" placeholder="검색어 입력" v-model.trim="grid.params.searchText3"
@keypress="onlyName" @input="onlyName" @keyup.enter="search" ref="_searchText3" maxlength="100">
@keypress="onlyText" @input="onlyText" @keyup.enter="search" ref="_searchText3" maxlength="100">
</div>
<button type="button" class="button grey" @click="search">조회</button>
</div>
@@ -173,17 +171,17 @@ export default {
columns: [
{name: 'no', header: 'NO', align: 'center', width: '5%'},
{name: '', header: '발송일자', align: 'left', width: '11%'},
{name: '', header: '고객사명', align: 'left', width: '9%'},
{name: '', header: '발송아이디(사용자ID)', align: 'center', width: '9%'},
{name: '', header: '수신번호', align: 'center', width: '11%'},
{name: '', header: '발신번호', align: 'center', width: '11%'},
{name: '', header: '요청채널', align: 'center', width: '5%'},
{name: '', header: '최종채널', align: 'center', width: '5%'},
{name: '', header: '이통사', align: 'center', width: '5%'},
{name: '', header: '결과(코드)', align: 'center', width: '9%'},
{name: '', header: '요청일시', align: 'center', width: '10%'},
{name: '', header: '완료일시', align: 'center', width: '10%'},
{name: 'sentDate', header: '발송일자', align: 'center', width: '11%'},
{name: 'custNm', header: '고객사명', align: 'center', width: '9%'},
{name: 'userId', header: '발송아이디(사용자ID)', align: 'center', width: '9%'},
{name: 'phone', header: '수신번호', align: 'center', width: '11%'},
{name: 'callbackNumber', header: '발신번호', align: 'center', width: '11%'},
{name: 'reqProduct', header: '요청채널', align: 'center', width: '5%'},
{name: 'doneCh', header: '최종채널', align: 'center', width: '5%'},
{name: 'doneTelco', header: '이통사', align: 'center', width: '5%'},
{name: 'doneCode', header: '결과(코드)', align: 'center', width: '9%'},
{name: 'reqDate', header: '요청일시', align: 'center', width: '10%'},
{name: 'doneDate', header: '완료일시', align: 'center', width: '10%'},
],
noDataStr: '검색 결과가 없습니다.',
@@ -252,8 +250,8 @@ export default {
methods: {
search: function (isKeep) {
if (this.initMode) {
this.grid.params.phone = 99999999999;
this.grid.params.callbackNumber = 99999999999;
this.grid.params.phone = '';
this.grid.params.callbackNumber = '';
} else {
if (this.doValidate()) {
this.grid.params.sentDate = moment(this.startDate).format('YYYYMMDD');

View File

@@ -95,7 +95,7 @@ public class CustMgtService {
@Value("${msghubez.homepage-url:https://mhez.uplus.co.kr}")
private String mailTempleteHomeUrl;
@Value("${msghubez.uri.homepageLogin: /auth/bo}")
@Value("${msghubez.uri.homepageLogin:/auth/bo}")
private String loginUri;
@Value("${msghubez.authKey: bohubez!@#$%}")

View File

@@ -296,7 +296,12 @@ public class LoginService {
}
String newPw = EncryptionUtil.getCustomSHA512(updatePasswordReqDto.getUserId(), updatePasswordReqDto.getNewPw());
String oldPw = user.getPwd();
if(oldPw.equals(newPw)) {
return new UpdatePasswordResDto(ApiResponseCode.CE_FAILED_TO_PW_CHANGE);
}
// 2. 비밀번호 변경 - update EZ_ADM_USER (비밀번호, 비밀번호변경일시)
AuthUser authUser = new AuthUser();
authUser.setOprtrId(updatePasswordReqDto.getUserId());

View File

@@ -42,7 +42,7 @@ mail:
templeteCode: E0005
msghubez:
hmoepage-url: https://mhez-dev.uplus.co.kr
homepage-url: https://mhez-dev.uplus.co.kr
api-url: https://api-int.mhez-dev.uplus.co.kr
applicationId: EZ_ADMIN
uri:

View File

@@ -4,157 +4,163 @@
<mapper namespace="kr.co.uplus.ez.api.mntrng.MntrngMapper">
<select id="selectSendListTotalCnt" parameterType="kr.co.uplus.ez.api.mntrng.dto.SendListReqDto" resultType="int">
SELECT
COUNT(*) AS TOTALCNT
FROM hubez_send.EZ_MSG_LOG eml
WHERE 1=1
AND eml.REQ_DATE BETWEEN STR_TO_DATE(#{sentDate}, '%Y%m%d') AND DATE_ADD(STR_TO_DATE(#{sentDate}, '%Y%m%d'), INTERVAL 1 DAY)
<if test='reqChennel != null and reqChennel != "" and reqChennel != "ALL"'>
AND eml.REQ_PRODUCT = #{reqChennel}
</if>
<if test='phone != null and phone != ""'>
AND eml.PHONE = #{phone}
</if>
<if test='callbackNumber != null and callbackNumber != ""'>
AND eml.CALLBACK_NUMBER = #{callbackNumber}
</if>
<if test='custNm != null and custNm != ""'>
AND eml.ORDER_ID IN (
SELECT
T3.ORDER_ID
FROM hubez_common.EZ_CUST_INFO T1
JOIN hubez_common.EZ_SVC_USER T2
ON T1.CUST_SEQ = T2.CUST_SEQ
JOIN hubez_admin.EZ_SNDDCT_REQ T3
ON T2.USER_SEQ = T3.SNDREQ_USER_SEQ
WHERE T1.CUST_NM LIKE CONCAT('%',#{custNm},'%'))
</if>
SELECT COUNT(*) AS TOTALCNT
FROM hubez_send.EZ_MSG_LOG eml
WHERE 1=1
AND eml.REQ_DATE<![CDATA[ >= ]]>STR_TO_DATE(#{sentDate}, '%Y%m%d')
AND eml.REQ_DATE<![CDATA[ < ]]>DATE_ADD(STR_TO_DATE(#{sentDate}, '%Y%m%d'), INTERVAL 1 DAY)
<if test='reqChennel != null and reqChennel != "" and reqChennel != "ALL"'>
AND eml.REQ_PRODUCT = #{reqChennel}
</if>
AND eml.PHONE = #{phone}
AND eml.CALLBACK_NUMBER = #{callbackNumber}
<if test='custNm != null and custNm != ""'>
AND EXISTS (
SELECT 1
FROM hubez_admin.EZ_SNDDCT_REQ esr
INNER JOIN hubez_common.EZ_SVC_USER esi
ON esi.USER_SEQ = esr.USER_SEQ
INNER JOIN hubez_common.EZ_CUST_INFO eci
ON eci.CUST_SEQ = esi.CUST_SEQ
AND eci.CUST_NM LIKE CONCAT('%',#{custNm},'%')
WHERE esr.ORDER_ID = eml.ORDER_ID
AND esr.ORDER_CRET_DT BETWEEN DATE_ADD(#{sentDate}, INTERVAL -3 DAY) AND DATE_ADD(#{sentDate}, INTERVAL 4 DAY)
)
</if>
</select>
<select id="selectSendList" parameterType="kr.co.uplus.ez.api.mntrng.dto.SendListReqDto" resultType="kr.co.uplus.ez.api.mntrng.dto.SendList">
SELECT
@ROWNUM := @ROWNUM + 1 AS NO,
A.*
FROM
(
SELECT
DATE_FORMAT(eml.REQ_DATE,'%Y-%m-%d') AS SENT_DATE
,(SELECT
esc.CUST_NM
FROM hubez_admin.EZ_SNDDCT_REQ esr
join hubez_common.EZ_SVC_USER esu
on esr.SNDREQ_USER_SEQ = esu.USER_SEQ
join hubez_common.EZ_CUST_INFO esc
on esu.CUST_SEQ = esc.CUST_SEQ
WHERE esr.ORDER_ID = eml.ORDER_ID) AS CUST_NM
,(SELECT
esu.USER_ID
FROM hubez_admin.EZ_SNDDCT_REQ esr
join hubez_common.EZ_SVC_USER esu
on esr.SNDREQ_USER_SEQ = esu.USER_SEQ
WHERE esr.ORDER_ID = eml.ORDER_ID) AS USER_ID
,eml.PHONE
,eml.CALLBACK_NUMBER
,eml.REQ_PRODUCT
,eml.DONE_CH
,eml.DONE_TELCO
,eml.DONE_CODE
,DATE_FORMAT(eml.REQ_DATE,'%Y-%m-%d %T') AS REQ_DATE
,DATE_FORMAT(eml.DONE_DATE,'%Y-%m-%d %T') AS DONE_DATE
FROM hubez_send.EZ_MSG_LOG eml
WHERE 1=1
AND eml.REQ_DATE BETWEEN STR_TO_DATE(#{sentDate}, '%Y%m%d') AND DATE_ADD(STR_TO_DATE(#{sentDate}, '%Y%m%d'), INTERVAL 1 DAY)
<if test='reqChennel != null and reqChennel != ""'>
AND eml.REQ_PRODUCT = #{reqChennel}
</if>
<if test='phone != null and phone != ""'>
AND eml.PHONE = #{phone}
</if>
<if test='callbackNumber != null and callbackNumber != ""'>
AND eml.CALLBACK_NUMBER = #{callbackNumber}
</if>
<if test='custNm != null and custNm != ""'>
AND eml.ORDER_ID IN (
SELECT
T3.ORDER_ID
FROM hubez_common.EZ_CUST_INFO T1
JOIN hubez_common.EZ_SVC_USER T2
ON T1.CUST_SEQ = T2.CUST_SEQ
JOIN hubez_admin.EZ_SNDDCT_REQ T3
ON T2.USER_SEQ = T3.SNDREQ_USER_SEQ
WHERE T1.CUST_NM = LIKE CONCAT('%',#{custNm},'%'))
</if>
ORDER BY eml.SENT_DATE DESC
LIMIT #{page}, #{pagePerRows}) A,
( SELECT @ROWNUM := #{page} ) AS R
SELECT
@ROWNUM := @ROWNUM + 1 AS NO,
A.*
FROM
(
SELECT
DATE_FORMAT(eml.REQ_DATE,'%Y-%m-%d') AS SENT_DATE
, CASE WHEN ORDER_ID in ('1', '2') THEN 'System'
ELSE (
SELECT esc.CUST_NM
FROM hubez_admin.EZ_SNDDCT_REQ esr
JOIN hubez_common.EZ_SVC_USER esu
ON esr.SNDREQ_USER_SEQ = esu.USER_SEQ
JOIN hubez_common.EZ_CUST_INFO esc
ON esu.CUST_SEQ = esc.CUST_SEQ
WHERE esr.ORDER_ID = eml.ORDER_ID
)
END AS CUST_NM
, CASE WHEN ORDER_ID IN ('1', '2') THEN 'System'
ELSE (
SELECT esu.USER_ID
FROM hubez_admin.EZ_SNDDCT_REQ esr
JOIN hubez_common.EZ_SVC_USER esu
ON esr.SNDREQ_USER_SEQ = esu.USER_SEQ
WHERE esr.ORDER_ID = eml.ORDER_ID
)
END AS USER_ID
,eml.PHONE
,eml.CALLBACK_NUMBER
,eml.REQ_PRODUCT
,eml.DONE_CH
,eml.DONE_TELCO
,eml.DONE_CODE
,DATE_FORMAT(eml.REQ_DATE,'%Y-%m-%d %T') AS REQ_DATE
,DATE_FORMAT(eml.DONE_DATE,'%Y-%m-%d %T') AS DONE_DATE
FROM hubez_send.EZ_MSG_LOG eml
WHERE 1=1
AND eml.REQ_DATE<![CDATA[ >= ]]>STR_TO_DATE(#{sentDate}, '%Y%m%d')
AND eml.REQ_DATE<![CDATA[ < ]]>DATE_ADD(STR_TO_DATE(#{sentDate}, '%Y%m%d'), INTERVAL 1 DAY)
<if test='reqChennel != null and reqChennel != ""'>
AND eml.REQ_PRODUCT = #{reqChennel}
</if>
AND eml.PHONE = #{phone}
AND eml.CALLBACK_NUMBER = #{callbackNumber}
<if test='custNm != null and custNm != ""'>
AND EXISTS (
SELECT 1
FROM hubez_admin.EZ_SNDDCT_REQ esr
INNER JOIN hubez_common.EZ_SVC_USER esi
ON esi.USER_SEQ = esr.USER_SEQ
INNER JOIN hubez_common.EZ_CUST_INFO eci
ON eci.CUST_SEQ = esi.CUST_SEQ
and eci.CUST_NM LIKE CONCAT('%',#{custNm},'%')
WHERE esr.ORDER_ID = eml.ORDER_ID
AND esr.ORDER_CRET_DT BETWEEN DATE_ADD(#{sentDate}, INTERVAL -3 DAY) AND DATE_ADD(#{sentDate}, INTERVAL 4 day)
)
</if>
ORDER BY eml.SENT_DATE DESC
LIMIT #{page}, #{pagePerRows}) A,
( SELECT @ROWNUM := #{page} ) AS R
</select>
<select id="selectLiveSendSttus" parameterType="kr.co.uplus.ez.api.mntrng.dto.LiveSendSttus" resultType="kr.co.uplus.ez.api.mntrng.dto.LiveSendSttus">
SELECT
IFNULL(SUM(T1.SEND_CNT + T2.FB_SEND_CNT), 0) AS SEND_CNT
,IFNULL(SUM(T1.SUCC_CNT+T2.FB_SUCC_CNT), 0) AS SUCC_CNT
,IFNULL(ROUND((SUM(T1.SUCC_CNT+T2.FB_SUCC_CNT) / SUM(T1.SEND_CNT+T2.FB_SEND_CNT) * 100), 2), 0) AS SUCC_RT
<if test='reqType != null and reqType != ""'>
<if test='reqType eq "M"'>
,DATE_FORMAT(DATE_ADD(NOW(), INTERVAL -10 MINUTE), '%Y.%m.%d %H:%i') AS START_TIME
SELECT IFNULL(SUM(SEND_CNT + FB_SEND_CNT), 0) AS SEND_CNT
, IFNULL(SUM(SUCC_CNT + FB_SUCC_CNT), 0) AS SUCC_CNT
, IFNULL(ROUND((SUM(SUCC_CNT + FB_SUCC_CNT) / SUM(SEND_CNT + FB_SEND_CNT) * 100), 2), 0) AS SUCC_RT
<if test='reqType != null and reqType != ""'>
<if test='reqType eq "M"'>
, DATE_FORMAT(DATE_ADD(NOW(), INTERVAL -10 MINUTE), '%Y.%m.%d %H:%i') AS START_TIME
</if>
<if test='reqType eq "H"'>
, DATE_FORMAT(DATE_ADD(NOW(), INTERVAL -1 HOUR), '%Y.%m.%d %H:%i') AS START_TIME
</if>
<if test='reqType eq "D"'>
, DATE_FORMAT(NOW(),'%Y.%m.%d 00:00') AS START_TIME
</if>
</if>
<if test='reqType eq "H"'>
,DATE_FORMAT(DATE_ADD(NOW(), INTERVAL -1 HOUR), '%Y.%m.%d %H:%i') AS START_TIME
, DATE_FORMAT(NOW(),'%Y.%m.%d %H:%i') AS END_TIME
FROM (
SELECT SUM(IFNULL(SEND_CNT,0)) AS SEND_CNT
, SUM(IFNULL(SUCC_CNT,0)) AS SUCC_CNT
, 0 as FB_SEND_CNT
, 0 as FB_SUCC_CNT
FROM hubez_common.EZ_WEB_MSG
WHERE 1=1
AND CH_STR = 'SMS'
<if test='reqType != null and reqType != ""'>
<if test='reqType eq "M"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -10 MINUTE)
]]>
</if>
<if test='reqType eq "H"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -1 HOUR)
]]>
</if>
<if test='reqType eq "D"'>
<![CDATA[
AND REQ_DT >= STR_TO_DATE(DATE_FORMAT(NOW(),'%Y%m%d'), '%Y%m%d')
]]>
</if>
</if>
GROUP BY CH_STR
union all
SELECT 0 AS SEND_CNT
, 0 AS SUCC_CNT
, SUM(IFNULL(FB_SUCC_CNT,0)+IFNULL(FB_FAIL_CNT,0)) AS FB_SEND_CNT
, SUM(IFNULL(FB_SUCC_CNT,0)) AS FB_SUCC_CNT
FROM hubez_common.EZ_WEB_MSG
WHERE 1=1
AND FB_CH_STR = 'SMS'
<if test='reqType != null and reqType != ""'>
<if test='reqType eq "M"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -10 MINUTE)
]]>
</if>
<if test='reqType eq "H"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -1 HOUR)
]]>
</if>
<if test='reqType eq "D"'>
<![CDATA[
AND REQ_DT >= STR_TO_DATE(DATE_FORMAT(NOW(),'%Y%m%d'), '%Y%m%d')
]]>
</if>
</if>
<if test='reqType eq "D"'>
,DATE_FORMAT(NOW(),'%Y.%m.%d 00:00') AS START_TIME
</if>
</if>
,DATE_FORMAT(NOW(),'%Y.%m.%d %H:%i') AS END_TIME
FROM
(SELECT
SUM(IFNULL(SEND_CNT,0)) AS SEND_CNT
,SUM(IFNULL(SUCC_CNT,0)) AS SUCC_CNT
FROM hubez_common.EZ_WEB_MSG
WHERE 1=1
AND CH_STR = #{chStr}
<if test='reqType != null and reqType != ""'>
<if test='reqType eq "M"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -10 MINUTE)
]]>
</if>
<if test='reqType eq "H"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -1 HOUR)
]]>
</if>
<if test='reqType eq "D"'>
<![CDATA[
AND REQ_DT >= STR_TO_DATE(DATE_FORMAT(NOW(),'%Y%m%d'), '%Y%m%d')
]]>
</if>
</if>
GROUP BY CH_STR) T1,
(SELECT
SUM(IFNULL(FB_SUCC_CNT,0)+IFNULL(FB_FAIL_CNT,0)) AS FB_SEND_CNT
,SUM(IFNULL(FB_SUCC_CNT,0)) AS FB_SUCC_CNT
FROM hubez_common.EZ_WEB_MSG
WHERE 1=1
AND FB_CH_STR = #{chStr}
<if test='reqType != null and reqType != ""'>
<if test='reqType eq "M"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -10 MINUTE)
]]>
</if>
<if test='reqType eq "H"'>
<![CDATA[
AND REQ_DT > DATE_ADD(NOW(), INTERVAL -1 HOUR)
]]>
</if>
<if test='reqType eq "D"'>
<![CDATA[
AND REQ_DT >= STR_TO_DATE(DATE_FORMAT(NOW(),'%Y%m%d'), '%Y%m%d')
]]>
</if>
</if>
GROUP BY FB_CH_STR) T2
</select>
GROUP BY FB_CH_STR
) T
</select>
</mapper>