Showing
1 changed file
with
6 additions
and
4 deletions
| ... | @@ -175,7 +175,9 @@ import AVFoundation | ... | @@ -175,7 +175,9 @@ import AVFoundation |
| 175 | barcodeImageHeight.constant = 0 | 175 | barcodeImageHeight.constant = 0 |
| 176 | } | 176 | } |
| 177 | 177 | ||
| 178 | - let couponsValueString = String(marketPassDetails?._total_available_discount ?? 0.0) | 178 | + let couponsValueFloat = marketPassDetails?._total_available_discount ?? 0.0 |
| 179 | + let couponsValueString = String(format: "%.2f", couponsValueFloat) | ||
| 180 | + // let couponsValueString = String(marketPassDetails?._total_available_discount ?? 0.0) | ||
| 179 | let attrRegular = [NSAttributedString.Key.font : UIFont(name: "PeridotPE-Regular", size: 17) ?? UIFont.systemFont(ofSize: 16), NSAttributedString.Key.foregroundColor: UIColor.white] | 181 | let attrRegular = [NSAttributedString.Key.font : UIFont(name: "PeridotPE-Regular", size: 17) ?? UIFont.systemFont(ofSize: 16), NSAttributedString.Key.foregroundColor: UIColor.white] |
| 180 | let attrBold = [NSAttributedString.Key.font : UIFont(name: "PeridotPE-Bold", size: 17) ?? UIFont.boldSystemFont(ofSize: 16), NSAttributedString.Key.foregroundColor: UIColor.white] | 182 | let attrBold = [NSAttributedString.Key.font : UIFont(name: "PeridotPE-Bold", size: 17) ?? UIFont.boldSystemFont(ofSize: 16), NSAttributedString.Key.foregroundColor: UIColor.white] |
| 181 | 183 | ||
| ... | @@ -193,7 +195,7 @@ import AVFoundation | ... | @@ -193,7 +195,7 @@ import AVFoundation |
| 193 | // Create a horizontal stack view | 195 | // Create a horizontal stack view |
| 194 | let stackView = UIStackView() | 196 | let stackView = UIStackView() |
| 195 | stackView.axis = .horizontal | 197 | stackView.axis = .horizontal |
| 196 | - stackView.spacing = 15 // Spacing between images | 198 | + stackView.spacing = 5 // Spacing between images |
| 197 | stackView.alignment = .center | 199 | stackView.alignment = .center |
| 198 | stackView.distribution = .equalSpacing | 200 | stackView.distribution = .equalSpacing |
| 199 | 201 | ||
| ... | @@ -201,8 +203,8 @@ import AVFoundation | ... | @@ -201,8 +203,8 @@ import AVFoundation |
| 201 | for sm in supermarkets { | 203 | for sm in supermarkets { |
| 202 | let imageView = UIImageView() | 204 | let imageView = UIImageView() |
| 203 | imageView.contentMode = .scaleAspectFit | 205 | imageView.contentMode = .scaleAspectFit |
| 204 | - imageView.widthAnchor.constraint(equalToConstant: 40).isActive = true | 206 | + imageView.widthAnchor.constraint(equalToConstant: 50).isActive = true |
| 205 | - imageView.heightAnchor.constraint(equalToConstant: 40).isActive = true | 207 | + imageView.heightAnchor.constraint(equalToConstant: 50).isActive = true |
| 206 | 208 | ||
| 207 | imageView.load(link: sm._logo, placeholder: UIImage(), cache: URLCache()) | 209 | imageView.load(link: sm._logo, placeholder: UIImage(), cache: URLCache()) |
| 208 | 210 | ... | ... |
-
Please register or login to post a comment