Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix add to report #2295

Merged
merged 1 commit into from
Sep 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was causing issues on the first time adding content to a report.


// 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
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed bug I introduced. However, the test pipeline still doesn't work for some reason.

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
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes it easier for new resources to get the syndication service running


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
Loading