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

增加改变成交价权限控制

parent 5fd771a7
......@@ -31,6 +31,8 @@
make.width.mas_equalTo(200);
make.height.mas_equalTo(40);
}];
}
......
......@@ -38,7 +38,7 @@
self.goodsCode.text = _model.goods.code;
self.tagsPriceLabe.text = [_model.goods.tagPrice stringValue];
self.clinchTextfield.text = [NSString stringWithFormat:@"%.2f",[_model.costPrice floatValue]?[_model.costPrice floatValue]:[_model.goods.tagPrice floatValue]];
self.goodsNumbersLabe.text = [NSString stringWithFormat:@"%d",_model.goodsNum];
self.goodsNumbersLabe.text = [NSString stringWithFormat:@"%ld",_model.goodsNum];
if ([_model.costPrice integerValue] == 0) {
_model.costPrice = _model.goods.tagPrice;
}
......@@ -111,11 +111,18 @@
#pragma mark -成交价完成修改
- (BOOL)textFieldShouldEndEditing:(UITextField *)textField
{
Shoppersmanager *user = [Shoppersmanager manager];
if (![self isPureInt:textField.text]) {
if (self.promptStringBlock) {
self.promptStringBlock(@"输入格式错误");
}
}else
} else if ([textField.text floatValue] < [user.Shoppers.lowestDiscount floatValue]/100 * [self.model.goods.tagPrice floatValue])
{
if (self.promptStringBlock) {
self.promptStringBlock(@"当前价格低于你的权限范围!");
}
}
else
{
//改变价格
self.productPriceLabe.text = [NSString stringWithFormat:@"¥%.2f",[self.goodsNumbersLabe.text integerValue]*[textField.text floatValue]];
......
......@@ -1383,7 +1383,7 @@
TargetAttributes = {
29706DA01CD082980003C412 = {
CreatedOnToolsVersion = 7.3;
DevelopmentTeam = W54V2VB863;
DevelopmentTeam = 39XYE6VSP8;
};
};
};
......@@ -1717,7 +1717,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = "Brand Assets";
CLANG_ENABLE_OBJC_WEAK = YES;
CODE_SIGN_IDENTITY = "iPhone Developer: 云霄 曹 (WM8ZU7YY98)";
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer: 云霄 曹 (WM8ZU7YY98)";
COMPRESS_PNG_FILES = NO;
ENABLE_BITCODE = NO;
......@@ -1761,7 +1761,7 @@
);
PRODUCT_BUNDLE_IDENTIFIER = com.gomore.opple;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "f89bebf5-81e2-4c61-9052-8c7bb0f9ddd6";
PROVISIONING_PROFILE = "e9bd3600-5e9c-4cd0-a0d5-b7d8b0882ca8";
STRIP_PNG_TEXT = NO;
TARGETED_DEVICE_FAMILY = 2;
USER_HEADER_SEARCH_PATHS = "$(PODS_ROOT)/**";
......@@ -1775,7 +1775,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = "Brand Assets";
CLANG_ENABLE_OBJC_WEAK = YES;
CODE_SIGN_IDENTITY = "iPhone Developer: 云霄 曹 (WM8ZU7YY98)";
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer: 云霄 曹 (WM8ZU7YY98)";
COMPRESS_PNG_FILES = NO;
ENABLE_BITCODE = NO;
......@@ -1819,7 +1819,7 @@
);
PRODUCT_BUNDLE_IDENTIFIER = com.gomore.opple;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "f89bebf5-81e2-4c61-9052-8c7bb0f9ddd6";
PROVISIONING_PROFILE = "e9bd3600-5e9c-4cd0-a0d5-b7d8b0882ca8";
STRIP_PNG_TEXT = NO;
TARGETED_DEVICE_FAMILY = 2;
USER_HEADER_SEARCH_PATHS = "$(PODS_ROOT)/**";
......
......@@ -495,6 +495,11 @@
}
- (void)dealloc
{
NSLog(@"%@",self.title);
}
......
......@@ -368,14 +368,12 @@ extern NSString * const SORTDIRECTION_DESC;
*
*/
@property (nonatomic, copy) NSString *consumerNameOrMobileEquals;
/**
* 客户标识等于
*
*
*/
@property (nonatomic, copy) NSString *consumerIdEquals;
/**
* 分页数据
*
......@@ -1318,6 +1316,12 @@ extern NSString * const SORTDIRECTION_DESC;
*
*/
@property (nonatomic, strong) NSNumber *commission;
/**
* (no documentation provided)
*
*
*/
@property (nonatomic, strong) NSNumber *lowestDiscount;
/**
* 方法: 取得java.lang.String
*
......@@ -1905,7 +1909,7 @@ extern NSString * const SORTDIRECTION_DESC;
* @see NSString
*
*/
@property (nonatomic, strong) NSArray *cartIds;
@property (nonatomic, strong) NSArray<NSString *> *cartIds;
@end /* interface DeleteCartRequest */
......@@ -2109,7 +2113,19 @@ extern NSString * const SORTDIRECTION_DESC;
*
*
*/
@property (nonatomic, strong) NSNumber *commission;
@property (nonatomic, strong) NSNumber *commissionRate;
/**
* 提成金额
*
*
*/
@property (nonatomic, strong) NSNumber *commissionTotal;
/**
* 最低分成比例
*
*
*/
@property (nonatomic, strong) NSNumber *lowestDiscount;
@end /* interface LoginResult */
......
......@@ -484,6 +484,7 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@synthesize code;
@synthesize name;
@synthesize commission;
@synthesize lowestDiscount;
@synthesize resellerCode;
+(BOOL)propertyIsOptional:(NSString*)propertyName
......@@ -760,7 +761,9 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@implementation LoginResult
@synthesize employee;
@synthesize commission;
@synthesize commissionRate;
@synthesize commissionTotal;
@synthesize lowestDiscount;
+(BOOL)propertyIsOptional:(NSString*)propertyName
{
......
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