修复bug
This commit is contained in:
@@ -174,6 +174,17 @@
|
||||
}
|
||||
|
||||
- (void)protcoloButtonAction:(UIButton *)sender {
|
||||
if(self.isFairyPay){
|
||||
XPWebViewController * webVC= [[XPWebViewController alloc] initWithCustomizeNav:YES];
|
||||
webVC.url = URLWithType(kRechargePrivacyURL);
|
||||
webVC.is_Pi_FairyPay = YES;
|
||||
webVC.view.backgroundColor = [UIColor whiteColor];
|
||||
[self addChildViewController:webVC];
|
||||
[self.view addSubview:webVC.view];
|
||||
webVC.view.frame = CGRectMake(0, 0, KScreenWidth, KScreenHeight);
|
||||
return;
|
||||
}
|
||||
|
||||
XPWebViewController * webVC= [[XPWebViewController alloc] init];
|
||||
webVC.url = URLWithType(kRechargePrivacyURL);
|
||||
[self.navigationController pushViewController:webVC animated:YES];
|
||||
|
@@ -12,7 +12,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface XPHomePartyViewController : MvpViewController<JXCategoryListContentViewDelegate>
|
||||
///模块的 ID
|
||||
@property (nonatomic,copy) NSString *tabId;
|
||||
@property (nonatomic,copy) NSString *pi_tabId;
|
||||
///是否是个播
|
||||
@property (nonatomic,assign) BOOL isAnchor;
|
||||
//TODO: 应该用一个新的控制器的 先发版吧
|
||||
|
@@ -85,7 +85,7 @@
|
||||
if (self.isAnchor) {
|
||||
[self.presenter getHomeMoreAnchorRoomList];
|
||||
} else {
|
||||
[self.presenter getRecommendRoomList:self.tabId page:self.page pageSize:20 state:0];
|
||||
[self.presenter getRecommendRoomList:self.pi_tabId page:self.page pageSize:20 state:0];
|
||||
}
|
||||
|
||||
}
|
||||
@@ -100,7 +100,7 @@
|
||||
if (self.isAnchor) {
|
||||
[self.presenter getHomeMoreAnchorRoomList];
|
||||
} else {
|
||||
[self.presenter getRecommendRoomList:self.tabId page:self.page pageSize:20 state:1];
|
||||
[self.presenter getRecommendRoomList:self.pi_tabId page:self.page pageSize:20 state:1];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -192,14 +192,14 @@
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
- (void)setTabId:(NSString *)tabId {
|
||||
_tabId = tabId;
|
||||
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.2 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
|
||||
[self headerRefresh];
|
||||
});
|
||||
- (void)setPi_tabId:(NSString *)pi_tabId{
|
||||
_pi_tabId = pi_tabId;
|
||||
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.2 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
|
||||
[self headerRefresh];
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
- (UITableView *)tableView {
|
||||
if (!_tableView) {
|
||||
_tableView = [[UITableView alloc] initWithFrame:CGRectZero style:UITableViewStylePlain];
|
||||
|
@@ -168,7 +168,7 @@ UIKIT_EXTERN NSString * const kOpenRoomNotification;
|
||||
return recommendVC;
|
||||
} else {
|
||||
XPHomePartyViewController * homeVC = [[XPHomePartyViewController alloc] init];
|
||||
homeVC.tabId = hometag.tid;
|
||||
homeVC.pi_tabId = hometag.tid;
|
||||
return homeVC;
|
||||
}
|
||||
}
|
||||
@@ -180,7 +180,7 @@ UIKIT_EXTERN NSString * const kOpenRoomNotification;
|
||||
HomeTagModel * hometag = [self.tagList safeObjectAtIndex1:index];
|
||||
if (![hometag.name isEqualToString:YMLocalizedString(@"XPNewHomeViewController1")]) {
|
||||
XPHomePartyViewController * list = (XPHomePartyViewController<JXCategoryListContentViewDelegate> *)[self.contentView.validListDict objectForKey:[NSNumber numberWithInteger:index]];;
|
||||
list.tabId = hometag.tid;
|
||||
list.pi_tabId = hometag.tid;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -27,7 +27,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,copy) NSString *roomUid;
|
||||
///是否从精灵页面过来
|
||||
@property (nonatomic,assign) BOOL isFairyPay;
|
||||
|
||||
@property (nonatomic,assign) BOOL is_Pi_FairyPay;
|
||||
|
||||
///XPWebViewController是否作为属性,yes则
|
||||
@property (nonatomic,assign) BOOL isProperty;
|
||||
|
@@ -181,6 +181,10 @@ NSString * const kJSOpenRoomForGiftId = @"openRoomForGiftId";
|
||||
} uid:uid ticket:ticket];
|
||||
}
|
||||
- (void)xPWebViewNavView:(XPWebViewNavView *)view didClickBack:(UIButton *)sender{
|
||||
if(self.is_Pi_FairyPay){
|
||||
[self.view removeFromSuperview];
|
||||
return;
|
||||
}
|
||||
if(self.isFairyPay){
|
||||
if(self.CloseWebViewBlock){
|
||||
self.CloseWebViewBlock(YES);
|
||||
|
Reference in New Issue
Block a user