|
|
@@ -346,7 +346,7 @@ JpcFlowTabSrv.prototype.createNew = function(){
|
|
|
}
|
|
|
}
|
|
|
};
|
|
|
- JpcFlowTabResult.setupAutoHeightData = function(bands, segIdx, rptTpl, dataObj, $CURRENT_RPT, defProperties) {
|
|
|
+ JpcFlowTabResult.setupAutoHeightData = function(bands, segIdx, rptTpl, dataObj, $CURRENT_RPT, defProperties, outputType) {
|
|
|
let me = this;
|
|
|
if (me.auto_height_fields_idx.length > 0) {
|
|
|
let CURRENT_FLOW_INFO = (me.isEx)?JV.NODE_FLOW_INFO_EX:JV.NODE_FLOW_INFO;
|
|
|
@@ -415,7 +415,7 @@ JpcFlowTabSrv.prototype.createNew = function(){
|
|
|
}
|
|
|
}
|
|
|
if (accAmt > rst) rst = accAmt;
|
|
|
- if (hasSplitStr) {
|
|
|
+ if (hasSplitStr && outputType !== JV.OUTPUT_TYPE_EXCEL) {
|
|
|
let newValArr = [];
|
|
|
for (let i = 0; i < values.length; i++) {
|
|
|
if (splitStrArr.indexOf(i) < 0) {
|
|
|
@@ -428,6 +428,7 @@ JpcFlowTabSrv.prototype.createNew = function(){
|
|
|
splitStrArr = [];
|
|
|
newValArr = [];
|
|
|
}
|
|
|
+ //备注: 如果outputType是excel类型,那么就只保留原始的分行符,无需介入分行,由excel本身去处理分行,只需要保留足够的空间即可。
|
|
|
}
|
|
|
}
|
|
|
return rst;
|
|
|
@@ -460,7 +461,7 @@ JpcFlowTabSrv.prototype.createNew = function(){
|
|
|
}
|
|
|
};
|
|
|
|
|
|
- JpcFlowTabResult.preSetupPages = function (rptTpl, dataObj, defProperties, option, $CURRENT_RPT, followTabEx) {
|
|
|
+ JpcFlowTabResult.preSetupPages = function (rptTpl, dataObj, defProperties, option, $CURRENT_RPT, followTabEx, outputType) {
|
|
|
//换一种思路来整理流水式数据
|
|
|
let me = this, rst = 1, counterRowRec = 0, counterRowRecEx = 0, maxRowRec = 1, pageIdx = 0, currentRecAmt = 0;
|
|
|
me.paging_option = option||JV.PAGING_OPTION_NORMAL;
|
|
|
@@ -576,7 +577,7 @@ JpcFlowTabSrv.prototype.createNew = function(){
|
|
|
grpPageInfo[JV.PROP_GRP_LINES] = me.group_lines_amt;
|
|
|
pageStatus[JV.STATUS_SEGMENT_START] = true;
|
|
|
private_resetBandArea();
|
|
|
- me.setupAutoHeightData(bands, segIdx, rptTpl, dataObj, $CURRENT_RPT, defProperties);
|
|
|
+ me.setupAutoHeightData(bands, segIdx, rptTpl, dataObj, $CURRENT_RPT, defProperties, outputType);
|
|
|
let threshold = 0;
|
|
|
currentRecAmt = 0;
|
|
|
counterRowRec = 0;
|
|
|
@@ -1257,13 +1258,13 @@ function combineAutoHeightCells(prepareObj, page, controls) {
|
|
|
rst.push(sameColCells[i].cellIdx); //记下Cell的位置,在函数外消除
|
|
|
//如果到了最后一条数据,得判断firstMergeCell是否满格(即数据是满的,有可能有些格数据也有折行但不是自动行高判断指标)
|
|
|
//不满格的cell的Vertical强制设置为 'center'
|
|
|
- if (i === sameColCells.length - 1 && validValueAmt !== fullValidValueAmt) {
|
|
|
+ if (i === sameColCells.length - 1 && validValueAmt !== fullValidValueAmt && (fullValidValueAmt / validValueAmt > 2.5) ) {
|
|
|
firstMergeCell[JV.PROP_CONTROL].VerticalForExcel = 'center';
|
|
|
}
|
|
|
} else {
|
|
|
//碰到新开始的自动行高行,判断原先的firstMergeCell是否满格(即数据是满的,有可能有些格数据也有折行但不是自动行高判断指标)
|
|
|
//不满格的cell的Vertical强制设置为 'center'
|
|
|
- if (validValueAmt !== fullValidValueAmt) {
|
|
|
+ if (validValueAmt !== fullValidValueAmt && (fullValidValueAmt / validValueAmt > 2.5)) {
|
|
|
firstMergeCell[JV.PROP_CONTROL].VerticalForExcel = 'center';
|
|
|
}
|
|
|
firstMergeCell = sameColCells[i].cell;
|