-
Notifications
You must be signed in to change notification settings - Fork 8
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
[TTAHUB-3192] Fetch topics separately for RTTAPA #2277
[TTAHUB-3192] Fetch topics separately for RTTAPA #2277
Conversation
@@ -486,7 +486,7 @@ function calculatePreviousStatus(goal) { | |||
// otherwise we check to see if there is the goal is on an activity report, | |||
// and also check the status | |||
if (goal.objectives.length) { | |||
const onAr = goal.objectives.some((objective) => objective.activityReports.length); | |||
const onAr = goal.objectives.some((objective) => objective.onApprovedAR); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just a convenience (we already had the flag in the query)
include: [ | ||
{ | ||
model: Topic, | ||
through: [], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
through and separate don't play nice
@@ -733,25 +734,6 @@ export async function getGoalsByActivityRecipient( | |||
where: { | |||
calculatedStatus: REPORT_STATUSES.APPROVED, | |||
}, | |||
include: [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem necessary
Description of change
Fetch topics data on the RTTAPA with Sequelize's
separate: true
flag, since the current way seems to run up against some limit with certain recipients.How to test
Confirm the RTTAPA cards display the correct topics. Open the case from the support ticket. Confirm that the recipient is visible and that the goal query doesn't time out and display an error in the front end.
Issue(s)
Checklists
Every PR
Before merge to main
Production Deploy
After merge/deploy