|
@@ -131,7 +131,7 @@ class KMAccountInfoView: KMBaseXibView {
|
|
|
self.accountLabel.stringValue = userInfo!.email
|
|
|
self.imageViewButton.title = userInfo?.email.substring(to: 1) ?? ""
|
|
|
|
|
|
- if userInfo?.subscriptionInfoList[0].payType == 1 {
|
|
|
+ if KMLightMemberManager.manager.info.subscriptionInfoList[0].payType == 1 {
|
|
|
self.tagContentView.isHidden = false
|
|
|
} else {
|
|
|
self.tagContentView.isHidden = true
|
|
@@ -145,7 +145,6 @@ class KMAccountInfoView: KMBaseXibView {
|
|
|
self.purchaseInfoContentView.isHidden = KMLightMemberManager.manager.existOrderInfo() ? false:true
|
|
|
self.subscribeButtonContentView.isHidden = true
|
|
|
self.statusContentView.isHidden = true
|
|
|
- self.purchaseInfoContentView.isHidden = true
|
|
|
self.subscriptionInfoContentViewHeightConstraint.constant = 74
|
|
|
self.subscriptionInfoContentViewTopConstraint.constant = 20
|
|
|
self.lineViewTopConttraint.constant = 16
|
|
@@ -163,11 +162,13 @@ class KMAccountInfoView: KMBaseXibView {
|
|
|
self.statusContentView.isHidden = false
|
|
|
#if VERSION_DMG
|
|
|
self.purchaseInfoContentView.isHidden = false
|
|
|
- if userInfo?.subscriptionInfoList[0].payType == 1 {
|
|
|
+ if KMLightMemberManager.manager.info.subscriptionInfoList[0].payType == 1 {
|
|
|
self.subscribeButtonContentView.isHidden = true
|
|
|
} else {
|
|
|
self.subscribeButtonContentView.isHidden = false
|
|
|
}
|
|
|
+#else
|
|
|
+ self.purchaseInfoContentView.isHidden = true
|
|
|
#endif
|
|
|
self.statusLabel.stringValue = NSLocalizedString("On Subscription", comment: "")
|
|
|
if purchaseState == .trial {
|
|
@@ -183,6 +184,8 @@ class KMAccountInfoView: KMBaseXibView {
|
|
|
|
|
|
#if VERSION_DMG
|
|
|
self.purchaseInfoContentView.isHidden = false
|
|
|
+#else
|
|
|
+ self.purchaseInfoContentView.isHidden = true
|
|
|
#endif
|
|
|
self.statusLabel.stringValue = NSLocalizedString("Expired", comment: "")
|
|
|
self.statusLabel.textColor = NSColor(hex: "#F3465B")
|
|
@@ -192,7 +195,7 @@ class KMAccountInfoView: KMBaseXibView {
|
|
|
}
|
|
|
|
|
|
if self.userInfo != nil {
|
|
|
- if userInfo?.subscriptionInfoList[0].payType == 1 {
|
|
|
+ if KMLightMemberManager.manager.info.subscriptionInfoList[0].payType == 1 {
|
|
|
let dateString = userInfo?.subscriptionInfoList[0].endDate ?? ""
|
|
|
self.statusTimeLabel.stringValue = "\(self.fetchDate(dateString: dateString))\n\(NSLocalizedString("Subscription renewal date", comment: ""))"
|
|
|
}
|