Skip to content

Commit

Permalink
feat: [PE-882] CGN new discounts count (#6607)
Browse files Browse the repository at this point in the history
## Short description
Replaced badge label of "novità" with actual new discounts count. 

## List of changes proposed in this pull request
- change label

## How to test
- to test with dev-api-server you need
pagopa/io-dev-api-server#455
- login into the app
- go to carta giovani nazionale trough portafoglio (add the card if
necessary)
- go to discount list by pressing "scopri opportunià"
- press "by partner" tab
- check that the badges contain numbers instead of a fixed label
- press "by category" tab
- press on any category
- check that the badges contain numbers instead of a fixed label

---------

Co-authored-by: Emanuele Dall'Ara <[email protected]>
  • Loading branch information
freddi301 and LeleDallas authored Jan 17, 2025
1 parent eddd677 commit 93bd0a8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion scripts/generate-api-models.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

IO_BACKEND_VERSION=v16.4.0-RELEASE
IO_BACKEND_VERSION=v16.7.3-RELEASE
# need to change after merge on io-services-metadata
IO_SERVICES_METADATA_VERSION=1.0.55

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,11 @@ export const CgnMerchantListViewRenderItem =
<View style={[IOStyles.rowSpaceBetween, IOStyles.alignCenter]}>
<Badge
variant="purple"
text={I18n.t("bonus.cgn.merchantsList.news")}
text={
item.numberOfNewDiscounts
? item.numberOfNewDiscounts.toString()
: I18n.t("bonus.cgn.merchantsList.news")
}
/>
</View>
)}
Expand Down

0 comments on commit 93bd0a8

Please sign in to comment.