Manos Chorianopoulos

fix MyRewards to show coupon tiles always

...@@ -1078,18 +1078,20 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ ...@@ -1078,18 +1078,20 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{
1078 // } 1078 // }
1079 1079
1080 if (section == 0) { 1080 if (section == 0) {
1081 - let sumRedeemed = totalCouponValue + totalCouponDiscount + unifiedCouponsDiscount 1081 +// TODO: Uncomment if we want to hide empty tiles again
1082 - if (self.dfyCoupons.count > 0 || self.unifiedCoupons.count > 0 || self.coupons.count > 0 || sumRedeemed > 0.0) { 1082 +// let sumRedeemed = totalCouponValue + totalCouponDiscount + unifiedCouponsDiscount
1083 +// if (self.dfyCoupons.count > 0 || self.unifiedCoupons.count > 0 || self.coupons.count > 0 || sumRedeemed > 0.0) {
1083 return 1 1084 return 1
1084 - } else { 1085 +// } else {
1085 - return 0 1086 +// return 0
1086 - } 1087 +// }
1087 } else if (section == 1) { 1088 } else if (section == 1) {
1088 - if (self.showEmptyView == true) { 1089 +// TODO: Uncomment if we want to show emptyView again
1089 - return 1 1090 +// if (self.showEmptyView == true) {
1090 - } else { 1091 +// return 1
1092 +// } else {
1091 return 0 1093 return 0
1092 - } 1094 +// }
1093 } else if (section == 2) { 1095 } else if (section == 2) {
1094 return 1 1096 return 1
1095 } 1097 }
...@@ -1150,18 +1152,20 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ ...@@ -1150,18 +1152,20 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{
1150 // } 1152 // }
1151 1153
1152 if (indexPath.section == 0) { 1154 if (indexPath.section == 0) {
1153 - let sumRedeemed = totalCouponValue + totalCouponDiscount + unifiedCouponsDiscount 1155 +// TODO: Uncomment if we want to hide empty tiles again
1154 - if (self.dfyCoupons.count > 0 || self.unifiedCoupons.count > 0 || self.coupons.count > 0 || sumRedeemed > 0.0) { 1156 +// let sumRedeemed = totalCouponValue + totalCouponDiscount + unifiedCouponsDiscount
1157 +// if (self.dfyCoupons.count > 0 || self.unifiedCoupons.count > 0 || self.coupons.count > 0 || sumRedeemed > 0.0) {
1155 return UITableView.automaticDimension 1158 return UITableView.automaticDimension
1156 - } else { 1159 +// } else {
1157 - return 0.0 1160 +// return 0.0
1158 - } 1161 +// }
1159 } else if (indexPath.section == 1) { 1162 } else if (indexPath.section == 1) {
1160 - if (self.showEmptyView == true) { 1163 +// TODO: Uncomment if we want to show emptyView again
1161 - return UITableView.automaticDimension 1164 +// if (self.showEmptyView == true) {
1162 - } else { 1165 +// return UITableView.automaticDimension
1166 +// } else {
1163 return 0.0 1167 return 0.0
1164 - } 1168 +// }
1165 } else if (indexPath.section == 2) { 1169 } else if (indexPath.section == 2) {
1166 return UITableView.automaticDimension 1170 return UITableView.automaticDimension
1167 } 1171 }
......