Browse Source

handled for first opening balance

pull/1/head
gme_2 6 years ago
parent
commit
c1913f0f6d
  1. 2
      GMERemittance/Module/Login/User Interface/View/LoginViewController.swift
  2. 17
      GMERemittance/Module/WalletStatement/User Interface/View/Cell/WalletStatementTableViewCell.swift
  3. 1
      GMERemittance/Module/WalletStatement/User Interface/View/WalletStatement.storyboard

2
GMERemittance/Module/Login/User Interface/View/LoginViewController.swift

@ -62,7 +62,7 @@ class LoginViewController: UIViewController {
private func setup() {
// all setup should be done here
setupNavBar()
showAnimation()
// showAnimation()
}
func showAnimation() {

17
GMERemittance/Module/WalletStatement/User Interface/View/Cell/WalletStatementTableViewCell.swift

@ -18,7 +18,8 @@ class WalletStatementTableViewCell: UITableViewCell {
@IBOutlet weak var dateLabel: UILabel!
@IBOutlet weak var particularLabel: UILabel!
@IBOutlet weak var closingAmountLabel: UILabel!
@IBOutlet weak var walletInOutLabel: UILabel!
@IBOutlet weak var amtLabelStackView: UIStackView!
@IBOutlet weak var walletAmountLabel: UILabel!
var model: WalletStatement?
@ -27,15 +28,25 @@ class WalletStatementTableViewCell: UITableViewCell {
self.dateLabel.text = model?.transactionDate
self.particularLabel.text = model?.particular
self.closingAmountLabel.text = model?.closingAmount
let type: WalletInOutType = (model?.walletOut ?? "") == "₩0" ? .walletIn : .walletOut
self.walletAmountLabel.layer.cornerRadius = 4
self.walletAmountLabel.clipsToBounds = true
walletAmountLabel.textColor = .white
switch type {
case .walletIn:
self.walletAmountLabel.backgroundColor = AppConstants.themeBlueColor
self.walletAmountLabel.text = "IN: \(model?.walletIn ?? "")"
if (model?.particular ?? "").lowercased() == "Balance Brought Forward".lowercased() {
self.walletAmountLabel.text = ""
self.walletAmountLabel.backgroundColor = AppConstants.themWhiteColor
}else {
self.walletAmountLabel.backgroundColor = AppConstants.themeBlueColor
self.walletAmountLabel.text = "IN: \(self.model?.walletIn ?? "")"
}
case .walletOut:
self.walletAmountLabel.backgroundColor = AppConstants.themeRedColor
self.walletAmountLabel.text = "OUT: \(model?.walletOut ?? "")"

1
GMERemittance/Module/WalletStatement/User Interface/View/WalletStatement.storyboard

@ -125,6 +125,7 @@
</constraints>
</tableViewCellContentView>
<connections>
<outlet property="amtLabelStackView" destination="BD2-GC-dic" id="r97-VH-Q23"/>
<outlet property="closingAmountLabel" destination="6ee-Ey-bqV" id="yp7-qc-NGS"/>
<outlet property="dateLabel" destination="dbP-sK-VqU" id="MLA-Vv-bH2"/>
<outlet property="particularLabel" destination="Uog-tj-cso" id="TB8-zi-akp"/>

Loading…
Cancel
Save