Commit b92e0670 authored by pete谢兆麟's avatar pete谢兆麟

首页部分bug修复 续签结果时间修复

parent 9815a4c1
......@@ -146,106 +146,116 @@ extension YHHomeBannerView: FSPagerViewDataSource, FSPagerViewDelegate {
// return
// }
// // TODO: - alex测试
if model.skip_url.isEmpty == false {
switch model.skip_type {
case 1: //跳转H5
//for test hjl 建明机器IP
//var url = "http://192.168.23.66:10300/superAppBridge.html#/schoolEvaluation"
//for test hjl 梁辉机器IP
// model.skip_url = "http://192.168.23.75:10300/superAppBridge.html#/double11-home"
//for test hjl steve机器IP
// model.skip_url = "http://192.168.52.158:10300/superAppBridge.html#/double11-home"
//for test hjl 测试环境
// model.skip_url = "https://test-hkdiy-h5.galaxy-immi.com/superAppBridge.html#/double11-home"
//for test hjl 贤宇IP
switch model.skip_type {
case 1: //跳转H5
if model.skip_url.isEmpty == false {
} else {
YHHUD.flash(message: "error:skip_url不能为空")
return
}
//for test hjl 建明机器IP
//var url = "http://192.168.23.66:10300/superAppBridge.html#/schoolEvaluation"
//for test hjl 梁辉机器IP
// model.skip_url = "http://192.168.23.75:10300/superAppBridge.html#/double11-home"
//for test hjl steve机器IP
// model.skip_url = "http://192.168.52.158:10300/superAppBridge.html#/double11-home"
//for test hjl 测试环境
// model.skip_url = "https://test-hkdiy-h5.galaxy-immi.com/superAppBridge.html#/double11-home"
//for test hjl 贤宇IP
// model.skip_url = "http://192.168.23.35:10300/signatureQrcode/EcqtQYs%2Bxey7t6jLbn6JkQ%3D%3D"
// model.skip_url = "http://192.168.23.71:10300/superAppBridge.html#/double11-home"
//1.增加app token
var url = ""
if YHLoginManager.shared.isLogin() {
let token = YHLoginManager.shared.h5Token
url = model.skip_url + "?param=" + token
let urlHasParam = String.hasQueryParameters(urlString: model.skip_url)
if urlHasParam {
url = model.skip_url + "&param=" + token
}
} else {
url = model.skip_url
//1.增加app token
var url = ""
if YHLoginManager.shared.isLogin() {
let token = YHLoginManager.shared.h5Token
url = model.skip_url + "?param=" + token
let urlHasParam = String.hasQueryParameters(urlString: model.skip_url)
if urlHasParam {
url = model.skip_url + "&param=" + token
}
//2.增加导航栏高度
var tUrl = url
if !url.contains("navigationH=") {
tUrl = url + "?navigationH=\(k_Height_NavigationtBarAndStatuBar)"
if url.contains("?") {
tUrl = url + "&navigationH=\(k_Height_NavigationtBarAndStatuBar)"
}
}
let vc = YHH5WebViewVC()
vc.url = tUrl
if model.is_double_11_flag {
vc.isHideNavigationBar = false
} else {
url = model.skip_url
}
//2.增加导航栏高度
var tUrl = url
if !url.contains("navigationH=") {
tUrl = url + "?navigationH=\(k_Height_NavigationtBarAndStatuBar)"
if url.contains("?") {
tUrl = url + "&navigationH=\(k_Height_NavigationtBarAndStatuBar)"
}
if model.is_share_h5_flag {
if let tModel = model.addtition_param {
if !tModel.ShareH5Url.isEmpty {
vc.isShowRightShareItemFlag = true
vc.shareH5Title = tModel.ShareH5Title
vc.shareH5Describe = tModel.ShareH5Describe
vc.shareUrlFromOutside = tModel.ShareH5Url
}
}
let vc = YHH5WebViewVC()
vc.url = tUrl
if model.is_double_11_flag {
vc.isHideNavigationBar = false
}
if model.is_share_h5_flag {
if let tModel = model.addtition_param {
if !tModel.ShareH5Url.isEmpty {
vc.isShowRightShareItemFlag = true
vc.shareH5Title = tModel.ShareH5Title
vc.shareH5Describe = tModel.ShareH5Describe
vc.shareUrlFromOutside = tModel.ShareH5Url
}
}
self.parentViewController?.navigationController?.pushViewController(vc)
case 2: //跳转APP内Tab
goAppTab(tabBarName:model.skip_url)
case 3://3-跳转资讯页
let vc = YHHomeWebViewController()
vc.url = model.skip_url
self.parentViewController?.navigationController?.pushViewController(vc)
case 100:// 直播
//文哥
// media_type 投放类型:1 图片,2 直播
// live_id 直播ID
// live_status 直播状态 1:直播中 2:未直播 0:未知状态 3:结束直播
// live_type 播放类型:1 展示最新直播,2指定直播,3 指定录播
// live_pull_url 直播拉流链接
// video_url 视频链接
// recorded_cate_id 录播分类id token: String? = nil, channelId
let cell: YHHomeBannerCollectionViewCell? = pagerView.cellForItem(at: index) as? YHHomeBannerCollectionViewCell
let playbackInfo = YHPlayerManager.PlaybackInfo(id: model.live_id, url: model.live_pull_url, title: nil, roomId: nil, token: model.token, channelId: model.rtmp_channel, uid: UInt(model.live_id), isLive: true, scene: .fullscreen)
YHPlayerManager.shared.enterLive(from: cell?.bannerImagV, playbackInfo: playbackInfo)
printLog("跳转直播")
case 101://录播
printLog("跳转录播")
let cell: YHHomeBannerCollectionViewCell? = pagerView.cellForItem(at: index) as? YHHomeBannerCollectionViewCell
let playbackInfo = YHPlayerManager.PlaybackInfo(id: model.live_id, url: model.video_url, title: nil, roomId: nil, uid: nil, isLive: false, scene: .fullscreen)
YHPlayerManager.shared.enterVOD(from: cell?.bannerImagV, playbackInfo: playbackInfo)
case 102://图片直播
printLog("跳转录播")
let cell: YHHomeBannerCollectionViewCell? = pagerView.cellForItem(at: index) as? YHHomeBannerCollectionViewCell
let playbackInfo = YHPlayerManager.PlaybackInfo(id: model.live_id, url: model.live_pull_url, title: nil, roomId: nil, token: model.token, channelId: model.rtmp_channel, uid: UInt(model.live_id), isLive: true, scene: .fullscreen)
YHPlayerManager.shared.enterLive(from: cell?.bannerImagV, playbackInfo: playbackInfo)
case 0://0 不需要跳转
printLog("0 不需要跳转")
default:
YHHUD.flash(message: "不需要处理的类型")
break
}
}
else {
YHHUD.flash(message: "error:skip_url不能为空")
self.parentViewController?.navigationController?.pushViewController(vc)
case 2: //跳转APP内Tab
if model.skip_url.isEmpty == false {
} else {
YHHUD.flash(message: "error:skip_url不能为空")
return
}
goAppTab(tabBarName:model.skip_url)
case 3://3-跳转资讯页
if model.skip_url.isEmpty == false {
} else {
YHHUD.flash(message: "error:skip_url不能为空")
return
}
let vc = YHHomeWebViewController()
vc.url = model.skip_url
self.parentViewController?.navigationController?.pushViewController(vc)
case 100:// 直播
//文哥
// media_type 投放类型:1 图片,2 直播
// live_id 直播ID
// live_status 直播状态 1:直播中 2:未直播 0:未知状态 3:结束直播
// live_type 播放类型:1 展示最新直播,2指定直播,3 指定录播
// live_pull_url 直播拉流链接
// video_url 视频链接
// recorded_cate_id 录播分类id token: String? = nil, channelId
let cell: YHHomeBannerCollectionViewCell? = pagerView.cellForItem(at: index) as? YHHomeBannerCollectionViewCell
let playbackInfo = YHPlayerManager.PlaybackInfo(id: model.live_id, url: model.live_pull_url, title: nil, roomId: nil, token: model.token, channelId: model.rtmp_channel, uid: UInt(model.live_id), isLive: true, scene: .fullscreen)
YHPlayerManager.shared.enterLive(from: cell?.bannerImagV, playbackInfo: playbackInfo)
printLog("跳转直播")
case 101://录播
printLog("跳转录播")
let cell: YHHomeBannerCollectionViewCell? = pagerView.cellForItem(at: index) as? YHHomeBannerCollectionViewCell
let playbackInfo = YHPlayerManager.PlaybackInfo(id: model.live_id, url: model.video_url, title: nil, roomId: nil, uid: nil, isLive: false, scene: .fullscreen)
YHPlayerManager.shared.enterVOD(from: cell?.bannerImagV, playbackInfo: playbackInfo)
case 102://图片直播
printLog("跳转录播")
let cell: YHHomeBannerCollectionViewCell? = pagerView.cellForItem(at: index) as? YHHomeBannerCollectionViewCell
let playbackInfo = YHPlayerManager.PlaybackInfo(id: model.live_id, url: model.live_pull_url, title: nil, roomId: nil, token: model.token, channelId: model.rtmp_channel, uid: UInt(model.live_id), isLive: true, scene: .fullscreen)
YHPlayerManager.shared.enterLive(from: cell?.bannerImagV, playbackInfo: playbackInfo)
case 0://0 不需要跳转
printLog("0 不需要跳转")
default:
YHHUD.flash(message: "不需要处理的类型")
break
}
YHAnalytics.track("homeBannerClick", properties: ["url": model.img_url, "index": index])
}
......
......@@ -135,7 +135,7 @@ class YHSelectLookViewCell: UICollectionViewCell {
lazy var descripeLable:UILabel = {
let label = UILabel()
label.text = "高才专家"
label.text = "更多直播"
label.textColor = UIColor(hex: 0x6d788a)
label.font = UIFont.PFSC_R(ofSize: 11)
label.textAlignment = .center
......
......@@ -185,8 +185,8 @@ class YHLookResignResultStateThreePeopleTableViewCell: UITableViewCell {
i += 1
}
titleLabel.text = title + names
peopleValueLabel.text = dataSource.result_date
docValueLabel.text = dataSource.pay_deadline
peopleValueLabel.text = dataSource.pay_deadline
docValueLabel.text = dataSource.result_date
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment