Commit b9d5e5ed authored by luyueming's avatar luyueming

no message

parent 5af69e26
......@@ -623,9 +623,9 @@
INFOPLIST_FILE = "GMAILab/GMAILab-Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
MODULE_NAME = ExampleApp;
PRODUCT_BUNDLE_IDENTIFIER = com.wanmeizhensuo.ZhengXing.ailab;
PRODUCT_BUNDLE_IDENTIFIER = com.wanmeizhensuo.ZhengXing;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = Wildcard;
PROVISIONING_PROFILE_SPECIFIER = user_dev;
SWIFT_OBJC_BRIDGING_HEADER = "GMAILab/GMAILab_Example-Bridging-Header.h";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 4.0;
......@@ -652,9 +652,9 @@
INFOPLIST_FILE = "GMAILab/GMAILab-Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
MODULE_NAME = ExampleApp;
PRODUCT_BUNDLE_IDENTIFIER = com.wanmeizhensuo.ZhengXing.ailab;
PRODUCT_BUNDLE_IDENTIFIER = com.wanmeizhensuo.ZhengXing;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = Wildcard;
PROVISIONING_PROFILE_SPECIFIER = user_dev;
SWIFT_OBJC_BRIDGING_HEADER = "GMAILab/GMAILab_Example-Bridging-Header.h";
SWIFT_VERSION = 4.0;
TARGETED_DEVICE_FAMILY = "1,2";
......
......@@ -5,7 +5,6 @@
// Created by zhouLiang on 2020/3/9.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
@protocol GMHospitalInfoModel @end
@interface GMHospitalInfoModel : GMObject
......
......@@ -5,7 +5,6 @@
// Created by zhouLiang on 2020/2/20.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
@protocol GMToFaceTabs @end
@interface GMToFaceTabs : GMObject
......
......@@ -7,7 +7,7 @@
//
#import "GMToFaceDoctorListViewModel.h"
#import "GMToFaceNetworking.h"
@interface GMToFaceDoctorListViewModel ()<WMFetchDataModelProtocol> {
NSMutableDictionary *_deduplicationDic;
NSString *_deduplicationKey;
......@@ -25,7 +25,7 @@
- (void)excuteToFaceTabsDoctorsSuccessBlock:(HttpSuccessBlock)successBlock
failBlock:(HttpFailedBlock)failBlock {
[[GMToFaceNetworking shareInstance] excuteToFaceTabsDoctorsTabsId:self.tabId page:self.page SuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceTabsDoctorsTabsId:self.tabId page:self.page SuccessBlock:^(id response) {
GMToFaceTabsDoctorListModel *model = [[GMToFaceTabsDoctorListModel alloc] initWithDictionary:response error:NULL];
if (self.page == 1) {
[self.dataArray removeAllObjects];
......
......@@ -5,7 +5,6 @@
// Created by yefengming on 2020/2/19.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import <GMKit/GMPopupBgView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,10 +7,9 @@
//
#import "GMBasicInfoCardView.h"
#import <WebKit/WebKit.h>
//#import "GMDetailWebViewController.h"
//#import "Gengmei-Swift.h"
//#import "GMCommentPopupView.h"
#import "GMDetailWebViewController.h"
#import "Gengmei-Swift.h"
#import "GMCommentPopupView.h"
#import "GMUserVideoTelephoneLogin.h"
#import "GMVideoWaitingView.h"
#import "GMDoctorInfoPopupView.h"
......@@ -19,10 +18,6 @@
#import "GMToFacePayPrepareModel.h"
#import "GMToFaceOrderViewController.h"
#import "GMToFacePayPopView.h"
#import "RequestHeader.h"
#import <GMBase/GMBaseTool.h>
#import <GMBaseWeb/GMBaseWeb-Swift.h>
#import <GMBaseWeb/GMWebutil.h>
#define counsellorAllHeight (573 + UIView.safeAreaInsetsBottom)
#define counsellorHalfHeight (366 + UIView.safeAreaInsetsBottom)
......@@ -59,13 +54,6 @@
[self containerRectCorner:self.container];
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
+ (void)showWithCorrectFrameView:(GMBasicInfoCardView *)cardView resultBlock:(nonnull void (^)(void))resultBlock {
[GMNetworking requestOCWithApi:API_CONSULTATION__COUNSEL_CUSTOMER method:GMHTTPMethodGet parameters:@{@"counsellor_id": SafeString(cardView.counsellorId), @"doctor_id": SafeString(cardView.doctorId)} completion:^(GMResponseOC * response) {
if (response.isSuccess) {
......@@ -75,10 +63,10 @@
cardView.type = [dic[@"counsellor_type"] integerValue];
}
[cardView updateConstraintsWithHasRecord:hasRecord];
[[GMBaseTool getCurrentViewController].view addSubview:cardView];
[AppDelegate.visibleController.view addSubview:cardView];
} else {
[cardView updateConstraintsWithHasRecord:NO];
[[GMBaseTool getCurrentViewController].view addSubview:cardView];
[AppDelegate.visibleController.view addSubview:cardView];
}
if (resultBlock) {
resultBlock();
......@@ -118,14 +106,14 @@
- (void)setDoctorId:(NSString *)doctorId {
_doctorId = doctorId;
self.webCompent.fullUrl = [NSString stringWithFormat:@"%@/phantom/treatment/user/typing_info_v4/%@?counsellor_id=%@&record_type=1",[GMWebutil getCurrentApiHost], SafeString(doctorId), SafeString(self.counsellorId)];
self.webCompent.fullUrl = [NSString stringWithFormat:@"%@/phantom/treatment/user/typing_info_v4/%@?counsellor_id=%@&record_type=1",GMServerDomains.apiHost, SafeString(doctorId), SafeString(self.counsellorId)];
[self.webCompent webviewLoad:self];
}
- (void)setIsDispatch:(BOOL)isDispatch {
_isDispatch = isDispatch;
if (self.isDispatch) {
self.webCompent.fullUrl = [NSString stringWithFormat:@"%@/phantom/treatment/user/typing_info_v4?record_type=2",[GMWebutil getCurrentApiHost]];
self.webCompent.fullUrl = [NSString stringWithFormat:@"%@/phantom/treatment/user/typing_info_v4?record_type=2",GMServerDomains.apiHost];
[self.webCompent webviewLoad:self];
}
}
......@@ -147,9 +135,9 @@
GMDoctorInfoPopupView *popupView = [[GMDoctorInfoPopupView alloc] init];
popupView.tabName = @"医生推荐";
popupView.model = model;
[[GMBaseTool getCurrentViewController].view addSubview:popupView];
[AppDelegate.visibleController.view addSubview:popupView];
} else {
[[GMBaseTool getCurrentViewController] toast:response.message];
[AppDelegate.visibleController toast:response.message];
}
}];
}
......@@ -169,9 +157,9 @@
-(void)globalDataLoaded:(NSDictionary *)data {
int consultation_type = [data[@"consultation_type"] intValue];
int counsellor_type = [data[@"counsellor_type"] intValue];
NSDictionary *dict = @{@"page_name":[GMBaseTool getCurrentViewController].pageName,
NSDictionary *dict = @{@"page_name":AppDelegate.visibleController.pageName,
@"popup_name":@"basic_info",
@"referrer_link":[GMBaseTool getCurrentViewController].referrerLink ? : @[],
@"referrer_link":AppDelegate.visibleController.referrerLink ? : @[],
@"consultation_type":@(consultation_type),
@"counsellor_type":@(counsellor_type),
@"tab_name":SafeString(self.tabName),
......@@ -264,7 +252,7 @@
popView.CloseView = ^{
[weakSelf hide];
};
[[GMBaseTool mainWindow] addSubview:popView];
[[AppDelegate shareInstance].window addSubview:popView];
//进到付款页面先隐藏view,等到付款成功的回调来了之后再显示
self.alpha = 0.f;
}else {
......@@ -277,7 +265,7 @@
//支付成功发起面诊
[weakSelf videoDiagnose];
};
[[GMBaseTool getCurrentViewController] pushViewController:controller animated:YES completion:nil];
[AppDelegate.visibleController pushViewController:controller animated:YES completion:nil];
}
}
- (BOOL)showAlertIfNotAllowed {
......@@ -293,13 +281,12 @@
[alert addAction:[UIAlertAction actionWithTitle:otherButton style:UIAlertActionStyleDefault handler:^(UIAlertAction *action) {
[GMLocationManager jumpToSettings];
}]];
[[GMBaseTool getCurrentViewController] presentViewController:alert animated:YES completion:NULL];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:NULL];
return YES;
}
return NO;
}
- (void)cancelDispatch {
[GMNetworking requestOCWithApi:API_CONSULTATION_CANCEL_DISPATCH method:GMHTTPMethodPost parameters:nil completion:^(GMResponseOC * _Nonnull response) {
......@@ -327,7 +314,7 @@
[weakSelf hide];
});
} else {
[[GMBaseTool getCurrentViewController] toast:response.message];
[AppDelegate.visibleController toast:response.message];
}
}];
}
......@@ -389,7 +376,7 @@
}
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
}]];
[[GMBaseTool getCurrentViewController] presentViewController:alert animated:YES completion:nil];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:nil];
}
- (void)showCameraAlert {
......@@ -404,7 +391,7 @@
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
}]];
[[GMBaseTool getCurrentViewController] presentViewController:alert animated:YES completion:nil];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:nil];
}
#pragma mark - 权限获取埋点(只有两个权限全部为点同一状态才算YES,并且必须两个都音视频都授权才进行埋点)
- (void)audioAndVideoJurisdiction:(BOOL)isOpen {
......@@ -439,7 +426,7 @@
};
}
if (!_waitingView.superview) {
[[GMBaseTool getCurrentViewController].view addSubview:_waitingView];
[AppDelegate.visibleController.view addSubview:_waitingView];
[_waitingView mas_makeConstraints:^(MASConstraintMaker *make) {
make.edges.mas_equalTo(0);
}];
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMConsultantInfoModel.h"
#import "GMLibraryHeader.h"
@protocol GMDoctorInfoPopupViewDelegate <NSObject>
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import <GMKit/GMView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,9 +7,7 @@
//
#import "GMToFaceDoctorBlockInfoView.h"
#import "GMLibraryHeader.h"
//#import "UIView+GMGradient.h"
#import "UIView+GMGradient.h"
@interface GMToFaceDoctorBlockInfoView ()
@property (nonatomic, strong) GMLabel *titleLabel;
@end
......@@ -32,10 +30,9 @@
make.height.mas_equalTo(46);
}];
//渐变色
[self setGradientBackgroundWithColors:@[RGBCOLOR_HEX(0xFF7096),RGBCOLOR_HEX(0xFF5963)] locations:nil startPoint:CGPointMake(0, 0) endPoint:CGPointMake(1, 0)];
[self setGradientBackgroundWithColors:@[GMColorFF7096,GMColorFF5963] locations:nil startPoint:CGPointMake(0, 0) endPoint:CGPointMake(1, 0)];
self.alpha = 0.7;
}
- (void)setBlockInfo:(NSString *)blockInfo {
self.titleLabel.text = SafeString(blockInfo);
self.hidden = ![SafeString(blockInfo) isNonEmpty];
......
......@@ -5,7 +5,7 @@
// Created by Jessica on 2020/3/28.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMLibraryHeader.h"
NS_ASSUME_NONNULL_BEGIN
@interface GMToFaceDoctorListHeaderFlowLayout : UICollectionViewFlowLayout
......
......@@ -10,10 +10,7 @@
#import "GMBasicInfoCardView.h"
#import "GMDoctorInfoPopupView.h"
#import "GMConsultantInfoModel.h"
#import "GMToFaceNetworking.h"
#import "GMLibraryHeader.h"
#import "RequestHeader.h"
#import <GMBase/GMBaseTool.h>
@interface GMToFaceDoctorListHorNewCell ()<GMDoctorInfoPopupViewDelegate>
/** 形象照 */
@property (nonatomic, strong) UIImageView *personalIcon;
......@@ -117,15 +114,15 @@
NSRange range = [str rangeOfString:@"/"];
[attribute addAttributes:@{NSFontAttributeName: [UIFont gmBoldFont:10]} range:NSMakeRange(range.location, str.length - range.location)];
[attribute addAttributes:@{NSFontAttributeName: [UIFont gmBoldFont:12]} range:NSMakeRange(0, 1)];
[attribute addAttributes:@{NSForegroundColorAttributeName: RGBCOLOR_HEX(0xFFFFFF) } range:NSMakeRange(range.location, str.length - range.location)];
[attribute addAttributes:@{NSForegroundColorAttributeName: ALColorFFFFFF} range:NSMakeRange(range.location, str.length - range.location)];
self.priceLabel.attributedText = attribute;
}
self.exposure = doctorsModel.exposure;
}
- (void)clickUserIconMethod {
[GMBaseTool getCurrentViewController].tabName = @"医生推荐";
[Phobos track:@"on_click_card" attributes:@{ @"page_name":[GMBaseTool getCurrentViewController].pageName,
AppDelegate.visibleController.tabName = @"医生推荐";
[Phobos track:@"on_click_card" attributes:@{ @"page_name":AppDelegate.visibleController.pageName,
@"tab_name":@"医生推荐",
@"position":@(self.indexPath.item),
@"card_id":SafeString(self.doctorsModel.counsellorId),
......@@ -141,8 +138,8 @@
}];
}
- (void)clickBottomBtnMethod {
[GMBaseTool getCurrentViewController].tabName = @"医生推荐";
[Phobos track:@"on_click_card" attributes:@{ @"page_name":[GMBaseTool getCurrentViewController].pageName,
AppDelegate.visibleController.tabName = @"医生推荐";
[Phobos track:@"on_click_card" attributes:@{ @"page_name":AppDelegate.visibleController.pageName,
@"tab_name":@"医生推荐",
@"position":@(self.indexPath.item),
@"card_id":SafeString(self.doctorsModel.counsellorId),
......@@ -160,13 +157,13 @@
- (void)counsellorFillInfoView {
//填写信息卡片
__weak __typeof(self)weakSelf = self;
[[GMToFaceNetworking shareInstance] excuteToFaceBlockInfoSuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceBlockInfoSuccessBlock:^(id response) {
NSDictionary *dict = response[@"block_info"];
NSString *alert = dict[@"alert"];
if (![alert isNonEmpty]) {
//请求用户填面诊信息的弹框
GMBasicInfoCardView *cardView = [GMBasicInfoCardView new];
cardView.referer = [GMBaseTool getCurrentViewController].pageName;
cardView.referer = AppDelegate.visibleController.pageName;
cardView.counsellorId = weakSelf.doctorsModel.counsellorId;
cardView.doctorId = weakSelf.doctorsModel.doctorId;
cardView.tabName = @"医生推荐";
......@@ -200,10 +197,10 @@
};
popupView.delegate = weakSelf;
popupView.model = model;
[[GMBaseTool getCurrentViewController].view addSubview:popupView];
[AppDelegate.visibleController.view addSubview:popupView];
weakSelf.personalIcon.userInteractionEnabled = YES;
} else {
[[GMBaseTool getCurrentViewController] toast:response.message];
[AppDelegate.visibleController toast:response.message];
weakSelf.personalIcon.userInteractionEnabled = YES;
}
}];
......@@ -211,7 +208,7 @@
#pragma mark - 医生头像
- (void)docIconClickMethod {
[GMBaseTool getCurrentViewController].tabName = @"医生推荐";
AppDelegate.visibleController.tabName = @"医生推荐";
self.personalIcon.userInteractionEnabled = NO;
// 若该医生为在线可面诊状态,则拉起基本信息卡,若为面诊中/不在线状态,跳转医生详情页/或者弹出面诊师卡片
if ( self.doctorsModel.status == 2) { // 在线状态
......@@ -295,7 +292,7 @@
}
- (GMLabel *)priceLabel {
if (!_priceLabel) {
_priceLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0xFF8C8D) fontSize:16];
_priceLabel = [GMLabel labelWithTextColor:GMColorFF8C8D fontSize:16];
_priceLabel.font = [UIFont gmBoldFont:16];
}
return _priceLabel;
......
......@@ -7,8 +7,6 @@
//
#import "GMToFaceDoctorListModel.h"
#import <GMKit/GMView.h>
NS_ASSUME_NONNULL_BEGIN
@interface GMToFaceDoctorListNewHeaderView : GMView
......
......@@ -9,7 +9,7 @@
#import "GMToFaceDoctorListNewHeaderView.h"
#import "GMToFaceDoctorListHeaderFlowLayout.h"
#import "GMToFaceDoctorListHorNewCell.h"
#import "GMTelephoneProxy.h"
#import "GMWeakProxy.h"
#import "GMFaceListPageControl.h"
#define MaxCount 500
......@@ -30,7 +30,7 @@
}
- (void)setUI {
self.backgroundColor = RGBCOLOR_HEX(0xF7F6FA);
self.backgroundColor = GMColorF7F6FA;
[self addSubview:self.collectView];
[self addSubview:self.pageControl];
......@@ -81,7 +81,7 @@
}
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
// GMToFaceRecommendsDoctors *model = self.dataArray[indexPath.row];
// [GMBaseTool getCurrentViewController].tabName = @"医生推荐";
// AppDelegate.visibleController.tabName = @"医生推荐";
// //跳到医生主页
// [[GMRouter sharedInstance] pushScheme:model.gm_url];
}
......@@ -114,7 +114,7 @@
[self invalidateTimer];
}
self.timer = [NSTimer timerWithTimeInterval:10 target:[GMTelephoneProxy proxyWithTarget:self] selector:@selector(nextPage) userInfo:nil repeats:YES];
self.timer = [NSTimer timerWithTimeInterval:10 target:[GMWeakProxy proxyWithTarget:self] selector:@selector(nextPage) userInfo:nil repeats:YES];
[[NSRunLoop mainRunLoop] addTimer:self.timer forMode:NSDefaultRunLoopMode];
}
......@@ -161,7 +161,7 @@
if (!_collectView) {
_collectView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:self.layout];
_collectView.showsHorizontalScrollIndicator = NO;
_collectView.backgroundColor = RGBCOLOR_HEX(0xF7F6FA);
_collectView.backgroundColor = GMColorF7F6FA;
_collectView.decelerationRate = UIScrollViewDecelerationRateFast;
_collectView.delegate = self;
_collectView.dataSource = self;
......@@ -173,8 +173,8 @@
if (!_pageControl) {
_pageControl = [[GMFaceListPageControl alloc] init];
_pageControl.numberOfPages = 0;
_pageControl.tintColor = RGBCOLOR_HEX(0xD8D8D8);
_pageControl.currentTintColor = RGBCOLOR_HEX(0x7DC6CC);
_pageControl.tintColor = GMColorD8D8D8;
_pageControl.currentTintColor = GMColor7DC6CC;
}
return _pageControl;
}
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMToFaceDoctorListViewModel.h"
#import "GMLibraryHeader.h"
@interface GMToFaceDoctorInfoView : GMView
- (void)showWithLikeRate:(NSString *)likeRate connectRate:(NSString *)connectRate consultPeopleNumber:(NSString *)consultPeopleNumber showType:(NSInteger)showType;
......
......@@ -7,7 +7,6 @@
//
#import "GMToFaceDoctorListVerCell.h"
@interface GMToFaceDoctorInfoView()
/** 好评率 */
@property (nonatomic, copy) NSString *likeRate;
......@@ -108,7 +107,7 @@
_icon.image = [UIImage imageNamed:@"to_face_like_rate"];
_label.text = [NSString stringWithFormat:@"好评%@", likeRate];
_icon1.backgroundColor = RGBCOLOR_HEX(0x44D7B6);
_icon1.backgroundColor = GMColor44D7B6;
_icon1.layer.cornerRadius = 2;
_icon1.layer.masksToBounds = YES;
_icon1.image = [UIImage imageNamed:@""];
......@@ -141,7 +140,7 @@
if (connectRate.isNonEmpty) {
[self addSubview:self.icon1];
[self addSubview:self.label1];
_icon1.backgroundColor = RGBCOLOR_HEX(0x44D7B6);
_icon1.backgroundColor = GMColor44D7B6;
_icon1.layer.cornerRadius = 2;
_icon1.layer.masksToBounds = YES;
_icon1.image = [UIImage imageNamed:@""];
......@@ -332,7 +331,7 @@
NSRange range = [str rangeOfString:@"/"];
range = NSMakeRange(range.location, str.length - range.location);
NSMutableAttributedString *attribute = [[NSMutableAttributedString alloc] initWithString:str];
[attribute addAttributes:@{NSForegroundColorAttributeName : RGBCOLOR_HEX(0x8E8E8E) } range:range];
[attribute addAttributes:@{NSForegroundColorAttributeName : ALColor8E8E8E} range:range];
[attribute addAttributes:@{NSFontAttributeName : [UIFont gmFont:12]} range:range];
self.priceLabel.attributedText = attribute;
}
......@@ -362,9 +361,9 @@
#pragma mark - 医生身份
- (void)doctorIdentity {
if (self.doctorsModel.type == 1) { // 医生
_docTitleView.layer.borderColor = RGBCOLOR_HEX(0x65B4FF).CGColor;
_docTitleView.layer.borderColor = GMColor65B4FF.CGColor;
} else if (self.doctorsModel.type == 2) {
_docTitleView.layer.borderColor = RGBCOLOR_HEX(0x51CDC7).CGColor;
_docTitleView.layer.borderColor = GMColor51CDC7.CGColor;
}
[self.docTitleView.subviews enumerateObjectsUsingBlock:^(__kindof UIView * _Nonnull obj, NSUInteger idx, BOOL * _Nonnull stop) {
if (idx == 0) {
......@@ -378,9 +377,9 @@
GMLabel *label = (GMLabel *)obj;
label.text = SafeString(self.doctorsModel.title);
if (self.doctorsModel.type == 1) { // 医生
label.textColor = RGBCOLOR_HEX(0x65B4FF);
label.textColor = GMColor65B4FF;
}else if (self.doctorsModel.type == 2) { // 面诊师
label.textColor = RGBCOLOR_HEX(0x51CDC7);
label.textColor = GMColor51CDC7;
}
}
}];
......@@ -424,7 +423,7 @@
_docTitleView = [[UIView alloc] init];
_docTitleView.layer.cornerRadius = 7.5f;
_docTitleView.layer.masksToBounds = YES;
_docTitleView.layer.borderColor = RGBCOLOR_HEX(0x65B4FF).CGColor;
_docTitleView.layer.borderColor = GMColor65B4FF.CGColor;
_docTitleView.layer.borderWidth = ONE_PIXEL;
UIImageView *corView = [[UIImageView alloc] init];
corView.layer.cornerRadius = 7.5f;
......@@ -435,7 +434,7 @@
make.size.mas_equalTo(CGSizeMake(15, 15));
make.centerY.mas_equalTo(0);
}];
GMLabel *label = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x65B4FF) fontSize:10];
GMLabel *label = [GMLabel labelWithTextColor:GMColor65B4FF fontSize:10];
[_docTitleView addSubview:label];
[label mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.mas_equalTo(0);
......@@ -455,7 +454,7 @@
- (GMLabel *)docNameLabel {
if (!_docNameLabel) {
_docNameLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:14];
_docNameLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:14];
_docNameLabel.font = [UIFont gmFont:14];
}
return _docNameLabel;
......@@ -463,7 +462,7 @@
- (GMLabel *)docWorkTimeLabel {
if (!_docWorkTimeLabel) {
_docWorkTimeLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x8E8E8E) fontSize:12];
_docWorkTimeLabel = [GMLabel labelWithTextColor:ALColor8E8E8E fontSize:12];
}
return _docWorkTimeLabel;
}
......@@ -478,7 +477,7 @@
make.left.mas_equalTo(0);
make.centerY.equalTo(_positionView.mas_centerY);
}];
GMLabel *label = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x8E8E8E) fontSize:10];
GMLabel *label = [GMLabel labelWithTextColor:ALColor8E8E8E fontSize:10];
[_positionView addSubview:label];
[label mas_makeConstraints:^(MASConstraintMaker *make) {
make.left.equalTo(icon.mas_right).offset(2);
......@@ -489,7 +488,7 @@
}
- (GMLabel *)goodAtLabel {
if (!_goodAtLabel) {
_goodAtLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:12];
_goodAtLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:12];
_goodAtLabel.font = [UIFont gmFont:12];
_goodAtLabel.numberOfLines = 2;
}
......@@ -497,7 +496,7 @@
}
- (GMLabel *)priceLabel {
if (!_priceLabel) {
_priceLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0xFF8C8D) fontSize:16];
_priceLabel = [GMLabel labelWithTextColor:GMColorFF8C8D fontSize:16];
_priceLabel.font = [UIFont gmBoldFont:16];
}
return _priceLabel;
......
......@@ -6,11 +6,11 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMFacePagingViewController.h"
#import "GMPagingViewController.h"
#import "GMToFaceDoctorListViewModel.h"
NS_ASSUME_NONNULL_BEGIN
@interface GMToFaceContainerViewController : GMFacePagingViewController
@interface GMToFaceContainerViewController : GMPagingViewController
@property (nonatomic, strong) GMToFaceDoctorListViewModel *viewModel;
@end
......
......@@ -15,9 +15,6 @@
#import "GMToFaceDoctorBlockInfoView.h"
#import "GMBasicInfoCardView.h"
#import "GMToFaceDoctorListNewHeaderView.h"
#import "GMToFaceNetworking.h"
#import "GMLibraryHeader.h"
#import "UIResponder+transmission.h"
@interface GMToFaceContainerViewController ()<GMInfinitelViewDelegate, UIScrollViewDelegate>
/** 头部视图 */
......@@ -76,7 +73,7 @@
self.navigationBar.isShowShadow = NO;
self.fd_interactivePopDisabled = YES;
self.navigationBar.title = @"更美视频面诊";
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(updateDoctorListMethod) name:@"login_success_notification" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(updateDoctorListMethod) name:LOGIN_SUCCESS_NOTIFICATION object:nil];
}
- (void)backAction:(OCNavigationBarButton *)button {
......@@ -98,13 +95,13 @@
}
- (void)reSetSegmentView {
self.segmentView.isShowShadow = NO;
self.segmentView.backgroundColor = RGBCOLOR_HEX(0xF7F6FA);
self.segmentView.indicatorColor = RGBCOLOR_HEX(0xFF8C8D);
self.segmentView.backgroundColor = GMColorF7F6FA;
self.segmentView.indicatorColor = GMColorFF8C8D;
self.segmentView.height = 74.f;
self.segmentView.titleTextAttributes = @{NSFontAttributeName:[UIFont gmBoldFont:15],
NSForegroundColorAttributeName:RGBCOLOR_HEX(0x696969)};
NSForegroundColorAttributeName:GMColor696969};
self.segmentView.selectedTitleTextAttributes = @{NSFontAttributeName:[UIFont gmBoldFont:16],
NSForegroundColorAttributeName:RGBCOLOR_HEX(0x2A2828)};
NSForegroundColorAttributeName:GMColor2A2828};
}
- (void)setupChildViews {
CGFloat height = self.recommendDoctorListModel.recommendsCounsellors.count > 0 ? [GMToFaceDoctorListNewHeaderView viewHeight] : 0;
......@@ -124,7 +121,7 @@
[self showLoading:nil];
}
__weak typeof(self)weakSelf = self;
[[GMToFaceNetworking shareInstance] excuteToFaceRecommendDoctorsSuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceRecommendDoctorsSuccessBlock:^(id response) {
NSError *error = [[NSError alloc] init];
weakSelf.recommendDoctorListModel = [[GMToFaceDoctorListModel alloc] initWithDictionary:response error:&error];
[weakSelf loadHome];
......@@ -253,7 +250,7 @@
- (void)bottomBtnClick {
[Phobos track:@"on_click_button" attributes:@{@"page_name":self.pageName,@"button_name":@"video_interview_now"}];
__weak __typeof(self)weakSelf = self;
[[GMToFaceNetworking shareInstance] excuteToFaceBlockInfoSuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceBlockInfoSuccessBlock:^(id response) {
NSDictionary *dict = response[@"block_info"];
NSString *alert = dict[@"alert"];
if (![alert isNonEmpty]) {
......
......@@ -8,14 +8,12 @@
#import "JXPagerView.h"
#import "GMToFaceDoctorListViewModel.h"
@import GMBase;
@interface GMToFaceDoctorListController : WMBaseViewController<JXPagerViewListViewDelegate>
@property (nonatomic, strong) GMToFaceDoctorListViewModel * _Nullable viewModel;
@property (nonatomic, strong) GMToFaceDoctorListViewModel *viewModel;
@property (nonatomic, assign) CGFloat topViewHeight;
@property (nonatomic, copy, nullable) void(^scrollCallback)(UIScrollView * _Nullable scrollView);
@property (nonatomic, copy, nullable) void(^scrollCallback)(UIScrollView *scrollView);
/** 获取封禁信息的回调 */
@property (nonatomic, copy, nullable) void(^blockInfoCallback)(NSString * _Nullable blockInfo);
@property (nonatomic, copy, nullable) void(^blockInfoCallback)(NSString *blockInfo);
- (void)requestData;
@end
......@@ -8,22 +8,17 @@
#import "GMToFaceDoctorListController.h"
#import "GMToFaceDoctorListVerCell.h"
#import <GMRefreshFooter.h>
#import "GMToFaceDoctorListModel.h"
#import "GMToFaceCommonEmptyView.h"
#import "GMCommonEmptyView.h"
#import "GMBasicInfoCardView.h"
#import "UIView+GMGradient.h"
#import "GMDoctorInfoPopupView.h"
#import "RequestHeader.h"
#import "GMToFaceNetworking.h"
#import "GMLibraryHeader.h"
#import <GMBase/GMBaseTool.h>
@interface GMToFaceDoctorListController ()<UICollectionViewDelegate, UICollectionViewDataSource, GMToFaceCommonEmptyViewDelegate>
@interface GMToFaceDoctorListController ()<UICollectionViewDelegate, UICollectionViewDataSource, GMCommonEmptyViewDelegate>
@property (nonatomic, strong) UICollectionViewFlowLayout *layout;
@property (nonatomic, strong) UICollectionView *collectView;
@property (nonatomic, strong) NSIndexPath *indexPath;
@property (nonatomic, strong) GMToFaceCommonEmptyView *commonEmptyView;
@property (nonatomic, strong) GMCommonEmptyView *commonEmptyView;
@end
@implementation GMToFaceDoctorListController
......@@ -61,20 +56,20 @@
}
- (void)requestData {
if (self.viewModel.page == 1) {
[[GMBaseTool getCurrentViewController] showLoading:nil];
[AppDelegate.visibleController showLoading:nil];
}
self.commonEmptyView.hidden = YES;
[self.viewModel excuteToFaceTabsDoctorsSuccessBlock:^(id responseObject) {
[[GMBaseTool getCurrentViewController] hideLoading];
[AppDelegate.visibleController hideLoading];
if (self.viewModel.dataArray.count == 0) {
self.commonEmptyView.type = GMToFaceCommonEmptyViewTypeEmpty;
self.commonEmptyView.type = GMCommonEmptyViewTypeEmpty;
}
[self.collectView.mj_footer endRefreshing];
[self.collectView reloadData];
} failBlock:^(NSString *message) {
[[GMBaseTool getCurrentViewController] hideLoading];
[AppDelegate.visibleController hideLoading];
[self.collectView.mj_footer endRefreshing];
self.commonEmptyView.type = GMToFaceCommonEmptyViewTypeError;
self.commonEmptyView.type = GMCommonEmptyViewTypeError;
}];
}
- (void)emptyViewDidClickReload {
......@@ -124,13 +119,11 @@
@"transaction_type":@"-1",
@"counsellor_type":@(model.type)
}];
[GMBaseTool getCurrentViewController].tabName = SafeString(self.viewModel.tabName);
AppDelegate.visibleController.tabName = SafeString(self.viewModel.tabName);
}
- (void)counsellorFillInfoView:(GMToFaceRecommendsDoctors *)model indexPath:(NSIndexPath *)indexPath{
BOOL status = (BOOL)[[GMRouter sharedInstance] pushScheme:@"gengmei://gm_showLoginViewIfNeeded"];
if (status) {
if ([[GMLoginManager shareInstance] showLoginViewIfNeeded]) {
return;
}
if (self.indexPath == indexPath) {//目的是防止重复点击
......@@ -139,7 +132,7 @@
self.collectView.userInteractionEnabled = NO;
self.indexPath = indexPath;
__weak __typeof(self)weakSelf = self;
[[GMToFaceNetworking shareInstance] excuteToFaceBlockInfoSuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceBlockInfoSuccessBlock:^(id response) {
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1.0 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
weakSelf.indexPath = nil;
});
......@@ -186,9 +179,9 @@
}
};
popupView.model = model;
[[GMBaseTool getCurrentViewController].view addSubview:popupView];
[AppDelegate.visibleController.view addSubview:popupView];
} else {
[[GMBaseTool getCurrentViewController] toast:response.message];
[AppDelegate.visibleController toast:response.message];
}
weakSelf.collectView.userInteractionEnabled = YES;
}];
......@@ -222,8 +215,8 @@
- (UICollectionView *)collectView {
if (!_collectView) {
_collectView = [[UICollectionView alloc] initWithFrame:self.view.bounds collectionViewLayout:self.layout];
// [_collectView setGradientBackgroundWithColors:@[RGBCOLOR_HEX(0xFFFFFF) ,GMColorF7F6FA] locations:nil startPoint:CGPointMake(0, 0) endPoint:CGPointMake(0, 0.1)];
_collectView.backgroundColor = RGBCOLOR_HEX(0xF7F6FA);
// [_collectView setGradientBackgroundWithColors:@[ALColorFFFFFF,GMColorF7F6FA] locations:nil startPoint:CGPointMake(0, 0) endPoint:CGPointMake(0, 0.1)];
_collectView.backgroundColor = GMColorF7F6FA;
_collectView.delegate = self;
_collectView.dataSource = self;
_collectView.showsVerticalScrollIndicator = NO;
......@@ -231,9 +224,9 @@
}
return _collectView;
}
- (GMToFaceCommonEmptyView *)commonEmptyView {
- (GMCommonEmptyView *)commonEmptyView {
if (!_commonEmptyView) {
_commonEmptyView = [[GMToFaceCommonEmptyView alloc] init];
_commonEmptyView = [[GMCommonEmptyView alloc] init];
_commonEmptyView.delegate = self;
_commonEmptyView.hidden = YES;
}
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
@interface GMPayResultModel : GMObject
......
......@@ -7,7 +7,6 @@
//
@import GMBase;
@interface GMToFaceOrderInfoModel : GMObject
......
......@@ -5,8 +5,6 @@
// Created by zhouLiang on 2020/4/8.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
@protocol GMToFacePayCounsellorInfoModel @end
@interface GMToFacePayCounsellorInfoModel : GMObject
@property (nonatomic, copy) NSString *id;
......
......@@ -7,7 +7,6 @@
//
#import "GMPayTypeView.h"
#import "GMLibraryHeader.h"
@interface GMPayTypeView ()
@property (strong, nonatomic) UIImageView *payWayImage;
......@@ -33,7 +32,7 @@
[self.payWayImage sd_setImageWithURL:[NSURL URLWithString:typeModel.icon]];
self.payDesc.text = typeModel.desc;
self.payName.text = typeModel.title;
self.payDesc.textColor = typeModel.recommend?RGBCOLOR_HEX(0xFF5963):RGBCOLOR_HEX(0x999999);
self.payDesc.textColor = typeModel.recommend?GMColorFF5963:GMColor999999;
self.recommendIcon.hidden = !typeModel.recommend;
}
- (void)setIsSelected:(BOOL)isSelected {
......@@ -83,14 +82,14 @@
}
- (GMLabel *)payName {
if (!_payName) {
_payName = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:14];
_payName = [GMLabel labelWithTextColor:GMColor282828 fontSize:14];
_payName.text = @"支付宝支付";
}
return _payName;
}
- (GMLabel *)payDesc {
if (!_payDesc) {
_payDesc = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0xFF5963) fontSize:12];
_payDesc = [GMLabel labelWithTextColor:GMColorFF5963 fontSize:12];
_payDesc.text = @"推荐使用支付宝支付";
}
return _payDesc;
......
......@@ -7,8 +7,6 @@
//
#import "GMToFaceOrderInfoModel.h"
#import "GMLibraryHeader.h"
@interface GMSureOrderPopView : GMPopupBgView
/// 面诊 ID
......
......@@ -9,9 +9,6 @@
#import "GMSureOrderPopView.h"
#import "GMEndConsultView.h"
#import "GMStarWithContentObject.h"
#import "GMToFaceNetworking.h"
#import <GMBase/GMBaseTool.h>
@interface GMSureOrderPopView ()
@property (nonatomic, strong) GMLabel *topLabel;
......@@ -136,13 +133,6 @@
});
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
- (void)setInfoModel:(GMToFaceOrderInfoModel *)infoModel {
_infoModel = infoModel;
self.titleLabel.text = infoModel.counsellorType == 1 ? @"面诊医生 | ":@"面诊师 | ";
......@@ -159,14 +149,14 @@
NSRange priceRange = [priceStr rangeOfString:@"¥"];
priceRange = NSMakeRange(priceRange.location, priceStr.length - priceRange.location);
NSMutableAttributedString *priceAttribute = [[NSMutableAttributedString alloc] initWithString:priceStr];
[priceAttribute addAttributes:@{NSForegroundColorAttributeName : RGBCOLOR_HEX(0xFF8C8D)} range:priceRange];
[priceAttribute addAttributes:@{NSForegroundColorAttributeName : GMColorFF8C8D} range:priceRange];
self.priceLabel.attributedText = priceAttribute;
NSString *payStr = self.payLabel.text;
NSRange payRange = [payStr rangeOfString:@"¥"];
payRange = NSMakeRange(payRange.location, payStr.length - payRange.location);
NSMutableAttributedString *payAttribute = [[NSMutableAttributedString alloc] initWithString:payStr];
[payAttribute addAttributes:@{NSForegroundColorAttributeName : RGBCOLOR_HEX(0xFF8C8D)} range:payRange];
[payAttribute addAttributes:@{NSForegroundColorAttributeName : GMColorFF8C8D} range:payRange];
self.payLabel.attributedText = payAttribute;
}
#pragma mark - 确认订单弹框
......@@ -176,11 +166,11 @@
if (self.isSureOrder) {
[self starMethod];
}else {
[[GMToFaceNetworking shareInstance] excuteToFaceSureOrder:self.infoModel.orderNo SuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceSureOrder:self.infoModel.orderNo SuccessBlock:^(id response) {
self.isSureOrder = YES;
[self starMethod];
} failureBlock:^(NSInteger errorCode, NSString *message) {
[[GMBaseTool getCurrentViewController] toast:message];
[AppDelegate.visibleController toast:message];
[self hide];
}];
}
......@@ -204,7 +194,7 @@
};
view.recordId = self.infoModel.consultationRecordId;
view.complaintType = GMComplaintTypeDoctor;
[[GMBaseTool getCurrentViewController].view addSubview:view];
[AppDelegate.navigation.view addSubview:view];
}
- (void)clickConfireBtnPhobo:(NSInteger)counsellorType consultationType:(NSInteger)consultationType doctorId:(NSString *)doctorId {
_counsellorType = counsellorType;
......@@ -226,7 +216,7 @@
- (void)starMethod {
//是面诊师直接弹评价弹框
__weak typeof(self) weakSelf = self;
[[GMToFaceNetworking shareInstance] excuteToFaceEvaluateItemDiagnosis_id:self.infoModel.consultationRecordId SuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceEvaluateItemDiagnosis_id:self.infoModel.consultationRecordId SuccessBlock:^(id response) {
GMStarWithContentObject *starContentModel = [[GMStarWithContentObject alloc] initWithDictionary:response error:nil];
GMEndConsultView *view = [[GMEndConsultView alloc] initWithType:(GMEndConsultViewTypeGrayStar) starNum:0];
[weakSelf hide];
......@@ -249,7 +239,7 @@
view.showComplaint = NO;
view.recordId = self.infoModel.consultationRecordId;
view.starContentArray = starContentModel.evaluates;
[[GMBaseTool getCurrentViewController].view addSubview:view];
[AppDelegate.navigation.view addSubview:view];
} failureBlock:^(NSInteger errorCode, NSString *message) {
[self hide];
}];
......@@ -262,7 +252,7 @@
}
- (GMLabel *)topLabel {
if (!_topLabel) {
_topLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
_topLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:16];
_topLabel.font = [UIFont gmBoldFont:16];
_topLabel.text = @"请确认视频面诊信息";
}
......@@ -278,44 +268,44 @@
}
- (GMLabel *)titleLabel {
if (!_titleLabel) {
_titleLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:12];
_titleLabel = [GMLabel labelWithTextColor:ALColor282828 fontSize:12];
}
return _titleLabel;
}
- (GMLabel *)nameLabel {
if (!_nameLabel) {
_nameLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
_nameLabel = [GMLabel labelWithTextColor:ALColor282828 fontSize:16];
_nameLabel.font = [UIFont gmBoldFont:16];
}
return _nameLabel;
}
- (GMLabel *)startTimeLabel {
if (!_startTimeLabel) {
_startTimeLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:12];
_startTimeLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:12];
}
return _startTimeLabel;
}
- (GMLabel *)endTimeLabel {
if (!_endTimeLabel) {
_endTimeLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:12];
_endTimeLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:12];
}
return _endTimeLabel;
}
- (GMLabel *)durationLabel {
if (!_durationLabel) {
_durationLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:12];
_durationLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:12];
}
return _durationLabel;
}
- (GMLabel *)priceLabel {
if (!_priceLabel) {
_priceLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:12];
_priceLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:12];
}
return _priceLabel;
}
- (GMLabel *)payLabel {
if (!_payLabel) {
_payLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:12];
_payLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:12];
}
return _payLabel;
}
......@@ -323,7 +313,7 @@
if (!_sureBtn) {
_sureBtn = [GMButton buttonWithType:(UIButtonTypeCustom)];
_sureBtn.multiControlTimeInterva = 2.f;
[_sureBtn setBackgroundColor:RGBCOLOR_HEX(0xFF8C8D) forState:(UIControlStateNormal)];
[_sureBtn setBackgroundColor:GMColorFF8C8D forState:(UIControlStateNormal)];
[_sureBtn setTitle:@"确认订单" forState:(UIControlStateNormal)];
[_sureBtn setTitleColor:UIColor.whiteColor forState:(UIControlStateNormal)];
[_sureBtn addTarget:self action:@selector(sureBtnClick) forControlEvents:(UIControlEventTouchUpInside)];
......@@ -341,7 +331,7 @@
[_problemBtn.titleLabel setFont:[UIFont gmFont:13]];
_problemBtn.enableAdaptive = YES;
[_problemBtn setTitle:@"问题申诉>" forState:(UIControlStateNormal)];
[_problemBtn setTitleColor:RGBCOLOR_HEX(0xFF8C8D) forState:(UIControlStateNormal)];
[_problemBtn setTitleColor:GMColorFF8C8D forState:(UIControlStateNormal)];
}
return _problemBtn;
}
......
......@@ -7,7 +7,6 @@
//
#import "GMToFaceOrderFooterView.h"
@import GMBase;
@interface GMToFaceOrderFooterView ()
@property (nonatomic, strong) GMLabel *payNameLabel;
......@@ -61,14 +60,14 @@
}
- (GMLabel *)payNameLabel {
if (!_payNameLabel) {
_payNameLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:14];
_payNameLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:14];
_payNameLabel.text = @"支付金额:";
}
return _payNameLabel;
}
- (GMLabel *)moneyLabel {
if (!_moneyLabel) {
_moneyLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0xFF8C8D) fontSize:14];
_moneyLabel = [GMLabel labelWithTextColor:GMColorFF8C8D fontSize:14];
}
return _moneyLabel;
}
......@@ -76,7 +75,7 @@
if (!_payBtn) {
_payBtn = [GMButton buttonWithType:(UIButtonTypeCustom)];
[_payBtn addTarget:self action:@selector(payBtnClick) forControlEvents:(UIControlEventTouchUpInside)];
[_payBtn setBackgroundColor:RGBCOLOR_HEX(0xFF8C8D) forState:(UIControlStateNormal)];
[_payBtn setBackgroundColor:GMColorFF8C8D forState:(UIControlStateNormal)];
[_payBtn setTitle:@"立即支付" forState:(UIControlStateNormal)];
[_payBtn.titleLabel setFont:[UIFont gmBoldFont:16]];
_payBtn.layer.cornerRadius = 20.f;
......
......@@ -7,7 +7,6 @@
//
#import "GMToFaceOrderHeaderView.h"
#import "GMLibraryHeader.h"
@interface GMToFaceOrderHeaderView ()
@property (nonatomic, strong) UIImageView *headerIcon;
......@@ -36,7 +35,7 @@
NSRange range = [self.payLabel.text rangeOfString:@"/"];
range = NSMakeRange(range.location, self.payLabel.text.length - range.location);
NSMutableAttributedString *attribute = [[NSMutableAttributedString alloc] initWithString:self.payLabel.text];
[attribute addAttributes:@{NSForegroundColorAttributeName : RGBCOLOR_HEX(0x999999) } range:range];
[attribute addAttributes:@{NSForegroundColorAttributeName : ALColor999999} range:range];
[attribute addAttributes:@{NSFontAttributeName : [UIFont gmFont:10]} range:NSMakeRange(0, 1)];
self.payLabel.attributedText = attribute;
}
......@@ -88,26 +87,26 @@
}
- (GMLabel *)titleLabel {
if (!_titleLabel) {
_titleLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:17];
_titleLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:17];
}
return _titleLabel;
}
- (GMLabel *)organizationLabel {
if (!_organizationLabel) {
_organizationLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:13];
_organizationLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:13];
}
return _organizationLabel;
}
- (GMLabel *)moneyLabel {
if (!_moneyLabel) {
_moneyLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:10];
_moneyLabel = [GMLabel labelWithTextColor:GMColor999999 fontSize:10];
_moneyLabel.text = @"金额:";
}
return _moneyLabel;
}
- (GMLabel *)payLabel {
if (!_payLabel) {
_payLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0xFF5963) fontSize:16];
_payLabel = [GMLabel labelWithTextColor:GMColorFF5963 fontSize:16];
}
return _payLabel;
}
......
......@@ -12,10 +12,6 @@
#import "GMToFacePayViewModel.h"
#import "GMPayResultModel.h"
#import "GMThirdPartyDefine.h"
#import "RequestHeader.h"
#import "GMLibraryHeader.h"
#import <GMBase/GMBaseTool.h>
@interface GMToFacePayPopView ()
@property (nonatomic, strong) GMLabel *titleLabel;
......@@ -72,13 +68,13 @@
}
- (void)setNotification {
//支付宝支付成功
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:@"order_pay_success" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:ORDER_PAY_SUCCESS object:nil];
//支付宝支付失败
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:@"order_pay_fail" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:ORDER_PAY_FAIL object:nil];
//微信支付成功
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:@"kWechatPaySuccess" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:kWechatPaySuccess object:nil];
//微信支付失败
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:@"kWechatPayFail" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:kWechatPayFail object:nil];
//从后台回到前台
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(enterForground) name:UIApplicationWillEnterForegroundNotification object:nil];
}
......@@ -127,13 +123,6 @@
//这个set方法只会走一次,所以放在这里不会有问题
[self pvPhoboMethod];
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
- (void)selectPayTypeMethod:(UIGestureRecognizer *)gesture {
__weak typeof(self) weakSelf = self;
[self.orderModel.paymentChannels enumerateObjectsUsingBlock:^(GMToFacePayTypeModel *obj, NSUInteger idx, BOOL * _Nonnull stop) {
......@@ -152,15 +141,15 @@
self.viewModel.paymentAmount = self.orderModel.paymentAmount;
//目的是防止重复点击,所以必须要网络请求回来之后才可再次点击
self.footerView.isCanClick = NO;
[[GMBaseTool getCurrentViewController] showLoading:nil];
[AppDelegate.visibleController showLoading:nil];
__weak typeof(self) weakSelf = self;
[self.viewModel excuteToFacePayCompleteBlock:^(id responseObject) {
weakSelf.footerView.isCanClick = YES;
[[GMBaseTool getCurrentViewController] hideLoading];
[AppDelegate.visibleController hideLoading];
} failedBlock:^(NSString *message) {
//支付参数获取失败 则可以重新支付
[[GMBaseTool getCurrentViewController] toast:message];
[[GMBaseTool getCurrentViewController] hideLoading];
[AppDelegate.visibleController toast:message];
[AppDelegate.visibleController hideLoading];
weakSelf.footerView.isCanClick = YES;
}];
}
......@@ -190,20 +179,20 @@
weakSelf.paiedIsFinish = NO;
NSNumber *status = responseObject.data[@"order_status"];
if ([status integerValue] == 2) {
[[GMBaseTool getCurrentViewController] toast:@"支付成功,不要走开,立即进入视频面诊连线"];
[AppDelegate.visibleController toast:@"支付成功,不要走开,立即进入视频面诊连线"];
//回调到信息卡页面去做一些操作
if (weakSelf.PaySuccessBlock) {
weakSelf.PaySuccessBlock();
[weakSelf hide];
}
}else {
[[GMBaseTool getCurrentViewController] toast:responseObject.message];
[AppDelegate.visibleController toast:responseObject.message];
}
} failBlock:^(NSString *message) {
weakSelf.paiedIsFinish = NO;
[GMHudModule hideLoading];
[[GMBaseTool getCurrentViewController] toast:message];
[AppDelegate.visibleController toast:message];
}];
}
......@@ -211,10 +200,10 @@
- (void)orderPayFail:(NSNotification *)noti{
self.paiedIsFail = YES;
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1.f * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[[GMBaseTool getCurrentViewController] showWarning:@"支付失败"];
[AppDelegate.visibleController showWarning:@"支付失败"];
self.paiedIsFail = NO;
});
[[GMBaseTool getCurrentViewController] hideLoading];
[AppDelegate.visibleController hideLoading];
self.footerView.isCanClick = YES;
}
#pragma mark - notification
......@@ -244,19 +233,19 @@
[GMHudModule hideLoading];
NSNumber *status = responseObject.data[@"order_status"];
if ([status integerValue] == 2) {
[[GMBaseTool getCurrentViewController] toast:@"支付成功,不要走开,立即进入视频面诊连线"];
[AppDelegate.visibleController toast:@"支付成功,不要走开,立即进入视频面诊连线"];
//回调到信息卡页面去做一些操作
if (weakSelf.PaySuccessBlock) {
weakSelf.PaySuccessBlock();
[weakSelf hide];
}
}else {
[[GMBaseTool getCurrentViewController] toast:responseObject.message];
[AppDelegate.visibleController toast:responseObject.message];
}
} failBlock:^(NSString *message) {
[GMHudModule hideLoading];
[[GMBaseTool getCurrentViewController] toast:message];
[AppDelegate.visibleController toast:message];
}];
});
}
......@@ -284,7 +273,7 @@
}
- (GMLabel *)titleLabel {
if (!_titleLabel) {
_titleLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:22.5];
_titleLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:22.5];
_titleLabel.font = [UIFont gmBoldFont:22.5];
_titleLabel.text = @"请选择支付方式";
}
......
......@@ -7,7 +7,6 @@
//
#import "GMToFacePaySectionHeaderView.h"
@import GMKit;
@interface GMToFacePaySectionHeaderView ()
@property (nonatomic, strong) UIView *labelView;
......@@ -50,21 +49,21 @@
- (UIView *)grayView {
if (!_grayView) {
_grayView = [[UIView alloc] init];
_grayView.backgroundColor = RGBCOLOR_HEX(0xF7F6FA);
_grayView.backgroundColor = GMColorF7F6FA;
}
return _grayView;
}
- (UIView *)lineView {
if (!_lineView) {
_lineView = [[UIView alloc] init];
_lineView.backgroundColor = RGBCOLOR_HEX(0xE5E5E5);
_lineView.backgroundColor = GMColorE5E5E5;
}
return _lineView;
}
- (UIView *)labelView {
if (!_labelView) {
_labelView = [[UIView alloc] init];
GMLabel *label = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:15];
GMLabel *label = [GMLabel labelWithTextColor:GMColor282828 fontSize:15];
label.text = @"请选择支付方式";
[_labelView addSubview:label];
[label mas_makeConstraints:^(MASConstraintMaker *make) {
......
......@@ -7,8 +7,7 @@
//
#import "GMToFacePayTypeCell.h"
@import GMBase;
@import SDWebImage;
@interface GMToFacePayTypeCell ()
@property (strong, nonatomic) UIImageView *payWayImage;
@property (strong, nonatomic) GMLabel *payName;
......@@ -31,7 +30,7 @@
[self.payWayImage sd_setImageWithURL:[NSURL URLWithString:typeModel.icon]];
self.payDesc.text = typeModel.desc;
self.payName.text = typeModel.title;
self.payDesc.textColor = typeModel.recommend?RGBCOLOR_HEX(0xFF5963):RGBCOLOR_HEX(0x999999);
self.payDesc.textColor = typeModel.recommend?GMColorFF5963:GMColor999999;
self.recommendIcon.hidden = !typeModel.recommend;
}
- (void)setUI {
......@@ -83,13 +82,13 @@
}
- (GMLabel *)payName {
if (!_payName) {
_payName = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:14];
_payName = [GMLabel labelWithTextColor:GMColor282828 fontSize:14];
}
return _payName;
}
- (GMLabel *)payDesc {
if (!_payDesc) {
_payDesc = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0xFF5963) fontSize:12];
_payDesc = [GMLabel labelWithTextColor:GMColorFF5963 fontSize:12];
}
return _payDesc;
}
......
......@@ -13,13 +13,9 @@
#import "GMToFaceOrderFooterView.h"
#import "GMToFacePayViewModel.h"
#import "GMPayResultModel.h"
#import "NSString+jsonData.h"
#import "GMThirdPartyDefine.h"
#import "RequestHeader.h"
#import "GMLibraryHeader.h"
#import <GMBase/GMBaseTool.h>
#import "NSString+AIJsonData.h"
@import GMNetworking;
@interface GMToFaceOrderViewController ()
@property (nonatomic, strong) GMToFacePayViewModel *payViewModel;
/** 头部视图 */
......@@ -70,17 +66,15 @@
self.extraParam = [NSString convertToBriefJsonString:param];
self.businessId = self.orderModel.orderNo;
}
- (void)setNotification {
//支付宝支付成功
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:@"order_pay_success" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:ORDER_PAY_SUCCESS object:nil];
//支付宝支付失败
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:@"order_pay_fail" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:ORDER_PAY_FAIL object:nil];
//微信支付成功
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:@"kWechatPaySuccess" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPaySuccess:) name:kWechatPaySuccess object:nil];
//微信支付失败
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:@"kWechatPayFail" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(orderPayFail:) name:kWechatPayFail object:nil];
//从后台回到前台
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(enterForground) name:UIApplicationWillEnterForegroundNotification object:nil];
}
......@@ -128,7 +122,7 @@
- (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section {
UIView *backView = [[UIView alloc] init];
backView.backgroundColor = UIColor.whiteColor;
GMLabel *label = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:11];
GMLabel *label = [GMLabel labelWithTextColor:GMColor999999 fontSize:11];
label.frame = CGRectMake(15, 28, MAINSCREEN_WIDTH - 15, 12);
label.text = @"为避免订单失效,建议您在3分钟内完成支付";
[backView addSubview:label];
......@@ -149,7 +143,7 @@
}]];
UIAlertAction *action = alert.actions.firstObject;
//这个key是用 runtime属性列表Ivar遍历得到的
[action setValue:RGBCOLOR_HEX(0x282828) forKey:@"titleTextColor"];
[action setValue:GMColor282828 forKey:@"titleTextColor"];
[self presentViewController:alert animated:YES completion:nil];
}
//页面按钮的点击埋点
......@@ -169,7 +163,7 @@
[GMNetworking requestOCWithApi:API_ORDER_CANCEL method:GMHTTPMethodPost parameters:@{@"order_no":self.orderModel.orderNo} completion:^(GMResponseOC * _Nonnull responseObject) {
[GMHudModule hideLoading];
[GMHudModule toastInView:[UIApplication sharedApplication].keyWindow text:responseObject.message];
[[GMBaseTool getCurrentViewController] popViewControllerAnimated:YES completion:nil];
[AppDelegate.visibleController popViewControllerAnimated:YES completion:nil];
}];
}
#pragma mark - 点击 "立即支付"
......
......@@ -9,13 +9,9 @@
#import "GMTofaceOrderDetailViewController.h"
#import "GMComplaintObject.h"
#import "GMComplaintResultView.h"
//#import "Gengmei-Swift.h"
#import "Gengmei-Swift.h"
#import "GMEndConsultView.h"
#import "RequestHeader.h"
#import "GMToFaceNetworking.h"
#import <GMBaseWeb/GMBaseWeb-Swift.h>
#import <WebKit/WebKit.h>
@import GMHud;
@interface GMTofaceOrderDetailViewController () <WKWebViewDelegate>
@property (nonatomic, strong) GMComplaintObject *complaintObject;
......@@ -48,7 +44,7 @@
- (void)viewComplaint:(NSString *)jsonString {
NSString *diagnosisId = SafeString(jsonString);
[GMHudModule showLoading:nil];
[[GMToFaceNetworking shareInstance] excuteToFaceComplaintGetDiagnosis_id:diagnosisId SuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceComplaintGetDiagnosis_id:diagnosisId SuccessBlock:^(id response) {
[GMHudModule hideLoading];
GMComplaintInterfaceObject *model = [[GMComplaintInterfaceObject alloc] initWithDictionary:response error:nil];
self.complaintObject.report_detail = model.complaint.content;
......@@ -58,10 +54,10 @@
self.complaintObject.custom_url = model.custom_url;
self.complaintObject.status = model.status;
GMComplaintResultView *view = [[GMComplaintResultView alloc] initWithType:self.complaintObject.status dictModel:self.complaintObject];
[[GMBaseTool mainWindow] addSubview:view];
[[AppDelegate shareInstance].window addSubview:view];
} failureBlock:^(NSInteger errorCode, NSString *message) {
[GMHudModule hideLoading];
[[GMBaseTool getCurrentViewController] toast:message];
[AppDelegate.visibleController toast:message];
}];
}
#pragma mark - 去投诉
......@@ -74,7 +70,7 @@
NSString *jsStr = [NSString stringWithFormat:@"window.gm&&window.gm.pack&&window.gm.pack.run('notificReportState')"];
[self.webCompent.webView evaluateJavaScript:jsStr completionHandler:nil];
};
[[GMBaseTool getCurrentViewController].view addSubview:view];
[AppDelegate.navigation.view addSubview:view];
}
- (GMComplaintObject *)complaintObject {
......
......@@ -7,7 +7,7 @@
//
#import <Foundation/Foundation.h>
@import GMNetService;
NS_ASSUME_NONNULL_BEGIN
typedef NS_ENUM(NSInteger, GMToFacePayType) {
/** 支付宝 */
......
......@@ -10,16 +10,10 @@
#import <AlipaySDK/AlipaySDK.h>
#import "WXApiObject.h"
#import "WXApi.h"
#import "GMNotificationName.h"
#import "AppDelegate.h"
#import "GMPayResultModel.h"
#import "GMThirdPartyDefine.h"
#import "RequestHeader.h"
#import "GMLibraryHeader.h"
#import <GMBase/GMBaseTool.h>
/*** @brief 订单支付部分*/
#define ORDER_PAY_SUCCESS @"order_pay_success"
//订单支付成功
#define ORDER_PAY_FAIL @"order_pay_fail"
@interface GMToFacePayViewModel ()
......@@ -31,11 +25,11 @@
*/
- (void)excuteToFacePayCompleteBlock:(HttpSuccessBlock)successBlock failedBlock:(HttpFailedBlock)failedBlock {
if (self.payType == GMToFacePayTypeAlipay && ![[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"alipay://"]]) {
[[GMBaseTool getCurrentViewController] toast:@"请安装支付宝"];
[AppDelegate.visibleController toast:@"请安装支付宝"];
return;
}
if (self.payType == GMToFacePayTypeWechat && ![WXApi isWXAppInstalled]) {
[[GMBaseTool getCurrentViewController] toast:@"请安装微信"];
[AppDelegate.visibleController toast:@"请安装微信"];
return;
}
NSString *channel;
......
......@@ -7,8 +7,6 @@
//
#import "GMAppCameraAndMicrophone.h"
#import <GMBase/GMBaseTool.h>
@implementation GMAppCameraAndMicrophone
/// 相机权限
......@@ -68,8 +66,7 @@
[alert addAction:[UIAlertAction actionWithTitle:@"设置" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
}]];
UIViewController *vc = [GMBaseTool getCurrentViewController];
[vc presentViewController:alert animated:YES completion:nil];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:nil];
}
+ (void)showCameraAlert {
......@@ -79,9 +76,7 @@
[alert addAction:[UIAlertAction actionWithTitle:@"设置" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
}]];
UIViewController *vc = [GMBaseTool getCurrentViewController];
[vc presentViewController:alert animated:YES completion:nil];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:nil];
}
@end
......@@ -14,10 +14,6 @@
#import "GMEndConsultView.h"
#import "GMAppCameraAndMicrophone.h"
#import "GMVideoPhobos.h"
#import <GMBase/GMBaseTool.h>
@import GMHud;
@import GMRouter;
static GMDoctorVideoTelephoneLogin *loginManager = nil;
@interface GMDoctorVideoTelephoneLogin ()<GMTelephoneViewDelegate, TTTRtcEngineDelegate, GMVideoTelephoneWindowDelegate>
......@@ -94,7 +90,7 @@ static GMDoctorVideoTelephoneLogin *loginManager = nil;
#pragma mark - 初始化直播间
- (void)doctorLoginVideoRoomModel:(GMVideoTelephoneModel *)model {
_uid = (NSInteger)[[GMRouter sharedInstance] pushScheme:@"gengmei://gm_userId"];;
_uid = GMLoginManager.shareInstance.user.userId;
_channelId = model.channelId;
_pushURL = model.streamUrl;
......@@ -172,7 +168,7 @@ static GMDoctorVideoTelephoneLogin *loginManager = nil;
}
NSString *button_name = status ? @"answer" : @"cancel";
UIViewController *vc = [GMBaseTool getCurrentViewController].navigationController.viewControllers.lastObject;
UIViewController *vc = AppDelegate.visibleController.navigationController.viewControllers.lastObject;
NSString *referrer = vc.pageName;
[Phobos track:@"on_click_button" attributes:@{
@"page_name":@"video_face_consultation_doctor",
......@@ -260,7 +256,7 @@ static GMDoctorVideoTelephoneLogin *loginManager = nil;
GMEndConsultView *view = [[GMEndConsultView alloc] initWithType:TTManager.totalTime > 180 ? GMEndConsultViewTypeReport : GMEndConsultViewTypeDefault starNum:0];
view.complaintType = GMComplaintTypeDoctor;
view.recordId = TTManager.consultationRecordId;
[[GMBaseTool getCurrentViewController].view addSubview:view];
[AppDelegate.navigation.view addSubview:view];
if (TTManager.totalTime > 180) {
[[NSNotificationCenter defaultCenter] postNotificationName:@"doctor_finshed_video" object:nil];
}
......
......@@ -8,7 +8,7 @@
#import "GMNimChannelManager.h"
#import <CommonCrypto/CommonDigest.h>
@import GMRouter;
@implementation GMNimChannelManager
+ (instancetype)shareInstance {
static dispatch_once_t onceToken;
......@@ -167,8 +167,7 @@
/// @param resultBlock 结果
- (void)doCallWithAccountId:(NSString *)accountId customInfo:(NSString *)customInfo resultBlock:(nonnull NIMResultBlock)resultBlock {
NIMSignalingCallRequest *request = [[NIMSignalingCallRequest alloc] init];
NSInteger user = (NSInteger)[[GMRouter sharedInstance] pushScheme:@"gengmei://gm_userId"];
request.uid = user;
request.uid = [GMLoginManager shareInstance].user.userId;
request.accountId = accountId;
request.requestId = [self createRequestId];
request.customInfo = customInfo;
......
......@@ -7,7 +7,7 @@
//
#import "GMRtcManager.h"
#import "GMFaceHeader.h"
@implementation GMRtcManager : NSObject
static id _manager;
......@@ -45,7 +45,7 @@ static id _manager;
_localProfile = TTTRtc_VideoProfile_Default;
_cdnProfile = TTTRtc_VideoProfile_Default;
// 杀死app 需要退出
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(closeRoom) name:@"gm_close_app" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(closeRoom) name:GM_CLOSE_APP object:nil];
}
return self;
}
......
......@@ -11,16 +11,14 @@
#import "GMUserVideoTelephoneWindow.h"
#import "GMVideoTelephoneRequestTool.h"
#import "GMTelephoneAudioPlay.h"
#import "GMLoginManager.h"
#import <GMPublicNomalHUD.h>
#import "GMAppCameraAndMicrophone.h"
#import "GMVideoPhobos.h"
#import "GMSureOrderPopView.h"
#import "GMToFaceOrderInfoModel.h"
#import "GMNimChannelManager.h"
#import "NSDictionary+json.h"
#import "GMToFaceNetworking.h"
#import <GMBase/GMBaseTool.h>
static GMUserVideoTelephoneLogin *loginManager = nil;
......@@ -65,7 +63,7 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
self.logoHud = [[GMPublicNomalHUD alloc] init];
self.logoHud.frame = CGRectMake(0, 0, 100, 100);
self.logoHud.hidden = YES;
self.logoHud.center = [GMBaseTool getCurrentViewController].view.center;
self.logoHud.center = AppDelegate.visibleController.view.center;
}
return self;
}
......@@ -78,7 +76,7 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
return;
}
[[GMBaseTool getCurrentViewController].view addSubview:self.logoHud];
[AppDelegate.visibleController.view addSubview:self.logoHud];
self.logoHud.hidden = NO;
_clientRole = TTTRtc_ClientRole_Anchor;
_extensionDict = extentsionDict;
......@@ -103,7 +101,7 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
//如果相机或是麦克风权限必须获取才能视频通话
return;
}
[[GMBaseTool getCurrentViewController].view addSubview:self.logoHud];
[AppDelegate.visibleController.view addSubview:self.logoHud];
_clientRole = TTTRtc_ClientRole_Broadcaster;
_extensionDict = extentsionDict;
TTManager = [GMRtcManager sharedRtcManager];
......@@ -114,7 +112,7 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
#pragma mark - 初始化直播间
- (void)userLoginVideoRoomModel:(GMVideoTelephoneModel *)model {
_uid = (NSInteger)[[GMRouter sharedInstance] pushScheme:@"gengmei://gm_userId"];
_uid = GMLoginManager.shareInstance.user.userId;
_channelId = model.channelId;
_pushURL = model.streamUrl;
_neteaseModel = model.neteaseIm;
......@@ -162,6 +160,7 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
@"consultation_record_id": TTManager.consultationRecordId
};
[[GMNimChannelManager shareInstance] doInviteJoinWithChannelId:_neteaseModel.channelId accountId:_neteaseModel.toAccountId customInfo:[NSDictionary dictionaryToJson:customInfo] resultBlock:^(BOOL isSuccess) {
debugLog(@"doInviteJoinWithChannelId %d", isSuccess ? 1 : 0);
}];
}
}];
......@@ -231,16 +230,16 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
NSString *doctorId = counsellorType == 1 ? TTManager.vidoeTelephoneModel.counsellorInfo.doctorId:TTManager.vidoeTelephoneModel.counsellorInfo.id;
[self clickConfireBtnPhobo:counsellorType consultationType:consultationType doctorId:doctorId];
//确认订单
[[GMToFaceNetworking shareInstance] excuteToFaceInfoSureOrder:self.messageDict[@"order_no"] SuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceInfoSureOrder:self.messageDict[@"order_no"] SuccessBlock:^(id response) {
GMToFaceOrderInfoModel *infoModel = [[GMToFaceOrderInfoModel alloc] initWithDictionary:response error:nil];
infoModel.consultationRecordId = TTManager.consultationRecordId;
GMSureOrderPopView *popView = [[GMSureOrderPopView alloc] init];
popView.isCloseBtnHidden = YES;
popView.infoModel = infoModel;
[popView clickConfireBtnPhobo:counsellorType consultationType:consultationType doctorId:doctorId];
[[GMBaseTool mainWindow] addSubview:popView];
[[AppDelegate shareInstance].window addSubview:popView];
} failureBlock:^(NSInteger errorCode, NSString *message) {
[[GMBaseTool getCurrentViewController] toast:message];
[AppDelegate.visibleController toast:message];
}];
}
......
......@@ -7,9 +7,6 @@
//
#import "GMVideoPhobos.h"
@import GMFoundation;
@import GMPhobos;
@import GMBase;
@implementation GMVideoPhobos
/**
......
......@@ -7,8 +7,7 @@
//
#import "GMVideoTelephoneRequestTool.h"
#import "RequestHeader.h"
#import "GMLibraryHeader.h"
@implementation GMVideoTelephoneRequestTool
......
......@@ -7,8 +7,6 @@
//
#import <Foundation/Foundation.h>
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
@protocol GMConsultationInfoModel @end
......
......@@ -8,9 +8,6 @@
#import <Foundation/Foundation.h>
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
@interface GMRecommendShopingModel : GMObject
......
......@@ -7,7 +7,6 @@
//
#import <Foundation/Foundation.h>
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,7 +7,6 @@
//
#import <Foundation/Foundation.h>
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,8 +7,6 @@
//
#import <Foundation/Foundation.h>
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
@protocol GMUserInfoModel @end
......
......@@ -9,8 +9,6 @@
#import <Foundation/Foundation.h>
#import "GMUserInfoModel.h"
#import "GMConsultationInfoModel.h"
@import GMBase;
@class GMTelephoneDoctorModel;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,7 +8,7 @@
#import <UIKit/UIKit.h>
#import "GMVideoTelephoneModel.h"
#import <GMKit/GMView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -9,14 +9,12 @@
#import "GMDoctorRecommendShoppingView.h"
#import "GMDoctorShoppingViewCell.h"
#import "GMDoctorShopingViewSelectedCell.h"
#import "GMAISearchNavigationView.h"
#import "GMSearchNavigationView.h"
#import "GMRecommendShopingModel.h"
#import "GMRtcManager.h"
#import "GMToFaceCommonEmptyView.h"
#import "GMCommonEmptyView.h"
#import "GMContextualAcitonImage.h"
#import <GMKit/GMView.h>
#import "RequestHeader.h"
@import GMNetworking;
@protocol GMShoppingTitleView1Delegate <NSObject>
-(void)shoppingTitleView1TureBtnClick;
......@@ -161,8 +159,8 @@
@interface GMDoctorRecommendShoppingView ()<UITableViewDelegate,UITableViewDataSource,UITextFieldDelegate,GMShoppingTitleViewDelegate,GMShoppingTitleView1Delegate>
@property(nonatomic, strong)GMTableView *tableView;
@property(nonatomic, strong)GMAISearchNavigationView *searchNavigationView;
@property (nonatomic, strong)GMToFaceCommonEmptyView *emptyView;
@property(nonatomic, strong)GMSearchNavigationView *searchNavigationView;
@property (nonatomic, strong)GMCommonEmptyView *emptyView;
@property(nonatomic, strong)GMShoppingTitleView *titltView;
@property(nonatomic, strong)GMShoppingTitleView1 *titltView1;
@property (nonatomic, assign)GMShoppingViewSelecteType seletedType;
......@@ -470,15 +468,15 @@
}
- (void)addemptyView {
_emptyView = [[GMToFaceCommonEmptyView alloc] initWithFrame:CGRectZero];
_emptyView = [[GMCommonEmptyView alloc] initWithFrame:CGRectZero];
_emptyView.hidden = YES;
_emptyView.emptyLabel.text = @"你的推荐带空空如也";
[self addSubview:_emptyView];
}
- (GMAISearchNavigationView *)searchNavigationView{
- (GMSearchNavigationView *)searchNavigationView{
if (!_searchNavigationView) {
_searchNavigationView = [GMAISearchNavigationView new];
_searchNavigationView = [GMSearchNavigationView new];
_searchNavigationView.textField.delegate = self;
_searchNavigationView.hidden = YES;
_searchNavigationView.textField.placeholder = @"请输入美购名称";
......
......@@ -5,7 +5,7 @@
// Created by 刘鹿杰的mac on 2020/2/25.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMLibraryHeader.h"
@class GMRecommendShopingModel;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,6 +8,7 @@
#import "GMDoctorShopingViewSelectedCell.h"
#import "GMRecommendShopingModel.h"
@interface GMDoctorShopingViewSelectedCell ()
@property (nonatomic, strong) GMButton *seleBtn;
......
......@@ -5,7 +5,7 @@
// Created by 刘鹿杰的mac on 2020/2/24.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMLibraryHeader.h"
@class GMRecommendShopingModel;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,7 +8,7 @@
#import "GMDoctorTelephoneFunctionView.h"
#import "GMTelephoneProxy.h"
@import GMBase;
@implementation GMDoctorTelephoneFunctionView
{
UIButton *shoppingBtn; //购物
......
......@@ -7,7 +7,7 @@
//
#import <UIKit/UIKit.h>
#import "GMLibraryHeader.h"
NS_ASSUME_NONNULL_BEGIN
@interface GMLinkPromptView : UIView
......
......@@ -7,7 +7,6 @@
//
#import "GMTelephoneAttentionView.h"
#import "GMLibraryHeader.h"
@implementation GMTelephoneAttentionView
{
......
......@@ -7,7 +7,6 @@
//
#import "GMTelephoneBtnView.h"
#import "GMLibraryHeader.h"
@implementation GMTelephoneBtnView
......
......@@ -7,7 +7,6 @@
//
#import "GMTelephoneShoppingEmptyView.h"
#import "GMLibraryHeader.h"
@implementation GMTelephoneShoppingEmptyView
{
......
......@@ -9,11 +9,9 @@
#import "GMTelephoneView.h"
#import "GMTelephoneBtnView.h"
#import "GMVideoTelephoneRequestTool.h"
#import "UITabBar+BottomSafe.h"
#import "UITabBar+ViewConstant.h"
#import "GMUserFillMessageView.h"
#import "GMVideoPhobos.h"
#import "GMLibraryHeader.h"
@implementation GMTelephoneView
{
GMTelephoneBtnView *jieting;
......
......@@ -7,8 +7,8 @@
//
#import "GMUserFillMessageView.h"
#import "UITabBar+BottomSafe.h"
#import "GMLibraryHeader.h"
#import "UITabBar+ViewConstant.h"
@implementation GMUserFillMessageView
{
UIImageView *_iconImgV;
......
......@@ -8,7 +8,7 @@
#import "GMUserTelephoneFunctionView.h"
#import "GMTelephoneProxy.h"
@import GMKit;
@implementation GMUserTelephoneFunctionView
{
UIButton *shoppingBtn; //购物
......
......@@ -10,7 +10,6 @@
#import "GMVideoTelephoneRecommodWelfareTableViewCell.h"
#import "GMTelephoneShoppingEmptyView.h"
#import "GMVideoTelephoneRequestTool.h"
#import "GMLibraryHeader.h"
@interface GMVideoTelephoneRecommendShoppingView ()<UITableViewDelegate, UITableViewDataSource>
{
......
......@@ -7,8 +7,7 @@
//
#import "GMVideoTelephoneRecommodWelfareTableViewCell.h"
@import GMBase;
@import SDWebImage;
@implementation GMVideoTelephoneRecommodWelfareTableViewCell
{
UIImageView *_iconImg;
......
......@@ -13,9 +13,6 @@
#import "GMLinkPromptView.h"
#import "GMTelephoneAudioPlay.h"
#import "GMVideoPhobos.h"
#import <GMBase/GMBaseTool.h>
@interface GMUserVideoTelephoneWindow ()<TTTRtcEngineDelegate, GMTelephoneFunctionViewDelegate, GMRecommendShoppingDelegate, GMTelephoneAttentionViewDelegate>
{
......@@ -196,6 +193,11 @@
#pragma mark - 点击美购进入美购详情
- (void)selectedIndex:(NSInteger)index welfareId:(NSString *)welfareId {
[self windowMini];
GMWelfareDetailGrayController *vc = [GMWelfareDetailGrayController new];
//@"5708692"
vc.welfareId = welfareId;
vc.referer = self.pageName;
vc.customRefererLink = self.pageName;
[Phobos track:@"welfare_multiattribute_click_add" attributes:@{
@"page_name":self.pageName,
@"referrer_tab_name":SafeString(self.referrerTabName),
......@@ -203,8 +205,7 @@
@"doctor_id":SafeString(_TTManager.vidoeTelephoneModel.counsellorInfo.doctorId) ,
@"referrer":self.referer,
}];
NSString *url = [NSString stringWithFormat:@"gengmei://service?service_id=%@&referer=%@&customRefererLink=%@", welfareId,self.pageName,self.pageName];
[[GMRouter sharedInstance] pushScheme:url];
[AppDelegate.visibleController.navigationController pushViewController:vc animated:YES];
}
#pragma mark - 关闭购物页面
......@@ -352,8 +353,8 @@
[alert addAction:[UIAlertAction actionWithTitle:@"继续等待" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {}]];
UIAlertAction *action = alert.actions.firstObject;
//这个key是用 runtime属性列表Ivar遍历得到的
[action setValue:RGBCOLOR_HEX(0x282828) forKey:@"titleTextColor"];
[[GMBaseTool getCurrentViewController] presentViewController:alert animated:YES completion:nil];
[action setValue:GMColor282828 forKey:@"titleTextColor"];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:nil];
}
#pragma mark - 退出房间 yes 主动离线 no 被动
......@@ -374,7 +375,7 @@
GMTelphoneStatusModel *model = message[@"model"];
_TTManager.totalTime = [model.callDuration intValue];
if (_TTManager.totalTime == 0 && status) {//没有接通并主动离开的时候会退款
[[GMBaseTool getCurrentViewController] toast:@"视频面诊已取消,本次视频面诊订单金额将原路退还至您的账户中"];
[AppDelegate.visibleController toast:@"视频面诊已取消,本次视频面诊订单金额将原路退还至您的账户中"];
}
}
if ([self.delgate respondsToSelector:@selector(nomalExitRoom)]) {
......
......@@ -9,6 +9,8 @@
#import <UIKit/UIKit.h>
#import "GMAVRegionView.h"
#import "GMRtcManager.h"
#import "GMWelfareDetailGrayController.h"
#import "AppDelegate.h"
#import "GMVideoTelephoneRequestTool.h"
@import CoreTelephony;
......
......@@ -7,9 +7,7 @@
//
#import "GMVideoTelephoneWindow.h"
#import <GMBase/GMBaseTool.h>
@import GMHud;
#import "AppDelegate+AppInit.h"
@interface GMVideoTelephoneWindow ()
@end
......@@ -21,7 +19,7 @@
self = [super initWithFrame:frame];
if (self) {
self.layer.masksToBounds = YES;
UIViewController *vc = [GMBaseTool getCurrentViewController].navigationController.viewControllers.lastObject;
UIViewController *vc = AppDelegate.visibleController.navigationController.viewControllers.lastObject;
self.referer = vc.pageName;
self.referrerTabName = vc.tabName;
......@@ -29,7 +27,10 @@
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(userExitTime) name:@"gm_telephone_cancal" object:nil];
//网络发生变化
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(netWorkingChanged:) name:@"gm_networkingChang" object:nil];
//当用手机网络进入直播间时
if ([AppDelegate shareInstance].preNetworkStatus == 1) {
[GMHudModule showWarning:@"当前为非WiFi环境,请注意流量消耗!"];
}
}
return self;
......
......@@ -5,7 +5,6 @@
// Created by yefengming on 2020/3/10.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -5,7 +5,6 @@
// Created by yefengming on 2020/3/6.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import <GMKit/GMPopupBgView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,12 +8,9 @@
#import "GMVideoWaitingView.h"
#import "GMWaitingSuccessView.h"
#import "UIImage+WebP.h"
#import "GMNoticeInfoObject.h"
#import "GMVideoPhobos.h"
#import "GMLibraryHeader.h"
#import <GMBase/GMBaseTool.h>
#define centerPoint CGPointMake(MAINSCREEN_WIDTH / 2, MAINSCREEN_HEIGHT / 2)
#define circleAnimaitionTime 2
#define fromRadius sqrtf((centerPoint.x * centerPoint.x) + (centerPoint.y * centerPoint.y))
......@@ -45,13 +42,13 @@
self.animationView.hidden = NO;
self.topLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
self.topLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:16];
self.topLabel.font = [UIFont gmBoldFont:16];
self.topLabel.text = @"正在匹配";
self.topLabel.textAlignment = NSTextAlignmentCenter;
[self.container addSubview:self.topLabel];
self.bottomLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
self.bottomLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:16];
self.bottomLabel.font = [UIFont gmBoldFont:16];
self.bottomLabel.text = @"60s";
[self.container addSubview:self.bottomLabel];
......@@ -59,13 +56,13 @@
self.cancelBtn = [[GMButton alloc] init];
[self.cancelBtn setTitle:@"取消连线" forState:UIControlStateNormal];
[self.cancelBtn setTitleColor:UIColor.whiteColor forState:UIControlStateNormal];
self.cancelBtn.backgroundColor = RGBCOLOR_HEX(0xCCCCCC);
self.cancelBtn.backgroundColor = GMColorCCCCCC;
self.cancelBtn.layer.cornerRadius = 23;
self.cancelBtn.layer.masksToBounds = YES;
[self.container addSubview:self.cancelBtn];
[self.cancelBtn addTarget:self action:@selector(cancelBtnClick) forControlEvents:UIControlEventTouchUpInside];
self.infoLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x464646) fontSize:14];
self.infoLabel = [GMLabel labelWithTextColor:GMColor464646 fontSize:14];
self.infoLabel.text = @"正在全力为您匹配";
self.infoLabel.textAlignment = NSTextAlignmentCenter;
[self.container addSubview:self.infoLabel];
......@@ -107,15 +104,6 @@
make.centerX.mas_equalTo(0);
}];
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
- (void)startShowPhotoAnimation {
CGPathRef fromPath = _maskLayer.path;
CGPathRef toPath = [UIBezierPath bezierPathWithArcCenter:centerPoint radius:toRadius startAngle:0 endAngle:2 * M_PI clockwise:YES].CGPath;
......@@ -179,7 +167,7 @@
self.currentTime --;
if (self.currentTime % 5 == 0) {
__weak __typeof(self)weakSelf = self;
[GMNetworking requestOCWithApi:@"/api/consultation_counsel/get_current_dispatch_info" method:GMHTTPMethodGet parameters:nil completion:^(GMResponseOC * _Nonnull response) {
[GMNetworking requestOCWithApi:API_CONSULTATION_DISPATCH_INFO method:GMHTTPMethodGet parameters:nil completion:^(GMResponseOC * _Nonnull response) {
if (response.data[@"notice_info"]) {
[weakSelf showSuccessView];
weakSelf.successView.object = [[GMNoticeInfoObject alloc] initWithDictionary:response.data[@"notice_info"] error:nil];
......@@ -194,7 +182,7 @@
} else {
NSString *str = self.counsellorType == 1 ? @"医生":@"面诊师";
str = [NSString stringWithFormat:@"抱歉,暂无%@接单,请稍后再试,本次视频面诊订单金额将原路退还至您的账户中",str];
[[GMBaseTool getCurrentViewController] toast:str];
[AppDelegate.visibleController toast:str];
[self invalidateCountDownTimer];
[self cancelDispatch];
[self hide];
......@@ -205,7 +193,7 @@
}
- (void)cancelDispatch {
[GMNetworking requestOCWithApi:@"/api/consultation_counsel/cancel_dispatch" method:GMHTTPMethodPost parameters:nil completion:^(GMResponseOC * _Nonnull response) {
[GMNetworking requestOCWithApi:API_CONSULTATION_CANCEL_DISPATCH method:GMHTTPMethodPost parameters:nil completion:^(GMResponseOC * _Nonnull response) {
}];
}
......@@ -221,7 +209,7 @@
} rightAlertAction:^{
}];
[[GMBaseTool getCurrentViewController] presentViewController:alert animated:YES completion:nil];
[AppDelegate.visibleController presentViewController:alert animated:YES completion:nil];
}
}
......@@ -239,7 +227,7 @@
}
- (void)waitViewHide {
[[GMBaseTool getCurrentViewController] toast:@"取消派单成功,本次视频面诊订单金额将原路退还至您的账户中"];
[AppDelegate.visibleController toast:@"取消派单成功,本次视频面诊订单金额将原路退还至您的账户中"];
[self invalidateCountDownTimer];
[self removeAnimation];
[self hide];
......@@ -256,7 +244,7 @@
- (GMWaitingSuccessView *)successView {
if (!_successView) {
_successView = [[GMWaitingSuccessView alloc] init];
[[GMBaseTool getCurrentViewController].view addSubview:_successView];
[AppDelegate.visibleController.view addSubview:_successView];
}
return _successView;
}
......
......@@ -7,7 +7,6 @@
//
#import "GMNoticeInfoObject.h"
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,12 +7,9 @@
//
#import "GMWaitingSuccessView.h"
#import "Gengmei-Swift.h"
#import "GMUserVideoTelephoneLogin.h"
#import "GMLibraryHeader.h"
//#import <GMBase/GMBase-Swift.h>
#import <GMBaseSwift/GMBaseSwift-Swift.h>
//@import GMBaseSwift
@import GMBaseSwift;
@interface GMWaitingSuccessView ()
{
NSTimer *_timer;
......@@ -43,21 +40,21 @@
self.doctorView.layer.masksToBounds = YES;
[self.container addSubview:self.doctorView];
self.nameLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
self.nameLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:16];
self.nameLabel.font = [UIFont gmBoldFont:16];
[self.container addSubview:self.nameLabel];
self.infoLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x8E8E8E) fontSize:12];
self.infoLabel = [GMLabel labelWithTextColor:ALColor8E8E8E fontSize:12];
[self.container addSubview:self.infoLabel];
self.hospitalLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
self.hospitalLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:16];
self.hospitalLabel.font = [UIFont gmBoldFont:16];
[self.container addSubview:self.hospitalLabel];
self.rateLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x8E8E8E) fontSize:12];
self.rateLabel = [GMLabel labelWithTextColor:ALColor8E8E8E fontSize:12];
[self.container addSubview:self.rateLabel];
self.projectLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:13];
self.projectLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:13];
self.projectLabel.text = @"擅长项目:";
[self.container addSubview:self.projectLabel];
......@@ -67,17 +64,17 @@
[self.container addSubview:self.iconView];
NSMutableAttributedString *attribute = [[NSMutableAttributedString alloc] initWithString:@"- 匹配成功 -"];
[attribute addAttribute:NSForegroundColorAttributeName value:RGBCOLOR_HEX(0x4ABAB4) range:NSMakeRange(0, 1)];
[attribute addAttribute:NSForegroundColorAttributeName value:RGBCOLOR_HEX(0x4ABAB4) range:NSMakeRange(7, 1)];
self.successLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:16];
[attribute addAttribute:NSForegroundColorAttributeName value:GMColor4ABAB4 range:NSMakeRange(0, 1)];
[attribute addAttribute:NSForegroundColorAttributeName value:GMColor4ABAB4 range:NSMakeRange(7, 1)];
self.successLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:16];
self.successLabel.textAlignment = NSTextAlignmentCenter;
self.successLabel.font = [UIFont gmBoldFont:16];
self.successLabel.attributedText = attribute;
[self.container addSubview:self.successLabel];
NSMutableAttributedString *attribute2 = [[NSMutableAttributedString alloc] initWithString:@"5S 后开启摄像头进行视频通话\n建议您选择安静、光线充足的环境"];
[attribute2 addAttribute:NSForegroundColorAttributeName value:RGBCOLOR_HEX(0x4ABAB4) range:NSMakeRange(0, 2)];
self.successInfoLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:14];
[attribute2 addAttribute:NSForegroundColorAttributeName value:GMColor4ABAB4 range:NSMakeRange(0, 2)];
self.successInfoLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:14];
self.successInfoLabel.textAlignment = NSTextAlignmentCenter;
self.successInfoLabel.numberOfLines = 0;
self.successInfoLabel.attributedText = attribute2;
......@@ -87,7 +84,7 @@
label.backgroundColor = RGBCOLOR_HEX(0xEEF8F7);
label.textAlignment = NSTextAlignmentCenter;
label.font = [UIFont gmFont:11];
label.textColor = RGBCOLOR_HEX(0x4DBBB5);
label.textColor = GMColor4DBBB5;
label.paddingEdge = UIEdgeInsetsMake(1, 11, 1, 11);
label.layer.cornerRadius = ONE_PIXEL + 1;
label.layer.masksToBounds = YES;
......@@ -156,13 +153,7 @@
selector:@selector(didBecomeActive)
name:UIApplicationDidBecomeActiveNotification object:nil];
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
- (void)didBecomeActive {
[self invalidateCountDownTimer];
[[NSNotificationCenter defaultCenter] removeObserver:self];
......@@ -187,22 +178,22 @@
NSMutableAttributedString *content = [[NSMutableAttributedString alloc] init];
// 0:不显示1: 好评率 + 接通率 2: 好评率 + 有效面诊人数
if (_object.showType == 1) {
NSAttributedString *subContentA = [[NSAttributedString alloc] initWithString:@"好评率:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x282828)}];
NSAttributedString *subContent = [[NSAttributedString alloc] initWithString:SafeString(_object.likeRate) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x7DC6CC)}];
NSAttributedString *subContentA = [[NSAttributedString alloc] initWithString:@"好评率:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor282828}];
NSAttributedString *subContent = [[NSAttributedString alloc] initWithString:SafeString(_object.likeRate) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor7DC6CC}];
NSAttributedString *subContentB = [[NSAttributedString alloc] initWithString:@" 接通率:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x282828)}];
NSAttributedString *subContentC = [[NSAttributedString alloc] initWithString:SafeString(_object.connectRate) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x7DC6CC)}];
NSAttributedString *subContentB = [[NSAttributedString alloc] initWithString:@" 接通率:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor282828}];
NSAttributedString *subContentC = [[NSAttributedString alloc] initWithString:SafeString(_object.connectRate) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor7DC6CC}];
[content appendAttributedString: subContentA];
[content appendAttributedString: subContent];
[content appendAttributedString: subContentB];
[content appendAttributedString: subContentC];
return content;
} else {
NSAttributedString *subContentA = [[NSAttributedString alloc] initWithString:@"好评率:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x282828)}];
NSAttributedString *subContent = [[NSAttributedString alloc] initWithString:SafeString(_object.likeRate) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x7DC6CC)}];
NSAttributedString *subContentA = [[NSAttributedString alloc] initWithString:@"好评率:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor282828}];
NSAttributedString *subContent = [[NSAttributedString alloc] initWithString:SafeString(_object.likeRate) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor7DC6CC}];
NSAttributedString *subContentB = [[NSAttributedString alloc] initWithString:@" 有效面诊:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x282828)}];
NSAttributedString *subContentC = [[NSAttributedString alloc] initWithString:SafeString(_object.consultPeopleNumber) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x7DC6CC)}];
NSAttributedString *subContentB = [[NSAttributedString alloc] initWithString:@" 有效面诊:" attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor282828}];
NSAttributedString *subContentC = [[NSAttributedString alloc] initWithString:SafeString(_object.consultPeopleNumber) attributes:@{NSFontAttributeName: [UIFont gmFont:12], NSForegroundColorAttributeName: GMColor7DC6CC}];
[content appendAttributedString: subContentA];
[content appendAttributedString: subContent];
[content appendAttributedString: subContentB];
......@@ -223,7 +214,7 @@
- (void)updateCountDown {
if (currentTime >= 0) {
NSMutableAttributedString *attribute = [[NSMutableAttributedString alloc] initWithString:[NSString stringWithFormat:@"%dS 后开启摄像头进行视频通话\n建议您选择安静、光线充足的环境", currentTime]];
[attribute addAttribute:NSForegroundColorAttributeName value:RGBCOLOR_HEX(0x4ABAB4) range:NSMakeRange(0, 2)];
[attribute addAttribute:NSForegroundColorAttributeName value:GMColor4ABAB4 range:NSMakeRange(0, 2)];
self.successInfoLabel.attributedText = attribute;
currentTime --;
} else {
......
......@@ -5,7 +5,6 @@
// Created by zhouLiang on 2020/2/22.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
// 从杜欣前端给传的数据 --- 投诉结果
@interface GMComplaintObject : GMObject
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -5,7 +5,6 @@
// Created by Locus on 2020/2/19.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,7 +7,6 @@
//
#import "GMEditQuesPartModel.h"
#import "GMLibraryHeader.h"
@implementation GMEditQuesPartDetailModel
......
......@@ -5,7 +5,6 @@
// Created by zhouLiang on 2020/2/22.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
@protocol GMStarInfoObject @end
@interface GMStarInfoObject : GMObject
......
......@@ -7,7 +7,6 @@
//
#import "GMDiagnosisWorkingTableSwitch.h"
@import GMBase;
@protocol GMWorkTableNotifyObject @end
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import <GMKit/GMPopupBgView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,10 +8,7 @@
#import "GMCommonTipAlertView.h"
#import "UIView+CornerRadius.h"
#import <GMBase/GMBaseTool.h>
@import GMBase;
@import GMFoundation;
@interface GMCommonTipAlertView()
@property(nonatomic, strong) GMLabel *title;
@property(nonatomic, strong) GMLabel *contentLabel;
......@@ -41,7 +38,7 @@ static GMCommonTipAlertView *_alertView = nil;
}];
_title = [[GMLabel alloc] init];
_title.textColor = RGBCOLOR_HEX(0x282828);
_title.textColor = GMColor282828;
_title.textAlignment = NSTextAlignmentCenter;
_title.font = [UIFont gmBoldFont:18];
[_title setContentHuggingPriority:UILayoutPriorityRequired forAxis:UILayoutConstraintAxisHorizontal];
......@@ -49,7 +46,7 @@ static GMCommonTipAlertView *_alertView = nil;
[_contentView addSubview:_title];
_contentLabel = [[GMLabel alloc] init];
_contentLabel.textColor = RGBCOLOR_HEX(0x282828);
_contentLabel.textColor = GMColor282828;
_contentLabel.textAlignment = NSTextAlignmentCenter;
_contentLabel.font = [UIFont gmFont:17];
_contentLabel.numberOfLines = 0;
......@@ -69,7 +66,7 @@ static GMCommonTipAlertView *_alertView = nil;
_leftBtn = [UIButton new];
_leftBtn.titleLabel.font = [UIFont gmFont:16];
[_leftBtn setTitleColor:RGBCOLOR_HEX(0x999999) forState:UIControlStateNormal];
[_leftBtn setTitleColor:ALColor999999 forState:UIControlStateNormal];
[_contentView addSubview:_leftBtn];
[_leftBtn mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(44);
......@@ -90,7 +87,7 @@ static GMCommonTipAlertView *_alertView = nil;
_rightBtn = [UIButton new];
_rightBtn.titleLabel.font = [UIFont gmFont:16];
[_rightBtn setTitleColor:RGBCOLOR_HEX(0x4ABAB4) forState:UIControlStateNormal];
[_rightBtn setTitleColor:GMColor4ABAB4 forState:UIControlStateNormal];
[_contentView addSubview:_rightBtn];
[_rightBtn mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(44);
......@@ -153,7 +150,7 @@ static GMCommonTipAlertView *_alertView = nil;
[_alertView.rightBtn addTarget:target action:rightAction forControlEvents:UIControlEventTouchUpInside];
[_alertView.leftBtn addTarget:target action:leftAction forControlEvents:UIControlEventTouchUpInside];
[_alertView updateConstraints];
[[GMBaseTool getCurrentViewController].view addSubview:_alertView];
[AppDelegate.navigation.view addSubview:_alertView];
}
+(void)hideAtertView {
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMComplaintObject.h"
#import <GMKit/GMView.h>
typedef NS_ENUM(NSInteger, GMComplaintResultViewType) {
/// 投诉审核中
......
......@@ -9,8 +9,7 @@
#import "GMComplaintResultView.h"
#import "NSAttributedString+YYText.h"
#import "YYLabel.h"
@import GMRouter;
//#import "GMCustomerServiceDetailViewController.h"
#import "GMCustomerServiceDetailViewController.h"
@interface GMComplaintResultCellView : UIView
@property (nonatomic, strong) GMLabel *titleLabel;
......@@ -64,7 +63,7 @@
}
- (GMLabel *)titleLabel {
if (!_titleLabel) {
_titleLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x666666) fontSize:14];
_titleLabel = [GMLabel labelWithTextColor:ALColor666666 fontSize:14];
_titleLabel.font = [UIFont gmBoldFont:14];
_titleLabel.textAlignment = NSTextAlignmentLeft;
}
......@@ -72,14 +71,14 @@
}
- (GMLabel *)rightLabel {
if (!_rightLabel) {
_rightLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x999999) fontSize:11];
_rightLabel = [GMLabel labelWithTextColor:ALColor999999 fontSize:11];
_rightLabel.textAlignment = NSTextAlignmentRight;
}
return _rightLabel;
}
- (GMLabel *)contentLabel {
if (!_contentLabel) {
_contentLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x666666) fontSize:13];
_contentLabel = [GMLabel labelWithTextColor:ALColor666666 fontSize:13];
_contentLabel.numberOfLines = 0;
}
return _contentLabel;
......@@ -114,13 +113,6 @@
}
return self;
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
- (void)setup {
[super setup];
[self setUI];
......@@ -184,14 +176,14 @@
if (self.type == GMComplaintResultViewTypeInAudit) {
self.resultCell.rightLabel.text = @"审核处理中";
self.resultCell.rightLabel.textColor = RGBCOLOR_HEX(0xFF2F4F);
self.resultCell.rightLabel.textColor = GMColorFF2F4F;
}
self.titleLabel.text = self.textArray[self.type];
}
- (UIView *)grayLineView {
if (!_grayLineView) {
_grayLineView = [[UIView alloc] init];
_grayLineView.backgroundColor = RGBCOLOR_HEX(0xEEEEEE);
_grayLineView.backgroundColor = GMColorEEEEEE;
_grayLineView.layer.cornerRadius = 2.5f;
_grayLineView.layer.masksToBounds = YES;
}
......@@ -238,7 +230,7 @@
if (!_callPhoneLabel) {
NSMutableAttributedString *text = [[NSMutableAttributedString alloc] initWithString:@"如你对处理结果有异议,可联系客服"];
text.yy_font = [UIFont gmFont:11];
text.yy_color = RGBCOLOR_HEX(0x999999);
text.yy_color = ALColor999999;
[text yy_setUnderlineStyle:NSUnderlineStyleSingle range:NSMakeRange(12, 4)];
[text yy_setUnderlineColor:[UIColor colorWithHex:0x4DBBB5] range:NSMakeRange(12, 4)];
[text yy_setTextHighlightRange:NSMakeRange(12, 4) color:[UIColor colorWithHex:0x4DBBB5] backgroundColor:[UIColor clearColor] tapAction:^(UIView * _Nonnull containerView, NSAttributedString * _Nonnull text, NSRange range, CGRect rect) {
......@@ -254,7 +246,7 @@
- (UIView *)lineView {
if (!_lineView) {
_lineView = [[UIView alloc] init];
_lineView.backgroundColor = RGBCOLOR_HEX(0xF8F8F8);
_lineView.backgroundColor = ALColorF8F8F8;
}
return _lineView;
}
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import <GMKit/GMView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -7,7 +7,6 @@
//
#import "GMDiagnosisDispatchInfoView.h"
@import GMBase;
@implementation GMDiagnosisDispatchInfoView
- (void)setup {
......@@ -24,7 +23,7 @@
_locationLabel = [[UILabel alloc] init];
_locationLabel.text = @"北京";
_locationLabel.textColor = RGBCOLOR_HEX(0x282828);
_locationLabel.textColor = ALColor282828;
_locationLabel.font = [UIFont gmBoldFont:14];
[self addSubview:_locationLabel];
[_locationLabel mas_makeConstraints:^(MASConstraintMaker *make) {
......@@ -35,7 +34,7 @@
_infoLabel = [[UILabel alloc] init];
_infoLabel.text = @"女,22岁,没做过医美";
_infoLabel.textColor = RGBCOLOR_HEX(0x282828);
_infoLabel.textColor = ALColor282828;
_infoLabel.textAlignment = NSTextAlignmentCenter;
_infoLabel.font = [UIFont gmBoldFont:14];
[self addSubview:_infoLabel];
......@@ -47,7 +46,7 @@
_projectLabel = [[UILabel alloc] init];
_projectLabel.text = @"咨询项目:皮肤美容 | 面部轮廓 | 眼部";
_projectLabel.textColor = RGBCOLOR_HEX(0x282828);
_projectLabel.textColor = ALColor282828;
_projectLabel.font = [UIFont gmFont:13];
[self addSubview:_projectLabel];
[_projectLabel mas_makeConstraints:^(MASConstraintMaker *make) {
......
......@@ -5,7 +5,7 @@
// Created by Jessica on 2020/2/19.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMKit;
@protocol GMDiagnosisWorkingTableChooseIdentityViewDelegate <NSObject>
// 点击
-(void)openWorkTableDidclickedWithTags:(NSArray *)tags;
......
......@@ -8,12 +8,9 @@
#import "GMDiagnosisWorkingTableChooseIdentityView.h"
#import "UIView+CornerRadius.h"
#import "YYText.h"
#import <YYText.h>
#import "NSString+CalculateSize.h"
#import "WMTagObject.h"
#import <GMBase/GMBaseTool.h>
@import GMHud;
@import GMRouter;
@implementation GMChooseIdentityTagCell
- (void)setup {
......@@ -22,7 +19,7 @@
_contentBtn.userInteractionEnabled = NO;
[_contentBtn setImage:[UIImage imageNamed:@"wt_good_unselected_icon"] forState:UIControlStateNormal];
[_contentBtn setImage:[UIImage imageNamed:@"wt_good_selected_icon"] forState:UIControlStateSelected];
[_contentBtn setTitleColor:RGBCOLOR_HEX(0x282828) forState:UIControlStateNormal];
[_contentBtn setTitleColor:GMColor282828 forState:UIControlStateNormal];
_contentBtn.titleEdgeInsets = UIEdgeInsetsMake(0, 6, 0, 0);
_contentBtn.contentEdgeInsets = UIEdgeInsetsMake(6, 12, 6, 12);
_contentBtn.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
......@@ -60,7 +57,7 @@
}];
_identityBtn = [GMButton new];
[_identityBtn setTitleColor:RGBCOLOR_HEX(0x282828) forState:UIControlStateNormal];
[_identityBtn setTitleColor:ALColor282828 forState:UIControlStateNormal];
_identityBtn.titleLabel.font = [UIFont gmBoldFont:16];
[_identityBtn setImage:[UIImage imageNamed:@"wt_identity"] forState:UIControlStateNormal];
[_identityBtn setImage:[UIImage imageNamed:@"wt_identity_selected"] forState:UIControlStateSelected];
......@@ -125,7 +122,7 @@
[_openBtn setTitle:@"开启面诊" forState:UIControlStateNormal];
_openBtn.titleLabel.font = [UIFont gmBoldFont:16];
_openBtn.userInteractionEnabled = NO;
[_openBtn setBackgroundColor:RGBCOLOR_HEX(0xFF8C8D) forState:UIControlStateNormal];
[_openBtn setBackgroundColor:GMColorFF8C8D forState:UIControlStateNormal];
[self.container addSubview:_openBtn];
[_openBtn mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(45);
......@@ -154,7 +151,7 @@
_projectLabel = [[UILabel alloc] init];
_projectLabel.text = @"擅长的项目(最多3个)";
_projectLabel.textColor = RGBCOLOR_HEX(0x282828);
_projectLabel.textColor = ALColor282828;
_projectLabel.textAlignment = NSTextAlignmentCenter;
_projectLabel.font = [UIFont gmBoldFont:16];
[self.contentView addSubview:_projectLabel];
......@@ -175,7 +172,7 @@
_tipLabel = [[UILabel alloc] init];
_tipLabel.text = @"温馨提示:";
_tipLabel.textColor = RGBCOLOR_HEX(0x282828);
_tipLabel.textColor = ALColor282828;
_tipLabel.textAlignment = NSTextAlignmentLeft;
_tipLabel.font = [UIFont gmBoldFont:11];
[self.contentView addSubview:_tipLabel];
......@@ -196,10 +193,10 @@
NSMutableAttributedString *attribute = [[NSMutableAttributedString alloc] initWithString:content];
attribute.yy_lineSpacing = 6;
attribute.yy_font = [UIFont gmFont:11];
attribute.yy_color = RGBCOLOR_HEX(0x282828);
[attribute yy_setTextHighlightRange:privateRange color:RGBCOLOR_HEX(0xFF8C8D) backgroundColor:UIColor.whiteColor tapAction:^(UIView * _Nonnull containerView, NSAttributedString * _Nonnull text, NSRange range, CGRect rect) {
attribute.yy_color = ALColor282828;
[attribute yy_setTextHighlightRange:privateRange color:GMColorFF8C8D backgroundColor:UIColor.whiteColor tapAction:^(UIView * _Nonnull containerView, NSAttributedString * _Nonnull text, NSRange range, CGRect rect) {
// 视频面诊使用管理条例
NSString *url = @"gengmei://common_webview?url=https://backend.igengmei.com/phantom/about/treatment_agreement";
NSString *url = [NSString stringWithFormat:@"gengmei://common_webview?url=%@/phantom/about/treatment_agreement", GMServerDomains.apiHost];
[[GMRouter sharedInstance] pushScheme:url];
}];
self.contentLabel.attributedText = attribute;
......@@ -223,10 +220,10 @@
- (void)isCanOpen {
if (_tagIds.count == 0) {
_openBtn.userInteractionEnabled = NO;
[_openBtn setBackgroundColor:RGBCOLOR_HEX(0xD5D5D5) forState:UIControlStateNormal];
[_openBtn setBackgroundColor:GMColorD5D5D5 forState:UIControlStateNormal];
} else {
_openBtn.userInteractionEnabled = YES;
[_openBtn setBackgroundColor:RGBCOLOR_HEX(0xFF8C8D) forState:UIControlStateNormal];
[_openBtn setBackgroundColor:GMColorFF8C8D forState:UIControlStateNormal];
}
}
......@@ -315,7 +312,7 @@
[_tagIds removeObject:@(tagObject.tagId)];
}
} else if (!tagObject.isSelected && _tagIds.count >= 3 ) {
[[GMBaseTool getCurrentViewController] toast:@"最多选择三个"];
[AppDelegate.visibleController toast:@"最多选择三个"];
}
[cell updateStatus:tagObject.isSelected];
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMWorkTableObject.h"
#import <GMKit/GMView.h>
@interface GMServiceDataItemView : GMView
@property(nonatomic, strong)UILabel *dataLabel;
......
......@@ -9,10 +9,8 @@
#import "GMDiagnosisWorkingTableHeaderView.h"
#import "GMWoikingTableCollectionCell.h"
#import "GMGMDiagnosisWorkingTableScrollView.h"
#import "RequestHeader.h"
#import "GMLibraryHeader.h"
//#import "WMBrowserViewController.h"
@import GMRouter;
#import "WMBrowserViewController.h"
@interface GMServiceDataItemView()
@property (nonatomic, strong) UILabel *line;
@end
......@@ -21,7 +19,7 @@
- (void)setup {
[super setup];
_dataLabel = [[UILabel alloc] init];
_dataLabel.textColor = RGBCOLOR_HEX(0x282828);
_dataLabel.textColor = ALColor282828;
_dataLabel.textAlignment = NSTextAlignmentCenter;
_dataLabel.font = [UIFont gmBoldFont:21];
[self addSubview:_dataLabel];
......@@ -32,7 +30,7 @@
}];
_descLabel = [[UILabel alloc] init];
_descLabel.textColor = RGBCOLOR_HEX(0x909399);
_descLabel.textColor = GMColor909399;
_descLabel.textAlignment = NSTextAlignmentCenter;
_descLabel.font = [UIFont gmFont:11];
[self addSubview:_descLabel];
......@@ -43,7 +41,7 @@
}];
_line = [[UILabel alloc] init];
_line.backgroundColor = RGBCOLOR_HEX(0xEEEEEE);
_line.backgroundColor = GMColorEEEEEE;
[self addSubview:_line];
[_line mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.mas_equalTo(self.mas_centerY);
......@@ -94,7 +92,7 @@
_dataDesc = [[UILabel alloc] init];
_dataDesc.text = @"服务数据";
_dataDesc.textColor = RGBCOLOR_HEX(0x282828);
_dataDesc.textColor = ALColor282828;
_dataDesc.textAlignment = NSTextAlignmentCenter;
_dataDesc.font = [UIFont gmBoldFont:16];
[self addSubview:_dataDesc];
......@@ -107,7 +105,7 @@
_desc = [[UILabel alloc] init];
_desc.text = @"(当天)";
_desc.textColor = RGBCOLOR_HEX(0x909399);
_desc.textColor = GMColor909399;
_desc.textAlignment = NSTextAlignmentCenter;
_desc.font = [UIFont gmFont:14];
[self addSubview:_desc];
......@@ -130,7 +128,7 @@
_desc1 = [[UILabel alloc] init];
_desc1.text = @"明细";
_desc1.textColor = RGBCOLOR_HEX(0x909399);
_desc1.textColor = GMColor909399;
_desc1.textAlignment = NSTextAlignmentRight;
_desc1.font = [UIFont gmFont:14];
[self addSubview:_desc1];
......@@ -179,7 +177,7 @@
_bottomLabel = [[UILabel alloc] init];
_bottomLabel.text = @"公告区";
_bottomLabel.textColor = RGBCOLOR_HEX(0x909399);
_bottomLabel.textColor = GMColor909399;
_bottomLabel.textAlignment = NSTextAlignmentCenter;
_bottomLabel.font = [UIFont gmBoldFont:12];
[self addSubview:_bottomLabel];
......@@ -191,7 +189,7 @@
}];
_leftLine = [[UILabel alloc] init];
_leftLine.backgroundColor = RGBCOLOR_HEX(0xEEEEEE);
_leftLine.backgroundColor = GMColorEEEEEE;
[self addSubview:_leftLine];
[_leftLine mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.mas_equalTo(_bottomLabel.mas_centerY);
......@@ -201,7 +199,7 @@
}];
_rightLine = [[UILabel alloc] init];
_rightLine.backgroundColor = RGBCOLOR_HEX(0xEEEEEE);
_rightLine.backgroundColor = GMColorEEEEEE;
[self addSubview:_rightLine];
[_rightLine mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.mas_equalTo(_bottomLabel.mas_centerY);
......@@ -313,10 +311,10 @@
- (NSMutableAttributedString *)scrollItemStr:(NSString *)string leftStr:(NSString *)leftStr rightStr:(NSString *)rightStr {
NSMutableAttributedString *content = [[NSMutableAttributedString alloc] init];
NSAttributedString *subContentA = [[NSAttributedString alloc] initWithString:leftStr attributes:@{NSFontAttributeName: [UIFont gmBoldFont:15], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x282828)}];
NSAttributedString *subContent = [[NSAttributedString alloc] initWithString:string attributes:@{NSFontAttributeName: [UIFont gmBoldFont:15], NSForegroundColorAttributeName: RGBCOLOR_HEX(0xFF8C8D)}];
NSAttributedString *subContentA = [[NSAttributedString alloc] initWithString:leftStr attributes:@{NSFontAttributeName: [UIFont gmBoldFont:15], NSForegroundColorAttributeName: GMColor282828}];
NSAttributedString *subContent = [[NSAttributedString alloc] initWithString:string attributes:@{NSFontAttributeName: [UIFont gmBoldFont:15], NSForegroundColorAttributeName: GMColorFF8C8D}];
NSAttributedString *subContentB = [[NSAttributedString alloc] initWithString:rightStr attributes:@{NSFontAttributeName: [UIFont gmBoldFont:15], NSForegroundColorAttributeName: RGBCOLOR_HEX(0x282828)}];
NSAttributedString *subContentB = [[NSAttributedString alloc] initWithString:rightStr attributes:@{NSFontAttributeName: [UIFont gmBoldFont:15], NSForegroundColorAttributeName: GMColor282828}];
[content appendAttributedString: subContentA];
[content appendAttributedString: subContent];
[content appendAttributedString: subContentB];
......
......@@ -5,7 +5,6 @@
// Created by Jessica on 2020/2/19.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
typedef NS_ENUM(NSInteger, DiagnosisWorkingTableSwitchStatus) {
DiagnosisWorkingTableSwitchStatusOff = 1,// 关闭 (可以开启)
......
......@@ -7,7 +7,7 @@
//
#import "GMDoctorConsultatioPromptView.h"
@import GMBase;
@implementation GMDoctorConsultatioPromptView
- (instancetype)initWithFrame:(CGRect)frame
......
......@@ -7,7 +7,7 @@
//
#import "GMEditQuesPartModel.h"
#import "GMLibraryHeader.h"
NS_ASSUME_NONNULL_BEGIN
@interface GMEditQuesPartCell : GMTableViewCell
......
......@@ -7,7 +7,6 @@
//
#import "GMEditQuesPartModel.h"
#import <GMKit/GMView.h>
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,8 +8,6 @@
#import "GMEditQuesPartSelectView.h"
#import "GMEditQuesPartController.h"
#import <GMBase/GMBaseTool.h>
@interface GMEditQuesPartSelectCell : GMTableViewCell
......@@ -123,7 +121,7 @@
[_selectArray addObject:cell.model];
cell.selectButton.selected = YES;
} else {
[[GMBaseTool getCurrentViewController] toast:@"最多选3个"];
[AppDelegate.visibleController toast:@"最多选3个"];
}
}
}
......@@ -246,7 +244,7 @@
if (!_confirmButton) {
_confirmButton = [GMButton buttonWithType:UIButtonTypeCustom];
[_confirmButton setTitle:@"确定" forState:UIControlStateNormal];
[_confirmButton setTitleColor:RGBCOLOR_HEX(0xFF8C8D) forState:UIControlStateNormal];
[_confirmButton setTitleColor:GMColorFF8C8D forState:UIControlStateNormal];
[_confirmButton addTarget:self action:@selector(confirmButtonClick) forControlEvents:UIControlEventTouchUpInside];
_confirmButton.titleLabel.font = [UIFont gmFont:14];
}
......
......@@ -5,7 +5,7 @@
// Created by Locus on 2020/2/19.
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "GMLibraryHeader.h"
NS_ASSUME_NONNULL_BEGIN
@interface GMEditQuesSuggestCell : GMTableViewCell
......
......@@ -7,7 +7,6 @@
//
#import "GMStarWithContentObject.h"
@import GMBase;
NS_ASSUME_NONNULL_BEGIN
......
......@@ -8,13 +8,6 @@
#import "GMEndConsultView.h"
#import "GMEditQuesPartController.h"
#import "RequestHeader.h"
#import "GMToFaceNetworking.h"
#import <GMBase/GMBaseTool.h>
@import GMNetworking;
@import MBProgressHUD;
@interface GMEndConsultView () <UITextViewDelegate>
......@@ -54,13 +47,6 @@
[self setLayout];
[self containerRectCorner:self.container];
}
- (void)containerRectCorner:(UIView *)view {
UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:view.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(12, 12)];
CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
maskLayer.frame = view.bounds;
maskLayer.path = maskPath.CGPath;
view.layer.mask = maskLayer;
}
- (void)setUI {
self.animationType = GMPopupAnimationTypeFlipFromBottom;
[self.container addSubview:self.grayLineView];
......@@ -289,10 +275,10 @@
weakSelf.evaluateFinish(1, 0, @"");
}
if (weakSelf.complaintType == GMComplaintTypeUser) {
[GMHudModule toastInView:[GMBaseTool mainWindow] text:@"投诉意见提交成功"];
[GMHudModule toastInView:[AppDelegate shareInstance].window text:@"投诉意见提交成功"];
}
}else {
[GMHudModule toastInView:[GMBaseTool mainWindow] text:response.message];
[GMHudModule toastInView:[AppDelegate shareInstance].window text:response.message];
}
}];
}
......@@ -301,32 +287,32 @@
[self showLoading];
__weak __typeof(self)weakSelf = self;
if (self.starNum <= 0) {
[GMHudModule toastInView:[GMBaseTool mainWindow] text:@"请选择1-5星进行评价"];
[GMHudModule toastInView:[AppDelegate shareInstance].window text:@"请选择1-5星进行评价"];
return;
}
[[GMToFaceNetworking shareInstance] excuteToFaceEvaluateDiagnosis_id:self.recordId star:self.starNum SuccessBlock:^(id response) {
[[GMInterfaceNetwork shareInstance] excuteToFaceEvaluateDiagnosis_id:self.recordId star:self.starNum SuccessBlock:^(id response) {
if (weakSelf.evaluateFinish && weakSelf.starNum>=1) {
GMStarInfoObject *object = weakSelf.starContentArray[weakSelf.starNum - 1];
weakSelf.evaluateFinish(0, weakSelf.starNum, object.descrip);
}
[weakSelf hideLoading];
[weakSelf hide];
[GMHudModule toastInView:[GMBaseTool mainWindow] text:@"感谢您的评价~"];
[GMHudModule toastInView:[AppDelegate shareInstance].window text:@"感谢您的评价~"];
} failureBlock:^(NSInteger errorCode, NSString *message) {
[weakSelf hideLoading];
[weakSelf hide];
[GMHudModule toastInView:[GMBaseTool mainWindow] text:message];
[GMHudModule toastInView:[AppDelegate shareInstance].window text:message];
}];
}
- (void)confirmButtonClick {
if (self.type == GMEndConsultViewTypeReport) {
GMEditQuesPartController *vc = [GMEditQuesPartController new];
vc.viewModel.recordId = self.recordId;
[[GMBaseTool getNavigation] pushViewController:vc animated:YES];
[AppDelegate.navigation pushViewController:vc animated:YES];
[self hide];
} else if (self.type == GMEndConsultViewTypeDoctorComplaint || self.type == GMEndConsultViewTypeUserComplaint) {
if (self.textView.text.length < 10) {
[[GMBaseTool getCurrentViewController] toast:@"请填写您的投诉原因,至少10个字"];
[AppDelegate.visibleController toast:@"请填写您的投诉原因,至少10个字"];
} else {
[self complaint];
}
......@@ -379,7 +365,7 @@
- (UIView *)grayLineView {
if (!_grayLineView) {
_grayLineView = [[UIView alloc] init];
_grayLineView.backgroundColor = RGBCOLOR_HEX(0xEEEEEE);
_grayLineView.backgroundColor = GMColorEEEEEE;
_grayLineView.layer.cornerRadius = 2.5f;
_grayLineView.layer.masksToBounds = YES;
}
......@@ -401,7 +387,7 @@
_confirmButton.titleLabel.font = [UIFont gmBoldFont:17];
[_confirmButton setTitle:@"保存" forState:UIControlStateNormal];
[_confirmButton setTitleColor:UIColor.whiteColor forState:UIControlStateNormal];
[_confirmButton setBackgroundColor:RGBCOLOR_HEX(0xFF8C8D) forState:UIControlStateNormal];
[_confirmButton setBackgroundColor:GMColorFF8C8D forState:UIControlStateNormal];
[_confirmButton addTarget:self action:@selector(confirmButtonClick) forControlEvents:UIControlEventTouchUpInside];
}
return _confirmButton;
......@@ -433,7 +419,7 @@
_complaintUserButton = [GMButton buttonWithType:UIButtonTypeCustom];
_complaintUserButton.titleLabel.font = [UIFont gmFont:13];
[_complaintUserButton setTitle:@"我要投诉>" forState:UIControlStateNormal];
[_complaintUserButton setTitleColor:RGBCOLOR_HEX(0xFF8C8D) forState:UIControlStateNormal];
[_complaintUserButton setTitleColor:GMColorFF8C8D forState:UIControlStateNormal];
[_complaintUserButton addTarget:self action:@selector(complaintUserButtonClick) forControlEvents:UIControlEventTouchUpInside];
}
return _complaintUserButton;
......@@ -477,14 +463,14 @@
}
- (GMLabel *)bottomLabel {
if (!_bottomLabel) {
_bottomLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:14];
_bottomLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:14];
_bottomLabel.textAlignment = NSTextAlignmentCenter;
}
return _bottomLabel;
}
- (GMLabel *)tipLabel {
if (!_tipLabel) {
_tipLabel = [GMLabel labelWithTextColor:RGBCOLOR_HEX(0x282828) fontSize:11];
_tipLabel = [GMLabel labelWithTextColor:GMColor282828 fontSize:11];
_tipLabel.text = @"请详细填写您需要申诉的问题,审核通过后将会为您安排退款";
}
return _tipLabel;
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
@import GMBase;
@protocol GMGMDiagnosisWorkingTableScrollViewDelegate <NSObject>
//0:数据明细 1:提示view
......
......@@ -7,12 +7,9 @@
//
#import "GMGMDiagnosisWorkingTableScrollView.h"
#import "GMTelephoneProxy.h"
#import "GMWeakProxy.h"
#import "GMMissUsersTipView.h"
#import "GMTelephoneProxy.h"
#import <GMBase/GMBaseTool.h>
@import MJRefresh;
#define kTop 21
@implementation GMScrollItemView
......@@ -126,7 +123,7 @@
} else {
[self invalidateTimer]; // 暂停滚动
// 弹出提示气泡
[[GMBaseTool getCurrentViewController].view addSubview:self.tipView];
[AppDelegate.navigation.view addSubview:self.tipView];
}
}
}
......@@ -167,7 +164,7 @@
[self invalidateTimer];
}
self.timer = [NSTimer timerWithTimeInterval:5.f target:[GMTelephoneProxy proxyWithTarget:self] selector:@selector(updateScrolling) userInfo:nil repeats:YES];
self.timer = [NSTimer timerWithTimeInterval:5.f target:[GMWeakProxy proxyWithTarget:self] selector:@selector(updateScrolling) userInfo:nil repeats:YES];
[[NSRunLoop mainRunLoop] addTimer:self.timer forMode:NSDefaultRunLoopMode];
}
......@@ -192,6 +189,7 @@
}
-(void)dealloc{
debugLog(@"%s", __func__);
[self invalidateTimer];
}
......
......@@ -6,7 +6,6 @@
// Copyright © 2020 更美互动信息科技有限公司. All rights reserved.
//
#import "Lottie.h"
#import "GMLibraryHeader.h"
@interface GMGrabLoadingAnimaitionView : GMView
@property (nonatomic, strong) LOTAnimationView *animationView;
......
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