|
@@ -13,7 +13,6 @@
|
|
|
@property (nonatomic, strong) UILabel *nameLab;
|
|
|
@property (nonatomic, strong) UILabel *countLab;
|
|
|
@property (nonatomic, strong) UILabel *realPriceLab;
|
|
|
-@property (nonatomic, strong) UILabel *priceLab;
|
|
|
@property (nonatomic, strong) UILabel *optLab;
|
|
|
|
|
|
@property (nonatomic, strong) UILabel *giftLab;
|
|
@@ -64,18 +63,11 @@
|
|
|
make.left.equalTo(_goodsImage.mas_right).offset(10);
|
|
|
}];
|
|
|
|
|
|
- _priceLab = [UILabel labelCreateWithText:@"123" font:[UIFont fontWithName:Rob_Regular size:12] textColor:[UIColor colorWithHexString:@"#8c8c8c"]];
|
|
|
- [backView addSubview:_priceLab];
|
|
|
- [_priceLab mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
|
- make.centerY.mas_equalTo(_countLab);
|
|
|
- make.right.mas_equalTo(-10);
|
|
|
- }];
|
|
|
-
|
|
|
_realPriceLab = [UILabel labelCreateWithText:@"" font:[UIFont fontWithName:Rob_Bold size:14] textColor:_0B0B0B];
|
|
|
[backView addSubview:_realPriceLab];
|
|
|
[_realPriceLab mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
|
make.centerY.mas_equalTo(_countLab);
|
|
|
- make.right.mas_equalTo(_priceLab.mas_left).offset(-6);
|
|
|
+ make.right.mas_equalTo(-10);
|
|
|
}];
|
|
|
|
|
|
_optLab = [UILabel labelCreateWithText:@"" font:[UIFont fontWithName:Rob_Regular size:12] textColor:_0B0B0B];
|
|
@@ -114,23 +106,16 @@
|
|
|
_giftLab.hidden = NO;
|
|
|
_countLab.hidden = YES;
|
|
|
_realPriceLab.hidden = YES;
|
|
|
- _priceLab.hidden = YES;
|
|
|
}else{
|
|
|
_giftLab.hidden = YES;
|
|
|
_countLab.hidden = NO;
|
|
|
_realPriceLab.hidden = NO;
|
|
|
- _priceLab.hidden = NO;
|
|
|
}
|
|
|
|
|
|
_nameLab.text = AS_String_NotNull(_itemModel.name);
|
|
|
_countLab.text = [NSString stringWithFormat:@"X%@", AS_String_NotNull(_itemModel.qty_ordered)];
|
|
|
_realPriceLab.text = [NSString stringWithFormat:@"%@%.2f", AS_String_NotNull(_itemModel.currency_symbol), [AS_String_NotNull(_itemModel.price) floatValue]];
|
|
|
|
|
|
- NSMutableAttributedString *priceAtr = [[NSMutableAttributedString alloc]initWithString:[NSString stringWithFormat:@"%@%.2f",AS_String_NotNull(_itemModel.currency_symbol), [AS_String_NotNull(_itemModel.original_price) floatValue]]];
|
|
|
- [priceAtr addAttribute:NSStrikethroughStyleAttributeName
|
|
|
- value:[NSNumber numberWithInteger:NSUnderlineStyleSingle]
|
|
|
- range:NSMakeRange(0, priceAtr.length)];
|
|
|
- _priceLab.attributedText = priceAtr;
|
|
|
|
|
|
|
|
|
NSArray *array = [Current_normalTool arrFromjsonStr:_itemModel.sku];
|