Commit 6ba39a01 authored by 朱璇's avatar 朱璇

评价弹窗显示规则修改

parent 527ea1bb
......@@ -15,6 +15,8 @@
@property (nonatomic, strong) GMToFaceOrderInfoModel *infoModel;
/// 面诊订单列表页可以关闭界面,面诊结束弹起的界面不可以
@property (nonatomic, assign) BOOL isCloseBtnHidden;
@property (nonatomic, assign) BOOL isNotShowStarView; // 接通<=30s不弹评价弹窗
/**
* 确认订单完成(评价或者投诉也操作过),回传给h5,更改订单列表该订单的状态
* 目前只有面诊订单列表才用到此回调
......
......@@ -224,32 +224,37 @@
}
#pragma mark - 星级评价弹框
- (void)starMethod {
//是面诊师直接弹评价弹框
__weak typeof(self) weakSelf = self;
[[GMToFaceNetworking 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];
//投诉弹框右上角的×的点击,原因是订单列表会用到这个值,目的是回传给h5改订单列表的状态
view.hideFinish = ^{
if (weakSelf.completeCallBack) {
weakSelf.completeCallBack(0, @"", 0);
}
};
//星级评价,原因是订单列表会用到这个值,目的是回传给h5改订单列表的状态
view.evaluateFinish = ^(NSInteger type, NSInteger starNum, NSString * _Nonnull evaluateStr) {
[self hide];
if (type == 0) {
//type = 0 是填写评价,所以只有这种情况才是需要回传给h5
if (self.isNotShowStarView) {
[weakSelf hide];
} else {
GMStarWithContentObject *starContentModel = [[GMStarWithContentObject alloc] initWithDictionary:response error:nil];
GMEndConsultView *view = [[GMEndConsultView alloc] initWithType:(GMEndConsultViewTypeGrayStar) starNum:0];
[weakSelf hide];
//投诉弹框右上角的×的点击,原因是订单列表会用到这个值,目的是回传给h5改订单列表的状态
view.hideFinish = ^{
if (weakSelf.completeCallBack) {
weakSelf.completeCallBack(2, evaluateStr, starNum);
weakSelf.completeCallBack(0, @"", 0);
}
}
};
view.showComplaint = NO;
view.recordId = self.infoModel.consultationRecordId;
view.starContentArray = starContentModel.evaluates;
[[GMBaseTool getCurrentViewController].view addSubview:view];
};
//星级评价,原因是订单列表会用到这个值,目的是回传给h5改订单列表的状态
view.evaluateFinish = ^(NSInteger type, NSInteger starNum, NSString * _Nonnull evaluateStr) {
[self hide];
if (type == 0) {
//type = 0 是填写评价,所以只有这种情况才是需要回传给h5
if (weakSelf.completeCallBack) {
weakSelf.completeCallBack(2, evaluateStr, starNum);
}
}
};
view.showComplaint = NO;
view.recordId = self.infoModel.consultationRecordId;
view.starContentArray = starContentModel.evaluates;
[[GMBaseTool getCurrentViewController].view addSubview:view];
}
} failureBlock:^(NSInteger errorCode, NSString *message) {
[self hide];
}];
......
......@@ -273,6 +273,7 @@ static GMUserVideoTelephoneLogin *loginManager = nil;
GMToFaceOrderInfoModel *infoModel = [[GMToFaceOrderInfoModel alloc] initWithDictionary:response error:nil];
infoModel.consultationRecordId = TTManager.consultationRecordId;
GMSureOrderPopView *popView = [[GMSureOrderPopView alloc] init];
popView.isNotShowStarView = TTManager.totalTime <= 30; // 视频面诊接通<=30s 不弹出评价弹窗
popView.isCloseBtnHidden = YES;
popView.infoModel = infoModel;
[popView clickConfireBtnPhobo:counsellorType consultationType:consultationType doctorId:doctorId];
......
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