我是Hybris的新手。到目前为止,这就是我要提出的:
PdfDocument pdf = new PdfDocument(new com.itextpdf.kernel.pdf.PdfWriter(dest));
PdfDocument sourcePdf = new PdfDocument(new PdfReader(SRC1));
//Original page
PdfPage origPage = sourcePdf.getPage(1);
com.itextpdf.kernel.geom.Rectangle orig = origPage.getPageSize();
PdfFormXObject pageCopy = origPage.copyAsFormXObject(pdf);
//N-up page
PageSize nUpPageSize = PageSize.A4.rotate();
PdfPage page = pdf.addNewPage(nUpPageSize);
PdfCanvas canvas = new PdfCanvas(page);
AffineTransform transformationMatrix = AffineTransform.getScaleInstance(
nUpPageSize.getWidth() / orig.getWidth() / 2f,
nUpPageSize.getHeight() / orig.getHeight() / 2f);
canvas.concatMatrix(transformationMatrix);
//Add pages to N-up page
canvas.addXObject(pageCopy, 0, orig.getHeight());
canvas.addXObject(pageCopy, orig.getWidth(), orig.getHeight());
// close the documents
pdf.close();
sourcePdf.close();
看起来不错,但是不起作用。非常感谢您的帮助
答案 0 :(得分:1)
$catalog
未定义,您已经定义了版本。
答案 1 :(得分:0)
在{p.catalog} = {}上从{genericvariantproduct中选择{p.pk}作为p join catalogVersion作为cv