|
@@ -587,9 +587,10 @@ let zTreeOprObj = {
|
|
|
params.sum_rpt_names = bill_rpt_names.concat(glj_rpt_names);
|
|
params.sum_rpt_names = bill_rpt_names.concat(glj_rpt_names);
|
|
|
params.rpt_names = rpt_names;
|
|
params.rpt_names = rpt_names;
|
|
|
params.isOneSheet = true;
|
|
params.isOneSheet = true;
|
|
|
-
|
|
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
CommonAjax.postEx("report_api/createExcelFiles", params, WAIT_TIME_EXPORT, true, function(result){
|
|
CommonAjax.postEx("report_api/createExcelFiles", params, WAIT_TIME_EXPORT, true, function(result){
|
|
|
if (result) {
|
|
if (result) {
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let uuIdUrls = [];
|
|
let uuIdUrls = [];
|
|
|
for (let uuIdObj of result) {
|
|
for (let uuIdObj of result) {
|
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + uuIdObj.uuid + "/" + stringUtil.replaceAll(uuIdObj.reportName, "#", "_") + "/xlsx";
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + uuIdObj.uuid + "/" + stringUtil.replaceAll(uuIdObj.reportName, "#", "_") + "/xlsx";
|
|
@@ -597,9 +598,17 @@ let zTreeOprObj = {
|
|
|
}
|
|
}
|
|
|
downloadReport(uuIdUrls);
|
|
downloadReport(uuIdUrls);
|
|
|
} else {
|
|
} else {
|
|
|
- //
|
|
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
}
|
|
}
|
|
|
- }, null, null
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(failRst);
|
|
|
|
|
+ },
|
|
|
|
|
+ function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(exceptionRst);
|
|
|
|
|
+ }
|
|
|
);
|
|
);
|
|
|
},
|
|
},
|
|
|
requestSumAndNormalRptForAllInOneExcel: function () {
|
|
requestSumAndNormalRptForAllInOneExcel: function () {
|
|
@@ -608,17 +617,26 @@ let zTreeOprObj = {
|
|
|
rptControlObj.getTplIdsCommon(refRptTplIds, refBillSumPrjsIds, refGljSumPrjsIds, null, null, null);
|
|
rptControlObj.getTplIdsCommon(refRptTplIds, refBillSumPrjsIds, refGljSumPrjsIds, null, null, null);
|
|
|
let params = rptControlObj.creatCommonExportParam(refRptTplIds, refBillSumPrjsIds, refGljSumPrjsIds);
|
|
let params = rptControlObj.creatCommonExportParam(refRptTplIds, refBillSumPrjsIds, refGljSumPrjsIds);
|
|
|
params.rptName = orgRptName;
|
|
params.rptName = orgRptName;
|
|
|
-
|
|
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
CommonAjax.postEx("report_api/createExcelFilesInOneBook", params, WAIT_TIME_EXPORT, true, function(result){
|
|
CommonAjax.postEx("report_api/createExcelFilesInOneBook", params, WAIT_TIME_EXPORT, true, function(result){
|
|
|
if (result) {
|
|
if (result) {
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let uuIdUrls = [];
|
|
let uuIdUrls = [];
|
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + result.uuid + "/" + stringUtil.replaceAll(result.reportName, "#", "_") + "/xlsx";
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + result.uuid + "/" + stringUtil.replaceAll(result.reportName, "#", "_") + "/xlsx";
|
|
|
uuIdUrls.push(uuIdUrl);
|
|
uuIdUrls.push(uuIdUrl);
|
|
|
downloadReport(uuIdUrls);
|
|
downloadReport(uuIdUrls);
|
|
|
} else {
|
|
} else {
|
|
|
- //
|
|
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
}
|
|
}
|
|
|
- }, null, null
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(failRst);
|
|
|
|
|
+ },
|
|
|
|
|
+ function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(exceptionRst);
|
|
|
|
|
+ }
|
|
|
);
|
|
);
|
|
|
},
|
|
},
|
|
|
showPage: function (pageNum, canvas) {
|
|
showPage: function (pageNum, canvas) {
|
|
@@ -759,17 +777,26 @@ let rptControlObj = {
|
|
|
if (zTreeOprObj.selectedPrjIDs.length > 0 && (refBillSumPrjsIds.length > 0 || refGljSumPrjsIds.length > 0)) {
|
|
if (zTreeOprObj.selectedPrjIDs.length > 0 && (refBillSumPrjsIds.length > 0 || refGljSumPrjsIds.length > 0)) {
|
|
|
let params = rptControlObj.creatCommonExportParam(refRptTplIds, refBillSumPrjsIds, refGljSumPrjsIds);
|
|
let params = rptControlObj.creatCommonExportParam(refRptTplIds, refBillSumPrjsIds, refGljSumPrjsIds);
|
|
|
params.rptName = orgRptName;
|
|
params.rptName = orgRptName;
|
|
|
-
|
|
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
CommonAjax.postEx("report_api/createExcelFilesInOneBook", params, WAIT_TIME_EXPORT, true, function(result){
|
|
CommonAjax.postEx("report_api/createExcelFilesInOneBook", params, WAIT_TIME_EXPORT, true, function(result){
|
|
|
if (result) {
|
|
if (result) {
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let uuIdUrls = [];
|
|
let uuIdUrls = [];
|
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + result.uuid + "/" + stringUtil.replaceAll(result.reportName, "#", "_") + "/xlsx";
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + result.uuid + "/" + stringUtil.replaceAll(result.reportName, "#", "_") + "/xlsx";
|
|
|
uuIdUrls.push(uuIdUrl);
|
|
uuIdUrls.push(uuIdUrl);
|
|
|
downloadReport(uuIdUrls);
|
|
downloadReport(uuIdUrls);
|
|
|
} else {
|
|
} else {
|
|
|
- //
|
|
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
}
|
|
}
|
|
|
- }, null, null
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(failRst);
|
|
|
|
|
+ },
|
|
|
|
|
+ function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(exceptionRst);
|
|
|
|
|
+ }
|
|
|
);
|
|
);
|
|
|
} else {
|
|
} else {
|
|
|
if (refBillSumPrjsIds.length > 0 || refGljSumPrjsIds.length > 0) {
|
|
if (refBillSumPrjsIds.length > 0 || refGljSumPrjsIds.length > 0) {
|
|
@@ -788,16 +815,26 @@ let rptControlObj = {
|
|
|
params.orientation = ((zTreeOprObj.checkedRptTplNodes.length > 1)?null:me.getCurrentOrientation());
|
|
params.orientation = ((zTreeOprObj.checkedRptTplNodes.length > 1)?null:me.getCurrentOrientation());
|
|
|
params.custCfg = zTreeOprObj.reportPageCfg;
|
|
params.custCfg = zTreeOprObj.reportPageCfg;
|
|
|
params.option = "normal";
|
|
params.option = "normal";
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
CommonAjax.postEx("report_api/createExcelFilesInOneBook", params, WAIT_TIME_EXPORT, true, function(result){
|
|
CommonAjax.postEx("report_api/createExcelFilesInOneBook", params, WAIT_TIME_EXPORT, true, function(result){
|
|
|
if (result) {
|
|
if (result) {
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let uuIdUrls = [];
|
|
let uuIdUrls = [];
|
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + result.uuid + "/" + stringUtil.replaceAll(result.reportName, "#", "_") + "/xlsx";
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + result.uuid + "/" + stringUtil.replaceAll(result.reportName, "#", "_") + "/xlsx";
|
|
|
uuIdUrls.push(uuIdUrl);
|
|
uuIdUrls.push(uuIdUrl);
|
|
|
downloadReport(uuIdUrls);
|
|
downloadReport(uuIdUrls);
|
|
|
} else {
|
|
} else {
|
|
|
- //
|
|
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
}
|
|
}
|
|
|
- }, null, null
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(failRst);
|
|
|
|
|
+ },
|
|
|
|
|
+ function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(exceptionRst);
|
|
|
|
|
+ }
|
|
|
);
|
|
);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -816,8 +853,10 @@ let rptControlObj = {
|
|
|
params.rpt_names = rpt_names;
|
|
params.rpt_names = rpt_names;
|
|
|
params.isOneSheet = true;
|
|
params.isOneSheet = true;
|
|
|
params.rptName = projectObj.project.projectInfo.name;
|
|
params.rptName = projectObj.project.projectInfo.name;
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
CommonAjax.postEx("report_api/createExcelFiles", params, WAIT_TIME_EXPORT, true, function(result){
|
|
CommonAjax.postEx("report_api/createExcelFiles", params, WAIT_TIME_EXPORT, true, function(result){
|
|
|
if (result) {
|
|
if (result) {
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let uuIdUrls = [];
|
|
let uuIdUrls = [];
|
|
|
for (let uuIdObj of result) {
|
|
for (let uuIdObj of result) {
|
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + uuIdObj.uuid + "/" + stringUtil.replaceAll(uuIdObj.reportName, "#", "_") + "/xlsx";
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + uuIdObj.uuid + "/" + stringUtil.replaceAll(uuIdObj.reportName, "#", "_") + "/xlsx";
|
|
@@ -825,9 +864,17 @@ let rptControlObj = {
|
|
|
}
|
|
}
|
|
|
downloadReport(uuIdUrls);
|
|
downloadReport(uuIdUrls);
|
|
|
} else {
|
|
} else {
|
|
|
- //
|
|
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
}
|
|
}
|
|
|
- }, null, null
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(failRst);
|
|
|
|
|
+ },
|
|
|
|
|
+ function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(exceptionRst);
|
|
|
|
|
+ }
|
|
|
);
|
|
);
|
|
|
} else {
|
|
} else {
|
|
|
if (refBillSumPrjsIds.length > 0 || refGljSumPrjsIds.length > 0) {
|
|
if (refBillSumPrjsIds.length > 0 || refGljSumPrjsIds.length > 0) {
|
|
@@ -847,8 +894,10 @@ let rptControlObj = {
|
|
|
params.isOneSheet = true;
|
|
params.isOneSheet = true;
|
|
|
params.custCfg = zTreeOprObj.reportPageCfg;
|
|
params.custCfg = zTreeOprObj.reportPageCfg;
|
|
|
params.option = "normal";
|
|
params.option = "normal";
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
CommonAjax.postEx("report_api/createExcelFiles", params, WAIT_TIME_EXPORT, true, function(result){
|
|
CommonAjax.postEx("report_api/createExcelFiles", params, WAIT_TIME_EXPORT, true, function(result){
|
|
|
if (result) {
|
|
if (result) {
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let uuIdUrls = [];
|
|
let uuIdUrls = [];
|
|
|
for (let uuIdObj of result) {
|
|
for (let uuIdObj of result) {
|
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + uuIdObj.uuid + "/" + stringUtil.replaceAll(uuIdObj.reportName, "#", "_") + "/xlsx";
|
|
let uuIdUrl = "/report_api/getFileByUUID/" + uuIdObj.uuid + "/" + stringUtil.replaceAll(uuIdObj.reportName, "#", "_") + "/xlsx";
|
|
@@ -856,9 +905,17 @@ let rptControlObj = {
|
|
|
}
|
|
}
|
|
|
downloadReport(uuIdUrls);
|
|
downloadReport(uuIdUrls);
|
|
|
} else {
|
|
} else {
|
|
|
- //
|
|
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
}
|
|
}
|
|
|
- }, null, null
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(failRst);
|
|
|
|
|
+ },
|
|
|
|
|
+ function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
|
|
+ console.log(exceptionRst);
|
|
|
|
|
+ }
|
|
|
);
|
|
);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -954,6 +1011,7 @@ let rptControlObj = {
|
|
|
},
|
|
},
|
|
|
getPDFPre: function () {
|
|
getPDFPre: function () {
|
|
|
let me = rptControlObj;
|
|
let me = rptControlObj;
|
|
|
|
|
+ $.bootstrapLoading.start();
|
|
|
if (rptTplObj.pdfFont['SmartSimsun'].length === 2) {
|
|
if (rptTplObj.pdfFont['SmartSimsun'].length === 2) {
|
|
|
me.getPDFEx();
|
|
me.getPDFEx();
|
|
|
} else {
|
|
} else {
|
|
@@ -981,6 +1039,7 @@ let rptControlObj = {
|
|
|
params.rptName = projectObj.project.projectInfo.name;
|
|
params.rptName = projectObj.project.projectInfo.name;
|
|
|
CommonAjax.postEx("report_api/getMultiReports", params, 30000, true,
|
|
CommonAjax.postEx("report_api/getMultiReports", params, 30000, true,
|
|
|
function(result){
|
|
function(result){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let pageSize = rptControlObj.getCurrentPageSize();
|
|
let pageSize = rptControlObj.getCurrentPageSize();
|
|
|
for (let idx = 0; idx < result.length; idx++) {
|
|
for (let idx = 0; idx < result.length; idx++) {
|
|
|
let pageData = result[idx];
|
|
let pageData = result[idx];
|
|
@@ -988,9 +1047,11 @@ let rptControlObj = {
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
function(failRst){
|
|
function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
console.log(failRst);
|
|
console.log(failRst);
|
|
|
},
|
|
},
|
|
|
function(exceptionRst){
|
|
function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
console.log(exceptionRst);
|
|
console.log(exceptionRst);
|
|
|
}
|
|
}
|
|
|
);
|
|
);
|
|
@@ -1014,6 +1075,7 @@ let rptControlObj = {
|
|
|
params.option = "normal";
|
|
params.option = "normal";
|
|
|
CommonAjax.postEx("report_api/getMultiReports", params, 30000, true,
|
|
CommonAjax.postEx("report_api/getMultiReports", params, 30000, true,
|
|
|
function(result){
|
|
function(result){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
let pageSize = rptControlObj.getCurrentPageSize();
|
|
let pageSize = rptControlObj.getCurrentPageSize();
|
|
|
for (let idx = 0; idx < result.length; idx++) {
|
|
for (let idx = 0; idx < result.length; idx++) {
|
|
|
let pageData = result[idx];
|
|
let pageData = result[idx];
|
|
@@ -1021,9 +1083,11 @@ let rptControlObj = {
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
function(failRst){
|
|
function(failRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
console.log(failRst);
|
|
console.log(failRst);
|
|
|
},
|
|
},
|
|
|
function(exceptionRst){
|
|
function(exceptionRst){
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
console.log(exceptionRst);
|
|
console.log(exceptionRst);
|
|
|
}
|
|
}
|
|
|
);
|
|
);
|
|
@@ -1031,6 +1095,7 @@ let rptControlObj = {
|
|
|
//这个分支是为了减少请求,用户已经点过的表,又没有勾选,那么就直接导出成PDF
|
|
//这个分支是为了减少请求,用户已经点过的表,又没有勾选,那么就直接导出成PDF
|
|
|
let pageSize = rptControlObj.getCurrentPageSize();
|
|
let pageSize = rptControlObj.getCurrentPageSize();
|
|
|
let pageData = zTreeOprObj.currentRptPageRst;
|
|
let pageData = zTreeOprObj.currentRptPageRst;
|
|
|
|
|
+ $.bootstrapLoading.end();
|
|
|
JpcJsPDFHelper.outputAsPdf(pageData, pageSize, rpt_names[0]);
|
|
JpcJsPDFHelper.outputAsPdf(pageData, pageSize, rpt_names[0]);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|