mirror of
http://git.mhez-qa.uplus.co.kr/hubez/hubez-admin.git
synced 2025-12-08 21:42:10 +09:00
엑셀 다운로드시 Entity코드 변환되어 노출될 수 있도록 수정
This commit is contained in:
@@ -328,6 +328,13 @@ export default {
|
||||
response = await custMgtApi.subsListExcel(params);
|
||||
|
||||
const result = response.data;
|
||||
// entity code 변환
|
||||
result.data.list = result.data.list.map((item) => {
|
||||
return {
|
||||
...item,
|
||||
custNm: this.fromHtmlEntities(item.custNm)
|
||||
}
|
||||
});
|
||||
if (result != null && result.retCode == "0000") {
|
||||
return result.data;
|
||||
} else {
|
||||
@@ -349,6 +356,13 @@ export default {
|
||||
const saveFileName = `청약고객정보_${today}.xls`;
|
||||
|
||||
const data = await this.getExcelDataDown();
|
||||
if (!data) {
|
||||
this.row.title = '청약고객관리';
|
||||
this.row.msg1 = '엑셀 다운로드가 실패해습니다.';
|
||||
this.$refs.commmonModal.alertModalOpen(this.row);
|
||||
return false;
|
||||
}
|
||||
|
||||
let options = {
|
||||
header: this.excelHeader,
|
||||
dataOrder: 'header'
|
||||
@@ -410,6 +424,11 @@ export default {
|
||||
let initStartDate = new Date(setYear, 0, 1);
|
||||
this.startDate = initStartDate;
|
||||
},
|
||||
fromHtmlEntities(str) {
|
||||
return (str + '').replace(/&#\d+;/gm, function (s) {
|
||||
return String.fromCharCode(s.match(/\d+/gm)[0]);
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
Reference in New Issue
Block a user