Skip to content

Add Tags To Photos

Seán Lynch edited this page May 5, 2023 · 3 revisions

1. Calculate Totals

  • We are calculating totalLitter and totalCustomTags.

    • We need to calculate totalLitter, totalBrands and totalCustomTags which will determine totalTags.

2. Update XP

  • We need to move this to Redis.

3. Update Leaderboards

  • todo

4. Set Picked Up

5. Initialise Verification

  • If its a new user, photo.verification is set to 0.1

  • If the user is trusted, we dispatch TagsVerifiedByAdmin

    • Use the given tags to create a key-value string pair that can display the tags in any language

      • CompileResultsString::class
    • Increase total_litter, total_brands, and total_category for each location, on Redis

      • IncrementLocation::class
    • Increment total_images total_litter on Team and TeamUser pivot, on SQL

    • this needs to be migrated to Redis

      • IncreaseTeamTotalLitter::class
    • Increase the users Littercoin score

    • Reward with Littercoin if criteria met

      • RewardLittercoin::class
    • Update the users total_litter, total_brands, total_photos and total_category on Redis

      • UpdateUserCategories::class
    • Photos per month, or ppm, needs to be migrated to Redis

      • UpdateUserTimeSeries::class
    • Update the last_user_id_uploaded for each Location

      • UpdateUserIdLastUpdatedLocation::class