-
Notifications
You must be signed in to change notification settings - Fork 4
Crowdaction badge threshold #111
Comments
How is this ticket dependent of the crowdactions? The way I look at it is that the participants are the ones that needed to be awarded. Maybe when you fetch the crowdaction you can get to see the different badges from each participant. Similar to a competition, just kind of showing which participant received Golden, Silver, Bronze? |
The badge-instances are properties of the profiles, but the crowdactions need to define thresholds for how many points are required to earn them. |
So when you fetch a crowdaction, you should be able to see how many points are required to get one of the 4 different badges: diamond, gold, silver, bronze? Is there anything else that needs to be done besides just adding the additional fields for the badges in the DDB table? I thought of this task in this way, maybe correct me if I'm wrong:
|
No, not in the scope of this task. We will go with the minimum for now. |
Okay so the task for this is to create an extra attribute in DDB with badges with the values specified in the array? Couple of follow up questions regarding this:
|
|
Okay I will create some new attributes manually in my DDB single table. I am not sure if I have to do some code changes. It seems like the CMS task would own some of these checkpoints, but maybe I'm wrong (hence the discussion haha). For me this task does not really make much sense if we don't build the logic behind getting the points, and rewarding the badges 😅. But I assume there are other tasks for this to be implemented. |
Yes, the points are calculated and compared to the threshold in #120 |
All right, I will get on that today. That was my bad, I accidentally typed the plural |
Re-opening issue, since change has not yet been merged. |
Added additional field (s. description above) |
Is this more or less the change that needs to be done for the second checkpoint? The value of points need to be according to the table in Confluence: Since this is type of commitment is: Vegan, it receives 70 points. I am doing this manually for now, but this needs to be taken care of when the CMS part is getting implemented |
Actually, this also needs to be changed in the GoLang code (here and maybe somewhere else as well, such as the crowdactions file), so we can access this fields after fetching a record from dynamo, since we don't work on the raw dynamo response and instead map them to a plain GoLang object. In the case of "Vegan", it would be 20 here and the rest of the points come from the commitments in "required". |
Perfect, I have already made the appropriate changes to the API documentation, as well as to the Commitment models. Please revise it in this branch: https://github.com/CollActionteam/collaction_backend/tree/feat/gh-111/badge_threshold |
…ollaction_backend into feat/gh-111/badge_threshold # Resolved Conflicts: # docs/api2.yaml
⚠ Blocked by #73
'badge_thresholds': [30, 50, 100, 150]
(example values)points: 10
(example value)At the end of the crowdaction the points of the selected commitments will be summed up and compared to the threshold values to determine the badge that should be awarded.
The text was updated successfully, but these errors were encountered: