Skip to content

Commit

Permalink
style: ktlint
Browse files Browse the repository at this point in the history
  • Loading branch information
HashEngineering committed Aug 15, 2024
1 parent 2d40aa9 commit 497fc5d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ data class Merchant(
var redeemType: String? = "",
@Ignore var minCardPurchase: Double? = null,
@Ignore var maxCardPurchase: Double? = null,
var savingsPercentage: Int? = 0, // in basis points 1 = 0.001%
var savingsPercentage: Int? = 0, // in basis points 1 = 0.001%
@Ignore var physicalAmount: Int = 0
) : SearchResult() {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,10 @@ class MerchantViewHolder(val binding: MerchantRowBinding) : ExploreViewHolder(bi
if (merchant != null) {
if (merchant.savingsAsDouble != 0.00) {
binding.discountValue.isVisible = true
binding.discountValue.text = binding.root.context.getString(R.string.explore_discount, merchant.savingsPercentageAsDouble)
binding.discountValue.text = binding.root.context.getString(
R.string.explore_discount,
merchant.savingsPercentageAsDouble
)
} else {
binding.discountValue.isVisible = false
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,10 @@ class ItemDetails(context: Context, attrs: AttributeSet) : LinearLayout(context,

if (merchant.savingsAsDouble != 0.0) {
binding.discountValue.isVisible = true
binding.discountValue.text = root.context.getString(R.string.explore_pay_with_dash_save, merchant.savingsPercentageAsDouble)
binding.discountValue.text = root.context.getString(
R.string.explore_pay_with_dash_save,
merchant.savingsPercentageAsDouble
)
} else {
binding.discountValue.isVisible = false
}
Expand Down

0 comments on commit 497fc5d

Please sign in to comment.