Commit 912fec60 authored by 曹云霄's avatar 曹云霄

修改项说明:修复导购抽奖闪退

parent ec8c4c9b
...@@ -211,6 +211,9 @@ ...@@ -211,6 +211,9 @@
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath - (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath
{ {
if ([self.cardState isEqualToString:CHECK]) {
return;
}
CardAmplificationViewController *cardVC = [[CardAmplificationViewController alloc]init]; CardAmplificationViewController *cardVC = [[CardAmplificationViewController alloc]init];
self.settingsPopoverController = [[WYPopoverController alloc] initWithContentViewController:cardVC]; self.settingsPopoverController = [[WYPopoverController alloc] initWithContentViewController:cardVC];
self.settingsPopoverController.theme.fillBottomColor = [UIColor clearColor]; self.settingsPopoverController.theme.fillBottomColor = [UIColor clearColor];
......
...@@ -26,6 +26,10 @@ ...@@ -26,6 +26,10 @@
*/ */
@property (weak, nonatomic) IBOutlet UIButton *isUsedButton; @property (weak, nonatomic) IBOutlet UIButton *isUsedButton;
/**
审核中
*/
@property (weak, nonatomic) IBOutlet UIButton *examinationButton;
/** /**
* 指示线 * 指示线
......
...@@ -33,6 +33,10 @@ ...@@ -33,6 +33,10 @@
// 未领取 // 未领取
CardDontUseViewController *dontUseVc = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"CardDontUseViewController"]; CardDontUseViewController *dontUseVc = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"CardDontUseViewController"];
[self addChildViewController:dontUseVc]; [self addChildViewController:dontUseVc];
// 审批中
CardBeenUseViewController *examineUseVc = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"CardBeenUseViewController"];
examineUseVc.cardState = CHECK;
[self addChildViewController:examineUseVc];
// 已领取 // 已领取
CardBeenUseViewController *beenUseVc = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"CardBeenUseViewController"]; CardBeenUseViewController *beenUseVc = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"CardBeenUseViewController"];
beenUseVc.cardState = ACTIVED; beenUseVc.cardState = ACTIVED;
...@@ -43,6 +47,7 @@ ...@@ -43,6 +47,7 @@
[self addChildViewController:usedVc]; [self addChildViewController:usedVc];
dontUseVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h); dontUseVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h);
beenUseVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h); beenUseVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h);
examineUseVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h);
usedVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h); usedVc.view.frame = CGRectMake(0, 0, self.cardBackgroundView.mj_w, self.cardBackgroundView.mj_h);
[self.cardBackgroundView addSubview:dontUseVc.view]; [self.cardBackgroundView addSubview:dontUseVc.view];
self.currentVC = dontUseVc; self.currentVC = dontUseVc;
...@@ -68,19 +73,28 @@ ...@@ -68,19 +73,28 @@
{ {
self.beenUseButton.selected = NO; self.beenUseButton.selected = NO;
self.isUsedButton.selected = NO; self.isUsedButton.selected = NO;
self.examinationButton.selected = NO;
} }
break; break;
case 101: case 101:
{ {
self.dontUseButton.selected = NO; self.dontUseButton.selected = NO;
self.isUsedButton.selected = NO; self.isUsedButton.selected = NO;
self.beenUseButton.selected = NO;
} }
break; break;
case 102: case 102:
{ {
self.dontUseButton.selected = NO; self.dontUseButton.selected = NO;
self.beenUseButton.selected = NO; self.beenUseButton.selected = NO;
self.examinationButton.selected = NO;
}
break;
case 103:
{
self.dontUseButton.selected = NO;
self.beenUseButton.selected = NO;
self.examinationButton.selected = NO;
} }
break; break;
......
...@@ -211,14 +211,11 @@ ...@@ -211,14 +211,11 @@
RsAwardDraw *drawEntity = self.datasArray[sender.tag]; RsAwardDraw *drawEntity = self.datasArray[sender.tag];
[self showLuckyDrawControl:drawEntity.draw.lotteryId andOrderNumber:drawEntity.draw.orderNumber andDrawid:drawEntity.draw.fid luckyDrawFinish:^(NSDictionary *dict) { [self showLuckyDrawControl:drawEntity.draw.lotteryId andOrderNumber:drawEntity.draw.orderNumber andDrawid:drawEntity.draw.fid luckyDrawFinish:^(NSDictionary *dict) {
id json = [NSJSONSerialization JSONObjectWithData:[dict[@"body"] dataUsingEncoding:NSUTF8StringEncoding] options:NSJSONReadingMutableContainers error:nil]; if ([dict isKindOfClass:[NSDictionary class]]) {
if (json) { if ([BaseViewController isBlankString:dict[@"awardId"]]) {
if ([json isKindOfClass:[NSDictionary class]]) {
if ([BaseViewController isBlankString:json[@"awardId"]]) {
[weakSelf SHOWPrompttext:@"未中奖"]; [weakSelf SHOWPrompttext:@"未中奖"];
}else { }else {
[weakSelf SHOWPrompttext:[NSString stringWithFormat:@"恭喜你获得了 %@",json[@"description"]]]; [weakSelf SHOWPrompttext:[NSString stringWithFormat:@"恭喜你获得了 %@",dict[@"description"]]];
}
} }
} }
}]; }];
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<key>CFBundleName</key> <key>CFBundleName</key>
<string>欧立方</string> <string>欧立方</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.2.6</string> <string>1.2.7</string>
<key>CFBundleURLTypes</key> <key>CFBundleURLTypes</key>
<array> <array>
<dict> <dict>
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -310,6 +310,11 @@ extern NSString *const ACTIVED; ...@@ -310,6 +310,11 @@ extern NSString *const ACTIVED;
*/ */
extern NSString *const USED; extern NSString *const USED;
/**
* 京东卡状态<审批中>
*/
extern NSString *const CHECK;
/** /**
* 更新购物车商品 * 更新购物车商品
*/ */
......
...@@ -299,6 +299,11 @@ NSString *const DISPENSED = @"dispensed"; ...@@ -299,6 +299,11 @@ NSString *const DISPENSED = @"dispensed";
*/ */
NSString *const ACTIVED = @"actived"; NSString *const ACTIVED = @"actived";
/**
* 京东卡状态<审批中>
*/
NSString *const CHECK = @"checking";
/** /**
* 京东卡状态<查看> * 京东卡状态<查看>
*/ */
......
...@@ -140,7 +140,7 @@ ...@@ -140,7 +140,7 @@
/** /**
* 服务器开发地址 * 服务器开发地址
*/ */
#define SERVERREQUESTURL(URL) [NSString stringWithFormat:@"http://139.196.195.30:8090/opple-web/app%@",URL] //#define SERVERREQUESTURL(URL) [NSString stringWithFormat:@"http://139.196.195.30:8090/opple-web/app%@",URL]
/** /**
...@@ -151,7 +151,7 @@ ...@@ -151,7 +151,7 @@
//** //**
// * 服务器正式地址 // * 服务器正式地址
// */ // */
//#define SERVERREQUESTURL(URL) [NSString stringWithFormat:@"http://dg.opple.com/opple-web/app%@",URL] #define SERVERREQUESTURL(URL) [NSString stringWithFormat:@"http://dg.opple.com/opple-web/app%@",URL]
/** /**
* 搜索框输入通知 * 搜索框输入通知
......
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