@measurequick/measurequick-report-generator 1.2.118 → 1.2.119
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -101,13 +101,12 @@ export async function getReport(payload) {
|
|
|
101
101
|
let correctiveMeasuresBase64 = await correctiveMeasures.getReport(payload);
|
|
102
102
|
const correctiveMeasuresDoc = correctiveMeasuresBase64 ? await PDFDocument.load(util._base64ToArrayBuffer(correctiveMeasuresBase64)) : false;
|
|
103
103
|
const [_correctiveMeasuresDoc] = correctiveMeasuresDoc ? await coreDoc.copyPages(correctiveMeasuresDoc, [0]) : false;
|
|
104
|
-
console.log(_correctiveMeasuresDoc);
|
|
105
104
|
if (correctiveMeasuresDoc.getPages().length > 1) {
|
|
106
105
|
const [_correctiveMeasuresDocPage2] = correctiveMeasuresDoc ? await coreDoc.copyPages(correctiveMeasuresDoc, [1]) : false;
|
|
107
106
|
console.log(_correctiveMeasuresDocPage2);
|
|
108
|
-
if (_correctiveMeasuresDoc && _correctiveMeasuresDocPage2) _correctiveMeasuresDoc
|
|
107
|
+
if (_correctiveMeasuresDoc && _correctiveMeasuresDocPage2) _correctiveMeasuresDoc = [_correctiveMeasuresDoc, _correctiveMeasuresDocPage2];
|
|
108
|
+
console.log(_correctiveMeasuresDoc);
|
|
109
109
|
}
|
|
110
|
-
console.log(_correctiveMeasuresDoc);
|
|
111
110
|
if (_correctiveMeasuresDoc) coreDoc.insertPage(coreDoc.getPages().length, _correctiveMeasuresDoc);
|
|
112
111
|
} catch (e) { console.log(e) }
|
|
113
112
|
|