From 62a24b3c7cf92919a93ee575e9460037e1a53816 Mon Sep 17 00:00:00 2001
From: 杨锴 <841720330@qq.com>
Date: 星期四, 07 十一月 2024 19:10:20 +0800
Subject: [PATCH] fix bug
---
XQMuse/Root/Course/VC/CourseDetialVC.swift | 6
XQMuse/Root/Me/VC/BindPhone_2_VC.swift | 7
XQMuse/Root/Me/VC/NoticeCenterUserRepeaceDetailVC.swift | 6
XQMuse/Root/Other/View/ChooseOptTitleView.xib | 38 +
XQMuse/Root/Me/VC/HelpCenterVC.swift | 2
XQMuse/Root/Me/VC/WatchHistoryDetailVC.swift | 11
XQMuse/Root/Other/View/ChooseOptTitleView.swift | 23
XQMuse/Root/Me/VC/BankWithdrawVC.swift | 43 +
XQMuse/Base/BaseNav.swift | 4
XQMuse/Root/Course/TCell/CourseDetail_1_TCell.xib | 6
XQMuse/Root/Home/CCell/HomeRelaxBanner_2_1_CCell.swift | 4
XQMuse/Root/Home/CCell/HomeRelaxBanner_2_CCell.swift | 15
XQMuse/Root/Home/VC/HomeItemListVC.swift | 10
XQMuse/Root/Other/WebVC.swift | 12
XQMuse/Root/Me/VC/WalletRechargeVC.swift | 18 +
XQMuse/Root/Me/VC/ContactCustomerDetailVC.swift | 26 +
XQMuse/Root/Me/VC/ContactCustomerDetailVC.xib | 175 +++++----
XQMuse/Root/Home/HomeVC.swift | 10
XQMuse/Config/Enums/Enums.swift | 20
XQMuse/Root/Me/VC/BindPhone_2_VC.xib | 69 ++-
XQMuse/Root/Me/VC/LogoutAccountVC.swift | 4
XQMuse/Root/Me/VC/SpendingDetailHeaderVC.xib | 2
XQMuse/Root/Me/VC/BankWithdrawVC.xib | 109 +++---
XQMuse/Root/Course/VC/CourseDetialVideoVC.swift | 2
XQMuse/Config/Themes.swift | 4
XQMuse/Root/Me/VC/WalletVC.xib | 20
XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/Contents.json | 4
XQMuse/Root/Home/TCell/Home_Style_3_TCell.swift | 4
XQMuse/Root/Home/TCell/Home_Style_4_TCell.swift | 5
XQMuse/Root/Me/VC/WalletVC.swift | 11
XQMuse/Root/Me/VC/WatchHistoryVC.swift | 18 +
XQMuse/Root/Home/VC/PaymentOrderVC.swift | 7
XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/组 1 拷贝@2x.png | 0
XQMuse/Config/Def.swift | 25 +
XQMuse/Root/Me/VC/SettingVC.swift | 6
XQMuse/Root/Me/VC/VIPCenterVC.xib | 2
XQMuse/Root/Home/VC/SearchContentVC.swift | 8
XQMuse/Root/Me/VC/NoticeCenterSysDetailVC.swift | 2
XQMuse/Root/Network/Models.swift | 9
XQMuse/Root/Course/CCell/CourseOfficalCommendTopCCell.swift | 2
XQMuse/Root/Me/MeVC.xib | 34 +-
XQMuse/Root/Me/VC/WalletRechargeVC.xib | 124 ++++---
XQMuse/Root/Course/View/CourseSendGiftView.swift | 3
XQMuse/Root/Me/VC/HelpCenterVC.xib | 30
XQMuse/Root/Course/TCell/CourseDetail_3_TCell.xib | 8
/dev/null | 0
XQMuse/Root/Me/VC/LevelVC.xib | 10
XQMuse/Root/Me/MeVC.swift | 14
XQMuse/Root/Me/VC/WatchHistoryVC.xib | 10
XQMuse/Root/Course/VC/CourseVCOfficalCommentVC.swift | 2
XQMuse/Root/Home/TCell/Home_Style_5_TCell.swift | 2
XQMuse/Root/Me/VC/VIPCenterVC.swift | 2
XQMuse/Root/Course/TCell/CourseDetail_2_TCell.swift | 4
XQMuse/Root/Course/View/CourseDetailHeaderView.swift | 2
XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/组 1 拷贝@2x 1.png | 0
XQMuse/Assets.xcassets/Btns/.DS_Store | 0
56 files changed, 617 insertions(+), 377 deletions(-)
diff --git a/XQMuse/Assets.xcassets/Btns/.DS_Store b/XQMuse/Assets.xcassets/Btns/.DS_Store
index 12ef8b5..ef62606 100644
--- a/XQMuse/Assets.xcassets/Btns/.DS_Store
+++ b/XQMuse/Assets.xcassets/Btns/.DS_Store
Binary files differ
diff --git a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/Contents.json b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/Contents.json
index 9cffb4f..222b937 100644
--- a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/Contents.json
+++ b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/Contents.json
@@ -5,12 +5,12 @@
"scale" : "1x"
},
{
- "filename" : "bg_help@2x.png",
+ "filename" : "组 1 拷贝@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
- "filename" : "bg_help@3x.png",
+ "filename" : "组 1 拷贝@2x 1.png",
"idiom" : "universal",
"scale" : "3x"
}
diff --git a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/bg_help@2x.png b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/bg_help@2x.png
deleted file mode 100644
index 507e85d..0000000
--- a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/bg_help@2x.png
+++ /dev/null
Binary files differ
diff --git a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/bg_help@3x.png b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/bg_help@3x.png
deleted file mode 100644
index 6be4940..0000000
--- a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/bg_help@3x.png
+++ /dev/null
Binary files differ
diff --git "a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/\347\273\204 1 \346\213\267\350\264\235@2x 1.png" "b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/\347\273\204 1 \346\213\267\350\264\235@2x 1.png"
new file mode 100644
index 0000000..4f3d287
--- /dev/null
+++ "b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/\347\273\204 1 \346\213\267\350\264\235@2x 1.png"
Binary files differ
diff --git "a/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/\347\273\204 1 \346\213\267\350\264\235@2x.png" "b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/\347\273\204 1 \346\213\267\350\264\235@2x.png"
new file mode 100644
index 0000000..4f3d287
--- /dev/null
+++ "b/XQMuse/Assets.xcassets/Placeholder/bg_help.imageset/\347\273\204 1 \346\213\267\350\264\235@2x.png"
Binary files differ
diff --git a/XQMuse/Base/BaseNav.swift b/XQMuse/Base/BaseNav.swift
index 6a97b3c..e73fc24 100644
--- a/XQMuse/Base/BaseNav.swift
+++ b/XQMuse/Base/BaseNav.swift
@@ -54,13 +54,15 @@
var musicVC:PayMusicVC?
+ let showTree:Bool = viewController is TreeTeskVC
+
for vc in navigationController.tabBarController?.children ?? []{
if vc is PayMusicVC{
musicVC = (vc as! PayMusicVC);break
}
}
- musicVC?.view.isHidden = navigationController.viewControllers.count != 1
+ musicVC?.view.isHidden = (navigationController.viewControllers.count != 1 || showTree)
let status = lucencyVCs.contains(where: {$0 == viewController.classForCoder})
if (navigationController.viewControllers.count == 1 || status){
diff --git a/XQMuse/Config/Def.swift b/XQMuse/Config/Def.swift
index 8f43b62..f656104 100644
--- a/XQMuse/Config/Def.swift
+++ b/XQMuse/Config/Def.swift
@@ -15,6 +15,8 @@
let WeChatAPPID = "wx4b9c1d814c2902a3"
let WeChatSecrect = "60fed4b6f52603ba6769e1118b4a57ae"
+let AppleID = "6737112249"
+
let app = UIApplication.shared.delegate as! AppDelegate
let locationTool = JQ_LocationTool.instance()
@@ -129,3 +131,26 @@
timer.resume()
}
}
+
+extension Double{
+ var radioW:Double{
+ return 390.0 * sceneDelegate!.window!.height / 844.0
+ }
+
+ var radioH:Double{
+ return sceneDelegate!.window!.height / 844.0 * self
+ }
+}
+
+extension CGFloat{
+ var radioW:CGFloat{
+ return 390.0 * sceneDelegate!.window!.height / 844.0
+ }
+
+ var radioH:CGFloat{
+ return 844.0 * sceneDelegate!.window!.width / 390.0
+ }
+}
+
+
+
diff --git a/XQMuse/Config/Enums/Enums.swift b/XQMuse/Config/Enums/Enums.swift
index 765ded2..50dfd08 100644
--- a/XQMuse/Config/Enums/Enums.swift
+++ b/XQMuse/Config/Enums/Enums.swift
@@ -87,16 +87,16 @@
var title:String{
switch self {
- case .level_1:return "第一"
- case .level_2:return "第二"
- case .level_3:return "第三"
- case .level_4:return "第四"
- case .level_5:return "第五"
- case .level_6:return "第六"
- case .level_7:return "第七"
- case .level_8:return "第八"
- case .level_9:return "第九"
- case .level_10:return "第十"
+ case .level_1:return "种子"
+ case .level_2:return "发芽"
+ case .level_3:return "幼苗"
+ case .level_4:return "小树苗"
+ case .level_5:return "中等树苗"
+ case .level_6:return "小树"
+ case .level_7:return "中树"
+ case .level_8:return "大树"
+ case .level_9:return "成熟的大树"
+ case .level_10:return "参天大树"
}
}
diff --git a/XQMuse/Config/Themes.swift b/XQMuse/Config/Themes.swift
index b0011b1..2c4e9eb 100644
--- a/XQMuse/Config/Themes.swift
+++ b/XQMuse/Config/Themes.swift
@@ -40,6 +40,10 @@
return UIFont(name: "SourceHanSerifCN-Medium", size: fontSize) ?? .systemFont(ofSize: fontSize)
}
+func Def_PingFang(fontSize:Double)->UIFont{
+ return UIFont(name: "PingFang SC", size: fontSize) ?? .systemFont(ofSize: fontSize)
+}
+
// MARK: -- Color
let Def_ThemeColor:UIColor = UIColor(hexStr: "#8DA178")
diff --git a/XQMuse/Root/Course/CCell/CourseOfficalCommendTopCCell.swift b/XQMuse/Root/Course/CCell/CourseOfficalCommendTopCCell.swift
index 9d1340a..c646c8e 100644
--- a/XQMuse/Root/Course/CCell/CourseOfficalCommendTopCCell.swift
+++ b/XQMuse/Root/Course/CCell/CourseOfficalCommendTopCCell.swift
@@ -27,7 +27,7 @@
func setTitles(_ items:[TitleItem]){
titleItems = items
- cons_hei.constant = ceil(Double(items.count) / 4) * 103.75
+ cons_hei.constant = ceil(Double(items.count) / 4) * 103.75
collectionView.reloadData()
}
diff --git a/XQMuse/Root/Course/TCell/CourseDetail_1_TCell.xib b/XQMuse/Root/Course/TCell/CourseDetail_1_TCell.xib
index 6a044bb..119e604 100644
--- a/XQMuse/Root/Course/TCell/CourseDetail_1_TCell.xib
+++ b/XQMuse/Root/Course/TCell/CourseDetail_1_TCell.xib
@@ -26,7 +26,7 @@
<nil key="highlightedColor"/>
</label>
<wkWebView contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="WYV-JQ-E3S">
- <rect key="frame" x="0.0" y="44.666666666666657" width="501" height="280.33333333333337"/>
+ <rect key="frame" x="21.666666666666657" y="44.666666666666657" width="458" height="280.33333333333337"/>
<constraints>
<constraint firstAttribute="height" relation="greaterThanOrEqual" constant="100" id="hfa-qQ-TpS"/>
</constraints>
@@ -39,9 +39,9 @@
<constraints>
<constraint firstItem="Lg9-70-w3n" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="5" id="4D5-on-wj2"/>
<constraint firstItem="WYV-JQ-E3S" firstAttribute="top" secondItem="Lg9-70-w3n" secondAttribute="bottom" constant="19.5" id="Ar0-7c-kQM"/>
- <constraint firstAttribute="trailing" secondItem="WYV-JQ-E3S" secondAttribute="trailing" id="BSc-yJ-F5G"/>
- <constraint firstItem="WYV-JQ-E3S" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="Mbt-TS-KCB"/>
<constraint firstItem="Lg9-70-w3n" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="21.5" id="dJv-7a-n9J"/>
+ <constraint firstItem="WYV-JQ-E3S" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="21.5" id="m6n-62-uuK"/>
+ <constraint firstAttribute="trailing" secondItem="WYV-JQ-E3S" secondAttribute="trailing" constant="21.5" id="tdS-fg-gym"/>
<constraint firstAttribute="bottom" secondItem="WYV-JQ-E3S" secondAttribute="bottom" id="ys9-aS-J2j"/>
</constraints>
</tableViewCellContentView>
diff --git a/XQMuse/Root/Course/TCell/CourseDetail_2_TCell.swift b/XQMuse/Root/Course/TCell/CourseDetail_2_TCell.swift
index 22adb47..6f3840f 100644
--- a/XQMuse/Root/Course/TCell/CourseDetail_2_TCell.swift
+++ b/XQMuse/Root/Course/TCell/CourseDetail_2_TCell.swift
@@ -40,9 +40,9 @@
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
guard let m = model else {return}
- let isVip = UserViewModel.getAvatarInfo().isVip
+ let isVip = UserViewModel.getAvatarInfo().checkVip()
- if m.chargeType == .free || (m.chargeType == .vipFree && isVip == .yes) || (m.chargeType == .payment && m.isBuy == .yes){
+ if m.chargeType == .free || (m.chargeType == .vipFree && isVip) || (m.chargeType == .payment && m.isBuy == .yes){
let vc = CourseDetialVideoVC(items: model!.list, selectIndex: indexPath)
JQ_currentNavigationController().pushViewController(vc)
}else{
diff --git a/XQMuse/Root/Course/TCell/CourseDetail_3_TCell.xib b/XQMuse/Root/Course/TCell/CourseDetail_3_TCell.xib
index acc54db..88c4ddb 100644
--- a/XQMuse/Root/Course/TCell/CourseDetail_3_TCell.xib
+++ b/XQMuse/Root/Course/TCell/CourseDetail_3_TCell.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
@@ -17,8 +17,8 @@
<rect key="frame" x="0.0" y="0.0" width="455" height="347"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
- <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="相关课程" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0G9-B5-m4l">
- <rect key="frame" x="21.666666666666668" y="35" width="61.333333333333329" height="14.666666666666664"/>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="相关推荐" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0G9-B5-m4l">
+ <rect key="frame" x="21.666666666666668" y="35" width="59.666666666666657" height="14.666666666666664"/>
<constraints>
<constraint firstAttribute="height" constant="14.5" id="COr-dp-lCx"/>
</constraints>
diff --git a/XQMuse/Root/Course/VC/CourseDetialVC.swift b/XQMuse/Root/Course/VC/CourseDetialVC.swift
index 99ab290..6fbe652 100644
--- a/XQMuse/Root/Course/VC/CourseDetialVC.swift
+++ b/XQMuse/Root/Course/VC/CourseDetialVC.swift
@@ -163,7 +163,7 @@
switch m.chargeType{
case .free:needPayment = false
case .payment:needPayment = !(m.isBuy == .yes)
- case .vipFree:needPayment = !(UserViewModel.getAvatarInfo().isVip == .yes)
+ case .vipFree:needPayment = !UserViewModel.getAvatarInfo().checkVip()
}
if needPayment{
@@ -262,9 +262,9 @@
@objc func handleAction(_ btn:QMUIButton){
if let m = courseDetailModel{
- if m.chargeType == .free || (m.chargeType == .vipFree && UserViewModel.getAvatarInfo().isVip == .yes) || (m.chargeType == .payment && m.isBuy == .yes){
+ if m.chargeType == .free || (m.chargeType == .vipFree && UserViewModel.getAvatarInfo().checkVip()) || (m.chargeType == .payment && m.isBuy == .yes){
guard m.list.count != 0 else {
- alertError(msg: "课程目录异常");return
+ alertError(msg: "该课程暂未添加章节");return
}
let vc = CourseDetialVideoVC(items: m.list, selectIndex: IndexPath(row: 0, section: 0))
push(vc: vc);return
diff --git a/XQMuse/Root/Course/VC/CourseDetialVideoVC.swift b/XQMuse/Root/Course/VC/CourseDetialVideoVC.swift
index ee4bba3..819bb98 100644
--- a/XQMuse/Root/Course/VC/CourseDetialVideoVC.swift
+++ b/XQMuse/Root/Course/VC/CourseDetialVideoVC.swift
@@ -113,7 +113,7 @@
if selectIndex == indexPath{return}
selectIndex = indexPath
- videoView?.updateVideoUrl(items[indexPath.row].videoUrl)
+ videoView?.updateVideoUrl(items[indexPath.row].videoUrl.jq_urlEncoded())
tableView.reloadData()
}
}
diff --git a/XQMuse/Root/Course/VC/CourseVCOfficalCommentVC.swift b/XQMuse/Root/Course/VC/CourseVCOfficalCommentVC.swift
index 1d57422..8269fa0 100644
--- a/XQMuse/Root/Course/VC/CourseVCOfficalCommentVC.swift
+++ b/XQMuse/Root/Course/VC/CourseVCOfficalCommentVC.swift
@@ -136,7 +136,7 @@
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize {
if indexPath.section == 0{
- let h = ceil(subTitleItems.count.double / 4.0) * 101.25 + floor(subTitleItems.count.double / 4.0) * 5 + 208.5
+ let h = ceil(subTitleItems.count.double / 4.0) * 103.75 + floor(subTitleItems.count.double / 4.0) * 5 + 208.5
return CGSize(width: JQ_ScreenW, height: h)
}
diff --git a/XQMuse/Root/Course/View/CourseDetailHeaderView.swift b/XQMuse/Root/Course/View/CourseDetailHeaderView.swift
index c29e0ae..36f4835 100644
--- a/XQMuse/Root/Course/View/CourseDetailHeaderView.swift
+++ b/XQMuse/Root/Course/View/CourseDetailHeaderView.swift
@@ -27,7 +27,7 @@
label_title.text = model.courseTitle
label_teacher.text = "导师 \(model.tutor)"
label_studyNum.text = "\(model.count)人已加入学习"
- image_cover.sd_setImage(with: URL(string: model.coverUrl.jq_urlEncoded()))
+ image_cover.sd_setImage(with: URL(string: model.detailUrl.jq_urlEncoded()))
}
func setVideo(url:String,coverImageUrl:String,delegate:CLPlayerDelegate){
diff --git a/XQMuse/Root/Course/View/CourseSendGiftView.swift b/XQMuse/Root/Course/View/CourseSendGiftView.swift
index af9075f..c67584e 100644
--- a/XQMuse/Root/Course/View/CourseSendGiftView.swift
+++ b/XQMuse/Root/Course/View/CourseSendGiftView.swift
@@ -28,6 +28,7 @@
static func show(price:Double,clouse:@escaping()->Void){
let view = CourseSendGiftView.jq_loadNibView()
+ view.frame = sceneDelegate?.window?.frame ?? .zero
view.label_price.text = "¥\(price.jq_formatFloat)"
sceneDelegate?.window?.addSubview(view)
view.clouse = clouse
@@ -40,7 +41,7 @@
override func layoutSubviews() {
super.layoutSubviews()
- btn_complete.jq_gradientNibColor(colorArr: [UIColor(hexStr: "#8EA47A").cgColor,UIColor(hexStr: "#AFCA98").cgColor], cornerRadius: 18.5)
+ btn_complete.localGradientColor(cornerRadius: 18.5,bounds: CGRect(x: 0, y: 0, width: JQ_ScreenW - 46 * 2, height: 40))
}
@IBAction func completeAction(_ sender: UIButton) {
diff --git a/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_1_CCell.swift b/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_1_CCell.swift
index 95f8c3d..062b2af 100644
--- a/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_1_CCell.swift
+++ b/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_1_CCell.swift
@@ -43,7 +43,9 @@
img_cover.sd_setImage(with: URL(string: model.coverUrl.jq_urlEncoded().components(separatedBy: ",").first))
label_title.text = model.courseTitle
- label_subTitle.text = model.briefIntroduction
+// label_subTitle.text = model.briefIntroduction
+ label_subTitle.text = model.description
+
label_num.text = "\(model.count)"
if model.courseType == .online{
diff --git a/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_CCell.swift b/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_CCell.swift
index 24a30ef..2dfa0d8 100644
--- a/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_CCell.swift
+++ b/XQMuse/Root/Home/CCell/HomeRelaxBanner_2_CCell.swift
@@ -24,6 +24,8 @@
@IBOutlet weak var img_offline: UIImageView!
private var meditationModel:MeditationModel?
+ private var showType: DisplayType!
+
override func awakeFromNib() {
super.awakeFromNib()
// Initialization code
@@ -43,8 +45,17 @@
view_price.jq_cornerRadius = 12.55
}
- func setMeditationModel(_ model:MeditationModel){
- img_cover.sd_setImage(with: URL(string: model.coverUrl.jq_urlEncoded().components(separatedBy: ",").last))
+ func setMeditationModel(_ model:MeditationModel,showType:DisplayType){
+
+ var imageUrl:String!
+ switch showType {
+ case .horizontal:
+ imageUrl = model.coverUrl.components(separatedBy: ",").first
+ case .vertical:
+ imageUrl = model.coverUrl.components(separatedBy: ",").last
+ }
+
+ img_cover.sd_setImage(with: URL(string: imageUrl))
label_title.text = model.meditationTitle
label_subTitle.text = model.coverDescription
label_num.text = "\(model.realLearnedNum)"
diff --git a/XQMuse/Root/Home/HomeVC.swift b/XQMuse/Root/Home/HomeVC.swift
index c6c5390..5c65bc3 100644
--- a/XQMuse/Root/Home/HomeVC.swift
+++ b/XQMuse/Root/Home/HomeVC.swift
@@ -136,7 +136,7 @@
override func setRx() {
topMenuView.clickItemAt {[unowned self] item in
- let vc = HomeItemListVC(topTitle: item.title, id: item.id)
+ let vc = HomeItemListVC(topTitle: item.title, id: item.id, showType:.horizontal)
self.push(vc: vc)
}
@@ -244,6 +244,12 @@
}
}).disposed(by: disposeBag)
+
+ if !(UserViewModel.getLoginInfo()?.accessToken.isEmpty ?? true){
+ Services.getUserDetail().subscribe(onNext: {data in
+ if let m = data.data{UserViewModel.saveAvatarInfo(m)}
+ }).disposed(by: disposeBag)
+ }
}
@objc func searchAction(){
@@ -269,7 +275,7 @@
let topTitle = titleItems[sender.tag - 200].title
let m = viewModel.meditationList[sender.tag - 200 - 3]
if let id = m.clientMeditationCategoryVO?.id{
- let vc = HomeItemListVC(topTitle: topTitle, id: id)
+ let vc = HomeItemListVC(topTitle: topTitle, id: id,showType: m.clientMeditationCategoryVO!.showType)
push(vc: vc)
}
}
diff --git a/XQMuse/Root/Home/TCell/Home_Style_3_TCell.swift b/XQMuse/Root/Home/TCell/Home_Style_3_TCell.swift
index 0873903..f671e52 100644
--- a/XQMuse/Root/Home/TCell/Home_Style_3_TCell.swift
+++ b/XQMuse/Root/Home/TCell/Home_Style_3_TCell.swift
@@ -51,9 +51,9 @@
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
let m = meditationModels[indexPath.row]
- let isVip = UserViewModel.getAvatarInfo().isVip
+ let isVip = UserViewModel.getAvatarInfo().checkVip()
- if m.chargeType == .free || (isVip == .yes && m.chargeType == .vipFree) || (m.chargeType == .payment && m.isBuy == .yes){
+ if m.chargeType == .free || (isVip && m.chargeType == .vipFree) || (m.chargeType == .payment && m.isBuy == .yes){
let vc = HomeItemDetailVC(id: m.id)
JQ_currentViewController().jq_push(vc: vc)
return
diff --git a/XQMuse/Root/Home/TCell/Home_Style_4_TCell.swift b/XQMuse/Root/Home/TCell/Home_Style_4_TCell.swift
index fd1fa6b..fa61359 100644
--- a/XQMuse/Root/Home/TCell/Home_Style_4_TCell.swift
+++ b/XQMuse/Root/Home/TCell/Home_Style_4_TCell.swift
@@ -47,9 +47,8 @@
alert(msg: "平台暂未设置私人定制");return
}
- let isVip = UserViewModel.getAvatarInfo().isVip
-
- if m.chargeType == .free || (m.chargeType == .vipFree && isVip == .yes) || (m.chargeType == .payment && m.isBuy == .yes){
+ let isVip = UserViewModel.getAvatarInfo().checkVip()
+ if m.chargeType == .free || (m.chargeType == .vipFree && isVip) || (m.chargeType == .payment && m.isBuy == .yes){
let detailVC = HomeItemDetailVC(id: meditationModels[indexPath.row].id)
JQ_currentViewController().jq_push(vc: detailVC)
}else{
diff --git a/XQMuse/Root/Home/TCell/Home_Style_5_TCell.swift b/XQMuse/Root/Home/TCell/Home_Style_5_TCell.swift
index fcba4cf..f6546db 100644
--- a/XQMuse/Root/Home/TCell/Home_Style_5_TCell.swift
+++ b/XQMuse/Root/Home/TCell/Home_Style_5_TCell.swift
@@ -63,7 +63,7 @@
@objc func tapAction(_ btn:UIButton){
let index = btn.tag - 1000
- let vc = HomeItemListVC(topTitle: items[index].title, id: items[index].id)
+ let vc = HomeItemListVC(topTitle: items[index].title, id: items[index].id,showType: .vertical)
JQ_currentViewController().jq_push(vc: vc)
}
}
diff --git a/XQMuse/Root/Home/VC/HomeItemListVC.swift b/XQMuse/Root/Home/VC/HomeItemListVC.swift
index 257dfcd..c57fb6f 100644
--- a/XQMuse/Root/Home/VC/HomeItemListVC.swift
+++ b/XQMuse/Root/Home/VC/HomeItemListVC.swift
@@ -23,10 +23,12 @@
private var collectionView:UICollectionView!
private var topTitle:String!
private var viewModel = HomeItemViewModel()
+ private var showType: DisplayType!
- init(topTitle:String,id:Int) {
+ init(topTitle:String,id:Int,showType: DisplayType) {
super.init(nibName: nil, bundle: nil)
self.topTitle = topTitle
+ self.showType = showType
self.viewModel.id.accept(id)
}
@@ -69,7 +71,7 @@
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "_HomeRelaxBanner_2_CCell", for: indexPath) as! HomeRelaxBanner_2_CCell
let model = viewModel.dataSource.value!.list[indexPath.row]
- cell.setMeditationModel(model)
+ cell.setMeditationModel(model,showType: showType)
return cell
}
@@ -80,9 +82,9 @@
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
let m = viewModel.dataSource.value!.list[indexPath.row]
- let isVip = UserViewModel.getAvatarInfo().isVip
+ let isVip = UserViewModel.getAvatarInfo().checkVip()
- if m.chargeType == .free || (m.chargeType == .vipFree && isVip == .yes) || (m.chargeType == .payment && m.isBuy == .yes){
+ if m.chargeType == .free || (m.chargeType == .vipFree && isVip) || (m.chargeType == .payment && m.isBuy == .yes){
let detailVC = HomeItemDetailVC(id: m.id)
jq_push(vc: detailVC)
}else{
diff --git a/XQMuse/Root/Home/VC/PaymentOrderVC.swift b/XQMuse/Root/Home/VC/PaymentOrderVC.swift
index e3c880a..21e1b80 100644
--- a/XQMuse/Root/Home/VC/PaymentOrderVC.swift
+++ b/XQMuse/Root/Home/VC/PaymentOrderVC.swift
@@ -75,7 +75,7 @@
self.label_courseName.text = m.courseTitle
self.label_price.text = "愈疗币\(m.iosPrice.jq_formatFloat)"
self.label_teacher.text = "导师 \(m.tutor)"
- self.label_paymentCount.text = "x\(m.count == 0 ? 1:m.count)"
+ self.label_paymentCount.text = "x1"
self.label_orderPrice.text = "愈疗币\(m.iosPrice.jq_formatFloat)"
self.label_totalPrice.text = "愈疗币\(m.iosPrice.jq_formatFloat)"
}
@@ -190,9 +190,10 @@
}
guard balance > money else{
- CommonAlertView.show(title: "提示", content: "当前余额不足,请先充值", cancelStr: "暂不充值", completeStr: "去充值", isSingle: false) { state in
+ CommonAlertView.show(title: "提示", content: "当前余额不足,请先充值", cancelStr: "暂不充值", completeStr: "去充值", isSingle: false) {[weak self] state in
if state{
-
+ let vc = WalletRechargeVC()
+ self?.push(vc: vc)
}
}
return
diff --git a/XQMuse/Root/Home/VC/SearchContentVC.swift b/XQMuse/Root/Home/VC/SearchContentVC.swift
index 7e689a5..2bd281d 100644
--- a/XQMuse/Root/Home/VC/SearchContentVC.swift
+++ b/XQMuse/Root/Home/VC/SearchContentVC.swift
@@ -128,12 +128,12 @@
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
- let isVip = UserViewModel.getAvatarInfo().isVip
+ let isVip = UserViewModel.getAvatarInfo().checkVip()
switch serchType{
case .course:
let m = courseViewModel!.dataSource.value!.list[indexPath.row]
- if m.chargeType == .free || (m.chargeType == .vipFree && isVip == .yes) || (m.chargeType == .payment && m.isBuy == .yes){
+ if m.chargeType == .free || (m.chargeType == .vipFree && isVip) || (m.chargeType == .payment && m.isBuy == .yes){
if m.courseType == .online{
let vc = CourseDetialVC(courseId: m.id)
@@ -154,7 +154,7 @@
case .muse:
let m = museViewModel!.dataSource.value!.list[indexPath.row]
- if m.chargeType == .free || (m.chargeType == .vipFree && isVip == .yes) || (m.chargeType == .payment && m.isBuy == .yes){
+ if m.chargeType == .free || (m.chargeType == .vipFree && isVip) || (m.chargeType == .payment && m.isBuy == .yes){
let detailVC = HomeItemDetailVC(id: m.id)
JQ_currentViewController().jq_push(vc: detailVC)
}else{
@@ -181,7 +181,7 @@
cell.setCourseModel(m)
case .muse:
let m = museViewModel!.dataSource.value!.list[indexPath.row]
- cell.setMeditationModel(m)
+ cell.setMeditationModel(m, showType: .vertical)
default:break
}
diff --git a/XQMuse/Root/Me/MeVC.swift b/XQMuse/Root/Me/MeVC.swift
index 6c4dad3..191c4fa 100644
--- a/XQMuse/Root/Me/MeVC.swift
+++ b/XQMuse/Root/Me/MeVC.swift
@@ -87,16 +87,18 @@
self.label_userName.text = "请先登录"
self.image_userAvatar.image = nil
self.label_phone.text = ""
- self.label_totalDay.attributedText = AttributedStringbuilder.build().add(string: "0", withFont: UIFont.init(name: "PingFang-SC-Regular", size: 60)!, withColor: UIColor(hexString: "#152715")!).add(string: "天", withFont: .systemFont(ofSize: 16), withColor: UIColor(hexString: "#152715")!).mutableAttributedString
+
+ self.label_totalDay.attributedText = AttributedStringbuilder.build().add(string: "0", withFont: Def_PingFang(fontSize: 60), withColor: UIColor(hexString: "#152715")!).add(string: "天", withFont: Def_PingFang(fontSize: 16), withColor: UIColor(hexString: "#353535")!).mutableAttributedString
self.image_medal.image = nil
- self.label_sustainDay.attributedText = AttributedStringbuilder.build().add(string: "0", withFont: .systemFont(ofSize: 23), withColor: UIColor(hexString: "#152715")!).add(string: "天", withFont: .systemFont(ofSize: 12), withColor: UIColor(hexString: "#152715")!).mutableAttributedString
+ self.label_sustainDay.attributedText = AttributedStringbuilder.build().add(string: "0", withFont: Def_PingFang(fontSize: 23), withColor: UIColor(hexString: "#353535")!).add(string: "天", withFont: Def_PingFang(fontSize: 12), withColor: UIColor(hexString: "#353535")!).mutableAttributedString
self.image_vipBg.image = UIImage(named: "bg_vip_u")
self.label_vipInfo.text = "升级为会员,解锁会员专属体验"
self.label_expirtTime.text = "你还未开通会员服务"
-
+ self.navigationController?.popToRootViewController(animated: false)
+ self.navigationController?.tabBarController?.selectedIndex = 0
}).disposed(by: disposeBag)
}
@@ -121,15 +123,15 @@
self.label_userName.text = model.nickname
self.label_phone.text = model.cellPhone
- self.label_totalDay.attributedText = AttributedStringbuilder.build().add(string: "\(model.cumulative)", withFont: UIFont.init(name: "PingFang-SC-Regular", size: 60)!, withColor: UIColor(hexString: "#152715")!).add(string: "天", withFont: .systemFont(ofSize: 16), withColor: UIColor(hexString: "#152715")!).mutableAttributedString
+ self.label_totalDay.attributedText = AttributedStringbuilder.build().add(string: "\(model.cumulative)", withFont: Def_PingFang(fontSize: 60), withColor: UIColor(hexString: "#353535")!).add(string: "天", withFont: Def_PingFang(fontSize: 16), withColor: UIColor(hexString: "#353535")!).mutableAttributedString
- self.label_sustainDay.attributedText = AttributedStringbuilder.build().add(string: "\(model.continuity)", withFont: .systemFont(ofSize: 23), withColor: UIColor(hexString: "#152715")!).add(string: "天", withFont: .systemFont(ofSize: 12), withColor: UIColor(hexString: "#152715")!).mutableAttributedString
+ self.label_sustainDay.attributedText = AttributedStringbuilder.build().add(string: "\(model.continuity)", withFont: Def_PingFang(fontSize:23), withColor: UIColor(hexString: "#353535")!).add(string: "天", withFont: Def_PingFang(fontSize:12), withColor: UIColor(hexString: "#353535")!).mutableAttributedString
self.image_medal.sd_setImage(with: URL(string: model.levelIcon.jq_urlEncoded()))
let timeTurple = Date.jq_formateToTime_tuple(model.today * 60)
- self.label_today.attributedText = AttributedStringbuilder.build().add(string: "\(timeTurple.hour)", withFont: .systemFont(ofSize: 23), withColor: UIColor(hexString: "#152715")!).add(string: "时", withFont: .systemFont(ofSize: 12), withColor: UIColor(hexString: "#152715")!).add(string: "\(timeTurple.minute)", withFont: .systemFont(ofSize: 23), withColor: UIColor(hexString: "#152715")!).add(string: "分", withFont: .systemFont(ofSize: 12), withColor: UIColor(hexString: "#152715")!).mutableAttributedString
+ self.label_today.attributedText = AttributedStringbuilder.build().add(string: "\(timeTurple.hour)", withFont: Def_PingFang(fontSize:23), withColor: UIColor(hexString: "#353535")!).add(string: "时", withFont: Def_PingFang(fontSize:12), withColor: UIColor(hexString: "#353535")!).add(string: "\(timeTurple.minute)", withFont: Def_PingFang(fontSize:23), withColor: UIColor(hexString: "#353535")!).add(string: "分", withFont: Def_PingFang(fontSize: 12), withColor: UIColor(hexString: "#353535")!).mutableAttributedString
if model.isVip == .yes{
self.image_vipBg.image = UIImage(named: "bg_vip")
diff --git a/XQMuse/Root/Me/MeVC.xib b/XQMuse/Root/Me/MeVC.xib
index a4d1e43..5c63213 100644
--- a/XQMuse/Root/Me/MeVC.xib
+++ b/XQMuse/Root/Me/MeVC.xib
@@ -39,7 +39,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="1283"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="PbG-Pc-wLz">
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="PbG-Pc-wLz">
<rect key="frame" x="0.0" y="0.0" width="393" height="297"/>
</imageView>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="eKy-w2-ydR">
@@ -168,13 +168,13 @@
<rect key="frame" x="70" y="92.666666666666686" width="228" height="171"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="累积练习天数" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="1zm-h2-b9F">
- <rect key="frame" x="136.33333333333334" y="157.33333333333331" width="95.333333333333343" height="19.333333333333343"/>
- <fontDescription key="fontDescription" type="system" pointSize="16"/>
+ <rect key="frame" x="136" y="157.33333333333331" width="96" height="22.666666666666657"/>
+ <fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="16"/>
<color key="textColor" red="0.082352941176470587" green="0.15294117647058825" blue="0.082352941176470587" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="0天" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="YPb-vk-RCa">
- <rect key="frame" x="136.66666666666669" y="192" width="94.666666666666686" height="45"/>
+ <rect key="frame" x="136.66666666666669" y="195.33333333333331" width="94.666666666666686" height="45"/>
<constraints>
<constraint firstAttribute="height" constant="45" id="Ma8-cs-j54"/>
</constraints>
@@ -183,7 +183,7 @@
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="4ho-wk-mFw">
- <rect key="frame" x="21.333333333333343" y="300" width="325" height="71"/>
+ <rect key="frame" x="21.333333333333343" y="303.33333333333337" width="325" height="71"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="XmC-Kd-dmq">
<rect key="frame" x="162" y="20.666666666666629" width="1" height="30"/>
@@ -205,13 +205,13 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="连续练习天数" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Wrx-Ep-1Ev">
- <rect key="frame" x="42.333333333333321" y="12.333333333333371" width="77.666666666666686" height="15.666666666666664"/>
- <fontDescription key="fontDescription" type="system" pointSize="13"/>
- <nil key="textColor"/>
+ <rect key="frame" x="42" y="9.666666666666627" width="78" height="18.333333333333329"/>
+ <fontDescription key="fontDescription" name="PingFangSC-Light" family="PingFang SC" pointSize="13"/>
+ <color key="textColor" red="0.20784313725490194" green="0.20784313725490194" blue="0.20784313725490194" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="lJq-Or-aac">
- <rect key="frame" x="30.333333333333325" y="17" width="6.3333333333333321" height="6.6666666666666679"/>
+ <rect key="frame" x="30.000000000000004" y="15.666666666666627" width="6.6666666666666679" height="6.6666666666666661"/>
<color key="backgroundColor" red="0.6705882352941176" green="0.89803921568627454" blue="0.68627450980392157" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="6.5" id="ODt-X4-p9t"/>
@@ -224,14 +224,14 @@
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
- <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="连续练习天数" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ihW-8E-Omi">
- <rect key="frame" x="205.33333333333334" y="12.333333333333371" width="77.666666666666657" height="15.666666666666664"/>
- <fontDescription key="fontDescription" type="system" pointSize="13"/>
- <nil key="textColor"/>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="今日练习时长" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ihW-8E-Omi">
+ <rect key="frame" x="205" y="9.666666666666627" width="78" height="18.333333333333329"/>
+ <fontDescription key="fontDescription" name="PingFangSC-Light" family="PingFang SC" pointSize="13"/>
+ <color key="textColor" red="0.20784313725490194" green="0.20784313725490194" blue="0.20784313725490194" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Tba-o9-bKq">
- <rect key="frame" x="193.33333333333334" y="17" width="6.3333333333333428" height="6.6666666666666679"/>
+ <rect key="frame" x="193" y="15.666666666666627" width="6.6666666666666572" height="6.6666666666666661"/>
<color key="backgroundColor" red="0.6705882353" green="0.8980392157" blue="0.68627450980000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="6.5" id="MST-0N-jSt"/>
@@ -268,10 +268,10 @@
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="n62-aO-gnS" customClass="TapBtn" customModule="XQMuse" customModuleProvider="target">
- <rect key="frame" x="21.333333333333343" y="386.66666666666663" width="325" height="50.333333333333314"/>
+ <rect key="frame" x="21.333333333333343" y="390" width="325" height="50.333333333333314"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="疗愈等级" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="z63-U0-xCY">
- <rect key="frame" x="4.6666666666666679" y="16.666666666666742" width="55.666666666666657" height="17"/>
+ <rect key="frame" x="4.6666666666666679" y="16.666666666666629" width="55.666666666666657" height="17"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<color key="textColor" red="0.13725490196078433" green="0.13725490196078433" blue="0.13725490196078433" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
@@ -284,7 +284,7 @@
</constraints>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="查看详情" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="flg-Hv-HHC">
- <rect key="frame" x="264.66666666666669" y="18.666666666666742" width="44" height="13.333333333333336"/>
+ <rect key="frame" x="264.66666666666669" y="18.666666666666629" width="44" height="13.333333333333336"/>
<fontDescription key="fontDescription" type="system" pointSize="11"/>
<color key="textColor" red="0.40392156862745099" green="0.40392156862745099" blue="0.40392156862745099" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
diff --git a/XQMuse/Root/Me/VC/BankWithdrawVC.swift b/XQMuse/Root/Me/VC/BankWithdrawVC.swift
index b6baea0..f1c5889 100644
--- a/XQMuse/Root/Me/VC/BankWithdrawVC.swift
+++ b/XQMuse/Root/Me/VC/BankWithdrawVC.swift
@@ -16,7 +16,8 @@
@IBOutlet weak var tf_withdraw: UITextField!
@IBOutlet weak var cons_height: NSLayoutConstraint!
@IBOutlet weak var label_income: UILabel!
- private var selectIndexPath:IndexPath?
+ @IBOutlet weak var btn_complete: UIButton!
+ private var selectIndexPath:IndexPath?
private var bankModels = [BankInfoModel]()
private var income:CGFloat = 0
@@ -32,9 +33,12 @@
override func viewDidLoad() {
super.viewDidLoad()
- title = "收益提现"
+ title = "余额提现"
label_income.text = "可提现余额:¥" + income.jq_formatFloat
getBanks()
+
+ btn_complete.isEnabled = false
+ btn_complete.alpha = 0.6
}
override func setUI() {
@@ -53,6 +57,11 @@
NotificationCenter.default.rx.notification(AddBank_Noti, object: nil).take(until: self.rx.deallocated).subscribe(onNext: { _ in
self.getBanks()
}).disposed(by: disposeBag)
+
+ tf_withdraw.rx.text.orEmpty.subscribe(onNext: {[weak self] text in
+ self?.btn_complete.isEnabled = !text.isEmpty
+ self?.btn_complete.alpha = text.isEmpty ? 0.6:1.0
+ }).disposed(by: disposeBag)
}
@@ -109,6 +118,11 @@
self.tf_withdraw.resignFirstResponder()
}).disposed(by: disposeBag)
}
+
+ override func viewDidLayoutSubviews() {
+ super.viewDidLayoutSubviews()
+ btn_complete.localGradientColor(cornerRadius: 20)
+ }
}
extension BankWithdrawVC:UITableViewDelegate & UITableViewDataSource{
@@ -131,18 +145,19 @@
func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCell.EditingStyle, forRowAt indexPath: IndexPath) {
let id = bankModels[indexPath.row].id
- CommonAlertView.show(title: "提示", content: "是否删除此张银行卡?") { _ in
- Services.deleteBank(id).subscribe(onNext: { _ in
- self.tableView.beginUpdates()
- self.bankModels.remove(at: indexPath.row)
- self.tableView.deleteItemsAtIndexPaths([indexPath], animationStyle: .left)
- self.tableView.endUpdates()
- self.cons_height.constant = CGFloat(self.bankModels.count) * 84.0
- UIView.animate(withDuration: 0.4) {
- self.view.layoutIfNeeded()
- }
- }).disposed(by: self.disposeBag)
-
+ CommonAlertView.show(title: "提示", content: "是否删除此张银行卡?") { state in
+ if state{
+ Services.deleteBank(id).subscribe(onNext: { _ in
+ self.tableView.beginUpdates()
+ self.bankModels.remove(at: indexPath.row)
+ self.tableView.deleteItemsAtIndexPaths([indexPath], animationStyle: .left)
+ self.tableView.endUpdates()
+ self.cons_height.constant = CGFloat(self.bankModels.count) * 84.0
+ UIView.animate(withDuration: 0.4) {
+ self.view.layoutIfNeeded()
+ }
+ }).disposed(by: self.disposeBag)
+ }
}
}
diff --git a/XQMuse/Root/Me/VC/BankWithdrawVC.xib b/XQMuse/Root/Me/VC/BankWithdrawVC.xib
index fe65558..adee65d 100644
--- a/XQMuse/Root/Me/VC/BankWithdrawVC.xib
+++ b/XQMuse/Root/Me/VC/BankWithdrawVC.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -11,6 +11,7 @@
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="BankWithdrawVC" customModule="XQMuse" customModuleProvider="target">
<connections>
+ <outlet property="btn_complete" destination="b5b-HD-xwQ" id="hOX-E4-ru6"/>
<outlet property="cons_height" destination="JnR-vu-dbn" id="8dW-o7-cqk"/>
<outlet property="label_income" destination="Jnw-DF-MrW" id="Geg-l9-clW"/>
<outlet property="tableView" destination="ANy-Y0-lhb" id="VHQ-LH-zK3"/>
@@ -23,59 +24,59 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
+ <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="5CF-zo-zBJ">
+ <rect key="frame" x="14" y="69" width="365" height="40"/>
+ <subviews>
+ <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="e5j-K3-G1y" customClass="QMUIButton">
+ <rect key="frame" x="127.66666666666666" y="9" width="110" height="22"/>
+ <constraints>
+ <constraint firstAttribute="height" constant="22" id="osq-rB-xnm"/>
+ </constraints>
+ <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+ <state key="normal" title="添加银行卡" image="btn_add">
+ <color key="titleColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="0.69999999999999996" colorSpace="custom" customColorSpace="sRGB"/>
+ </state>
+ <userDefinedRuntimeAttributes>
+ <userDefinedRuntimeAttribute type="number" keyPath="spacingBetweenImageAndTitle">
+ <real key="value" value="11"/>
+ </userDefinedRuntimeAttribute>
+ </userDefinedRuntimeAttributes>
+ <connections>
+ <action selector="addBankCardAction:" destination="-1" eventType="touchUpInside" id="ciD-sJ-quM"/>
+ </connections>
+ </button>
+ </subviews>
+ <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+ <constraints>
+ <constraint firstAttribute="height" constant="40" id="aSk-4S-Kqh"/>
+ <constraint firstItem="e5j-K3-G1y" firstAttribute="centerX" secondItem="5CF-zo-zBJ" secondAttribute="centerX" id="bwi-MC-8l1"/>
+ <constraint firstItem="e5j-K3-G1y" firstAttribute="centerY" secondItem="5CF-zo-zBJ" secondAttribute="centerY" id="lfh-wL-VtQ"/>
+ </constraints>
+ <userDefinedRuntimeAttributes>
+ <userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
+ <userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
+ <real key="value" value="4"/>
+ </userDefinedRuntimeAttribute>
+ </userDefinedRuntimeAttributes>
+ </view>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" translatesAutoresizingMaskIntoConstraints="NO" id="9BP-hx-1CV">
- <rect key="frame" x="0.0" y="59" width="393" height="759"/>
+ <rect key="frame" x="0.0" y="119" width="393" height="699"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="GWM-A7-0N4">
<rect key="frame" x="0.0" y="0.0" width="393" height="800"/>
<subviews>
- <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="5CF-zo-zBJ">
- <rect key="frame" x="14" y="10" width="365" height="40"/>
- <subviews>
- <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="e5j-K3-G1y" customClass="QMUIButton">
- <rect key="frame" x="126.66666666666666" y="9" width="112" height="22"/>
- <constraints>
- <constraint firstAttribute="height" constant="22" id="osq-rB-xnm"/>
- </constraints>
- <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
- <state key="normal" title="添加银行卡" image="btn_add">
- <color key="titleColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="0.69999999999999996" colorSpace="custom" customColorSpace="sRGB"/>
- </state>
- <userDefinedRuntimeAttributes>
- <userDefinedRuntimeAttribute type="number" keyPath="spacingBetweenImageAndTitle">
- <real key="value" value="11"/>
- </userDefinedRuntimeAttribute>
- </userDefinedRuntimeAttributes>
- <connections>
- <action selector="addBankCardAction:" destination="-1" eventType="touchUpInside" id="ciD-sJ-quM"/>
- </connections>
- </button>
- </subviews>
- <color key="backgroundColor" systemColor="systemBackgroundColor"/>
- <constraints>
- <constraint firstAttribute="height" constant="40" id="aSk-4S-Kqh"/>
- <constraint firstItem="e5j-K3-G1y" firstAttribute="centerX" secondItem="5CF-zo-zBJ" secondAttribute="centerX" id="bwi-MC-8l1"/>
- <constraint firstItem="e5j-K3-G1y" firstAttribute="centerY" secondItem="5CF-zo-zBJ" secondAttribute="centerY" id="lfh-wL-VtQ"/>
- </constraints>
- <userDefinedRuntimeAttributes>
- <userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
- <userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
- <real key="value" value="4"/>
- </userDefinedRuntimeAttribute>
- </userDefinedRuntimeAttributes>
- </view>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" scrollEnabled="NO" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" style="plain" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="-1" estimatedSectionHeaderHeight="-1" sectionFooterHeight="-1" estimatedSectionFooterHeight="-1" translatesAutoresizingMaskIntoConstraints="NO" id="ANy-Y0-lhb">
- <rect key="frame" x="0.0" y="55" width="393" height="50"/>
+ <rect key="frame" x="0.0" y="0.0" width="393" height="50"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="height" constant="50" id="JnR-vu-dbn"/>
</constraints>
</tableView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="dzL-mF-fWd">
- <rect key="frame" x="14" y="119.99999999999999" width="365" height="198.66666666666663"/>
+ <rect key="frame" x="14" y="64.999999999999986" width="365" height="198.66666666666663"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="提现方式" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="V3v-rW-oAU">
- <rect key="frame" x="10" y="17" width="65.333333333333329" height="19.333333333333329"/>
+ <rect key="frame" x="9.9999999999999964" y="17" width="63.666666666666657" height="19.333333333333329"/>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="16"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
@@ -84,13 +85,13 @@
<rect key="frame" x="349" y="21.333333333333343" width="6" height="10.666666666666664"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="银行卡" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="cQl-FF-lcU">
- <rect key="frame" x="292" y="17" width="49" height="19.333333333333329"/>
+ <rect key="frame" x="293.33333333333331" y="17" width="47.666666666666686" height="19.333333333333329"/>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="16"/>
<color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="0.80000000000000004" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_bankCard" translatesAutoresizingMaskIntoConstraints="NO" id="kNx-8Z-GFE">
- <rect key="frame" x="265" y="19.666666666666657" width="19" height="14"/>
+ <rect key="frame" x="266.33333333333331" y="19.666666666666657" width="19" height="14"/>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="DVz-Aw-J8e">
<rect key="frame" x="9" y="53.333333333333343" width="347" height="1"/>
@@ -100,7 +101,7 @@
</constraints>
</view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="提现金额" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ROF-gy-jCH">
- <rect key="frame" x="10.000000000000004" y="67.333333333333343" width="57.333333333333343" height="20"/>
+ <rect key="frame" x="9.9999999999999964" y="67.333333333333343" width="55.666666666666657" height="20"/>
<constraints>
<constraint firstAttribute="height" constant="20" id="2sL-SB-1hq"/>
</constraints>
@@ -130,13 +131,13 @@
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
</textField>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="可提现余额:¥0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Jnw-DF-MrW">
- <rect key="frame" x="10" y="165.33333333333331" width="103.66666666666667" height="17"/>
- <fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
- <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="0.68999999999999995" colorSpace="custom" customColorSpace="sRGB"/>
+ <rect key="frame" x="10" y="165.33333333333331" width="101" height="17"/>
+ <fontDescription key="fontDescription" type="system" pointSize="14"/>
+ <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="0.59999999999999998" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="qK8-WH-Xjd">
- <rect key="frame" x="297" y="159.33333333333331" width="58" height="29"/>
+ <rect key="frame" x="299" y="159.33333333333331" width="56" height="29"/>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="全部提现">
@@ -184,7 +185,7 @@
</userDefinedRuntimeAttributes>
</view>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="b5b-HD-xwQ">
- <rect key="frame" x="45" y="359.66666666666669" width="303" height="40"/>
+ <rect key="frame" x="45" y="304.66666666666669" width="303" height="40"/>
<color key="backgroundColor" red="0.54117647059999996" green="0.68235294120000001" blue="0.39607843139999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="K5B-2c-JFV"/>
@@ -204,17 +205,14 @@
</button>
</subviews>
<constraints>
- <constraint firstAttribute="trailing" secondItem="5CF-zo-zBJ" secondAttribute="trailing" constant="14" id="AtI-ag-4ub"/>
+ <constraint firstItem="ANy-Y0-lhb" firstAttribute="top" secondItem="GWM-A7-0N4" secondAttribute="top" id="Ew2-3n-IVl"/>
<constraint firstAttribute="trailing" secondItem="ANy-Y0-lhb" secondAttribute="trailing" id="H0V-oB-XGa"/>
- <constraint firstItem="5CF-zo-zBJ" firstAttribute="leading" secondItem="GWM-A7-0N4" secondAttribute="leading" constant="14" id="IbU-p7-hiO"/>
<constraint firstItem="b5b-HD-xwQ" firstAttribute="leading" secondItem="GWM-A7-0N4" secondAttribute="leading" constant="45" id="KEd-wH-jhs"/>
<constraint firstAttribute="trailing" secondItem="dzL-mF-fWd" secondAttribute="trailing" constant="14" id="NDH-oM-eEj"/>
<constraint firstItem="ANy-Y0-lhb" firstAttribute="leading" secondItem="GWM-A7-0N4" secondAttribute="leading" id="RKG-cR-ugx"/>
<constraint firstAttribute="trailing" secondItem="b5b-HD-xwQ" secondAttribute="trailing" constant="45" id="TF8-SJ-usb"/>
- <constraint firstItem="5CF-zo-zBJ" firstAttribute="top" secondItem="GWM-A7-0N4" secondAttribute="top" constant="10" id="V9t-TN-46v"/>
<constraint firstAttribute="height" constant="800" id="WYF-xC-zHB"/>
<constraint firstItem="dzL-mF-fWd" firstAttribute="leading" secondItem="GWM-A7-0N4" secondAttribute="leading" constant="14" id="XW0-P2-yxo"/>
- <constraint firstItem="ANy-Y0-lhb" firstAttribute="top" secondItem="5CF-zo-zBJ" secondAttribute="bottom" constant="5" id="g0r-vN-Avk"/>
<constraint firstItem="b5b-HD-xwQ" firstAttribute="top" secondItem="dzL-mF-fWd" secondAttribute="bottom" constant="41" id="rDE-op-yQV"/>
<constraint firstItem="dzL-mF-fWd" firstAttribute="top" secondItem="ANy-Y0-lhb" secondAttribute="bottom" constant="15" id="vaj-30-Erp"/>
</constraints>
@@ -235,7 +233,10 @@
<constraint firstItem="9BP-hx-1CV" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="5ZU-jQ-JWI"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="9BP-hx-1CV" secondAttribute="trailing" id="9vx-XO-21l"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="bottom" secondItem="9BP-hx-1CV" secondAttribute="bottom" id="E2O-eV-Ebm"/>
- <constraint firstItem="9BP-hx-1CV" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" id="Xr9-dx-BFq"/>
+ <constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="5CF-zo-zBJ" secondAttribute="trailing" constant="14" id="MLb-VY-urZ"/>
+ <constraint firstItem="9BP-hx-1CV" firstAttribute="top" secondItem="5CF-zo-zBJ" secondAttribute="bottom" constant="10" id="XBP-qs-NOm"/>
+ <constraint firstItem="5CF-zo-zBJ" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="14" id="kFM-oK-FLh"/>
+ <constraint firstItem="5CF-zo-zBJ" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" constant="10" id="vkh-k2-3K9"/>
</constraints>
<point key="canvasLocation" x="139.69465648854961" y="20.422535211267608"/>
</view>
diff --git a/XQMuse/Root/Me/VC/BindPhone_2_VC.swift b/XQMuse/Root/Me/VC/BindPhone_2_VC.swift
index 6bd3b1f..f1e288f 100644
--- a/XQMuse/Root/Me/VC/BindPhone_2_VC.swift
+++ b/XQMuse/Root/Me/VC/BindPhone_2_VC.swift
@@ -17,6 +17,10 @@
override func viewDidLoad() {
super.viewDidLoad()
title = "更改绑定手机"
+
+ yy_popBlock = { [weak self] in
+ self?.navigationController?.popToRootViewController(animated: true)
+ }
}
@IBAction func sendCodeAction(_ sender: UIButton) {
@@ -56,8 +60,7 @@
Services.changePhone(phone: tf_phone.text!, code: tf_code.text!).subscribe(onNext: {data in
let vc = BindPhone_3_VC()
- vc.modalPresentationStyle = .fullScreen
- self.present(vc, animated: true)
+ self.push(vc: vc)
}).disposed(by: disposeBag)
}
diff --git a/XQMuse/Root/Me/VC/BindPhone_2_VC.xib b/XQMuse/Root/Me/VC/BindPhone_2_VC.xib
index de78517..3542255 100644
--- a/XQMuse/Root/Me/VC/BindPhone_2_VC.xib
+++ b/XQMuse/Root/Me/VC/BindPhone_2_VC.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -23,7 +23,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="更换绑定手机号" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="hYd-rC-GZY">
- <rect key="frame" x="44" y="128" width="149.66666666666666" height="29"/>
+ <rect key="frame" x="44" y="128" width="140.66666666666666" height="29"/>
<constraints>
<constraint firstAttribute="height" constant="29" id="n37-Dg-3xA"/>
</constraints>
@@ -32,7 +32,7 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="请输入手机号" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="7LE-go-AsO">
- <rect key="frame" x="44" y="164" width="86" height="14"/>
+ <rect key="frame" x="44.000000000000007" y="164" width="83.666666666666686" height="14"/>
<constraints>
<constraint firstAttribute="height" constant="14" id="zfh-eC-uuc"/>
</constraints>
@@ -40,29 +40,21 @@
<color key="textColor" red="0.59215686274509804" green="0.59215686274509804" blue="0.59215686274509804" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
- <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="0mo-0P-B1S">
- <rect key="frame" x="45" y="218" width="303" height="124"/>
+ <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="23" translatesAutoresizingMaskIntoConstraints="NO" id="0mo-0P-B1S">
+ <rect key="frame" x="45" y="218" width="303" height="150"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="TCO-QE-qOb">
- <rect key="frame" x="0.0" y="0.0" width="303" height="62"/>
+ <rect key="frame" x="0.0" y="0.0" width="303" height="65"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Be0-Ub-wt1">
- <rect key="frame" x="0.0" y="61.333333333333314" width="303" height="0.6666666666666643"/>
+ <rect key="frame" x="0.0" y="64.333333333333314" width="303" height="0.6666666666666714"/>
<color key="backgroundColor" red="0.96470588239999999" green="0.94901960780000005" blue="0.94901960780000005" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="0.63" id="TcT-Ix-T8r"/>
</constraints>
</view>
- <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="CtF-TA-Wqg">
- <rect key="frame" x="0.0" y="15" width="30" height="32"/>
- <fontDescription key="fontDescription" type="system" pointSize="16"/>
- <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
- <state key="normal" title="+86">
- <color key="titleColor" red="0.0" green="0.0" blue="0.0" alpha="0.80000000000000004" colorSpace="custom" customColorSpace="sRGB"/>
- </state>
- </button>
<textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入手机号" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="iVY-a7-Dza" customClass="QMUITextField">
- <rect key="frame" x="57" y="21.666666666666657" width="219" height="18.666666666666671"/>
+ <rect key="frame" x="0.0" y="19.333333333333343" width="303" height="45"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
<userDefinedRuntimeAttributes>
@@ -71,22 +63,29 @@
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</textField>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="手机号码" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="KAV-oG-qiP">
+ <rect key="frame" x="0.0" y="0.0" width="63.666666666666664" height="19.333333333333332"/>
+ <fontDescription key="fontDescription" type="system" pointSize="16"/>
+ <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="0.80000000000000004" colorSpace="custom" customColorSpace="sRGB"/>
+ <nil key="highlightedColor"/>
+ </label>
</subviews>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
- <constraint firstItem="CtF-TA-Wqg" firstAttribute="leading" secondItem="TCO-QE-qOb" secondAttribute="leading" id="0n6-Gp-vi8"/>
+ <constraint firstItem="iVY-a7-Dza" firstAttribute="top" secondItem="KAV-oG-qiP" secondAttribute="bottom" id="0N0-Ob-ikF"/>
<constraint firstItem="Be0-Ub-wt1" firstAttribute="leading" secondItem="TCO-QE-qOb" secondAttribute="leading" id="2jl-od-m7X"/>
- <constraint firstAttribute="height" constant="62" id="B8f-My-kaP"/>
+ <constraint firstItem="KAV-oG-qiP" firstAttribute="leading" secondItem="TCO-QE-qOb" secondAttribute="leading" id="9ds-N8-yBp"/>
+ <constraint firstAttribute="height" constant="65" id="B8f-My-kaP"/>
<constraint firstAttribute="bottom" secondItem="Be0-Ub-wt1" secondAttribute="bottom" id="CYE-lE-HfD"/>
- <constraint firstItem="iVY-a7-Dza" firstAttribute="centerY" secondItem="CtF-TA-Wqg" secondAttribute="centerY" id="NsU-e6-LIH"/>
- <constraint firstItem="iVY-a7-Dza" firstAttribute="leading" secondItem="TCO-QE-qOb" secondAttribute="leading" constant="57" id="QfN-aw-swP"/>
- <constraint firstAttribute="trailing" secondItem="iVY-a7-Dza" secondAttribute="trailing" constant="27" id="VkS-BT-Jbd"/>
- <constraint firstItem="CtF-TA-Wqg" firstAttribute="centerY" secondItem="TCO-QE-qOb" secondAttribute="centerY" id="ddu-Nc-jYk"/>
+ <constraint firstItem="iVY-a7-Dza" firstAttribute="leading" secondItem="TCO-QE-qOb" secondAttribute="leading" id="dUz-IL-q4D"/>
+ <constraint firstAttribute="trailing" secondItem="iVY-a7-Dza" secondAttribute="trailing" id="fmK-A4-6bs"/>
+ <constraint firstItem="KAV-oG-qiP" firstAttribute="top" secondItem="TCO-QE-qOb" secondAttribute="top" id="o5z-Yc-GQb"/>
+ <constraint firstItem="Be0-Ub-wt1" firstAttribute="top" secondItem="iVY-a7-Dza" secondAttribute="bottom" id="tz1-uh-88a"/>
<constraint firstAttribute="trailing" secondItem="Be0-Ub-wt1" secondAttribute="trailing" id="uI5-1z-bEF"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="gkf-Nv-DjZ">
- <rect key="frame" x="0.0" y="62" width="303" height="62"/>
+ <rect key="frame" x="0.0" y="88" width="303" height="62"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="ZAk-6O-CpK">
<rect key="frame" x="0.0" y="61.333333333333314" width="303" height="0.6666666666666643"/>
@@ -96,7 +95,7 @@
</constraints>
</view>
<textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请填写验证码" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="fSc-90-mQd" customClass="QMUITextField">
- <rect key="frame" x="0.0" y="21.666666666666686" width="183" height="18.666666666666671"/>
+ <rect key="frame" x="0.0" y="31.666666666666686" width="183" height="18.666666666666671"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
<userDefinedRuntimeAttributes>
@@ -106,7 +105,7 @@
</userDefinedRuntimeAttributes>
</textField>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Wb8-hi-sEB">
- <rect key="frame" x="231" y="16.666666666666686" width="72" height="29"/>
+ <rect key="frame" x="233" y="28.666666666666686" width="70" height="24.666666666666671"/>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="获取验证码">
@@ -116,24 +115,34 @@
<action selector="sendCodeAction:" destination="-1" eventType="touchUpInside" id="VlK-D1-7Vq"/>
</connections>
</button>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="验证码" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0hM-r6-81i">
+ <rect key="frame" x="0.0" y="0.0" width="47.666666666666664" height="17.666666666666668"/>
+ <fontDescription key="fontDescription" type="system" pointSize="16"/>
+ <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="0.80000000000000004" colorSpace="custom" customColorSpace="sRGB"/>
+ <nil key="highlightedColor"/>
+ </label>
</subviews>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
+ <constraint firstItem="fSc-90-mQd" firstAttribute="top" secondItem="0hM-r6-81i" secondAttribute="bottom" constant="14" id="2Yn-ps-6Vm"/>
<constraint firstAttribute="trailing" secondItem="fSc-90-mQd" secondAttribute="trailing" constant="120" id="4nl-xb-GY5"/>
<constraint firstAttribute="trailing" secondItem="Wb8-hi-sEB" secondAttribute="trailing" id="80v-dZ-00f"/>
<constraint firstAttribute="bottom" secondItem="ZAk-6O-CpK" secondAttribute="bottom" id="AdJ-bm-lcT"/>
+ <constraint firstItem="ZAk-6O-CpK" firstAttribute="top" secondItem="fSc-90-mQd" secondAttribute="bottom" constant="11" id="Msc-Xp-x1h"/>
<constraint firstAttribute="height" constant="62" id="UGu-Ay-AEl"/>
+ <constraint firstItem="ZAk-6O-CpK" firstAttribute="top" secondItem="Wb8-hi-sEB" secondAttribute="bottom" constant="8" id="cla-lC-qOu"/>
+ <constraint firstItem="0hM-r6-81i" firstAttribute="top" secondItem="gkf-Nv-DjZ" secondAttribute="top" id="fZt-2O-2nL"/>
+ <constraint firstItem="0hM-r6-81i" firstAttribute="leading" secondItem="gkf-Nv-DjZ" secondAttribute="leading" id="liG-eF-8eb"/>
<constraint firstAttribute="trailing" secondItem="ZAk-6O-CpK" secondAttribute="trailing" id="nwM-yC-zKU"/>
<constraint firstItem="ZAk-6O-CpK" firstAttribute="leading" secondItem="gkf-Nv-DjZ" secondAttribute="leading" id="p58-xf-Fze"/>
- <constraint firstItem="fSc-90-mQd" firstAttribute="centerY" secondItem="gkf-Nv-DjZ" secondAttribute="centerY" id="v84-bT-yWM"/>
- <constraint firstItem="Wb8-hi-sEB" firstAttribute="centerY" secondItem="gkf-Nv-DjZ" secondAttribute="centerY" id="voX-At-6yY"/>
+ <constraint firstItem="Wb8-hi-sEB" firstAttribute="centerY" secondItem="fSc-90-mQd" secondAttribute="centerY" id="uIw-zP-8N2"/>
<constraint firstItem="fSc-90-mQd" firstAttribute="leading" secondItem="gkf-Nv-DjZ" secondAttribute="leading" id="vr8-WN-xI2"/>
</constraints>
</view>
</subviews>
</stackView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="5Y1-Lh-YrS">
- <rect key="frame" x="45" y="420" width="303" height="40"/>
+ <rect key="frame" x="45" y="446" width="303" height="40"/>
<color key="backgroundColor" red="0.68235294120000001" green="0.78823529410000004" blue="0.59215686270000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="Zje-3l-M6v"/>
@@ -166,7 +175,7 @@
<constraint firstItem="0mo-0P-B1S" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="45" id="ocw-Wx-IVl"/>
<constraint firstItem="7LE-go-AsO" firstAttribute="leading" secondItem="hYd-rC-GZY" secondAttribute="leading" id="r6I-JA-ULp"/>
</constraints>
- <point key="canvasLocation" x="59" y="21"/>
+ <point key="canvasLocation" x="58.778625954198468" y="20.422535211267608"/>
</view>
</objects>
<resources>
diff --git a/XQMuse/Root/Me/VC/ContactCustomerDetailVC.swift b/XQMuse/Root/Me/VC/ContactCustomerDetailVC.swift
index 508328f..0d37f87 100644
--- a/XQMuse/Root/Me/VC/ContactCustomerDetailVC.swift
+++ b/XQMuse/Root/Me/VC/ContactCustomerDetailVC.swift
@@ -14,7 +14,8 @@
@IBOutlet weak var label_content: UILabel!
@IBOutlet weak var webView: WKWebView!
@IBOutlet weak var image_qrCode: UIImageView!
-
+ @IBOutlet weak var cons_webHei: NSLayoutConstraint!
+
private var model:CommonQuestionModel!
private var customerImage:UIImage?
@@ -32,15 +33,17 @@
super.viewDidLoad()
title = "问题详情"
label_title.text = model.questionName
- label_content.text = model.content
+ label_content.text = model.questionDescription
+ webView.scrollView.showsHorizontalScrollIndicator = false
+ webView.scrollView.showsVerticalScrollIndicator = false
+ webView.scrollView.isScrollEnabled = false
Services.commonQuestionDetailBy(id: model.id).subscribe(onNext: {[weak self] data in
if let m = data.data{
- self?.webView.loadHTMLString(m.content.jq_wrapHtml(), baseURL: nil)
+ self?.webView.loadHTMLString(m.content.jq_wrapHtml(edge: UIEdgeInsets(top: 5, left: 5, bottom: 5, right: 5)), baseURL: nil)
self?.image_qrCode.sd_setImage(with: URL(string: m.customerServiceQrCode))
}
}).disposed(by: disposeBag)
-
// if let image = customerImage{
// self.image_qrCode.image = image
@@ -54,6 +57,21 @@
// }
}
+ override func setRx() {
+ webView.scrollView.rx.observe(CGSize.self, "contentSize").map { (size) -> CGFloat? in
+ if let size = size{
+ return size.height
+ }
+ return nil
+ }.subscribe(onNext: { [unowned self](height) in
+ if let height = height{
+ print(height)
+ self.cons_webHei.constant = height
+ }
+ }).disposed(by: disposeBag)
+
+ }
+
override func setUI() {
webView.scrollView.backgroundColor = .clear
webView.backgroundColor = UIColor(hexString: "#F5F5F5")
diff --git a/XQMuse/Root/Me/VC/ContactCustomerDetailVC.xib b/XQMuse/Root/Me/VC/ContactCustomerDetailVC.xib
index 4439add..621fe70 100644
--- a/XQMuse/Root/Me/VC/ContactCustomerDetailVC.xib
+++ b/XQMuse/Root/Me/VC/ContactCustomerDetailVC.xib
@@ -11,6 +11,7 @@
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="ContactCustomerDetailVC" customModule="XQMuse" customModuleProvider="target">
<connections>
+ <outlet property="cons_webHei" destination="utp-yS-90W" id="4UG-UR-XXT"/>
<outlet property="image_qrCode" destination="2kC-yj-fW4" id="fPg-s8-9wb"/>
<outlet property="label_content" destination="xb7-xl-air" id="reS-4e-B9w"/>
<outlet property="label_title" destination="UU5-p7-Ba1" id="IfO-PC-kEX"/>
@@ -23,92 +24,116 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Nd2-A4-M1T">
- <rect key="frame" x="14" y="76" width="364" height="53"/>
+ <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="QVJ-63-hdw">
+ <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_question" translatesAutoresizingMaskIntoConstraints="NO" id="GhE-Ws-GtH">
- <rect key="frame" x="0.0" y="0.0" width="18" height="18"/>
+ <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bSb-8V-PF9">
+ <rect key="frame" x="0.0" y="0.0" width="393" height="719.66666666666663"/>
+ <subviews>
+ <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Nd2-A4-M1T">
+ <rect key="frame" x="14" y="18.000000000000004" width="364" height="47.333333333333343"/>
+ <subviews>
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_question" translatesAutoresizingMaskIntoConstraints="NO" id="GhE-Ws-GtH">
+ <rect key="frame" x="0.0" y="0.0" width="18" height="18"/>
+ <constraints>
+ <constraint firstAttribute="width" constant="18" id="2FN-8o-LIj"/>
+ <constraint firstAttribute="height" constant="18" id="Tee-5h-uVY"/>
+ </constraints>
+ </imageView>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="--" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="UU5-p7-Ba1">
+ <rect key="frame" x="29" y="0.0" width="324" height="17"/>
+ <fontDescription key="fontDescription" type="system" pointSize="14"/>
+ <color key="textColor" red="0.098039215686274508" green="0.098039215686274508" blue="0.098039215686274508" alpha="0.78000000000000003" colorSpace="custom" customColorSpace="sRGB"/>
+ <nil key="highlightedColor"/>
+ </label>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="--" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xb7-xl-air">
+ <rect key="frame" x="29" y="22" width="325" height="14.333333333333336"/>
+ <fontDescription key="fontDescription" type="system" pointSize="12"/>
+ <color key="textColor" red="0.098039215686274508" green="0.098039215686274508" blue="0.098039215686274508" alpha="0.40000000000000002" colorSpace="custom" customColorSpace="sRGB"/>
+ <nil key="highlightedColor"/>
+ </label>
+ <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="MvE-Yv-e31">
+ <rect key="frame" x="0.0" y="46.333333333333329" width="364" height="1"/>
+ <color key="backgroundColor" red="0.59215686274509804" green="0.59215686274509804" blue="0.59215686274509804" alpha="0.080000000000000002" colorSpace="custom" customColorSpace="sRGB"/>
+ <constraints>
+ <constraint firstAttribute="height" constant="1" id="noh-0o-cef"/>
+ </constraints>
+ </view>
+ </subviews>
+ <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+ <constraints>
+ <constraint firstItem="GhE-Ws-GtH" firstAttribute="leading" secondItem="Nd2-A4-M1T" secondAttribute="leading" id="3Bz-mj-QuY"/>
+ <constraint firstItem="xb7-xl-air" firstAttribute="leading" secondItem="UU5-p7-Ba1" secondAttribute="leading" id="4oD-0p-CVc"/>
+ <constraint firstItem="xb7-xl-air" firstAttribute="top" secondItem="UU5-p7-Ba1" secondAttribute="bottom" constant="5" id="7U4-LB-MR4"/>
+ <constraint firstAttribute="trailing" secondItem="UU5-p7-Ba1" secondAttribute="trailing" constant="11" id="8ZL-P7-T1D"/>
+ <constraint firstItem="UU5-p7-Ba1" firstAttribute="leading" secondItem="GhE-Ws-GtH" secondAttribute="trailing" constant="11" id="CQ5-UU-7wH"/>
+ <constraint firstAttribute="bottom" secondItem="MvE-Yv-e31" secondAttribute="bottom" id="DGg-m3-q8K"/>
+ <constraint firstItem="MvE-Yv-e31" firstAttribute="top" secondItem="xb7-xl-air" secondAttribute="bottom" constant="10" id="OuV-ZV-zpU"/>
+ <constraint firstItem="UU5-p7-Ba1" firstAttribute="top" secondItem="Nd2-A4-M1T" secondAttribute="top" id="T0h-L4-CZB"/>
+ <constraint firstItem="GhE-Ws-GtH" firstAttribute="top" secondItem="Nd2-A4-M1T" secondAttribute="top" id="Zcu-1Y-15d"/>
+ <constraint firstItem="MvE-Yv-e31" firstAttribute="leading" secondItem="Nd2-A4-M1T" secondAttribute="leading" id="ev5-LN-w74"/>
+ <constraint firstAttribute="trailing" secondItem="xb7-xl-air" secondAttribute="trailing" constant="10" id="s0Y-dG-tai"/>
+ <constraint firstAttribute="trailing" secondItem="MvE-Yv-e31" secondAttribute="trailing" id="yYL-9o-UgQ"/>
+ </constraints>
+ </view>
+ <wkWebView contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="RzU-MN-ulm">
+ <rect key="frame" x="14" y="85.333333333333314" width="365" height="433.99999999999994"/>
+ <color key="backgroundColor" red="0.96078431372549022" green="0.96078431372549022" blue="0.96078431372549022" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+ <constraints>
+ <constraint firstAttribute="height" constant="434" id="utp-yS-90W"/>
+ </constraints>
+ <wkWebViewConfiguration key="configuration">
+ <audiovisualMediaTypes key="mediaTypesRequiringUserActionForPlayback" none="YES"/>
+ <wkPreferences key="preferences"/>
+ </wkWebViewConfiguration>
+ </wkWebView>
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="2kC-yj-fW4">
+ <rect key="frame" x="148.66666666666666" y="597.33333333333337" width="96" height="96"/>
+ <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+ <constraints>
+ <constraint firstAttribute="width" constant="96" id="Idf-Z4-2b1"/>
+ <constraint firstAttribute="height" constant="96" id="n5B-wR-B6d"/>
+ </constraints>
+ </imageView>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="咨询客服" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="WL0-dE-4xa">
+ <rect key="frame" x="172.66666666666666" y="697.33333333333337" width="48" height="14.333333333333371"/>
+ <fontDescription key="fontDescription" type="system" pointSize="12"/>
+ <color key="textColor" red="0.098039215686274508" green="0.12941176470588234" blue="0.24313725490196078" alpha="0.67000000000000004" colorSpace="custom" customColorSpace="sRGB"/>
+ <nil key="highlightedColor"/>
+ </label>
+ </subviews>
+ <color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
- <constraint firstAttribute="width" constant="18" id="2FN-8o-LIj"/>
- <constraint firstAttribute="height" constant="18" id="Tee-5h-uVY"/>
- </constraints>
- </imageView>
- <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="--" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="UU5-p7-Ba1">
- <rect key="frame" x="29" y="-1" width="324" height="20"/>
- <constraints>
- <constraint firstAttribute="height" constant="20" id="v0l-ze-jsK"/>
- </constraints>
- <fontDescription key="fontDescription" type="system" pointSize="14"/>
- <color key="textColor" red="0.098039215686274508" green="0.098039215686274508" blue="0.098039215686274508" alpha="0.78000000000000003" colorSpace="custom" customColorSpace="sRGB"/>
- <nil key="highlightedColor"/>
- </label>
- <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="--" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xb7-xl-air">
- <rect key="frame" x="29" y="24" width="261" height="14.333333333333336"/>
- <fontDescription key="fontDescription" type="system" pointSize="12"/>
- <color key="textColor" red="0.098039215686274508" green="0.098039215686274508" blue="0.098039215686274508" alpha="0.40000000000000002" colorSpace="custom" customColorSpace="sRGB"/>
- <nil key="highlightedColor"/>
- </label>
- <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="MvE-Yv-e31">
- <rect key="frame" x="0.0" y="52" width="364" height="1"/>
- <color key="backgroundColor" red="0.59215686274509804" green="0.59215686274509804" blue="0.59215686274509804" alpha="0.080000000000000002" colorSpace="custom" customColorSpace="sRGB"/>
- <constraints>
- <constraint firstAttribute="height" constant="1" id="noh-0o-cef"/>
+ <constraint firstItem="Nd2-A4-M1T" firstAttribute="top" secondItem="bSb-8V-PF9" secondAttribute="top" constant="18" id="2GK-Ie-kAo"/>
+ <constraint firstItem="RzU-MN-ulm" firstAttribute="top" secondItem="Nd2-A4-M1T" secondAttribute="bottom" constant="20" id="3ht-a2-pUa"/>
+ <constraint firstItem="WL0-dE-4xa" firstAttribute="top" secondItem="2kC-yj-fW4" secondAttribute="bottom" constant="4" id="E5I-Ll-ZTc"/>
+ <constraint firstAttribute="trailing" secondItem="Nd2-A4-M1T" secondAttribute="trailing" constant="15" id="HTH-KG-1Cm"/>
+ <constraint firstItem="Nd2-A4-M1T" firstAttribute="leading" secondItem="bSb-8V-PF9" secondAttribute="leading" constant="14" id="O8E-Ho-i47"/>
+ <constraint firstAttribute="bottomMargin" secondItem="WL0-dE-4xa" secondAttribute="bottom" priority="750" id="aXL-bS-HbB"/>
+ <constraint firstAttribute="trailing" secondItem="RzU-MN-ulm" secondAttribute="trailing" constant="14" id="dW8-MW-crQ"/>
+ <constraint firstItem="2kC-yj-fW4" firstAttribute="top" secondItem="RzU-MN-ulm" secondAttribute="bottom" constant="78" id="fBz-Hh-GuO"/>
+ <constraint firstItem="2kC-yj-fW4" firstAttribute="centerX" secondItem="bSb-8V-PF9" secondAttribute="centerX" id="hBS-FU-ADf"/>
+ <constraint firstItem="WL0-dE-4xa" firstAttribute="centerX" secondItem="bSb-8V-PF9" secondAttribute="centerX" id="sgX-8u-VFD"/>
+ <constraint firstItem="RzU-MN-ulm" firstAttribute="leading" secondItem="bSb-8V-PF9" secondAttribute="leading" constant="14" id="wM8-44-9kq"/>
</constraints>
</view>
</subviews>
- <color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
- <constraint firstItem="GhE-Ws-GtH" firstAttribute="leading" secondItem="Nd2-A4-M1T" secondAttribute="leading" id="3Bz-mj-QuY"/>
- <constraint firstItem="xb7-xl-air" firstAttribute="leading" secondItem="UU5-p7-Ba1" secondAttribute="leading" id="4oD-0p-CVc"/>
- <constraint firstItem="xb7-xl-air" firstAttribute="top" secondItem="UU5-p7-Ba1" secondAttribute="bottom" constant="5" id="7U4-LB-MR4"/>
- <constraint firstAttribute="trailing" secondItem="UU5-p7-Ba1" secondAttribute="trailing" constant="11" id="8ZL-P7-T1D"/>
- <constraint firstItem="UU5-p7-Ba1" firstAttribute="leading" secondItem="GhE-Ws-GtH" secondAttribute="trailing" constant="11" id="CQ5-UU-7wH"/>
- <constraint firstAttribute="bottom" secondItem="MvE-Yv-e31" secondAttribute="bottom" id="DGg-m3-q8K"/>
- <constraint firstAttribute="height" constant="53" id="RDB-68-GVb"/>
- <constraint firstItem="UU5-p7-Ba1" firstAttribute="centerY" secondItem="GhE-Ws-GtH" secondAttribute="centerY" id="XSi-1J-qUs"/>
- <constraint firstItem="GhE-Ws-GtH" firstAttribute="top" secondItem="Nd2-A4-M1T" secondAttribute="top" id="Zcu-1Y-15d"/>
- <constraint firstItem="MvE-Yv-e31" firstAttribute="leading" secondItem="Nd2-A4-M1T" secondAttribute="leading" id="ev5-LN-w74"/>
- <constraint firstAttribute="trailing" secondItem="xb7-xl-air" secondAttribute="trailing" constant="74" id="s0Y-dG-tai"/>
- <constraint firstAttribute="trailing" secondItem="MvE-Yv-e31" secondAttribute="trailing" id="yYL-9o-UgQ"/>
+ <constraint firstItem="bSb-8V-PF9" firstAttribute="top" secondItem="QVJ-63-hdw" secondAttribute="top" id="1cy-xZ-jHB"/>
+ <constraint firstAttribute="trailing" secondItem="bSb-8V-PF9" secondAttribute="trailing" id="2GD-0G-bmh"/>
+ <constraint firstAttribute="bottom" secondItem="bSb-8V-PF9" secondAttribute="bottom" id="D9N-yC-3Uh"/>
+ <constraint firstItem="bSb-8V-PF9" firstAttribute="leading" secondItem="QVJ-63-hdw" secondAttribute="leading" id="DaH-ji-oR5"/>
+ <constraint firstItem="bSb-8V-PF9" firstAttribute="centerX" secondItem="QVJ-63-hdw" secondAttribute="centerX" id="xdP-mE-tQX"/>
</constraints>
- </view>
- <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="咨询客服" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="WL0-dE-4xa">
- <rect key="frame" x="172.66666666666666" y="803.66666666666663" width="48" height="14.333333333333371"/>
- <fontDescription key="fontDescription" type="system" pointSize="12"/>
- <color key="textColor" red="0.098039215686274508" green="0.12941176470588234" blue="0.24313725490196078" alpha="0.67000000000000004" colorSpace="custom" customColorSpace="sRGB"/>
- <nil key="highlightedColor"/>
- </label>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="2kC-yj-fW4">
- <rect key="frame" x="148.66666666666666" y="703.66666666666663" width="96" height="96"/>
- <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
- <constraints>
- <constraint firstAttribute="width" constant="96" id="Idf-Z4-2b1"/>
- <constraint firstAttribute="height" constant="96" id="n5B-wR-B6d"/>
- </constraints>
- </imageView>
- <wkWebView contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="RzU-MN-ulm">
- <rect key="frame" x="14" y="149.00000000000003" width="365" height="476.66666666666674"/>
- <color key="backgroundColor" red="0.96078431372549022" green="0.96078431372549022" blue="0.96078431372549022" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
- <wkWebViewConfiguration key="configuration">
- <audiovisualMediaTypes key="mediaTypesRequiringUserActionForPlayback" none="YES"/>
- <wkPreferences key="preferences"/>
- </wkWebViewConfiguration>
- </wkWebView>
+ </scrollView>
</subviews>
<viewLayoutGuide key="safeArea" id="fnl-2z-Ty3"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
- <constraint firstItem="Nd2-A4-M1T" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="14" id="3MP-js-noI"/>
- <constraint firstItem="RzU-MN-ulm" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="14" id="7cQ-YK-X4f"/>
- <constraint firstItem="WL0-dE-4xa" firstAttribute="centerX" secondItem="fnl-2z-Ty3" secondAttribute="centerX" id="IuI-ib-PAq"/>
- <constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="Nd2-A4-M1T" secondAttribute="trailing" constant="15" id="SQd-1e-wUq"/>
- <constraint firstItem="WL0-dE-4xa" firstAttribute="top" secondItem="2kC-yj-fW4" secondAttribute="bottom" constant="4" id="aaA-Jd-IpY"/>
- <constraint firstItem="2kC-yj-fW4" firstAttribute="centerX" secondItem="fnl-2z-Ty3" secondAttribute="centerX" id="eVb-V7-9WK"/>
- <constraint firstItem="2kC-yj-fW4" firstAttribute="top" secondItem="RzU-MN-ulm" secondAttribute="bottom" constant="78" id="fBA-g0-0qZ"/>
- <constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="RzU-MN-ulm" secondAttribute="trailing" constant="14" id="hw7-dO-fxR"/>
- <constraint firstItem="fnl-2z-Ty3" firstAttribute="bottom" secondItem="WL0-dE-4xa" secondAttribute="bottom" id="iqe-ZZ-hcE"/>
- <constraint firstItem="RzU-MN-ulm" firstAttribute="top" secondItem="Nd2-A4-M1T" secondAttribute="bottom" constant="20" id="v4r-SW-ozA"/>
- <constraint firstItem="Nd2-A4-M1T" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="topMargin" constant="17" id="ycS-IN-qI9"/>
+ <constraint firstAttribute="bottom" secondItem="QVJ-63-hdw" secondAttribute="bottom" id="MoF-bb-sI0"/>
+ <constraint firstAttribute="trailing" secondItem="QVJ-63-hdw" secondAttribute="trailing" id="ZqY-Xd-CWz"/>
+ <constraint firstItem="QVJ-63-hdw" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" id="reg-8y-xis"/>
+ <constraint firstItem="QVJ-63-hdw" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" id="uso-Uz-t3X"/>
</constraints>
<point key="canvasLocation" x="139.69465648854961" y="20.422535211267608"/>
</view>
diff --git a/XQMuse/Root/Me/VC/HelpCenterVC.swift b/XQMuse/Root/Me/VC/HelpCenterVC.swift
index 64ac689..8226507 100644
--- a/XQMuse/Root/Me/VC/HelpCenterVC.swift
+++ b/XQMuse/Root/Me/VC/HelpCenterVC.swift
@@ -148,7 +148,7 @@
switch page {
case 0:
attribute.add(string: "如你当前登录心泉·疗愈的手机号码不是购买课程时填写的手机号码,请点击下方按钮,使用购买课程的手机号码登录即可。", withFont: .systemFont(ofSize: 13), withColor: UIColor(hexString:"#282828")!, indent: 0, lineSpace: 5)
- btn_handle.setTitle("换个手机号码登录", for: .normal)
+ btn_handle.setTitle("换个手机号登录", for: .normal)
case 1:
attribute.add(string: "如你希望变更心泉·疗愈的手机号码,请点击下方按钮,根据页面提示录入新的手机号码。", withFont: .systemFont(ofSize: 13), withColor: UIColor(hexString:"#282828")!, indent: 0, lineSpace: 5)
btn_handle.setTitle("前往改绑手机号", for: .normal)
diff --git a/XQMuse/Root/Me/VC/HelpCenterVC.xib b/XQMuse/Root/Me/VC/HelpCenterVC.xib
index 012c451..d5efb9d 100644
--- a/XQMuse/Root/Me/VC/HelpCenterVC.xib
+++ b/XQMuse/Root/Me/VC/HelpCenterVC.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
- <device id="retina6_12" orientation="portrait" appearance="light"/>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+ <device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -17,23 +17,23 @@
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
- <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
+ <rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="top" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_help" translatesAutoresizingMaskIntoConstraints="NO" id="pAC-sr-W8M">
- <rect key="frame" x="0.0" y="0.0" width="393" height="461"/>
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_help" translatesAutoresizingMaskIntoConstraints="NO" id="pAC-sr-W8M">
+ <rect key="frame" x="0.0" y="0.0" width="414" height="295"/>
<constraints>
- <constraint firstAttribute="width" secondItem="pAC-sr-W8M" secondAttribute="height" multiplier="1:1.173" id="jHB-RH-JlI"/>
+ <constraint firstAttribute="height" constant="295" id="Jml-kZ-fwD"/>
</constraints>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="找不到已购课程,通常是因为当前登录的手机号码并非购买课程时使用的手机号码所致,可通过以下方式找回课程。" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="w5R-wz-EoA">
- <rect key="frame" x="21.666666666666657" y="230.33333333333334" width="350" height="28.666666666666657"/>
+ <rect key="frame" x="21.5" y="199" width="371" height="29"/>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="12"/>
<color key="textColor" red="0.12156862745098039" green="0.12156862745098039" blue="0.12156862745098039" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="2" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Qa7-7e-0dj">
- <rect key="frame" x="21" y="142" width="184" height="57.333333333333343"/>
+ <rect key="frame" x="21" y="110.5" width="173.5" height="57.5"/>
<string key="text">找不到
已购课程怎么办?</string>
<fontDescription key="fontDescription" type="system" weight="heavy" pointSize="24"/>
@@ -41,11 +41,11 @@
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="dEu-an-YSc">
- <rect key="frame" x="0.0" y="461" width="393" height="357"/>
+ <rect key="frame" x="0.0" y="295" width="414" height="567"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="xML-KV-XeH">
- <rect key="frame" x="0.0" y="294" width="393" height="524"/>
+ <rect key="frame" x="0.0" y="275" width="414" height="587"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
@@ -64,23 +64,23 @@
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="dEu-an-YSc" secondAttribute="trailing" id="FcC-Z3-JLu"/>
<constraint firstItem="pAC-sr-W8M" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" id="Mg9-tJ-uOW"/>
<constraint firstItem="pAC-sr-W8M" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="POx-rJ-5a8"/>
+ <constraint firstItem="Qa7-7e-0dj" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" constant="62.5" id="SgT-H8-Yvz"/>
<constraint firstItem="w5R-wz-EoA" firstAttribute="centerX" secondItem="pAC-sr-W8M" secondAttribute="centerX" id="UOa-Td-Ybt"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="bottom" secondItem="xML-KV-XeH" secondAttribute="bottom" id="Wqj-5J-rSc"/>
- <constraint firstItem="w5R-wz-EoA" firstAttribute="bottom" secondItem="pAC-sr-W8M" secondAttribute="bottom" constant="-202" id="csA-GR-ldD"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="xML-KV-XeH" secondAttribute="trailing" id="dDM-rl-jM1"/>
<constraint firstItem="xML-KV-XeH" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="e6X-3Y-4Fq"/>
- <constraint firstItem="xML-KV-XeH" firstAttribute="top" secondItem="w5R-wz-EoA" secondAttribute="bottom" constant="35" id="fQR-Zl-po0"/>
<constraint firstItem="w5R-wz-EoA" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="21.5" id="gdW-lE-qmG"/>
<constraint firstItem="dEu-an-YSc" firstAttribute="top" secondItem="pAC-sr-W8M" secondAttribute="bottom" id="oVX-Y1-Y68"/>
+ <constraint firstItem="xML-KV-XeH" firstAttribute="top" secondItem="pAC-sr-W8M" secondAttribute="bottom" constant="-20" id="qet-Hf-ytM"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="pAC-sr-W8M" secondAttribute="trailing" id="tn6-ej-Iab"/>
<constraint firstItem="w5R-wz-EoA" firstAttribute="top" secondItem="Qa7-7e-0dj" secondAttribute="bottom" constant="31" id="wdH-CC-k2K"/>
<constraint firstItem="Qa7-7e-0dj" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="21" id="ygw-Ur-T4V"/>
</constraints>
- <point key="canvasLocation" x="139.69465648854961" y="20.422535211267608"/>
+ <point key="canvasLocation" x="139.13043478260872" y="20.089285714285712"/>
</view>
</objects>
<resources>
- <image name="bg_help" width="390" height="844"/>
+ <image name="bg_help" width="390" height="295"/>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
diff --git a/XQMuse/Root/Me/VC/LevelVC.xib b/XQMuse/Root/Me/VC/LevelVC.xib
index 10ebc1b..17cde94 100644
--- a/XQMuse/Root/Me/VC/LevelVC.xib
+++ b/XQMuse/Root/Me/VC/LevelVC.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
@@ -23,7 +23,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="5yn-MP-rMe">
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="5yn-MP-rMe">
<rect key="frame" x="0.0" y="0.0" width="393" height="297"/>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="P4c-hh-W7E">
@@ -50,13 +50,13 @@
</userDefinedRuntimeAttributes>
</progressView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="当前等级 0/0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="7JM-Vh-SUj">
- <rect key="frame" x="15" y="83.999999999999986" width="71.666666666666671" height="14.333333333333329"/>
+ <rect key="frame" x="15" y="83.999999999999986" width="70.333333333333329" height="14.333333333333329"/>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="12"/>
<color key="textColor" red="0.039215686274509803" green="0.25882352941176467" blue="0.074509803921568626" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="你离下一等级还差0经验值,加油!" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZIY-z8-gex">
- <rect key="frame" x="178.66666666666669" y="83.999999999999986" width="170.66666666666669" height="14.333333333333329"/>
+ <rect key="frame" x="182.66666666666669" y="83.999999999999986" width="166.66666666666669" height="14.333333333333329"/>
<fontDescription key="fontDescription" type="system" pointSize="11"/>
<color key="textColor" red="0.039215686274509803" green="0.25882352941176467" blue="0.074509803921568626" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
diff --git a/XQMuse/Root/Me/VC/LogoutAccountVC.swift b/XQMuse/Root/Me/VC/LogoutAccountVC.swift
index 2cc1ffd..e0e1002 100644
--- a/XQMuse/Root/Me/VC/LogoutAccountVC.swift
+++ b/XQMuse/Root/Me/VC/LogoutAccountVC.swift
@@ -21,6 +21,10 @@
Services.deleteUser().subscribe(onNext: {data in
CommonAlertView.show(title: "提示", content: "注销成功", cancelStr: nil, completeStr: "确定", isSingle: true) { _ in
sceneDelegate?.needLogin()
+ self.navigationController?.popToRootViewController(animated: false)
+ DispatchQueue.main.asyncAfter(delay: 0.5) {
+ self.navigationController?.tabBarController?.selectedIndex = 0
+ }
}
}).disposed(by: disposeBag)
}
diff --git a/XQMuse/Root/Me/VC/NoticeCenterSysDetailVC.swift b/XQMuse/Root/Me/VC/NoticeCenterSysDetailVC.swift
index f195af6..7320046 100644
--- a/XQMuse/Root/Me/VC/NoticeCenterSysDetailVC.swift
+++ b/XQMuse/Root/Me/VC/NoticeCenterSysDetailVC.swift
@@ -28,7 +28,7 @@
super.viewDidLoad()
title = "系统消息"
label_title.text = model.title
- label_content.text = model.reply
+ label_content.text = model.content
label_date.text = model.publishTime
}
diff --git a/XQMuse/Root/Me/VC/NoticeCenterUserRepeaceDetailVC.swift b/XQMuse/Root/Me/VC/NoticeCenterUserRepeaceDetailVC.swift
index 942134a..fe8eb99 100644
--- a/XQMuse/Root/Me/VC/NoticeCenterUserRepeaceDetailVC.swift
+++ b/XQMuse/Root/Me/VC/NoticeCenterUserRepeaceDetailVC.swift
@@ -6,6 +6,7 @@
//
import UIKit
+import JQTools
class NoticeCenterUserRepeaceDetailVC: BaseVC {
@IBOutlet weak var image_avartar: UIImageView!
@@ -33,7 +34,8 @@
override func viewDidLoad() {
super.viewDidLoad()
title = "回复消息"
- image_avartar.sd_setImage(with: URL(string: model.iconUrl))
+ let avartarImageUrl = model.iconUrl.components(separatedBy: ",").first?.jq_urlEncoded()
+ image_avartar.sd_setImage(with: URL(string: avartarImageUrl))
label_name.text = model.meditationTitle
label_content.text = model.coverDescription
image_reply_userAvartar.sd_setImage(with: URL(string: model.avatar))
@@ -41,6 +43,6 @@
label_reply_content.text = model.content
label_reply_date.text = model.publishTime
view_plantfrom.isHidden = model.replyContent.isEmpty
- view_plantfrom_reply.text = model.reply
+ view_plantfrom_reply.text = model.replyContent
}
}
diff --git a/XQMuse/Root/Me/VC/SettingVC.swift b/XQMuse/Root/Me/VC/SettingVC.swift
index 56076d9..b507262 100644
--- a/XQMuse/Root/Me/VC/SettingVC.swift
+++ b/XQMuse/Root/Me/VC/SettingVC.swift
@@ -18,6 +18,8 @@
override func viewDidLoad() {
super.viewDidLoad()
title = "设置"
+ navigationController?.navigationBar.standardAppearance.backgroundColor = .white
+ navigationController?.navigationBar.scrollEdgeAppearance?.backgroundColor = .white
btn_exchange.isHidden = UserViewModel.getLoginInfo()?.accessToken.isEmpty ?? true
btn_logout.isHidden = UserViewModel.getLoginInfo()?.accessToken.isEmpty ?? true
@@ -62,8 +64,8 @@
}
@IBAction func checkVersion(_ sender: TapBtn) {
- JQTool.checkVersion(appid: "") { stat, model, url in
-
+ JQTool.checkVersion(appid: AppleID) { stat, model, url in
+
}
}
diff --git a/XQMuse/Root/Me/VC/SpendingDetailHeaderVC.xib b/XQMuse/Root/Me/VC/SpendingDetailHeaderVC.xib
index 5e62ff5..5e7e694 100644
--- a/XQMuse/Root/Me/VC/SpendingDetailHeaderVC.xib
+++ b/XQMuse/Root/Me/VC/SpendingDetailHeaderVC.xib
@@ -19,7 +19,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="q7z-fp-0F3">
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="q7z-fp-0F3">
<rect key="frame" x="0.0" y="0.0" width="393" height="297"/>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="FLL-3F-OgN">
diff --git a/XQMuse/Root/Me/VC/VIPCenterVC.swift b/XQMuse/Root/Me/VC/VIPCenterVC.swift
index cf0694e..abfadf2 100644
--- a/XQMuse/Root/Me/VC/VIPCenterVC.swift
+++ b/XQMuse/Root/Me/VC/VIPCenterVC.swift
@@ -48,7 +48,7 @@
}
- if UserViewModel.getAvatarInfo().isVip == .yes{
+ if UserViewModel.getAvatarInfo().checkVip(){
self.bg_vip.image = UIImage(named: "bg_vip")
self.label_vipHint.text = "您将享受所有会员专享音频,尽情畅游心泉·疗愈世界"
self.label_expirtTime.text = UserViewModel.getAvatarInfo().vipExpireTime.components(separatedBy: " ").first! + "到期"
diff --git a/XQMuse/Root/Me/VC/VIPCenterVC.xib b/XQMuse/Root/Me/VC/VIPCenterVC.xib
index 0948409..11e9b8a 100644
--- a/XQMuse/Root/Me/VC/VIPCenterVC.xib
+++ b/XQMuse/Root/Me/VC/VIPCenterVC.xib
@@ -26,7 +26,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="VLP-Hy-naC">
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="VLP-Hy-naC">
<rect key="frame" x="0.0" y="0.0" width="393" height="297"/>
</imageView>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" translatesAutoresizingMaskIntoConstraints="NO" id="bkf-bh-gzu">
diff --git a/XQMuse/Root/Me/VC/WalletRechargeVC.swift b/XQMuse/Root/Me/VC/WalletRechargeVC.swift
index 103b80e..d286d01 100644
--- a/XQMuse/Root/Me/VC/WalletRechargeVC.swift
+++ b/XQMuse/Root/Me/VC/WalletRechargeVC.swift
@@ -25,6 +25,11 @@
super.viewDidLoad()
title = "疗愈币充值"
+ btn_handle.isEnabled = false
+ btn_handle.alpha = 0.6
+
+ view.backgroundColor = .white
+
for v in 0...5{
productList.insert("com.XQMuse.p.\(v)")
}
@@ -50,6 +55,10 @@
override func setUI() {
view.backgroundColor = UIColor(hexString: "f6f6f6")
+ }
+
+ override func viewDidLayoutSubviews() {
+ super.viewDidLayoutSubviews()
btn_handle.jq_gradientNibColor(colorArr: [UIColor(hexStr: "#8EA47A").cgColor,UIColor(hexStr: "#AFCA98").cgColor], cornerRadius: 20)
}
@@ -61,7 +70,10 @@
let product = products[selectIndexPath.row]
InPurchaseManager.purchaseProduct(ID: product.productIdentifier, applicationUsername: userId.string) { model in
-
+ if model.status == 0{
+ //需要后端监听推送后,才会更新金额,可能延迟
+ NotificationCenter.default.post(name: Refreh_PaymentWallet_Noti, object: nil)
+ }
} errorClouse: { error in
alertError(msg: error.localizedDescription)
}
@@ -84,6 +96,10 @@
cell.selectAt(indexPath == selectIndexPath)
let product = products[indexPath.row]
cell.lable_title.text = product.localizedTitle
+
+ btn_handle.isEnabled = true
+ btn_handle.alpha = 1.0
+
return cell
}
}
diff --git a/XQMuse/Root/Me/VC/WalletRechargeVC.xib b/XQMuse/Root/Me/VC/WalletRechargeVC.xib
index d2bf091..a129706 100644
--- a/XQMuse/Root/Me/VC/WalletRechargeVC.xib
+++ b/XQMuse/Root/Me/VC/WalletRechargeVC.xib
@@ -22,74 +22,86 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Ok4-Yz-gOY">
- <rect key="frame" x="14" y="68" width="365" height="141"/>
+ <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="z66-Ao-znz">
+ <rect key="frame" x="0.0" y="59" width="393" height="759"/>
<subviews>
- <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="充值金额" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="nAx-8V-3yC">
- <rect key="frame" x="9.9999999999999964" y="13" width="55.666666666666657" height="17"/>
- <fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
- <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="0.59999999999999998" colorSpace="custom" customColorSpace="sRGB"/>
- <nil key="highlightedColor"/>
- </label>
- <collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" dataMode="none" translatesAutoresizingMaskIntoConstraints="NO" id="dtD-pA-jk2">
- <rect key="frame" x="0.0" y="58" width="365" height="50"/>
+ <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Ok4-Yz-gOY">
+ <rect key="frame" x="14" y="9" width="365" height="141"/>
+ <subviews>
+ <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="充值金额" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="nAx-8V-3yC">
+ <rect key="frame" x="9.9999999999999964" y="13" width="55.666666666666657" height="17"/>
+ <fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
+ <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="0.59999999999999998" colorSpace="custom" customColorSpace="sRGB"/>
+ <nil key="highlightedColor"/>
+ </label>
+ <collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" dataMode="none" translatesAutoresizingMaskIntoConstraints="NO" id="dtD-pA-jk2">
+ <rect key="frame" x="0.0" y="58" width="365" height="50"/>
+ <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+ <constraints>
+ <constraint firstAttribute="height" constant="50" id="bd9-0q-BAP"/>
+ </constraints>
+ <collectionViewFlowLayout key="collectionViewLayout" minimumLineSpacing="10" minimumInteritemSpacing="10" id="Cco-HP-q4Y">
+ <size key="itemSize" width="128" height="128"/>
+ <size key="headerReferenceSize" width="0.0" height="0.0"/>
+ <size key="footerReferenceSize" width="0.0" height="0.0"/>
+ <inset key="sectionInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/>
+ </collectionViewFlowLayout>
+ </collectionView>
+ </subviews>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
- <constraint firstAttribute="height" constant="50" id="bd9-0q-BAP"/>
+ <constraint firstItem="nAx-8V-3yC" firstAttribute="leading" secondItem="Ok4-Yz-gOY" secondAttribute="leading" constant="10" id="1Dh-E8-vyT"/>
+ <constraint firstItem="dtD-pA-jk2" firstAttribute="top" secondItem="nAx-8V-3yC" secondAttribute="bottom" constant="28" id="4E4-or-gJ7"/>
+ <constraint firstAttribute="bottom" secondItem="dtD-pA-jk2" secondAttribute="bottom" constant="33" id="Ndh-eA-Y0R"/>
+ <constraint firstItem="nAx-8V-3yC" firstAttribute="top" secondItem="Ok4-Yz-gOY" secondAttribute="top" constant="13" id="WYJ-dl-1sf"/>
+ <constraint firstAttribute="trailing" secondItem="dtD-pA-jk2" secondAttribute="trailing" id="nvj-jM-GAI"/>
+ <constraint firstItem="dtD-pA-jk2" firstAttribute="leading" secondItem="Ok4-Yz-gOY" secondAttribute="leading" id="tIv-aS-XcX"/>
</constraints>
- <collectionViewFlowLayout key="collectionViewLayout" minimumLineSpacing="10" minimumInteritemSpacing="10" id="Cco-HP-q4Y">
- <size key="itemSize" width="128" height="128"/>
- <size key="headerReferenceSize" width="0.0" height="0.0"/>
- <size key="footerReferenceSize" width="0.0" height="0.0"/>
- <inset key="sectionInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/>
- </collectionViewFlowLayout>
- </collectionView>
+ <userDefinedRuntimeAttributes>
+ <userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
+ <userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
+ <real key="value" value="10"/>
+ </userDefinedRuntimeAttribute>
+ </userDefinedRuntimeAttributes>
+ </view>
+ <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="dho-ek-UFQ">
+ <rect key="frame" x="45" y="210" width="303" height="40"/>
+ <color key="backgroundColor" red="0.54117647059999996" green="0.68235294120000001" blue="0.39607843139999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+ <constraints>
+ <constraint firstAttribute="height" constant="40" id="4UX-8H-LKn"/>
+ </constraints>
+ <fontDescription key="fontDescription" type="system" weight="medium" pointSize="15"/>
+ <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+ <state key="normal" title="确认充值"/>
+ <userDefinedRuntimeAttributes>
+ <userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
+ <userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
+ <real key="value" value="20"/>
+ </userDefinedRuntimeAttribute>
+ </userDefinedRuntimeAttributes>
+ <connections>
+ <action selector="completeAction:" destination="-1" eventType="touchUpInside" id="J4Z-bu-S5a"/>
+ </connections>
+ </button>
</subviews>
- <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+ <color key="backgroundColor" red="0.96470588235294119" green="0.96470588235294119" blue="0.96470588235294119" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
- <constraint firstItem="nAx-8V-3yC" firstAttribute="leading" secondItem="Ok4-Yz-gOY" secondAttribute="leading" constant="10" id="1Dh-E8-vyT"/>
- <constraint firstItem="dtD-pA-jk2" firstAttribute="top" secondItem="nAx-8V-3yC" secondAttribute="bottom" constant="28" id="4E4-or-gJ7"/>
- <constraint firstAttribute="bottom" secondItem="dtD-pA-jk2" secondAttribute="bottom" constant="33" id="Ndh-eA-Y0R"/>
- <constraint firstItem="nAx-8V-3yC" firstAttribute="top" secondItem="Ok4-Yz-gOY" secondAttribute="top" constant="13" id="WYJ-dl-1sf"/>
- <constraint firstAttribute="trailing" secondItem="dtD-pA-jk2" secondAttribute="trailing" id="nvj-jM-GAI"/>
- <constraint firstItem="dtD-pA-jk2" firstAttribute="leading" secondItem="Ok4-Yz-gOY" secondAttribute="leading" id="tIv-aS-XcX"/>
+ <constraint firstItem="Ok4-Yz-gOY" firstAttribute="leading" secondItem="z66-Ao-znz" secondAttribute="leading" constant="14" id="0hn-eY-79h"/>
+ <constraint firstAttribute="trailing" secondItem="dho-ek-UFQ" secondAttribute="trailing" constant="45" id="B15-WD-cjm"/>
+ <constraint firstAttribute="trailing" secondItem="Ok4-Yz-gOY" secondAttribute="trailing" constant="14" id="IJU-kW-9Fa"/>
+ <constraint firstItem="Ok4-Yz-gOY" firstAttribute="top" secondItem="z66-Ao-znz" secondAttribute="top" constant="9" id="Qnn-9a-Nl6"/>
+ <constraint firstItem="dho-ek-UFQ" firstAttribute="top" secondItem="Ok4-Yz-gOY" secondAttribute="bottom" constant="60" id="sXQ-fx-OHD"/>
+ <constraint firstItem="dho-ek-UFQ" firstAttribute="leading" secondItem="z66-Ao-znz" secondAttribute="leading" constant="45" id="xtn-l7-j0B"/>
</constraints>
- <userDefinedRuntimeAttributes>
- <userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
- <userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
- <real key="value" value="10"/>
- </userDefinedRuntimeAttribute>
- </userDefinedRuntimeAttributes>
</view>
- <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="dho-ek-UFQ">
- <rect key="frame" x="45" y="269" width="303" height="40"/>
- <color key="backgroundColor" red="0.54117647059999996" green="0.68235294120000001" blue="0.39607843139999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
- <constraints>
- <constraint firstAttribute="height" constant="40" id="4UX-8H-LKn"/>
- </constraints>
- <fontDescription key="fontDescription" type="system" weight="medium" pointSize="15"/>
- <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
- <state key="normal" title="确认充值"/>
- <userDefinedRuntimeAttributes>
- <userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
- <userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
- <real key="value" value="20"/>
- </userDefinedRuntimeAttribute>
- </userDefinedRuntimeAttributes>
- <connections>
- <action selector="completeAction:" destination="-1" eventType="touchUpInside" id="J4Z-bu-S5a"/>
- </connections>
- </button>
</subviews>
<viewLayoutGuide key="safeArea" id="fnl-2z-Ty3"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
- <constraint firstItem="Ok4-Yz-gOY" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" constant="9" id="10y-6E-fB3"/>
- <constraint firstItem="dho-ek-UFQ" firstAttribute="top" secondItem="Ok4-Yz-gOY" secondAttribute="bottom" constant="60" id="9fP-sd-mfR"/>
- <constraint firstItem="Ok4-Yz-gOY" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="14" id="FPS-mE-2rl"/>
- <constraint firstItem="dho-ek-UFQ" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" constant="45" id="QJ6-pf-eSf"/>
- <constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="dho-ek-UFQ" secondAttribute="trailing" constant="45" id="azm-t3-fHr"/>
- <constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="Ok4-Yz-gOY" secondAttribute="trailing" constant="14" id="zDh-wQ-hh2"/>
+ <constraint firstItem="z66-Ao-znz" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" id="H4a-zO-PuC"/>
+ <constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="z66-Ao-znz" secondAttribute="trailing" id="LJm-cD-LIU"/>
+ <constraint firstItem="z66-Ao-znz" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="fX6-Bo-Efs"/>
+ <constraint firstItem="fnl-2z-Ty3" firstAttribute="bottom" secondItem="z66-Ao-znz" secondAttribute="bottom" id="zXV-to-W1g"/>
</constraints>
<point key="canvasLocation" x="58.778625954198468" y="20.422535211267608"/>
</view>
diff --git a/XQMuse/Root/Me/VC/WalletVC.swift b/XQMuse/Root/Me/VC/WalletVC.swift
index 9682f6b..6fcd76a 100644
--- a/XQMuse/Root/Me/VC/WalletVC.swift
+++ b/XQMuse/Root/Me/VC/WalletVC.swift
@@ -45,7 +45,7 @@
}
@IBAction func withdrawAction(_ sender: UIButton) {
- let vc = BankWithdrawVC(income: walletModel?.income ?? 0)
+ let vc = BankWithdrawVC(income: walletModel?.balance ?? 0)
push(vc: vc)
}
@@ -60,13 +60,14 @@
}
@IBAction func commentAction(_ sender: TapBtn) {
- let vc = MyCommentListVC()
- vc.title = "我的推荐"
- push(vc: vc)
+ let vc = WebVC(url: ShareUrl + "/ranking/recommend?userId=\(UserViewModel.getAvatarInfo().id)")
+ vc.title = "推荐名单"
+ push(vc: vc)
+
}
@IBAction func popularizeAction(_ sender: TapBtn) {
- let vc = MyCommentListVC()
+ let vc = InviteVC()
vc.title = "推广活动"
push(vc: vc)
}
diff --git a/XQMuse/Root/Me/VC/WalletVC.xib b/XQMuse/Root/Me/VC/WalletVC.xib
index 35ec6e8..8d49e03 100644
--- a/XQMuse/Root/Me/VC/WalletVC.xib
+++ b/XQMuse/Root/Me/VC/WalletVC.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -22,7 +22,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="YLf-DI-Qac">
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="YLf-DI-Qac">
<rect key="frame" x="0.0" y="0.0" width="393" height="297"/>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="KW9-Cu-mZr">
@@ -32,7 +32,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="260"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="可用余额(元)" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="1hb-Gu-i11">
- <rect key="frame" x="45.000000000000007" y="27.000000000000004" width="95.666666666666686" height="14.666666666666668"/>
+ <rect key="frame" x="45" y="27.000000000000004" width="93" height="14.666666666666668"/>
<constraints>
<constraint firstAttribute="height" constant="14.5" id="RjS-4t-g8T"/>
</constraints>
@@ -50,7 +50,7 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="充值(疗愈币)" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="bTT-6A-oeC">
- <rect key="frame" x="44.999999999999993" y="123.00000000000001" width="76.333333333333314" height="11.666666666666671"/>
+ <rect key="frame" x="44.999999999999993" y="123.00000000000001" width="74.333333333333314" height="11.666666666666671"/>
<constraints>
<constraint firstAttribute="height" constant="11.5" id="yb2-0Y-fpK"/>
</constraints>
@@ -59,7 +59,7 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="收益(元)" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="2Wj-Qo-uKd">
- <rect key="frame" x="228.33333333333334" y="123.00000000000001" width="51.666666666666657" height="11.666666666666671"/>
+ <rect key="frame" x="229.33333333333334" y="123.00000000000001" width="50.666666666666657" height="11.666666666666671"/>
<constraints>
<constraint firstAttribute="height" constant="11.5" id="WAM-OA-pHr"/>
</constraints>
@@ -74,7 +74,7 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0xP-OZ-ZWR">
- <rect key="frame" x="228.33333333333334" y="143.66666666666669" width="16" height="28.666666666666657"/>
+ <rect key="frame" x="229.33333333333334" y="143.66666666666669" width="16" height="28.666666666666657"/>
<fontDescription key="fontDescription" type="boldSystem" pointSize="24"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
@@ -163,7 +163,7 @@
<rect key="frame" x="16" y="17.666666666666686" width="15.666666666666664" height="15.666666666666664"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="余额明细" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Irv-xl-Q2e">
- <rect key="frame" x="41.666666666666657" y="17.666666666666686" width="53.333333333333343" height="15.666666666666664"/>
+ <rect key="frame" x="41.666666666666671" y="17.666666666666686" width="51.666666666666671" height="15.666666666666664"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
@@ -202,7 +202,7 @@
<rect key="frame" x="16" y="18.666666666666686" width="14.666666666666664" height="13.666666666666664"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="推荐名单" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ibw-8k-fbD">
- <rect key="frame" x="40.666666666666657" y="17.666666666666686" width="53.333333333333343" height="15.666666666666664"/>
+ <rect key="frame" x="40.666666666666671" y="17.666666666666686" width="51.666666666666671" height="15.666666666666664"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
@@ -233,7 +233,7 @@
<rect key="frame" x="14.666666666666657" y="519.66666666666663" width="364" height="66.333333333333371"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="推荐心泉疗愈给好友" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="XgZ-h6-scF">
- <rect key="frame" x="9.3333333333333357" y="25.333333333333375" width="119.66666666666666" height="15.666666666666668"/>
+ <rect key="frame" x="9.3333333333333357" y="25.333333333333375" width="116.33333333333331" height="15.666666666666668"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
diff --git a/XQMuse/Root/Me/VC/WatchHistoryDetailVC.swift b/XQMuse/Root/Me/VC/WatchHistoryDetailVC.swift
index dff0996..2a7a411 100644
--- a/XQMuse/Root/Me/VC/WatchHistoryDetailVC.swift
+++ b/XQMuse/Root/Me/VC/WatchHistoryDetailVC.swift
@@ -50,7 +50,7 @@
collectionView.dataSource = self
collectionView.showsVerticalScrollIndicator = false
collectionView.backgroundColor = .clear
- collectionView.register(UINib(nibName: "HomeRelaxBannerCCell", bundle: nil), forCellWithReuseIdentifier: "_HomeRelaxBannerCCell")
+ collectionView.register(UINib(nibName: "HomeRelaxBanner_2_1_CCell", bundle: nil), forCellWithReuseIdentifier: "_HomeRelaxBanner_2_1_CCell")
collectionView.contentInset = UIEdgeInsets(top: 0, left: 29.5 , bottom: 0, right: 29.5)
view.addSubview(collectionView)
@@ -70,9 +70,16 @@
}
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
- let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "_HomeRelaxBannerCCell", for: indexPath) as! HomeRelaxBannerCCell
+ let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "_HomeRelaxBanner_2_1_CCell", for: indexPath) as! HomeRelaxBanner_2_1_CCell
let m = viewModel.dataSource.value[indexPath.row]
cell.setCourseModel(m)
+
+ if viewModel.type.value == .payment{
+ cell.image_free.isHidden = true
+ cell.img_vip.isHidden = true
+ cell.view_price.isHidden = true
+ }
+
return cell
}
diff --git a/XQMuse/Root/Me/VC/WatchHistoryVC.swift b/XQMuse/Root/Me/VC/WatchHistoryVC.swift
index 83c0ebb..807aa14 100644
--- a/XQMuse/Root/Me/VC/WatchHistoryVC.swift
+++ b/XQMuse/Root/Me/VC/WatchHistoryVC.swift
@@ -123,6 +123,22 @@
}
func pageViewController(_ pageViewConteoller: FFPageViewController, controllerForPage page: Int) -> UIViewController {
- return WatchHistoryDetailVC(state: page+1, type: watchType)
+
+
+ switch watchType{
+ case .collect:
+ return WatchHistoryDetailVC(state: page+1, type: watchType)
+ case .history:
+ return WatchHistoryDetailVC(state: page+1, type: watchType)
+ case .payment:
+ var state = 1
+ if page == 0{
+ state = 2
+ }
+ return WatchHistoryDetailVC(state: state, type: watchType)
+ case .none:break
+ }
+
+ return UIViewController()
}
}
diff --git a/XQMuse/Root/Me/VC/WatchHistoryVC.xib b/XQMuse/Root/Me/VC/WatchHistoryVC.xib
index 3b480b5..5d63bd4 100644
--- a/XQMuse/Root/Me/VC/WatchHistoryVC.xib
+++ b/XQMuse/Root/Me/VC/WatchHistoryVC.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -26,7 +26,7 @@
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
- <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="top" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="Ftr-21-raE">
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="bg_voice_top" translatesAutoresizingMaskIntoConstraints="NO" id="Ftr-21-raE">
<rect key="frame" x="0.0" y="0.0" width="393" height="297"/>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="krq-u0-CTV">
@@ -49,7 +49,7 @@
<rect key="frame" x="0.0" y="0.0" width="171.66666666666666" height="81"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="疗 愈" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="XWw-mG-mV5">
- <rect key="frame" x="65" y="22" width="41.333333333333343" height="17"/>
+ <rect key="frame" x="65.666666666666671" y="22" width="40.333333333333329" height="17"/>
<constraints>
<constraint firstAttribute="height" constant="17" id="cfA-1T-aTt"/>
</constraints>
@@ -81,7 +81,7 @@
<rect key="frame" x="171.66666666666663" y="0.0" width="171.33333333333337" height="81"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="课 程" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="nAp-Sq-gu0">
- <rect key="frame" x="65.000000000000028" y="22" width="41.333333333333343" height="17"/>
+ <rect key="frame" x="65.333333333333343" y="22" width="40.333333333333343" height="17"/>
<constraints>
<constraint firstAttribute="height" constant="17" id="gqk-lU-Pbs"/>
</constraints>
diff --git a/XQMuse/Root/Network/Models.swift b/XQMuse/Root/Network/Models.swift
index 84a1e50..786c078 100644
--- a/XQMuse/Root/Network/Models.swift
+++ b/XQMuse/Root/Network/Models.swift
@@ -273,6 +273,15 @@
var levelIcon: String = ""
var levelName: String = ""
var today: Int = 0
+
+ //判断缓存里的VIP信息
+ func checkVip()->Bool{
+ if isVip == .yes{
+ let interval = Date.jq_StringToTimeInterval(vipExpireTime, "yyyy-MM-dd HH:mm:ss")
+ if interval > Date().timeIntervalSince1970{return true}
+ }
+ return false
+ }
}
struct TutorInfoModel:HandyJSON{
diff --git a/XQMuse/Root/Other/View/ChooseOptTitleView.swift b/XQMuse/Root/Other/View/ChooseOptTitleView.swift
index 6f800e3..31a478f 100644
--- a/XQMuse/Root/Other/View/ChooseOptTitleView.swift
+++ b/XQMuse/Root/Other/View/ChooseOptTitleView.swift
@@ -58,6 +58,22 @@
hidden()
}
+ @IBAction func completeAction(_ sender: UIButton) {
+
+ guard selectIndex != nil else{
+ alertError(msg: "请选择举报内容");return
+ }
+
+ CommonAlertView.show(title: "提示", content: "确认举报该提问?") {[weak self] state in
+ guard let weakSelf = self else { return }
+
+ if state{
+ weakSelf.clouse(weakSelf.items[weakSelf.selectIndex!.row])
+ weakSelf.hidden()
+ }
+ }
+ }
+
private func hidden(){
cons_bottom.constant = -JQ_ScreenW
cons_tableHei.constant = 0
@@ -74,13 +90,6 @@
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
selectIndex = indexPath
tableView.reloadData()
-
- CommonAlertView.show(title: "提示", content: "确认举报该提问?") { state in
- if state{
- self.clouse(self.items[indexPath.row])
- self.hidden()
- }
- }
}
}
diff --git a/XQMuse/Root/Other/View/ChooseOptTitleView.xib b/XQMuse/Root/Other/View/ChooseOptTitleView.xib
index 967f942..0580d2a 100644
--- a/XQMuse/Root/Other/View/ChooseOptTitleView.xib
+++ b/XQMuse/Root/Other/View/ChooseOptTitleView.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23094" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23084"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -26,7 +26,7 @@
</constraints>
<fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
- <state key="normal" title="取消"/>
+ <state key="normal" title="确认"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="boolean" keyPath="ld_maskToBoundsXIB" value="YES"/>
<userDefinedRuntimeAttribute type="number" keyPath="ld_cornerRadiusXIB">
@@ -34,7 +34,7 @@
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
- <action selector="cancelAction:" destination="iN0-l3-epB" eventType="touchUpInside" id="wE8-zo-YiR"/>
+ <action selector="completeAction:" destination="iN0-l3-epB" eventType="touchUpInside" id="ohQ-Xy-p4B"/>
</connections>
</button>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" style="plain" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="-1" estimatedSectionHeaderHeight="-1" sectionFooterHeight="-1" estimatedSectionFooterHeight="-1" translatesAutoresizingMaskIntoConstraints="NO" id="wFR-nY-ulZ">
@@ -45,13 +45,25 @@
</constraints>
</tableView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="标题" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="gY6-YR-rdt">
- <rect key="frame" x="178" y="34" width="37" height="21.666666666666671"/>
+ <rect key="frame" x="178.66666666666666" y="34" width="36" height="21.666666666666671"/>
<fontDescription key="fontDescription" type="boldSystem" pointSize="18"/>
<color key="textColor" red="0.2196078431372549" green="0.2196078431372549" blue="0.2196078431372549" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
+ <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="HTJ-U6-bdC">
+ <rect key="frame" x="343" y="29.666666666666629" width="30" height="30"/>
+ <constraints>
+ <constraint firstAttribute="width" constant="30" id="tKp-CU-vQ4"/>
+ <constraint firstAttribute="height" constant="30" id="v2h-2j-D5h"/>
+ </constraints>
+ <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+ <state key="normal" image="btn_close_1"/>
+ <connections>
+ <action selector="cancelAction:" destination="iN0-l3-epB" eventType="touchUpInside" id="BeL-Ck-wRd"/>
+ </connections>
+ </button>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="VKN-sY-6vr">
- <rect key="frame" x="24.666666666666657" y="79" width="349.33333333333337" height="0.66666666666668561"/>
+ <rect key="frame" x="24.666666666666657" y="79" width="349.33333333333337" height="0.6666666666666714"/>
<color key="backgroundColor" red="0.81568627450980391" green="0.81568627450980391" blue="0.81568627450980391" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="0.5" id="oNn-qG-4N0"/>
@@ -66,6 +78,8 @@
<constraint firstItem="gY6-YR-rdt" firstAttribute="centerX" secondItem="l0f-mg-47Y" secondAttribute="centerX" id="NtY-kc-c36"/>
<constraint firstItem="gY6-YR-rdt" firstAttribute="top" secondItem="l0f-mg-47Y" secondAttribute="top" constant="34" id="XbA-cX-hkF"/>
<constraint firstAttribute="bottomMargin" secondItem="6Qs-h9-yKJ" secondAttribute="bottom" constant="36" id="bI0-lX-IlS"/>
+ <constraint firstAttribute="trailing" secondItem="HTJ-U6-bdC" secondAttribute="trailing" constant="20" id="bjl-qV-Mh0"/>
+ <constraint firstItem="HTJ-U6-bdC" firstAttribute="centerY" secondItem="gY6-YR-rdt" secondAttribute="centerY" id="eOX-Dv-nSy"/>
<constraint firstAttribute="trailing" secondItem="VKN-sY-6vr" secondAttribute="trailing" constant="19" id="fr6-ao-RvF"/>
<constraint firstItem="VKN-sY-6vr" firstAttribute="leading" secondItem="l0f-mg-47Y" secondAttribute="leading" constant="24.5" id="kjd-HW-bdk"/>
<constraint firstAttribute="trailing" secondItem="wFR-nY-ulZ" secondAttribute="trailing" id="let-K1-rjZ"/>
@@ -74,10 +88,21 @@
<constraint firstAttribute="trailing" secondItem="6Qs-h9-yKJ" secondAttribute="trailing" constant="47.5" id="yxz-wD-Bu0"/>
</constraints>
</view>
+ <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="BNz-rS-MMK">
+ <rect key="frame" x="0.0" y="59" width="393" height="497"/>
+ <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+ <connections>
+ <action selector="cancelAction:" destination="iN0-l3-epB" eventType="touchUpInside" id="e28-N8-rxZ"/>
+ </connections>
+ </button>
</subviews>
<viewLayoutGuide key="safeArea" id="vUN-kp-3ea"/>
<constraints>
+ <constraint firstItem="BNz-rS-MMK" firstAttribute="leading" secondItem="vUN-kp-3ea" secondAttribute="leading" id="7Gr-p1-9TA"/>
+ <constraint firstItem="l0f-mg-47Y" firstAttribute="top" secondItem="BNz-rS-MMK" secondAttribute="bottom" id="8kY-Cb-p5X"/>
+ <constraint firstItem="BNz-rS-MMK" firstAttribute="top" secondItem="vUN-kp-3ea" secondAttribute="top" id="9M4-WF-RBl"/>
<constraint firstItem="vUN-kp-3ea" firstAttribute="trailing" secondItem="l0f-mg-47Y" secondAttribute="trailing" id="YHj-ce-zNF"/>
+ <constraint firstItem="vUN-kp-3ea" firstAttribute="trailing" secondItem="BNz-rS-MMK" secondAttribute="trailing" id="Yyd-8O-61u"/>
<constraint firstItem="l0f-mg-47Y" firstAttribute="leading" secondItem="vUN-kp-3ea" secondAttribute="leading" id="eqZ-1B-WLP"/>
<constraint firstAttribute="bottom" secondItem="l0f-mg-47Y" secondAttribute="bottom" id="fUy-1u-siK"/>
</constraints>
@@ -92,6 +117,7 @@
</view>
</objects>
<resources>
+ <image name="btn_close_1" width="12" height="12"/>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
diff --git a/XQMuse/Root/Other/WebVC.swift b/XQMuse/Root/Other/WebVC.swift
index f463d3d..7cae9d2 100644
--- a/XQMuse/Root/Other/WebVC.swift
+++ b/XQMuse/Root/Other/WebVC.swift
@@ -54,7 +54,7 @@
webView?.addObserver(self, forKeyPath: "estimatedProgress", options: .new, context: nil)
view.addSubview(webView!)
webView?.snp.makeConstraints({ (make) in
- make.top.equalToSuperview()
+ make.top.equalToSuperview().offset(UIDevice.jq_safeEdges.top)
make.left.right.bottom.equalToSuperview()
})
@@ -64,6 +64,7 @@
self.automaticallyAdjustsScrollViewInsets = false
}
+ webView!.scrollView.delegate = self
progressView.tintColor = tintColor
view.addSubview(progressView)
@@ -109,3 +110,12 @@
}
}
+
+extension WebVC:UIScrollViewDelegate{
+ func scrollViewDidScroll(_ scrollView: UIScrollView) {
+ // let v = min(scrollView.contentOffset.y / JQ_NavBarHeight, 1)
+ // navigationController?.navigationBar.standardAppearance.backgroundColor = .white.withAlphaComponent(v)
+ navigationController?.navigationBar.standardAppearance.backgroundColor = .white
+ navigationController?.navigationBar.scrollEdgeAppearance?.backgroundColor = .white
+ }
+}
--
Gitblit v1.7.1