add message exercises
This commit is contained in:
@@ -15,6 +15,9 @@
|
||||
#import "UIView+Toast.h"
|
||||
#import "GiGaMeViewController.h"
|
||||
#import "GiGaAdDetailViewController.h"
|
||||
#import "GiGaMasssagesVC.h"
|
||||
#import "Masonry.h"
|
||||
#import "GiGaQuestionVC.h"
|
||||
|
||||
@interface GiGaMaskTaskViewController ()
|
||||
@property(nonatomic,strong)MaskViewBootomWaringView *waringView;
|
||||
@@ -26,12 +29,46 @@
|
||||
[super viewDidLoad];
|
||||
// Do any additional setup after loading the view.
|
||||
[self setUpNav];
|
||||
[self initUI];
|
||||
[self addNotify];
|
||||
BOOL canshowGaurd = [GiGaUserDefault isShowedGaurd];
|
||||
if (!canshowGaurd) {
|
||||
NSLog(@"%d",(int)canshowGaurd );
|
||||
}
|
||||
|
||||
-(void)initUI{
|
||||
|
||||
UIButton *testBtn = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||
[testBtn setTitle:@"测试肤质" forState:UIControlStateNormal];
|
||||
[testBtn setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
|
||||
testBtn.backgroundColor = [UIColor blueColor];
|
||||
[testBtn addTarget:self action:@selector(testBtnAcion:) forControlEvents:UIControlEventTouchUpInside];
|
||||
testBtn.layer.masksToBounds = YES;
|
||||
testBtn.layer.cornerRadius = 4;
|
||||
|
||||
[self.view addSubview:testBtn];
|
||||
[testBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.centerX.mas_equalTo(self.view.mas_centerX);
|
||||
make.width.mas_equalTo(150);
|
||||
make.height.mas_equalTo(40);
|
||||
make.bottom.mas_equalTo(self.view.mas_bottom).offset(-200);
|
||||
}];
|
||||
|
||||
}
|
||||
|
||||
#pragma mark 开始测试
|
||||
-(void)testBtnAcion:(UIButton *)btn{
|
||||
|
||||
BOOL isUserLogin = [GiGaUserDefault isUserLogin];
|
||||
if (isUserLogin) {
|
||||
|
||||
//GIGA_ShowToast(@"userLogin!");
|
||||
GiGaQuestionVC *questionVC = [[GiGaQuestionVC alloc] init];
|
||||
[self.navigationController pushViewController:questionVC animated:YES];
|
||||
|
||||
}else{
|
||||
GiGaUserLoginVC *userlogInVC= [[GiGaUserLoginVC alloc] init];
|
||||
GiGaBaseNavViewController *baseNav = [[GiGaBaseNavViewController alloc] initWithRootViewController:userlogInVC];
|
||||
[self presentViewController:baseNav animated:YES completion:nil];
|
||||
}
|
||||
// NSLog(@"%d",(int)canshowGaurd );
|
||||
|
||||
}
|
||||
|
||||
-(void)viewDidAppear:(BOOL)animated{
|
||||
@@ -58,10 +95,12 @@
|
||||
[self.navigationController pushViewController:detailVC animated:YES];
|
||||
|
||||
}
|
||||
|
||||
#pragma mark 新手引导消失
|
||||
-(void)guardViewDissmiss{
|
||||
[self showWaringView];
|
||||
}
|
||||
|
||||
#pragma mark app引导页消失
|
||||
-(void)appGauardViewDissmiss{
|
||||
//出现新手引导
|
||||
@@ -71,6 +110,7 @@
|
||||
[self showUserGaurdView];
|
||||
}
|
||||
}
|
||||
|
||||
-(void)dealloc{
|
||||
|
||||
NC_REMOVE_NAME(self, USER_GUARD_DISSMISS, nil);
|
||||
@@ -120,9 +160,11 @@
|
||||
-(void)leftBtnAction{
|
||||
BOOL isUserLogin = [GiGaUserDefault isUserLogin];
|
||||
if (isUserLogin) {
|
||||
|
||||
GIGA_ShowToast(@"userLogin!");
|
||||
|
||||
|
||||
GiGaMasssagesVC *masageVC= [[GiGaMasssagesVC alloc] init];
|
||||
[self.navigationController pushViewController:masageVC animated:YES];
|
||||
|
||||
}else{
|
||||
GiGaUserLoginVC *userlogInVC= [[GiGaUserLoginVC alloc] init];
|
||||
GiGaBaseNavViewController *baseNav = [[GiGaBaseNavViewController alloc] initWithRootViewController:userlogInVC];
|
||||
|
||||
Reference in New Issue
Block a user