Просмотр исходного кода

Optimize the navigation bar display -- 优化导航栏显示 resolve: #14

Ray Zhang 5 лет назад
Родитель
Сommit
d2e88806f4

+ 6 - 6
RA TradeFiling/RA TradeFiling.xcodeproj/project.pbxproj

@@ -145,7 +145,7 @@
 		3C5F8D972583500A00CFD26A /* ResultACICell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3C5F8D952583500A00CFD26A /* ResultACICell.xib */; };
 		3C5F8DBA2583655200CFD26A /* searchresult_emanifest.json in Resources */ = {isa = PBXBuildFile; fileRef = 3C5F8DB92583655200CFD26A /* searchresult_emanifest.json */; };
 		3C5F8DC325836A9F00CFD26A /* ResultACEM1Model.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C5F8DC225836A9F00CFD26A /* ResultACEM1Model.m */; };
-		3C7670342595932D00588DB5 /* RANavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C7670332595932D00588DB5 /* RANavigationController.m */; };
+		3C7670342595932D00588DB5 /* TFNavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C7670332595932D00588DB5 /* TFNavigationController.m */; };
 		3C7670392595BE2A00588DB5 /* detail.json in Resources */ = {isa = PBXBuildFile; fileRef = 3C7670382595BE2900588DB5 /* detail.json */; };
 		3C7670482599B1E000588DB5 /* ResulteManifestModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C7670472599B1E000588DB5 /* ResulteManifestModel.m */; };
 		3C7670512599B29D00588DB5 /* ResulteManifestCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C7670502599B29D00588DB5 /* ResulteManifestCell.m */; };
@@ -455,8 +455,8 @@
 		3C5F8DB92583655200CFD26A /* searchresult_emanifest.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = searchresult_emanifest.json; sourceTree = "<group>"; };
 		3C5F8DC125836A9E00CFD26A /* ResultACEM1Model.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ResultACEM1Model.h; sourceTree = "<group>"; };
 		3C5F8DC225836A9F00CFD26A /* ResultACEM1Model.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ResultACEM1Model.m; sourceTree = "<group>"; };
-		3C7670322595932D00588DB5 /* RANavigationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RANavigationController.h; sourceTree = "<group>"; };
-		3C7670332595932D00588DB5 /* RANavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RANavigationController.m; sourceTree = "<group>"; };
+		3C7670322595932D00588DB5 /* TFNavigationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TFNavigationController.h; sourceTree = "<group>"; };
+		3C7670332595932D00588DB5 /* TFNavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TFNavigationController.m; sourceTree = "<group>"; };
 		3C7670382595BE2900588DB5 /* detail.json */ = {isa = PBXFileReference; lastKnownFileType = text.json; path = detail.json; sourceTree = "<group>"; };
 		3C7670462599B1E000588DB5 /* ResulteManifestModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ResulteManifestModel.h; sourceTree = "<group>"; };
 		3C7670472599B1E000588DB5 /* ResulteManifestModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ResulteManifestModel.m; sourceTree = "<group>"; };
@@ -621,8 +621,8 @@
 				3C0CB338255E56BF00718A03 /* SceneDelegate.m */,
 				3C0CB33A255E56BF00718A03 /* ViewController.h */,
 				3C0CB33B255E56BF00718A03 /* ViewController.m */,
-				3C7670322595932D00588DB5 /* RANavigationController.h */,
-				3C7670332595932D00588DB5 /* RANavigationController.m */,
+				3C7670322595932D00588DB5 /* TFNavigationController.h */,
+				3C7670332595932D00588DB5 /* TFNavigationController.m */,
 				3C0CB33D255E56BF00718A03 /* Main.storyboard */,
 				3C0CB340255E56BF00718A03 /* Assets.xcassets */,
 				3C0CB342255E56BF00718A03 /* LaunchScreen.storyboard */,
@@ -1362,7 +1362,7 @@
 				3C452FA825BE98410035AF5F /* HomeDasheManifestCellE.m in Sources */,
 				3C0CB3BA255E829000718A03 /* SearchlistViewController.m in Sources */,
 				3C7F382D2564C78C0033BF82 /* JLRefreshFooter.m in Sources */,
-				3C7670342595932D00588DB5 /* RANavigationController.m in Sources */,
+				3C7670342595932D00588DB5 /* TFNavigationController.m in Sources */,
 				3C5F8CA3256F847400CFD26A /* FunctionSettingViewController.m in Sources */,
 				3C7F37282563CC5F0033BF82 /* NetworkUtils.m in Sources */,
 				3C5F8BC12565017E00CFD26A /* ResultACIModel.m in Sources */,

BIN
RA TradeFiling/RA TradeFiling.xcodeproj/project.xcworkspace/xcuserdata/ruizhang.xcuserdatad/UserInterfaceState.xcuserstate


+ 155 - 11
RA TradeFiling/RA TradeFiling.xcodeproj/xcuserdata/ruizhang.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist

@@ -202,8 +202,8 @@
             filePath = "RA TradeFiling/Detail/DetailTabBarController.m"
             startingColumnNumber = "9223372036854775807"
             endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "93"
-            endingLineNumber = "93"
+            startingLineNumber = "94"
+            endingLineNumber = "94"
             landmarkName = "-init:actions:params:"
             landmarkType = "7">
          </BreakpointContent>
@@ -426,8 +426,8 @@
             filePath = "RA TradeFiling/Detail/DetailTabBarController.m"
             startingColumnNumber = "9223372036854775807"
             endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "80"
-            endingLineNumber = "80"
+            startingLineNumber = "81"
+            endingLineNumber = "81"
             landmarkName = "-init:actions:params:"
             landmarkType = "7">
          </BreakpointContent>
@@ -458,8 +458,8 @@
             filePath = "RA TradeFiling/Detail/DetailTabBarController.m"
             startingColumnNumber = "9223372036854775807"
             endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "490"
-            endingLineNumber = "490"
+            startingLineNumber = "491"
+            endingLineNumber = "491"
             landmarkName = "-menuClick:"
             landmarkType = "7">
          </BreakpointContent>
@@ -724,14 +724,14 @@
          BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
          <BreakpointContent
             uuid = "8AE315C0-1343-4014-B48E-6D44C4555964"
-            shouldBeEnabled = "Yes"
+            shouldBeEnabled = "No"
             ignoreCount = "0"
             continueAfterRunningActions = "No"
             filePath = "RA TradeFiling/SignUp/SignupViewController.m"
             startingColumnNumber = "9223372036854775807"
             endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "108"
-            endingLineNumber = "108"
+            startingLineNumber = "111"
+            endingLineNumber = "111"
             landmarkName = "-onSignUpClick:"
             landmarkType = "7">
          </BreakpointContent>
@@ -740,7 +740,7 @@
          BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
          <BreakpointContent
             uuid = "D108059F-EED7-4670-A0A5-F01E73623B12"
-            shouldBeEnabled = "Yes"
+            shouldBeEnabled = "No"
             ignoreCount = "0"
             continueAfterRunningActions = "No"
             filePath = "RA TradeFiling/SignUp/SignupViewController.m"
@@ -788,7 +788,7 @@
          BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
          <BreakpointContent
             uuid = "6851E550-64D0-4FB4-A762-CC9B2A51A109"
-            shouldBeEnabled = "Yes"
+            shouldBeEnabled = "No"
             ignoreCount = "0"
             continueAfterRunningActions = "No"
             filePath = "../common/NetworkUtils.m"
@@ -864,5 +864,149 @@
             landmarkType = "7">
          </BreakpointContent>
       </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "BAF97B11-A3BF-4EAB-B014-CE8E0578DD94"
+            shouldBeEnabled = "No"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/TFNavigationController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "117"
+            endingLineNumber = "117"
+            landmarkName = "-_configAppearance"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "11E049C9-E6FB-4F72-9BD4-EDD6498624E8"
+            shouldBeEnabled = "No"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/TFNavigationController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "120"
+            endingLineNumber = "120"
+            landmarkName = "-_configAppearance"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "32FBAEBB-0B1B-4449-AC20-5DF6105C9FAA"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/Home/RAHomeViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "572"
+            endingLineNumber = "572"
+            landmarkName = "-_updateUploadItem:withUploadCount:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "7CB4F21F-54CC-4A15-A2BF-15355EF55AB3"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/Login/LoginViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "315"
+            endingLineNumber = "315"
+            landmarkName = "-viewWillAppear:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "81452FF2-7013-4633-999E-3AFD779A9AC0"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/Tab Root/TFRootViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "114"
+            endingLineNumber = "114"
+            landmarkName = "-handleNotification:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "FFC155ED-81A8-4CA2-B292-95CE57DB60A6"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/Tab Root/TFRootViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "109"
+            endingLineNumber = "109"
+            landmarkName = "-handleNotification:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "AAA951D8-135C-408A-B2AE-8653BB18A8FC"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/About/AboutViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "25"
+            endingLineNumber = "25"
+            landmarkName = "-viewWillAppear:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "5C6BB60F-1B65-4C62-8B20-336ADC633FBB"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/About/AboutViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "27"
+            endingLineNumber = "27"
+            landmarkName = "-viewWillAppear:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "EAD49121-7006-468C-9BE3-E6B9B4DF8BB4"
+            shouldBeEnabled = "Yes"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "RA TradeFiling/SignUp/SignupViewController.m"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "33"
+            endingLineNumber = "33"
+            landmarkName = "-viewWillAppear:"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
    </Breakpoints>
 </Bucket>

+ 6 - 0
RA TradeFiling/RA TradeFiling/About/AboutViewController.m

@@ -8,6 +8,7 @@
 #import "AboutViewController.h"
 #import "config.h"
 #import "WebViewController.h"
+#import "RASingleton.h"
 @interface AboutViewController ()
 
 @end
@@ -20,6 +21,11 @@
 }
 - (void)viewWillAppear:(BOOL)animated
 {
+//    if(RASingleton.sharedInstance.isLogin)
+//        [self.navigationController.navigationBar setHidden:false];
+//    else
+//        [self.navigationController.navigationBar setHidden:true];
+    
     [super viewWillAppear:animated];
     [[self navigationController] setNavigationBarHidden:NO animated:NO];
     

+ 1 - 1
RA TradeFiling/RA TradeFiling/Base.lproj/Main.storyboard

@@ -11,7 +11,7 @@
         <!--Navigation Controller-->
         <scene sceneID="PIA-VS-5R0">
             <objects>
-                <navigationController storyboardIdentifier="root_nav" useStoryboardIdentifierAsRestorationIdentifier="YES" id="QI4-5R-VRg" customClass="RANavigationController" sceneMemberID="viewController">
+                <navigationController storyboardIdentifier="root_nav" useStoryboardIdentifierAsRestorationIdentifier="YES" id="QI4-5R-VRg" customClass="TFNavigationController" sceneMemberID="viewController">
                     <navigationBar key="navigationBar" contentMode="scaleToFill" insetsLayoutMarginsFromSafeArea="NO" id="pPg-bQ-dHz">
                         <rect key="frame" x="0.0" y="44" width="414" height="44"/>
                         <autoresizingMask key="autoresizingMask"/>

+ 1 - 1
RA TradeFiling/RA TradeFiling/DataProvider/OnlineDataProvider.m

@@ -53,7 +53,7 @@
    [params setValue:@"signup" forKey:@"action"];
    //    [headers setValue:[NSString stringWithFormat:@"%d",dataLength] forKey:@"Content-Length"];
    
-   [params setValue:user forKey:@"email"];
+   [params setValue:user forKey:@"user"];
    [params setValue:password forKey:@"password"];
 //   [params setValue:[NSString stringWithFormat:@"%ld",ver]  forKey:@"auth_ver"];
 //#ifdef TEST

+ 1 - 0
RA TradeFiling/RA TradeFiling/Detail/DetailTabBarController.m

@@ -31,6 +31,7 @@
 -(id) init :(NSString*) function_name actions:(NSArray*)actions params:(NSMutableDictionary*)params
 {
     self = [super init];
+    
     if (self) {
          DebugLog(@"DetailTabBarController init.................");
 

+ 0 - 45
RA TradeFiling/RA TradeFiling/Home/RAHomeOrderModel.h

@@ -1,45 +0,0 @@
-//
-//  RAHomeOrderModel.h
-//  Apex And Drivers
-//
-//  Created by Jack on 2018/6/1.
-//  Copyright © 2018年 USAI. All rights reserved.
-//
-
-#import <Foundation/Foundation.h>
-#import <UIKit/UIKit.h>
-typedef enum {
-    RAOrderStatusFinish = 3,
-    RAOrderStatusProcessing = 1,
-    RAOrderStatusNew = 2
-} RAOrderStatus;
-
-@protocol RAHomeOrderModelDelegate <NSObject>
-
-- (void)refreshUI;
-
-@end
-
-@interface RAHomeOrderModel : NSObject
-
-@property (nonatomic,assign) RAOrderStatus status;
-@property (nonatomic,copy) NSString *title;
-@property (nonatomic,copy) NSString *orderNo;
-@property (nonatomic,copy) NSString *containerNo;
-@property (nonatomic,copy) NSString *date;
-@property (nonatomic,copy) NSString *orderID;
-@property (nonatomic,copy) NSString *order_type2;
-@property (nonatomic,copy) NSString *iconURL;
-@property (nonatomic,assign) BOOL backendFlag;
-@property (nonatomic,copy) NSString *status_no;
-
-@property (nonatomic,copy) NSString *color;///<orderTypeColor;
-@property (nonatomic,strong,readonly) UIColor *orderTypeColor;
-
-@property (nonatomic,copy) NSString *order_type;
-
-@property (nonatomic,strong,readonly) UIImage *icon;
-
-@property (nonatomic,weak) id<RAHomeOrderModelDelegate> delegate;
-
-@end

+ 0 - 141
RA TradeFiling/RA TradeFiling/Home/RAHomeOrderModel.m

@@ -1,141 +0,0 @@
-//
-//  RAHomeOrderModel.m
-//  Apex And Drivers
-//
-//  Created by Jack on 2018/6/1.
-//  Copyright © 2018年 USAI. All rights reserved.
-//
-
-#import "RAHomeOrderModel.h"
-#import "UIImage+RedAnt.h"
-#import "NSData+RAImageType.h"
-#import "const.h"
-#import "RASingleton.h"
-
-@implementation RAHomeOrderModel {
-    UIImage *_icon;
-    UIColor *_orderTypeColor;
-}
-
-- (void)setValue:(id)value forUndefinedKey:(NSString *)key {
-    
-}
-
-- (UIImage *)icon {
-    return _icon;
-}
-
-- (UIColor *)orderTypeColor {
-    if (!_orderTypeColor) {
-        _orderTypeColor = [UIColor blackColor];
-    }
-    return _orderTypeColor;
-}
-
-- (void)setColor:(NSString *)color {
-    _color = color;
-    
-    if ([color hasPrefix:@"#"]) {
-        color = [color stringByReplacingOccurrencesOfString:@"#" withString:@"0x"];
-    }
-    
-    if (![color hasPrefix:@"0x"]) {
-        _orderTypeColor = nil;
-    }
-    
-    _orderTypeColor = UIColorFromRGB(strtoul([color UTF8String], 0, 16));
-}
-
-- (void)setBackendFlag:(BOOL)backendFlag {
-    _backendFlag = backendFlag;
-    
-    if (self.delegate && [self.delegate respondsToSelector:@selector(refreshUI)]) {
-        dispatch_async(dispatch_get_main_queue(), ^{
-            [self.delegate refreshUI];
-        });
-    }
-}
-
-- (void)setIcon:(UIImage *)icon {
-    _icon = icon;
-//    _icon = [UIImage imageNamed:@"on_the_way"];
-    if (self.delegate && [self.delegate respondsToSelector:@selector(refreshUI)]) {
-        dispatch_async(dispatch_get_main_queue(), ^{
-            [self.delegate refreshUI];
-        });
-    }
-}
-
-//- (void)setValuesForKeysWithDictionary:(NSDictionary<NSString *,id> *)keyedValues {
-//    [super setValuesForKeysWithDictionary:keyedValues];
-//    
-//    [self setIconURL:@"https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1536134884&di=9ea523019212b373ac04f4411e8aa56b&imgtype=jpg&er=1&src=http%3A%2F%2Fp3.music.126.net%2Fyp-UZgqWp6FV_AN4hPozjQ%3D%3D%2F109951163414711232.jpg"];
-//}
-
-- (void)setIconURL:(NSString *)iconURL {
-    _iconURL = iconURL;
-    
-//    iconURL = @"https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1536134884&di=9ea523019212b373ac04f4411e8aa56b&imgtype=jpg&er=1&src=http%3A%2F%2Fp3.music.126.net%2Fyp-UZgqWp6FV_AN4hPozjQ%3D%3D%2F109951163414711232.jpg";
-    
-    if (_iconURL.length > 0 && [_iconURL hasPrefix:@"http"]) {
-        __weak typeof(self) weakSelf = self;
-        [RASingleton.sharedInstance.networkQueue addOperationWithBlock:^{
-            
-            NSString *path = [UIImage imageCachePath:iconURL];
-            UIImage *icon = nil;
-            
-            if ([[NSFileManager defaultManager] fileExistsAtPath:path]) {
-                // 加载缓存的缩放后的图片
-                icon = [UIImage imageWithContentsOfFile:path];
-            } else {
-                // 从服务器获取图片
-                icon = [UIImage ra_imageWithURL:[NSURL URLWithString:iconURL]];
-                // 缩放图片
-                icon = [self antiAlias:icon];
-                // 缓存缩放后的图片
-                [self cacheScaledIcon:icon withPath:path];
-            }
-            
-            if (weakSelf) {
-                __strong typeof(weakSelf) strongSelf = weakSelf;
-                [strongSelf setIcon:icon];
-            }
-            
-        }];
-    }
-}
-
-- (UIImage *)antiAlias:(UIImage *)img {
-    
-    CGFloat size = 50.0f;
-    
-    UIGraphicsBeginImageContextWithOptions(CGSizeMake(size, size), NO, [UIScreen mainScreen].scale);
-    [img drawInRect:CGRectMake(0, 0, size, size)];
-    UIImage *antialias = UIGraphicsGetImageFromCurrentImageContext();
-    UIGraphicsEndImageContext();
-    return antialias;
-}
-
-- (void)cacheScaledIcon:(UIImage *)icon withPath:(NSString *)path {
-    
-    NSData *data = [NSData dataWithContentsOfFile:path];
-    RAIMAGETYPE type = [data imageType];
-    if (type == RAIMAGETYPEPNG) {
-        data = UIImagePNGRepresentation(icon);
-    } else if (type == RAIMAGETYPEJPG) {
-        data = UIImageJPEGRepresentation(icon, 1);
-    } else {
-        data = nil;
-    }
-    
-    if (data) {
-        [self cacheData:data toPath:path];
-    }
-}
-
-- (void)cacheData:(NSData *)data toPath:(NSString *)path {
-    
-    [data writeToFile:path atomically:NO];
-}
-
-@end

+ 2 - 2
RA TradeFiling/RA TradeFiling/Home/RAHomeViewController.m

@@ -57,7 +57,7 @@
 #import "HomeDasheManifestModelE.h"
 
 
-#import "RANavigationController.h"
+#import "TFNavigationController.h"
 
 @implementation RAHomeSectionModel
 
@@ -466,7 +466,7 @@
     self.tabBarController.navigationItem.rightBarButtonItem =welcomeItem;
     
     
-    RANavigationController* ranav= (RANavigationController*)self.navigationController;
+    TFNavigationController* ranav= (TFNavigationController*)self.navigationController;
     
     [ranav setupColor];
 

+ 3 - 2
RA TradeFiling/RA TradeFiling/Login/LoginViewController.m

@@ -13,7 +13,7 @@
 #import "RADataProvider.h"
 #import "RASingleton.h"
 #import "SignupViewController.h"
-#import "RANavigationController.h"
+#import "TFNavigationController.h"
 @interface LoginViewController ()
 @property (strong, nonatomic) IBOutlet UILabel *verLabel;
 
@@ -312,6 +312,7 @@
     NSUserDefaults *defaults =[NSUserDefaults standardUserDefaults];
     
 
+//    [self.navigationController.navigationBar setHidden:true];
     
     NSString * user = [AESCrypt decrypt:[defaults stringForKey:@"user"] password:@"usai"];
     NSString * password = [AESCrypt decrypt:[defaults stringForKey:@"password"] password:@"usai"];
@@ -347,7 +348,7 @@
         UIBarButtonItem *logoItem = [[UIBarButtonItem alloc] initWithImage:logo landscapeImagePhone:logo style:UIBarButtonItemStylePlain target:nil action:nil];
         logoItem.enabled = NO;
 //        self.tabBarController.navigationItem.leftBarButtonItem = logoItem;
-        RANavigationController* ranav= (RANavigationController*)self.navigationController;
+        TFNavigationController* ranav= (TFNavigationController*)self.navigationController;
         
         [ranav setupColor];
     }

+ 7 - 3
RA TradeFiling/RA TradeFiling/SignUp/SignupViewController.m

@@ -29,8 +29,8 @@
 - (void)viewWillAppear:(BOOL)animated
 {
     [super viewWillAppear:animated];
-    [[self navigationController] setNavigationBarHidden:NO animated:NO];
     
+//        [self.navigationController.navigationBar setHidden:false];
 }
 - (IBAction)onAgreeClick:(id)sender {
     self.btn_agree.selected = !self.btn_agree.selected;
@@ -104,8 +104,12 @@
         {
             
             
-            [RAUtils message_alert:@"Successful" title:@"Signup" controller:self action_handler:nil completion:^{
-                [self.navigationController popToRootViewControllerAnimated:YES];
+            [RAUtils message_alert:@"Successful" title:@"Signup" controller:self action_handler:^(UIAlertAction * _Nonnull action) {
+                [self.navigationController popToRootViewControllerAnimated:YES];;
+            }  completion:^{
+                
+                
+                
             }];
 //            NSUserDefaults *defaults =[NSUserDefaults standardUserDefaults];
 //            [defaults removeObjectForKey:@"user"];

+ 1 - 1
RA TradeFiling/RA TradeFiling/RANavigationController.h → RA TradeFiling/RA TradeFiling/TFNavigationController.h

@@ -8,6 +8,6 @@
 
 #import <UIKit/UIKit.h>
 
-@interface RANavigationController : UINavigationController
+@interface TFNavigationController : UINavigationController
 -(void) setupColor;
 @end

+ 16 - 5
RA TradeFiling/RA TradeFiling/RANavigationController.m → RA TradeFiling/RA TradeFiling/TFNavigationController.m

@@ -6,19 +6,19 @@
 //  Copyright © 2018年 USAI. All rights reserved.
 //
 
-#import "RANavigationController.h"
+#import "TFNavigationController.h"
 #import "RASingleton.h"
 #import "const.h"
 //#import "RAOrderDetailViewController.h"
 
-@interface RANavigationController ()
+@interface TFNavigationController ()
 {
     CAGradientLayer *_gradientLayer;
     UIView *_barBackgroundView, *_gradientView;
 }
 @end
 
-@implementation RANavigationController
+@implementation TFNavigationController
 
 - (void)viewDidLoad {
     [super viewDidLoad];
@@ -74,9 +74,17 @@
 {
     [self initglayer];
     if(RASingleton.sharedInstance.isLogin)
+    {
         _gradientView.hidden=false;
+            [self.navigationBar setTintColor:WhiteColor]; // BarItem颜色
+        [self setNeedsStatusBarAppearanceUpdate];
+    }
     else
+    {
         _gradientView.hidden=true;
+        [self.navigationBar setTintColor:nil]; // BarItem颜色
+        [self setNeedsStatusBarAppearanceUpdate];
+    }
         
 }
 - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary<NSKeyValueChangeKey,id> *)change context:(void *)context {
@@ -98,13 +106,16 @@
 }
 
 - (UIStatusBarStyle)preferredStatusBarStyle {
-    return UIStatusBarStyleLightContent;
+    if(RASingleton.sharedInstance.isLogin)
+        return UIStatusBarStyleLightContent;
+    else
+        return UIStatusBarStyleDefault;
 }
 
 - (void)_configAppearance {
     
     [self.navigationBar setTitleTextAttributes:@{NSForegroundColorAttributeName:WhiteColor}]; // Title Color
-    [self.navigationBar setTintColor:WhiteColor]; // BarItem颜色
+//    [self.navigationBar setTintColor:WhiteColor]; // BarItem颜色
     self.navigationBar.barTintColor = WhiteColor; // 背景色
     self.navigationBar.translucent = NO;
     

+ 5 - 1
RA TradeFiling/RA TradeFiling/Tab Root/TFRootViewController.m

@@ -74,6 +74,7 @@
 }
 
 -(void) setup{
+    
     //    AppDelegate *appDelegate = (AppDelegate *)[[UIApplication sharedApplication] delegate];
     //
         LoginViewController * loginVC = [ [UIStoryboard storyboardWithName:@"Login" bundle:nil] instantiateViewControllerWithIdentifier:@"LoginPanel"];
@@ -105,11 +106,14 @@
         self.viewControllers = self.logout_bar;
         self.selectedIndex = 0;
         
-        
+//        [self.navigationController.navigationBar setHidden:true];
 //
     }
     else if ([notification.name isEqualToString:RA_NOTIFICATION_LOGIN])
     {
+//            [self.navigationController.navigationBar setHidden:false];
+            
+        
                 self.viewControllers = self.login_bar;
                 self.selectedIndex = 0;
     }

+ 1 - 1
RA TradeFiling/RA TradeFiling/config.h

@@ -10,7 +10,7 @@
 
 //连接超时
 #define JSON_TIMEOUT 60
-#define fake_data true
+#define fake_data false
 #ifdef DEBUG
     #define test_server
 //    #define fake_data true