JXMybossVc.m 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227
  1. //
  2. // JXMybossVc.m
  3. // shiku_im
  4. //
  5. // Created by 123 on 2020/5/18.
  6. // Copyright © 2020 Reese. All rights reserved.
  7. //
  8. #import "JXMybossVc.h"
  9. @interface JXMybossVc ()
  10. @property (nonatomic,weak) UIButton *bossQQL;
  11. @property (nonatomic,weak) UIButton *myQQL;
  12. @end
  13. @implementation JXMybossVc
  14. - (void)viewWillAppear:(BOOL)animated{
  15. [super viewWillAppear:animated];
  16. [self.navigationController setNavigationBarHidden:NO];
  17. }
  18. - (void)viewDidLoad {
  19. [super viewDidLoad];
  20. self.navigationItem.title=@"我的上级";
  21. self.view.backgroundColor=kRGBColor(246, 246, 246);
  22. //
  23. [self defineNavBar:@"我的上级" andRinghtBtnImg:@""];
  24. UIImageView *bgIMG=[[UIImageView alloc]init];
  25. bgIMG.image=[UIImage imageNamed:@"BG2111"];
  26. [self.view addSubview:bgIMG];
  27. [bgIMG mas_makeConstraints:^(MASConstraintMaker *make) {
  28. make.top.mas_equalTo(JX_SCREEN_TOP);
  29. make.right.left.mas_equalTo(20);
  30. make.bottom.mas_equalTo(0);
  31. }];
  32. UILabel *titleL=[[UILabel alloc]init];
  33. titleL.font=[UIFont systemFontOfSize:18 weight:UIFontWeightRegular];
  34. titleL.textColor=kRGBColor(106, 106, 106);
  35. titleL.text=@"尊敬的会员:";
  36. [self.view addSubview:titleL];
  37. [titleL mas_makeConstraints:^(MASConstraintMaker *make) {
  38. make.top.mas_equalTo(JX_SCREEN_TOP+10);
  39. make.left.mas_equalTo(20);
  40. }];
  41. UILabel *usertit=[[UILabel alloc]init];
  42. usertit.text=@" 平台有4点温馨提示,请您注意!\n\n 1、上级导师、管理员、群主都是属于吉利彩票平台的独家代理,他们是不会给您推荐其他平台的!\n\n 2、如果推荐其他平台,就是要骗取您的资金。请您向在线客服进行举报,我们将予以重奖。\n\n 3、【HTTPS://WWW.7520.COM】是吉利彩票的国际域名(备用域名7520.VIP),请您认准域名登录。\n\n 4、每次充值前请您到官方充值窗口或联系在线客服获取卡号。如果是您的上级发给您的充值卡号,请您一定要再三核对是否与本平台的官方卡号一致,谨防上当受骗。";
  43. usertit.numberOfLines=0;
  44. usertit.font=[UIFont systemFontOfSize:15 weight:UIFontWeightRegular];
  45. usertit.textColor=kRGBColor(106, 106, 106);
  46. [self.view addSubview:usertit];
  47. [usertit mas_makeConstraints:^(MASConstraintMaker *make) {
  48. make.top.mas_equalTo(titleL.mas_bottom).mas_offset(20);
  49. make.left.mas_equalTo(20);
  50. make.right.mas_equalTo(-20);
  51. }];
  52. UILabel *bossQQL=[[UILabel alloc]init];
  53. bossQQL.text=@"您的上级QQ";
  54. bossQQL.font=[UIFont systemFontOfSize:16 weight:UIFontWeightRegular];
  55. [self.view addSubview:bossQQL];
  56. [bossQQL mas_makeConstraints:^(MASConstraintMaker *make) {
  57. make.top.mas_equalTo(usertit.mas_bottom).mas_offset(30);
  58. make.left.mas_equalTo(20);
  59. }];
  60. UIButton *bossQQLValue=[[UIButton alloc]init];
  61. [bossQQLValue setTitle:@"13254650" forState:UIControlStateNormal];
  62. //bossQQLValue.contentMode=UIViewContentModeScaleAspectFit;
  63. [bossQQLValue setImage:[UIImage imageNamed:@"qqValue"] forState:UIControlStateNormal];
  64. [bossQQLValue setTitleColor:kRGBColor(11, 11, 11) forState:UIControlStateNormal];
  65. [self.view addSubview:bossQQLValue];
  66. self.bossQQL=bossQQLValue;
  67. [bossQQLValue mas_makeConstraints:^(MASConstraintMaker *make) {
  68. make.centerY.mas_equalTo(bossQQL.mas_centerY).mas_offset(0);
  69. make.centerX.mas_equalTo(self.view.mas_centerX);
  70. //make.height.mas_equalTo(15);
  71. }];
  72. UIButton *addBtn=[[UIButton alloc]init];
  73. [addBtn setTitle:@" 复制 " forState:UIControlStateNormal];
  74. addBtn.titleLabel.font=[UIFont systemFontOfSize:14 weight:UIFontWeightMedium];
  75. [addBtn setTitleColor:kRGBColor(206, 28, 28) forState:UIControlStateNormal];
  76. addBtn.backgroundColor=[UIColor whiteColor];
  77. [self.view addSubview:addBtn];
  78. [addBtn addTarget:self action:@selector(fuzhiBtnQQClick) forControlEvents:UIControlEventTouchUpInside];
  79. [addBtn mas_makeConstraints:^(MASConstraintMaker *make) {
  80. make.top.mas_equalTo(usertit.mas_bottom).mas_offset(20);
  81. make.right.mas_equalTo(-20);
  82. make.height.mas_equalTo(36);
  83. }];
  84. UILabel *line_VIew=[[UILabel alloc]init];
  85. line_VIew.backgroundColor=kRGBColor(222, 222, 222);
  86. [self.view addSubview:line_VIew];
  87. [line_VIew mas_makeConstraints:^(MASConstraintMaker *make) {
  88. make.top.mas_equalTo(addBtn.mas_bottom).mas_offset(8);
  89. make.right.left.mas_equalTo(20);
  90. make.height.mas_equalTo(1);
  91. }];
  92. UILabel *myQQL=[[UILabel alloc]init];
  93. myQQL.text=@"您的上级微信";
  94. myQQL.font=[UIFont systemFontOfSize:16 weight:UIFontWeightRegular];
  95. [self.view addSubview:myQQL];
  96. [myQQL mas_makeConstraints:^(MASConstraintMaker *make) {
  97. make.top.mas_equalTo(line_VIew.mas_bottom).mas_offset(10);
  98. make.left.mas_equalTo(20);
  99. }];
  100. UIButton *wxBtnValue=[[UIButton alloc]init];
  101. [wxBtnValue setTitle:@"13254650" forState:UIControlStateNormal];
  102. [wxBtnValue setImage:[UIImage imageNamed:@"wxValue"] forState:UIControlStateNormal];
  103. [wxBtnValue setTitleColor:kRGBColor(11, 11, 11) forState:UIControlStateNormal];
  104. [self.view addSubview:wxBtnValue];
  105. self.myQQL=wxBtnValue;
  106. [wxBtnValue mas_makeConstraints:^(MASConstraintMaker *make) {
  107. make.centerY.mas_equalTo(myQQL.mas_centerY).mas_offset(0);
  108. make.centerX.mas_equalTo(self.view.mas_centerX);
  109. make.height.mas_equalTo(15);
  110. }];
  111. UIButton *fuzhiBtn=[[UIButton alloc]init];
  112. [fuzhiBtn setTitle:@" 复制 " forState:UIControlStateNormal];
  113. fuzhiBtn.titleLabel.font=[UIFont systemFontOfSize:14 weight:UIFontWeightMedium];
  114. [fuzhiBtn setTitleColor:kRGBColor(206, 28, 28) forState:UIControlStateNormal];
  115. fuzhiBtn.backgroundColor=[UIColor whiteColor];
  116. [self.view addSubview:fuzhiBtn];
  117. [fuzhiBtn addTarget:self action:@selector(fuzhiBtnWXClick) forControlEvents:UIControlEventTouchUpInside];
  118. [fuzhiBtn mas_makeConstraints:^(MASConstraintMaker *make) {
  119. make.top.mas_equalTo(line_VIew.mas_bottom).mas_offset(0);
  120. make.right.mas_equalTo(-20);
  121. make.height.mas_equalTo(36);
  122. }];
  123. UILabel *vesionL=[[UILabel alloc]init];
  124. vesionL.text=@" 即信版本号:2.0.3";
  125. vesionL.textAlignment=NSTextAlignmentCenter;
  126. vesionL.font=[UIFont systemFontOfSize:15 weight:UIFontWeightRegular];
  127. [self.view addSubview:vesionL];
  128. [vesionL mas_makeConstraints:^(MASConstraintMaker *make) {
  129. make.bottom.mas_equalTo(self.view.mas_bottom).mas_offset(-44);
  130. make.left.mas_equalTo(20);
  131. make.right.mas_equalTo(-20);
  132. }];
  133. long time = (long)[[NSDate date] timeIntervalSince1970];
  134. time = (time *1000 + g_server.timeDifference);
  135. NSString *salt = [NSString stringWithFormat:@"%ld", time];
  136. NSString *membershipAccount=[[NSUserDefaults standardUserDefaults] objectForKey:@"membershipAccount_ID"];
  137. [g_server get_act_GetshangXiaJi:membershipAccount salt:salt toView:self];
  138. }
  139. //复制qq
  140. - (void)fuzhiBtnQQClick{
  141. UIPasteboard *paseBoard=[UIPasteboard generalPasteboard];
  142. paseBoard.string=_strWXURL[@"qq"];
  143. [SVProgressHUD showWithStatus:@"复制成功"];
  144. [SVProgressHUD dismissWithDelay:1.0];
  145. }
  146. //复制微信号
  147. - (void)fuzhiBtnWXClick{
  148. UIPasteboard *paseBoard=[UIPasteboard generalPasteboard];
  149. paseBoard.string=_strWXURL[@"wx"];
  150. [SVProgressHUD showWithStatus:@"复制成功"];
  151. [SVProgressHUD dismissWithDelay:1.0];
  152. }
  153. //服务端返回数据
  154. -(void) didServerResultSucces:(JXConnection*)aDownload dict:(NSDictionary*)dict array:(NSArray*)array1{
  155. if([aDownload.action isEqualToString:act_GetshangXiaJi]){
  156. NSDictionary * currentDictionary = [dict objectForKey:@"superior"];
  157. _strWXURL=currentDictionary;
  158. //[self.bossQQL setImage:[UIImage imageNamed:@"qqValue"] forState:UIControlStateNormal];
  159. [self.bossQQL setTitle:[NSString stringWithFormat:@" %@ ",currentDictionary[@"qq"]] forState:UIControlStateNormal];
  160. //[self.myQQL setImage:[UIImage imageNamed:@"wxValue"] forState:UIControlStateNormal];
  161. [self.myQQL setTitle:[NSString stringWithFormat:@" %@ ",currentDictionary[@"wx"]] forState:UIControlStateNormal];
  162. }
  163. }
  164. - (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex{
  165. }
  166. -(int) didServerResultFailed:(JXConnection*)aDownload dict:(NSDictionary*)dict{
  167. if( [aDownload.action isEqualToString:act_GetSerServeWxget] ){
  168. }
  169. return hide_error;
  170. }
  171. @end