Skip to content

Commit

Permalink
Fix add to report
Browse files Browse the repository at this point in the history
  • Loading branch information
Fosol committed Sep 26, 2024
1 parent 1648208 commit 201eec0
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion app/subscriber/src/components/tool-bar/AddToReportMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,14 @@ export const AddToReportMenu: React.FC<IAddToReportMenuProps> = ({ content, onCl

if (!report.instances.length) {
// Fetch the report because the one in memory has no instances.
currentReport = await getReport(report.id);
currentReport = await getReport(report.id, true);

// The report does not have an instance, we must create one to add content.
// This should only occur the first time after a new report is created.
if (!currentReport?.instances.length) {
currentReport = await generateReport(report.id, true);
}
instance = currentReport.instances.length ? currentReport.instances[0] : undefined;
}

if (
Expand Down
2 changes: 1 addition & 1 deletion openshift/kustomize/tekton/base/tasks/git-conditions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ spec:
buildVar="${1/\-/\_}"
# convert to uppercase
buildVar="${buildVar^^}"
BUILD_${buildVar}=true
BUILD=BUILD_${buildVar}=true
if grep -s services/net/$folderName <<< $DIFF; then
echo $BUILD >> build.env
elif grep -s libs/net/services <<< $DIFF; then
Expand Down
3 changes: 2 additions & 1 deletion tools/scripts/gen-env-files.sh
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,7 @@ Auth__Keycloak__Secret={YOU WILL NEED TO GET THIS FROM KEYCLOAK}
Auth__OIDC__Token=/realms/mmi/protocol/openid-connect/token
Service__ApiUrl=http://host.docker.internal:$portApi/api
Service__DataLocation=Openshift
CHES__AuthUrl=https://dev.loginproxy.gov.bc.ca/auth/realms/comsvcauth/protocol/openid-connect/token
CHES__HostUri=https://ches-dev.api.gov.bc.ca/api/v1
Expand Down Expand Up @@ -910,4 +911,4 @@ S3_ACCESS_KEY={Your S3_ACCESS_KEY}
S3_SECRET_KEY={Your S3_SECRET_KEY}
S3_BUCKET={Your Bucket Name}" >> ./tools/objects-backup/.env
echo "./tools/objects-backup/.env created"
fi
fi

0 comments on commit 201eec0

Please sign in to comment.