diff --git a/Ifish.xcodeproj/project.pbxproj b/Ifish.xcodeproj/project.pbxproj index 23a9bd6..a55ed51 100644 --- a/Ifish.xcodeproj/project.pbxproj +++ b/Ifish.xcodeproj/project.pbxproj @@ -2243,6 +2243,8 @@ C024B7AF2379668B00509424 /* NSMutableString+AvoidCrash.h in Headers */ = {isa = PBXBuildFile; fileRef = C024B79B2379668B00509424 /* NSMutableString+AvoidCrash.h */; }; C024B7B02379668B00509424 /* NSMutableAttributedString+AvoidCrash.h in Headers */ = {isa = PBXBuildFile; fileRef = C024B79C2379668B00509424 /* NSMutableAttributedString+AvoidCrash.h */; }; C024B7B12379668B00509424 /* NSMutableArray+AvoidCrash.h in Headers */ = {isa = PBXBuildFile; fileRef = C024B79D2379668B00509424 /* NSMutableArray+AvoidCrash.h */; }; + C02ED596249E3B7300CAC37D /* InfoByImageViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = C02ED594249E3B7300CAC37D /* InfoByImageViewController.h */; }; + C02ED597249E3B7300CAC37D /* InfoByImageViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = C02ED595249E3B7300CAC37D /* InfoByImageViewController.m */; }; C0837A57244FF5510034FEC5 /* EGOCache.m in Sources */ = {isa = PBXBuildFile; fileRef = C0837A55244FF5500034FEC5 /* EGOCache.m */; }; C0837A58244FF5510034FEC5 /* EGOCache.h in Headers */ = {isa = PBXBuildFile; fileRef = C0837A56244FF5500034FEC5 /* EGOCache.h */; }; C0873EE12491060000D47D34 /* ESPUDPSocketClient.h in Headers */ = {isa = PBXBuildFile; fileRef = C0873EBE249105FF00D47D34 /* ESPUDPSocketClient.h */; }; @@ -5700,6 +5702,8 @@ C024B79B2379668B00509424 /* NSMutableString+AvoidCrash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSMutableString+AvoidCrash.h"; sourceTree = ""; }; C024B79C2379668B00509424 /* NSMutableAttributedString+AvoidCrash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSMutableAttributedString+AvoidCrash.h"; sourceTree = ""; }; C024B79D2379668B00509424 /* NSMutableArray+AvoidCrash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSMutableArray+AvoidCrash.h"; sourceTree = ""; }; + C02ED594249E3B7300CAC37D /* InfoByImageViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = InfoByImageViewController.h; sourceTree = ""; }; + C02ED595249E3B7300CAC37D /* InfoByImageViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = InfoByImageViewController.m; sourceTree = ""; }; C0837A55244FF5500034FEC5 /* EGOCache.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = EGOCache.m; sourceTree = ""; }; C0837A56244FF5500034FEC5 /* EGOCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EGOCache.h; sourceTree = ""; }; C0873EBE249105FF00D47D34 /* ESPUDPSocketClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ESPUDPSocketClient.h; sourceTree = ""; }; @@ -9665,6 +9669,8 @@ E5212234210760A600BA24C5 /* SettingResetViewController.xib */, CB7D6ABA229660370014E5C7 /* IfishConnectUsViewController.h */, CB7D6ABB229660370014E5C7 /* IfishConnectUsViewController.m */, + C02ED594249E3B7300CAC37D /* InfoByImageViewController.h */, + C02ED595249E3B7300CAC37D /* InfoByImageViewController.m */, ); path = mineControllers; sourceTree = ""; @@ -12899,6 +12905,7 @@ CB7D6AA322953BEB0014E5C7 /* YYMemoryCache.h in Headers */, 3D1C50E6221A9EE00096AE43 /* ParamDao.h in Headers */, CB484DFC22B8C8C80075F050 /* bswap.h in Headers */, + C02ED596249E3B7300CAC37D /* InfoByImageViewController.h in Headers */, 3D1C5134221A9EE10096AE43 /* YooseeNextConnectViewController.h in Headers */, CB484DFF22B8C8C80075F050 /* audioconvert.h in Headers */, CB484DED22B8C8C80075F050 /* file.h in Headers */, @@ -15147,6 +15154,7 @@ 881A1D591DD41C0700BA1AF4 /* MineKanEditSec2SecCell.m in Sources */, 888EEB5F1DC346D3003C5C5B /* FBShimmeringView.m in Sources */, 3D1C174B2171BB0700A159A8 /* PNLineChart.m in Sources */, + C02ED597249E3B7300CAC37D /* InfoByImageViewController.m in Sources */, 3D1C50E7221A9EE00096AE43 /* CameraManager.m in Sources */, 8816719F1EA5DE2B00BEBF23 /* UMComFeedEditDataController.m in Sources */, 883BCD741ED58B810046283B /* ShopDetailViewGoodsViewCell.m in Sources */, @@ -15745,7 +15753,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 17; + CURRENT_PROJECT_VERSION = 5.1.5; DEVELOPMENT_TEAM = WFX8GD5HFX; ENABLE_BITCODE = NO; ENABLE_TESTABILITY = YES; @@ -15863,7 +15871,7 @@ CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 17; + CURRENT_PROJECT_VERSION = 5.1.5; DEVELOPMENT_TEAM = WFX8GD5HFX; ENABLE_BITCODE = NO; ENABLE_TESTABILITY = YES; diff --git a/Ifish/Assets.xcassets/HotBar/apmodeInfo.imageset/Contents.json b/Ifish/Assets.xcassets/HotBar/apmodeInfo.imageset/Contents.json new file mode 100644 index 0000000..5567633 --- /dev/null +++ b/Ifish/Assets.xcassets/HotBar/apmodeInfo.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "apmodeInfo.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Ifish/Assets.xcassets/HotBar/apmodeInfo.imageset/apmodeInfo.png b/Ifish/Assets.xcassets/HotBar/apmodeInfo.imageset/apmodeInfo.png new file mode 100644 index 0000000..75bf320 Binary files /dev/null and b/Ifish/Assets.xcassets/HotBar/apmodeInfo.imageset/apmodeInfo.png differ diff --git a/Ifish/Assets.xcassets/HotBar/hotbarInfo.imageset/Contents.json b/Ifish/Assets.xcassets/HotBar/hotbarInfo.imageset/Contents.json new file mode 100644 index 0000000..e3388fb --- /dev/null +++ b/Ifish/Assets.xcassets/HotBar/hotbarInfo.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "hotbarInfo.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Ifish/Assets.xcassets/HotBar/hotbarInfo.imageset/hotbarInfo.png b/Ifish/Assets.xcassets/HotBar/hotbarInfo.imageset/hotbarInfo.png new file mode 100644 index 0000000..92e5bd7 Binary files /dev/null and b/Ifish/Assets.xcassets/HotBar/hotbarInfo.imageset/hotbarInfo.png differ diff --git a/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishConnectUsViewController.m b/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishConnectUsViewController.m index 6d96119..0369f25 100644 --- a/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishConnectUsViewController.m +++ b/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishConnectUsViewController.m @@ -7,10 +7,11 @@ // #import "IfishConnectUsViewController.h" +#import "InfoByImageViewController.h" -@interface IfishConnectUsViewController () +@interface IfishConnectUsViewController () Strong UIImageView *codeImage;//二维码 -Strong UIButton *telBtn; +Strong UITextView *textView; @end @implementation IfishConnectUsViewController @@ -18,34 +19,110 @@ Strong UIButton *telBtn; - (void)viewDidLoad { [super viewDidLoad]; self.titleString = @"联系我们"; + self.view.backgroundColor=[UIColor whiteColor]; [self.view addSubview:self.codeImage]; - [self.view addSubview:self.telBtn]; + [self.view addSubview:self.textView]; [self.codeImage mas_makeConstraints:^(MASConstraintMaker *make) { - make.top.mas_equalTo(kSizeFrom750(128)); - make.width.mas_equalTo(kSizeFrom750(578)); - make.height.mas_equalTo(kSizeFrom750(770)); + make.bottom.mas_equalTo(self.view.mas_bottom).offset(-34); + make.width.mas_equalTo(kSizeFrom750(300.5)); + make.height.mas_equalTo(kSizeFrom750(400)); make.centerX.mas_equalTo(self.view); }]; - [self.telBtn mas_makeConstraints:^(MASConstraintMaker *make) { - make.width.centerX.mas_equalTo(self.codeImage); - make.top.mas_equalTo(self.codeImage.mas_bottom).offset(kSizeFrom750(70)); - make.height.mas_equalTo(kSizeFrom750(70)); + [self.textView mas_makeConstraints:^(MASConstraintMaker *make) { + make.left.mas_equalTo(self.view.mas_left).offset(10); + make.right.mas_equalTo(self.view.mas_right).offset(-10); + + make.top.mas_equalTo(self.view.mas_top).offset(0); + make.bottom.mas_equalTo(self.codeImage.mas_top); }]; // Do any additional setup after loading the view. } --(UIButton *)telBtn{ - if (!_telBtn) { - _telBtn = InitObject(UIButton); - _telBtn.titleLabel.font = SYSTEMSIZE(34); - [_telBtn setTitle:@"服务热线:18667812003" forState:UIControlStateNormal]; - [_telBtn setTitleColor:[UIColor blackColor] forState:UIControlStateNormal]; - [_telBtn addTarget:self action:@selector(telBtnClick:) forControlEvents:UIControlEventTouchUpInside]; +-(UITextView *)textView{ + if (!_textView) { + _textView = InitObject(UITextView); + + [self protocolIsSelect:YES]; } - return _telBtn; + return _textView; } +- (void)protocolIsSelect:(BOOL)select { + +NSMutableAttributedString *attributedString = [[NSMutableAttributedString alloc] initWithString:@"1、设备绑定不上?查看遥控器或显示屏控制插排是否正常?\na、若不正常考虑设备问题,可与购买方或厂家联系。\nb、若正常先查看手机连接路由器是否为2.4g频率wifi。若连接时提示去更改网络,则此时手机连接一定为5g网络,需更换2.4g网络重新绑定。\n2、换路由器后网络为2.4g频率WIFI,还是无法绑定?\na、若老路由器连接没问题,先用老路由器把设备绑定在线,联系爱鱼奇客服升级。\nb、两台手机开热点方法(暂时不用路由器)先把设备绑定上,设备在线后与爱鱼奇客服联系升级。手机开热点如何连接点击这里。\nc、手机开热点也连接不上,可与购买方或厂家联系。\n3、感谢您使用爱鱼奇app,连接智能设备请查看下方说明书,内含操作视频:http://u.eqxiu.com/s/KmmVl87l,插排及热流器售后服务热线点击这里。\n4、摄像头售后及爱鱼奇服务微信:18667812003"]; + +[attributedString addAttribute:NSLinkAttributeName + +value:@"apmode://" + +range:[[attributedString string] rangeOfString:@"手机开热点如何连接点击这里。"]]; + +[attributedString addAttribute:NSLinkAttributeName + +value:@"http://u.eqxiu.com/s/KmmVl87l" + +range:[[attributedString string] rangeOfString:@"http://u.eqxiu.com/s/KmmVl87l"]]; + [attributedString addAttribute:NSLinkAttributeName + + value:@"hotbar://" + + range:[[attributedString string] rangeOfString:@"插排及热流器售后服务热线点击这里。"]]; + + [attributedString addAttribute:NSFontAttributeName value:[UIFont systemFontOfSize:18] range:NSMakeRange(0, attributedString.length)]; + [attributedString addAttribute:NSFontAttributeName value:[UIFont boldSystemFontOfSize:18] range:[[attributedString string] rangeOfString:@"http://u.eqxiu.com/s/KmmVl87l"]]; + [attributedString addAttribute:NSLinkAttributeName value:@"tel://18667812003" range:[[attributedString string] rangeOfString:@"18667812003"]]; + + + +_textView.attributedText = attributedString; + +_textView.linkTextAttributes = @{NSForegroundColorAttributeName: [UIColor blueColor], + +NSUnderlineColorAttributeName: [UIColor lightGrayColor], + +NSUnderlineStyleAttributeName: @(NSUnderlinePatternSolid)}; + +_textView.delegate=self; + +_textView.editable=NO; + +_textView.scrollEnabled = NO; + +} +- (BOOL)textView:(UITextView *)textView shouldInteractWithURL:(NSURL *)URL inRange:(NSRange)characterRange { + + self.hidesBottomBarWhenPushed=YES; + +if ([[URL scheme] isEqualToString:@"apmode"]) { + + InfoByImageViewController*info=[[InfoByImageViewController alloc]init]; + info.title=@"热点连接方法"; + info.image=[UIImage imageNamed:@"apmodeInfo"]; + [self.navigationController pushViewController:info animated:YES]; + + +return NO; + +} else if ([[URL scheme] isEqualToString:@"hotbar"]) { + + InfoByImageViewController*info=[[InfoByImageViewController alloc]init]; + info.title=@"售后服务热线"; + info.type=@"service"; + info.image=[UIImage imageNamed:@"hotbarInfo"]; + [self.navigationController pushViewController:info animated:YES]; + +return NO; + +} + +return YES; + +} + + + + -(UIImageView *)codeImage { if (!_codeImage) { diff --git a/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishMeViewController.m b/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishMeViewController.m index 0881ad2..c9997f0 100644 --- a/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishMeViewController.m +++ b/Ifish/controllers/IfishTabControllers/我的/mineControllers/IfishMeViewController.m @@ -87,7 +87,7 @@ -(void)getTableData{ - self.tileArr=@[@[@"扫二维码",@"我的看护"],@[@"关于我们",@"设置"],@[@"分享爱鱼奇",@"产品说明书",@"联系爱鱼奇"]]; + self.tileArr=@[@[@"扫二维码",@"我的看护"],@[@"关于我们",@"设置"],@[@"分享爱鱼奇",@"产品说明书",@"联系我们"]]; self.headimgeArr = @[@[@"personal_iocn_scan",@"personal_iocn_care"],@[@"personal_iocn_about",@"personal_iocn_set"],@[@"personal_iocn_share",@"personal_iocn_instructions",@"personal_iocn_feedback"]]; } diff --git a/Ifish/controllers/IfishTabControllers/我的/mineControllers/InfoByImageViewController.h b/Ifish/controllers/IfishTabControllers/我的/mineControllers/InfoByImageViewController.h new file mode 100644 index 0000000..b4a8d97 --- /dev/null +++ b/Ifish/controllers/IfishTabControllers/我的/mineControllers/InfoByImageViewController.h @@ -0,0 +1,19 @@ +// +// InfoByImageViewController.h +// Ifish +// +// Created by 祝发冬 on 2020/6/20. +// Copyright © 2020 lianlian. All rights reserved. +// + +#import "BaseViewController.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface InfoByImageViewController : BaseViewController +@property (nonatomic, strong) UIImageView *imageView; +@property (nonatomic, strong) UIImage *image; +@property (nonatomic, strong) NSString *type; +@end + +NS_ASSUME_NONNULL_END diff --git a/Ifish/controllers/IfishTabControllers/我的/mineControllers/InfoByImageViewController.m b/Ifish/controllers/IfishTabControllers/我的/mineControllers/InfoByImageViewController.m new file mode 100644 index 0000000..4706408 --- /dev/null +++ b/Ifish/controllers/IfishTabControllers/我的/mineControllers/InfoByImageViewController.m @@ -0,0 +1,123 @@ +// +// InfoByImageViewController.m +// Ifish +// +// Created by 祝发冬 on 2020/6/20. +// Copyright © 2020 lianlian. All rights reserved. +// + +#import "InfoByImageViewController.h" + +@interface InfoByImageViewController () + +@end + +@implementation InfoByImageViewController + +- (void)viewDidLoad { + [super viewDidLoad]; + // Do any additional setup after loading the view. + self.imageView=[[UIImageView alloc]initWithFrame:CGRectZero]; + [self.view addSubview:self.imageView]; + [ self.imageView mas_makeConstraints:^(MASConstraintMaker *make) { + make.left.mas_equalTo(0); + make.top.mas_equalTo(0); + make.bottom.mas_equalTo(0); + make.right.mas_equalTo(0); + }]; + if (self.image) + { + self.imageView.image=self.image; + } + if (self.title) + { + self.titleString=self.title; + } + if ([self.type isEqualToString:@"service"]) + { + UIButton*xuanduo=[UIButton buttonWithType:UIButtonTypeSystem]; + [self.view addSubview:xuanduo]; + [xuanduo mas_makeConstraints:^(MASConstraintMaker *make) { + + make.left.mas_equalTo(0); + make.top.mas_equalTo(0); + make.height.mas_equalTo(self.view.frame.size.height/12); + make.right.mas_equalTo(0); + + }]; + xuanduo.tag=1; + xuanduo.backgroundColor=[UIColor clearColor]; + [xuanduo addTarget:self action:@selector(service:) forControlEvents:UIControlEventTouchUpInside]; + + + + + UIButton*reuxin=[UIButton buttonWithType:UIButtonTypeSystem]; + [self.view addSubview:reuxin]; + [reuxin mas_makeConstraints:^(MASConstraintMaker *make) { + + make.left.mas_equalTo(0); + make.top.mas_equalTo(4*self.view.frame.size.height/12-25); + make.height.mas_equalTo(self.view.frame.size.height/12); + make.right.mas_equalTo(0); + + }]; + reuxin.tag=2; + reuxin.backgroundColor=[UIColor clearColor]; + [reuxin addTarget:self action:@selector(service:) forControlEvents:UIControlEventTouchUpInside]; + + + UIButton*songnuo=[UIButton buttonWithType:UIButtonTypeSystem]; + [self.view addSubview:songnuo]; + [songnuo mas_makeConstraints:^(MASConstraintMaker *make) { + + make.left.mas_equalTo(0); + make.top.mas_equalTo(8*self.view.frame.size.height/12-25); + make.height.mas_equalTo(self.view.frame.size.height/12); + make.right.mas_equalTo(0); + + }]; + songnuo.tag=3; + songnuo.backgroundColor=[UIColor clearColor]; + [songnuo addTarget:self action:@selector(service:) forControlEvents:UIControlEventTouchUpInside]; + + } + + +} +-(void)service:(UIButton*)button +{ + NSURL*url; + if (button.tag==1) + { + url=[NSURL URLWithString:@"tel://17321129273"]; + + } + else if (button.tag==2) + { + url=[NSURL URLWithString:@"tel://4000121101"]; + } + else if (button.tag==3) + { + url=[NSURL URLWithString:@"tel://13392205468"]; + } + + + if (@available(iOS 10.0, *)) { + [[UIApplication sharedApplication] openURL:url options:@{} completionHandler:nil]; + }else { + [[UIApplication sharedApplication] openURL:url]; + } + +} +/* +#pragma mark - Navigation + +// In a storyboard-based application, you will often want to do a little preparation before navigation +- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { + // Get the new view controller using [segue destinationViewController]. + // Pass the selected object to the new view controller. +} +*/ + +@end