Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
O
Opple-iOS
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张杰
Opple-iOS
Commits
a4dd6aae
Commit
a4dd6aae
authored
Nov 10, 2016
by
曹云霄
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改项说明:优化无促销情况不主动提示支付
parent
dd372597
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
53 additions
and
38 deletions
+53
-38
OrderdetailsViewController.m
Class/OrderdetailsViewController.m
+39
-35
project.pbxproj
Lighting.xcodeproj/project.pbxproj
+2
-2
AppDelegate.m
Lighting/AppDelegate.m
+3
-1
opple_objc_json_client.h
Tools/opple_objc_json_client.h
+7
-0
opple_objc_json_client.m
Tools/opple_objc_json_client.m
+2
-0
No files found.
Class/OrderdetailsViewController.m
View file @
a4dd6aae
...
@@ -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
s
elf
.
luckyDrawAndJDECardArray
)
{
for
(
id
object
in
weakS
elf
.
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
])
{
...
...
Lighting.xcodeproj/project.pbxproj
View file @
a4dd6aae
...
@@ -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 D
istribution: Shanghai Gomore Information Technology Co.,Ltd
"
;
CODE_SIGN_IDENTITY
=
"iPhone D
eveloper: 云霄 曹 (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 D
istribution: Shanghai Gomore Information Technology Co.,Ltd
"
;
CODE_SIGN_IDENTITY
=
"iPhone D
eveloper: 云霄 曹 (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
;
...
...
Lighting/AppDelegate.m
View file @
a4dd6aae
...
@@ -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
];
...
...
Tools/opple_objc_json_client.h
View file @
a4dd6aae
...
@@ -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 */
...
...
Tools/opple_objc_json_client.m
View file @
a4dd6aae
...
@@ -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
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment