월별 통계 엑셀 다운로드 수정

This commit is contained in:
USER
2022-09-21 09:08:17 +09:00
parent a3fb4e5a2c
commit eaf348b117
3 changed files with 103 additions and 23 deletions

View File

@@ -245,7 +245,53 @@ export default {
header: this.excelHeader,
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() {

View File

@@ -273,8 +273,52 @@ export default {
header: this.excelHeader,
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() {