Commit a4dd6aae authored by 曹云霄's avatar 曹云霄

修改项说明:优化无促销情况不主动提示支付

parent dd372597
...@@ -246,9 +246,9 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -246,9 +246,9 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
goodsModel.goods = goods; goodsModel.goods = goods;
goodsModel.isSelected = YES; goodsModel.isSelected = YES;
[weakSelf.promotionalArray addObject:goodsModel]; [weakSelf.promotionalArray addObject:goodsModel];
}
} else if (![BaseViewController isBlankString:[oldPromotion.promotionMoney stringValue]]) {
/// 促销金额 /// 促销金额
if (![BaseViewController isBlankString:[oldPromotion.promotionMoney stringValue]]) {
if (![weakSelf.sectionTitle containsObject:PROMOTIONALSTRING]) { if (![weakSelf.sectionTitle containsObject:PROMOTIONALSTRING]) {
[weakSelf.sectionTitle addObject:PROMOTIONALSTRING]; [weakSelf.sectionTitle addObject:PROMOTIONALSTRING];
} }
...@@ -257,6 +257,14 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -257,6 +257,14 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
deductionModel.isSelected = YES; deductionModel.isSelected = YES;
deductionModel.type = @"deductionAction"; deductionModel.type = @"deductionAction";
[weakSelf.promotionalArray addObject:deductionModel]; [weakSelf.promotionalArray addObject:deductionModel];
}else if (![BaseViewController isBlankString:[oldPromotion.jdecardDenomation stringValue]]) {
/// 判断京东E卡
PromotionalDeductionModel *model = [[PromotionalDeductionModel alloc]init];
model.total = [oldPromotion.jdecardDenomation integerValue];
model.body = GUIDE;
model.type = JDECardAction;
[weakSelf.luckyDrawAndJDECardArray addObject:model];
} }
} }
} }
...@@ -285,7 +293,6 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -285,7 +293,6 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
page.page = ZERO; page.page = ZERO;
page.rows = ONE; page.rows = ONE;
queryDrawState.page = page; queryDrawState.page = page;
NSLog(@"%@",[queryDrawState toDictionary]);
[[NetworkRequestClassManager Manager] NetworkRequestWithURL:SERVERREQUESTURL(LOTTERYED) WithCallClass:weakSelf WithRequestType:ZERO WithParameter:queryDrawState WithReturnValueBlock:^(id returnValue) { [[NetworkRequestClassManager Manager] NetworkRequestWithURL:SERVERREQUESTURL(LOTTERYED) WithCallClass:weakSelf WithRequestType:ZERO WithParameter:queryDrawState WithReturnValueBlock:^(id returnValue) {
dispatch_group_leave(group); dispatch_group_leave(group);
if ([returnValue[@"code"] isEqualToNumber:@0]) { if ([returnValue[@"code"] isEqualToNumber:@0]) {
...@@ -319,11 +326,14 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -319,11 +326,14 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
} }
/// 默认弹出支付框 /// 默认弹出支付框
if (weakSelf.isShowPayButton && [weakSelf.orderDetails.order.orderState isEqualToString:NOTPAY]) { if (weakSelf.isShowPayButton && [weakSelf.orderDetails.order.orderState isEqualToString:NOTPAY]) {
if (weakSelf.luckyDrawAndJDECardArray.count && !resultModel) { for (id object in weakSelf.luckyDrawAndJDECardArray) {
[weakSelf queryConsumerLuckyDrawChance]; if ([object isKindOfClass:[LuckyDrawModel class]] && !resultModel) {
[weakSelf queryConsumerLuckyDrawChance:object];
}else { }else {
[weakSelf payButtonClickAction]; [weakSelf payButtonClickAction];
} }
break;
}
} }
if (finish) { if (finish) {
finish(); finish();
...@@ -442,13 +452,9 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -442,13 +452,9 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
} }
#pragma mark - 查询客户抽奖机会 #pragma mark - 查询客户抽奖机会
- (void)queryConsumerLuckyDrawChance - (void)queryConsumerLuckyDrawChance:(LuckyDrawModel *)model
{ {
WS(weakSelf); WS(weakSelf);
/// 查询是否有客户抽奖机会
for (id object in self.luckyDrawAndJDECardArray) {
if ([object isKindOfClass:[LuckyDrawModel class]]) {
LuckyDrawModel *model = (LuckyDrawModel *)object;
if ([model.body isEqualToString:CONSUMER]) { if ([model.body isEqualToString:CONSUMER]) {
UIAlertController *alertControl = [UIAlertController alertControllerWithTitle:nil message:@"恭喜您获得一次大转盘抽奖机会!" preferredStyle:UIAlertControllerStyleAlert]; UIAlertController *alertControl = [UIAlertController alertControllerWithTitle:nil message:@"恭喜您获得一次大转盘抽奖机会!" preferredStyle:UIAlertControllerStyleAlert];
[alertControl addAction:[UIAlertAction actionWithTitle:@"马上参与" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) { [alertControl addAction:[UIAlertAction actionWithTitle:@"马上参与" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
...@@ -470,8 +476,6 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -470,8 +476,6 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
}]]; }]];
[self presentViewController:alertControl animated:YES completion:nil]; [self presentViewController:alertControl animated:YES completion:nil];
} }
}
}
} }
#pragma mark - 查询导购抽奖机会 #pragma mark - 查询导购抽奖机会
...@@ -519,7 +523,7 @@ NSString *const PROMOTIONALSTRING = @"促销信息"; ...@@ -519,7 +523,7 @@ NSString *const PROMOTIONALSTRING = @"促销信息";
/// 刷新数据成功 /// 刷新数据成功
[weakSelf getOrderDetailsData:^{ [weakSelf getOrderDetailsData:^{
/// 先判断促销中有无E卡,有则认为发放成功 /// 先判断促销中有无E卡,有则认为发放成功
for (id object in self.luckyDrawAndJDECardArray) { for (id object in weakSelf.luckyDrawAndJDECardArray) {
if ([object isKindOfClass:[PromotionalDeductionModel class]]) { if ([object isKindOfClass:[PromotionalDeductionModel class]]) {
PromotionalDeductionModel *model = (PromotionalDeductionModel *)object; PromotionalDeductionModel *model = (PromotionalDeductionModel *)object;
if ([model.body isEqualToString:GUIDE] && [model.type isEqualToString:JDECardAction]) { if ([model.body isEqualToString:GUIDE] && [model.type isEqualToString:JDECardAction]) {
......
...@@ -2090,7 +2090,7 @@ ...@@ -2090,7 +2090,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = "Brand Assets"; ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = "Brand Assets";
CLANG_ENABLE_OBJC_WEAK = YES; CLANG_ENABLE_OBJC_WEAK = YES;
CODE_SIGN_IDENTITY = "iPhone Distribution: Shanghai Gomore Information Technology Co.,Ltd"; CODE_SIGN_IDENTITY = "iPhone Developer: 云霄 曹 (WM8ZU7YY98)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COMPRESS_PNG_FILES = NO; COMPRESS_PNG_FILES = NO;
DEVELOPMENT_TEAM = W54V2VB863; DEVELOPMENT_TEAM = W54V2VB863;
...@@ -2149,7 +2149,7 @@ ...@@ -2149,7 +2149,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = "Brand Assets"; ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = "Brand Assets";
CLANG_ENABLE_OBJC_WEAK = YES; CLANG_ENABLE_OBJC_WEAK = YES;
CODE_SIGN_IDENTITY = "iPhone Distribution: Shanghai Gomore Information Technology Co.,Ltd"; CODE_SIGN_IDENTITY = "iPhone Developer: 云霄 曹 (WM8ZU7YY98)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COMPRESS_PNG_FILES = NO; COMPRESS_PNG_FILES = NO;
DEVELOPMENT_TEAM = W54V2VB863; DEVELOPMENT_TEAM = W54V2VB863;
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#import "AppDelegate.h" #import "AppDelegate.h"
#import "LoginViewController.h" #import "LoginViewController.h"
#import "DeviceDirectionManager.h" #import "DeviceDirectionManager.h"
#import <Bugly/Bugly.h>
@interface AppDelegate () @interface AppDelegate ()
@end @end
...@@ -20,6 +20,8 @@ ...@@ -20,6 +20,8 @@
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
// Override point for customization after application launch. // Override point for customization after application launch.
//bug检测
[Bugly startWithAppId:@"900033734"];
//检测版本更新 //检测版本更新
[self detectionNetwork]; [self detectionNetwork];
[self SetIQKeyboardManager]; [self SetIQKeyboardManager];
......
...@@ -2170,6 +2170,13 @@ extern NSString * const SORTDIRECTION_DESC; ...@@ -2170,6 +2170,13 @@ extern NSString * const SORTDIRECTION_DESC;
* *
*/ */
@property (nonatomic, copy) NSString *wxcardRealDeduction; @property (nonatomic, copy) NSString *wxcardRealDeduction;
/**
* 方法: 京东E卡面额
*
*
*/
@property (nonatomic, strong) NSNumber *jdecardDenomation;
@end /* interface TOOrderPromotionEntity */ @end /* interface TOOrderPromotionEntity */
......
...@@ -818,6 +818,7 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -818,6 +818,7 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@synthesize wxcardNumber; @synthesize wxcardNumber;
@synthesize wxcardDenomation; @synthesize wxcardDenomation;
@synthesize wxcardRealDeduction; @synthesize wxcardRealDeduction;
@synthesize jdecardDenomation;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -863,6 +864,7 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -863,6 +864,7 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@synthesize resellerName; @synthesize resellerName;
@synthesize oldPrice; @synthesize oldPrice;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
return YES; return YES;
......
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