mirror of
http://git.mhez-qa.uplus.co.kr/hubez/hubez-admin.git
synced 2025-12-06 20:08:41 +09:00
월별 통계 엑셀 다운로드 수정
This commit is contained in:
@@ -245,7 +245,53 @@ export default {
|
|||||||
header: this.excelHeader,
|
header: this.excelHeader,
|
||||||
dataOrder: 'header'
|
dataOrder: 'header'
|
||||||
};
|
};
|
||||||
xlsx.export(this.list, saveFileName, options).then(() => {
|
console.log(this.list);
|
||||||
|
// 일 별 통계 엑셀 데이터 만들기
|
||||||
|
|
||||||
|
var excelList = [];
|
||||||
|
for(var i=0; i<this.list.length; i++){
|
||||||
|
var excelData = {};
|
||||||
|
excelData.sumYmd = this.list[i].sumYmd;
|
||||||
|
// 성공 건수
|
||||||
|
var succCnt = this.list[i].succCnt;
|
||||||
|
var succRt = this.list[i].succRt;
|
||||||
|
succCnt = succCnt + '(' + succRt + '%)'
|
||||||
|
excelData.sndCnt = this.list[i].sndCnt;
|
||||||
|
excelData.succCnt = succCnt;
|
||||||
|
|
||||||
|
|
||||||
|
// SMS 성공 건수
|
||||||
|
var succCntS = this.list[i].succCntS;
|
||||||
|
var succRtS = this.list[i].succRtS;
|
||||||
|
succCntS = succCntS + '(' + succRtS + '%)'
|
||||||
|
excelData.sndCntS = this.list[i].sndCntS;
|
||||||
|
excelData.succCntS = succCntS;
|
||||||
|
|
||||||
|
// LMS 성공 건수
|
||||||
|
var succCntL = this.list[i].succCntL;
|
||||||
|
var succRtL = this.list[i].succRtL;
|
||||||
|
succCntL = succCntL + '(' + succRtL + '%)'
|
||||||
|
excelData.sndCntL = this.list[i].sndCntL;
|
||||||
|
excelData.succCntL = succCntL;
|
||||||
|
|
||||||
|
// MMS 성공 건수
|
||||||
|
var succCntM = this.list[i].succCntM;
|
||||||
|
var succRtM = this.list[i].succRtM;
|
||||||
|
succCntM = succCntM + '(' + succRtM + '%)'
|
||||||
|
excelData.sndCntM = this.list[i].sndCntM;
|
||||||
|
excelData.succCntM = succCntM;
|
||||||
|
|
||||||
|
// ALIMTALK 성공 건수
|
||||||
|
var succCntR = this.list[i].succCntR;
|
||||||
|
var succRtR = this.list[i].succRtR;
|
||||||
|
succCntR = succCntR + '(' + succRtR + '%)'
|
||||||
|
excelData.sndCntR = this.list[i].sndCntR;
|
||||||
|
excelData.succCntR = succCntR;
|
||||||
|
|
||||||
|
excelList.push(excelData);
|
||||||
|
}
|
||||||
|
|
||||||
|
xlsx.export(excelList, saveFileName, options).then(() => {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
getExcelHeader() {
|
getExcelHeader() {
|
||||||
|
|||||||
@@ -273,8 +273,52 @@ export default {
|
|||||||
header: this.excelHeader,
|
header: this.excelHeader,
|
||||||
dataOrder: 'header'
|
dataOrder: 'header'
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 월 별 통계 엑셀 데이터 만들기
|
||||||
|
var excelList = [];
|
||||||
|
for(var i=0; i<this.list.length; i++){
|
||||||
|
var excelData = {};
|
||||||
|
excelData.sumYm = this.list[i].sumYm;
|
||||||
|
// 성공 건수
|
||||||
|
var succCnt = this.list[i].succCnt;
|
||||||
|
var succRt = this.list[i].succRt;
|
||||||
|
succCnt = succCnt + '(' + succRt + '%)'
|
||||||
|
excelData.sndCnt = this.list[i].sndCnt;
|
||||||
|
excelData.succCnt = succCnt;
|
||||||
|
|
||||||
xlsx.export(this.list, saveFileName, options).then(() => {
|
|
||||||
|
// SMS 성공 건수
|
||||||
|
var succCntS = this.list[i].succCntS;
|
||||||
|
var succRtS = this.list[i].succRtS;
|
||||||
|
succCntS = succCntS + '(' + succRtS + '%)'
|
||||||
|
excelData.sndCntS = this.list[i].sndCntS;
|
||||||
|
excelData.succCntS = succCntS;
|
||||||
|
|
||||||
|
// LMS 성공 건수
|
||||||
|
var succCntL = this.list[i].succCntL;
|
||||||
|
var succRtL = this.list[i].succRtL;
|
||||||
|
succCntL = succCntL + '(' + succRtL + '%)'
|
||||||
|
excelData.sndCntL = this.list[i].sndCntL;
|
||||||
|
excelData.succCntL = succCntL;
|
||||||
|
|
||||||
|
// MMS 성공 건수
|
||||||
|
var succCntM = this.list[i].succCntM;
|
||||||
|
var succRtM = this.list[i].succRtM;
|
||||||
|
succCntM = succCntM + '(' + succRtM + '%)'
|
||||||
|
excelData.sndCntM = this.list[i].sndCntM;
|
||||||
|
excelData.succCntM = succCntM;
|
||||||
|
|
||||||
|
// ALIMTALK 성공 건수
|
||||||
|
var succCntR = this.list[i].succCntR;
|
||||||
|
var succRtR = this.list[i].succRtR;
|
||||||
|
succCntR = succCntR + '(' + succRtR + '%)'
|
||||||
|
excelData.sndCntR = this.list[i].sndCntR;
|
||||||
|
excelData.succCntR = succCntR;
|
||||||
|
|
||||||
|
excelList.push(excelData);
|
||||||
|
}
|
||||||
|
|
||||||
|
xlsx.export(excelList, saveFileName, options).then(() => {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
getExcelHeader() {
|
getExcelHeader() {
|
||||||
|
|||||||
@@ -673,20 +673,15 @@
|
|||||||
, t1.CUST_NM AS custNm
|
, t1.CUST_NM AS custNm
|
||||||
, t1.BIZRNO AS bizrno
|
, t1.BIZRNO AS bizrno
|
||||||
, (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) AS sndCnt
|
, (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) AS sndCnt
|
||||||
, (t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR) AS succCnt
|
, CONCAT((t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR),'(',(TRUNCATE((t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR) / (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) * 100, 2)),'%)') AS succCnt
|
||||||
, TRUNCATE((t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR) / (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) * 100, 2) as succRt
|
|
||||||
, t2.sndCntS
|
, t2.sndCntS
|
||||||
, t2.succCntS
|
, CONCAT(t2.succCntS, '(', t2.succRtS, '%)') AS succCntS
|
||||||
, t2.succRtS
|
|
||||||
, t2.sndCntL
|
, t2.sndCntL
|
||||||
, t2.succCntL
|
, CONCAT(t2.succCntL, '(', t2.succRtL, '%)') AS succCntL
|
||||||
, t2.succRtL
|
, t2.sndCntM
|
||||||
, t2.sndCntM
|
, CONCAT(t2.succCntM, '(', t2.succRtM, '%)') AS succCntM
|
||||||
, t2.succCntM
|
|
||||||
, t2.succRtM
|
|
||||||
, t2.sndCntR
|
, t2.sndCntR
|
||||||
, t2.succCntR
|
, CONCAT(t2.succCntR, '(', t2.succRtR, '%)') AS succCntR
|
||||||
, t2.succRtR
|
|
||||||
from (
|
from (
|
||||||
select SUM_YM
|
select SUM_YM
|
||||||
, USER_SEQ
|
, USER_SEQ
|
||||||
@@ -998,20 +993,15 @@
|
|||||||
, t1.CUST_NM AS CUST_NM
|
, t1.CUST_NM AS CUST_NM
|
||||||
, t1.BIZRNO AS BIZRNO
|
, t1.BIZRNO AS BIZRNO
|
||||||
, (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) AS SND_CNT
|
, (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) AS SND_CNT
|
||||||
, (t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR) AS SUCC_CNT
|
, CONCAT((t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR),'(',(TRUNCATE((t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR) / (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) * 100, 2)) , '%)') AS SUCC_CNT
|
||||||
, TRUNCATE((t2.succCntS + t2.succCntL + t2.succCntM + t2.succCntR) / (t2.sndCntS + t2.sndCntL + t2.sndCntM + t2.sndCntR) * 100, 2) as SUCC_RT
|
|
||||||
, t2.sndCntS as SND_CNT_S
|
, t2.sndCntS as SND_CNT_S
|
||||||
, t2.succCntS as SUCC_CNT_S
|
, CONCAT(t2.succCntS,'(', t2.succRtS, '%)') as SUCC_CNT_S
|
||||||
, t2.succRtS as SUCC_RT_S
|
|
||||||
, t2.sndCntL as SND_CNT_L
|
, t2.sndCntL as SND_CNT_L
|
||||||
, t2.succCntL as SUCC_CNT_L
|
, CONCAT(t2.succCntL, '(', t2.succRtL, '%)') as SUCC_CNT_L
|
||||||
, t2.succRtL as SUCC_RT_L
|
|
||||||
, t2.sndCntM as SND_CNT_M
|
, t2.sndCntM as SND_CNT_M
|
||||||
, t2.succCntM as SUCC_CNT_M
|
, CONCAT(t2.succCntM, '(', t2.succRtM, '%)') as SUCC_CNT_M
|
||||||
, t2.succRtM as SUCC_RT_M
|
|
||||||
, t2.sndCntR as SND_CNT_R
|
, t2.sndCntR as SND_CNT_R
|
||||||
, t2.succCntR as SUCC_CNT_R
|
, CONCAT(t2.succCntR, '(', t2.succRtR, '%)') as SUCC_CNT_R
|
||||||
, t2.succRtR as SUCC_RT_R
|
|
||||||
from (
|
from (
|
||||||
select SUM_YMD
|
select SUM_YMD
|
||||||
, USER_SEQ
|
, USER_SEQ
|
||||||
|
|||||||
Reference in New Issue
Block a user