ebta-workflow-prod 4.0.11 → 4.0.13

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
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ebta-workflow-prod",
3
3
  "private": false,
4
- "version": "4.0.11",
4
+ "version": "4.0.13",
5
5
  "description": "",
6
6
  "license": "UNLICENSED",
7
7
  "author": "",
@@ -469,7 +469,7 @@ export default class PDFMapGeneratorActivity implements IActivityHandler {
469
469
  const lableSize = 100
470
470
  if (inputs.template == 'VMP') {
471
471
  newPage.drawImage(image10, {
472
- x: 28 + 200,
472
+ x: 40,
473
473
  y: 145,
474
474
  width: lableSize,
475
475
  height: lableSize * (image10.height / image10.width),
@@ -571,18 +571,19 @@ export default class PDFMapGeneratorActivity implements IActivityHandler {
571
571
  const revField = form.getTextField('Rev.' + i)
572
572
  revField.setText(inputs.Rev)
573
573
  revField.updateAppearances(font)
574
- if (inputs.template=='VMP'){
575
- //supervisor
576
- const supervisorField = form.getTextField('Supervisor')
577
- supervisorField.setText(inputs.extraField['supervisor'])
578
- supervisorField.setAlignment(TextAlignment.Center)
579
- supervisorField.updateAppearances(font)
580
- //UHF
581
- const uhfField = form.getTextField('UHF')
582
- uhfField.setText(inputs.extraField['UHF'])
583
- uhfField.setAlignment(TextAlignment.Center)
584
- uhfField.updateAppearances(font)
585
- }
574
+ if (inputs.template == 'VMP') {
575
+ //supervisor
576
+ const supervisorField = form.getTextField('Supervisor')
577
+ supervisorField.setText(inputs.extraField['supervisor'])
578
+ supervisorField.setAlignment(TextAlignment.Center)
579
+ supervisorField.updateAppearances(font)
580
+ //UHF
581
+ const uhfField = form.getTextField('UHF')
582
+ uhfField.setText(inputs.extraField['UHF'])
583
+ uhfField.setAlignment(TextAlignment.Center)
584
+ uhfField.updateAppearances(font)
585
+ console.log('VMP text inserted successful')
586
+ }
586
587
  //date
587
588
  const today = new Date();
588
589
  const formattedDate = today.toLocaleDateString('en-AU');
@@ -611,23 +612,14 @@ export default class PDFMapGeneratorActivity implements IActivityHandler {
611
612
  }
612
613
  }
613
614
  console.log('Text Fields removal successful')
614
-
615
-
616
615
  const boldFont = await doc.embedFont(StandardFonts.HelveticaBold);
617
-
616
+ console.log('bold font embed successful')
618
617
  if (inputs.template == 'VMP') {
619
618
  newPage.drawText('Maximum Speed 10KM/h within Work Area', {
620
- x: (28+150),
619
+ x: (28 + 151),
621
620
  y: 145,
622
- size: 10.5,
623
- color: rgb(255, 255, 255), // White color
624
- font: font,
625
- });
626
- newPage.drawText('Maximum Speed 10KM/h within Work Area', {
627
- x: (28+151),
628
- y: 145,
629
- size: 10,
630
- color: rgb(255, 0, 0), // red color
621
+ size: 30,
622
+ color: rgb(1, 0, 0), // red color, IGNORE VSCODE COLOR
631
623
  font: boldFont,
632
624
  });
633
625
  console.log('speed limit text inserted')
@@ -647,12 +639,12 @@ export default class PDFMapGeneratorActivity implements IActivityHandler {
647
639
  width: buttonW,
648
640
  height: buttonH,
649
641
  });
650
-
642
+
651
643
  newPage.drawText('Go to EBTA GIS', {
652
644
  x: buttonX + 5,
653
645
  y: buttonY + 22,
654
646
  size: 10,
655
- color: rgb(1, 1, 1), // White color
647
+ color: rgb(1, 1, 1), // White color, VS CODE COLOR PICKER IS WRONG
656
648
  font: boldFont,
657
649
  });
658
650