IDEMPIERE-4667 Project can not be printed using template print format (#550)
This commit is contained in:
parent
2dbbc93485
commit
72d66b8868
|
@ -53,6 +53,7 @@ import org.compiere.model.MClientInfo;
|
|||
import org.compiere.model.MQuery;
|
||||
import org.compiere.model.MSysConfig;
|
||||
import org.compiere.model.MTable;
|
||||
import org.compiere.model.PO;
|
||||
import org.compiere.model.PrintInfo;
|
||||
import org.compiere.print.ArchiveEngine;
|
||||
import org.compiere.print.CPaper;
|
||||
|
@ -69,6 +70,7 @@ import org.compiere.print.util.SerializableMatrix;
|
|||
import org.compiere.print.util.SerializableMatrixImpl;
|
||||
import org.compiere.report.MReportLine;
|
||||
import org.compiere.util.CLogger;
|
||||
import org.compiere.util.CacheMgt;
|
||||
import org.compiere.util.DB;
|
||||
import org.compiere.util.DisplayType;
|
||||
import org.compiere.util.Env;
|
||||
|
@ -1649,8 +1651,17 @@ public class LayoutEngine implements Pageable, Printable, Doc
|
|||
additionalLines.put(Integer.valueOf(col), Integer.valueOf(item.getBelowColumn()-1));
|
||||
if (!item.isSuppressNull())
|
||||
{
|
||||
if (item.is_Immutable())
|
||||
item = new MPrintFormatItem(item);
|
||||
item.setIsSuppressNull(true); // display size will be set to 0 in TableElement
|
||||
item.saveEx();
|
||||
try {
|
||||
//this can be tenant or system print format
|
||||
PO.setCrossTenantSafe();
|
||||
item.saveEx();
|
||||
} finally {
|
||||
PO.clearCrossTenantSafe();
|
||||
}
|
||||
CacheMgt.get().reset(MPrintFormat.Table_Name, format.get_ID());
|
||||
}
|
||||
}
|
||||
columnHeader[col] = new ValueNamePair(item.getColumnName(),
|
||||
|
|
Loading…
Reference in New Issue