Skip to content

Commit

Permalink
Merge pull request #1511 from bcgov/bugfix/alcs-1762
Browse files Browse the repository at this point in the history
Noi pdf template fixes
  • Loading branch information
urmikgov authored Mar 14, 2024
2 parents 23f5ec5 + 09c3329 commit 99ae999
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -312,9 +312,22 @@ export class GenerateNoiSubmissionDocumentService {
const buildingPlans = documents.filter(
(document) => document.type?.code === DOCUMENT_TYPE.BUILDING_PLAN,
);

const hasFarmStructure = submission?.soilProposedStructures.some(
(structure) => structure.type === 'Farm Structure'
);
pdfData = {
...pdfData,
isSoilAgriParcelActivityVisible: hasFarmStructure,
isSoilStructureFarmUseReasonVisible: hasFarmStructure,
isSoilStructureResidentialUseReasonVisible: !!submission?.soilProposedStructures.some(
(structure) => structure.type === "Residential - Principal Residence" || structure.type === "Residential - Additional Residence"
),
isSoilStructureResidentialAccessoryUseReasonVisible: !!submission?.soilProposedStructures.some(
(structure) => structure.type === "Residential - Accessory Structure"
),
isSoilOtherStructureUseReasonVisible: !!submission?.soilProposedStructures.some(
(structure) => structure.type === "Other Structure"
),
fillProjectDuration: submission.fillProjectDuration,
soilIsFollowUp: formatBooleanToYesNoString(submission.soilIsFollowUp),
soilFollowUpIDs: submission.soilFollowUpIDs,
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 comments on commit 99ae999

Please sign in to comment.