فهرست منبع

1.修改Homer Model Detail价格显示。

Pen Li 8 سال پیش
والد
کامیت
0d6cfee819

BIN
RedAnt ERP Mobile/RedAnt ERP Mobile.xcworkspace/xcuserdata/macmini1.xcuserdatad/UserInterfaceState.xcuserstate


+ 12 - 0
RedAnt ERP Mobile/RedAnt ERP Mobile.xcworkspace/xcuserdata/macmini1.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist

@@ -2,4 +2,16 @@
 <Bucket
    type = "0"
    version = "2.0">
+   <Breakpoints>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.ExceptionBreakpoint">
+         <BreakpointContent
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            scope = "0"
+            stopOnStyle = "0">
+         </BreakpointContent>
+      </BreakpointProxy>
+   </Breakpoints>
 </Bucket>

+ 10 - 4
RedAnt ERP Mobile/common/Functions/modelDetail/DetailViewController.m

@@ -1031,7 +1031,6 @@ self.isrefreshing=false;
         cell.hmlg_stock_count_lb.hidden = YES;
         cell.on_sale_lb.hidden = YES;
         BOOL is_special_model = [[section_json objectForKey:@"is_special_model"] boolValue];
-        BOOL is_promotion_price = [[section_json objectForKey:@"is_promotion_price"] boolValue];
         if (!appDelegate.user) { // 没有登录时隐藏add to portfolio,使add to cart与add to wishlist对齐
             
             cell.btnaddPortfolio.hidden = YES;
@@ -1578,10 +1577,17 @@ self.isrefreshing=false;
         }
         }
 #ifdef BUILD_HOMER
-        if (appDelegate.user && is_special_model && !is_promotion_price) {
-            
+        NSString *old_price = [section_json objectForKey:@"old_price"];
+        if (appDelegate.user && old_price != nil && old_price.length > 0) {
             cell.priceLabel.text = nil;
-            NSAttributedString *attrStr = [[NSAttributedString alloc] initWithString:price attributes:@{NSStrikethroughStyleAttributeName : [NSNumber numberWithInt:NSUnderlineStyleSingle]}];
+            NSString *new_price_str = [NSString stringWithFormat:@"%@  %@",price,old_price];
+            NSRange range = [new_price_str rangeOfString:@"$" options:NSBackwardsSearch];
+            range = NSMakeRange(range.location,new_price_str.length - range.location);
+            NSMutableAttributedString *attrStr = [[NSMutableAttributedString alloc] initWithString:new_price_str];
+            [attrStr addAttributes:@{
+                                     NSStrikethroughStyleAttributeName : [NSNumber numberWithInt:NSUnderlineStyleSingle]
+                                     }
+                             range:range];
             cell.priceLabel.attributedText = attrStr;
             
         } else {

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 121 - 121
RedAnt ERP Mobile/iSales-NPD/Base.lproj/Main.storyboard


برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است