Ver Fonte

NPD MOBILE

修改 CART table header 对齐
Ray Zhang há 8 anos atrás
pai
commit
00651dbe78

+ 6 - 4
RedAnt ERP Mobile/common/Functions/cart/CartViewController.m

@@ -1471,23 +1471,25 @@
     [solabel sizeToFit];
     [myView addSubview:solabel];
     CGFloat x = tableView.bounds.size.width - (768 - 320);
-    UILabel *contactlabel = [[UILabel alloc] initWithFrame:CGRectMake(320, 5.5, 90, 22)];
+    
+    UILabel *contactlabel = [[UILabel alloc] initWithFrame:CGRectMake(x, 5.5, 90, 22)];
     contactlabel.textColor=UIColorFromRGB(color);
-    contactlabel.autoresizingMask=UIViewAutoresizingFlexibleRightMargin;
+    contactlabel.autoresizingMask=UIViewAutoresizingFlexibleLeftMargin;
     contactlabel.backgroundColor = [UIColor clearColor];
     contactlabel.text=NSLocalizedString(@"Unit price", nil);
     [contactlabel sizeToFit];
     [myView addSubview:contactlabel];
     
     x = tableView.bounds.size.width - (768 - 470);
-    UILabel *modellabel = [[UILabel alloc] initWithFrame:CGRectMake(470, 5.5, 90, 22)];
+    UILabel *modellabel = [[UILabel alloc] initWithFrame:CGRectMake(x, 5.5, 90, 22)];
     modellabel.textColor=UIColorFromRGB(color);
-     modellabel.autoresizingMask=UIViewAutoresizingFlexibleRightMargin;
+     modellabel.autoresizingMask=UIViewAutoresizingFlexibleLeftMargin;
     modellabel.backgroundColor = [UIColor clearColor];
     modellabel.text=NSLocalizedString(@"Discount/QTY", nil);
     [modellabel sizeToFit];
     [myView addSubview:modellabel];
     x = tableView.bounds.size.width - (768 - 640);
+    
     UILabel *pricelabel = [[UILabel alloc] initWithFrame:CGRectMake(x, 5.5, 90, 22)];
     pricelabel.textColor=UIColorFromRGB(color);
     pricelabel.autoresizingMask=UIViewAutoresizingFlexibleLeftMargin;