This is the 29th day of my participation in the Gwen Challenge in November. Check out the details: The last Gwen Challenge in 2021.

The introduction

OEM (Original Equipment Manufacturer, OEM)

Because the purchaser can provide the brand and authorization, allowing the manufacturer to produce products labeled with the brand, so it is commonly known as “OEM production”.

Requirement Background: the SAAS platform-level application system is for a large merchant, which provides exclusive OEM projects and carries out customized development on the basis of the original general APP

For example, remove the open screen advertisement, delete part of the module, and retain the core module. Change exclusive APP icon and theme color

I Shelf information

  1. User agreement and Privacy Policy
  2. App version, review test account information
  3. Icon, Name, Bundle Identifier (BUNDLE ID)
  4. Key words:
  5. The app description:
  6. Technical support website:

Kunnan.blog.csdn.net/article/det…

II Development details

  1. Replace basic configuration information, such as push notification certificate, third-party SDK ApiKey, startup diagram, user protocol, and privacy policy.
  2. Interface modification: For example, SysId request field is added to the login interface to distinguish between the new version and the old version and modify the domain name (record information).
  3. Discard open screen adsPod 'GDTMobSDK', '4.13.26'

1.1 Replace the apiKey of Autonavi positioning SDK

    NSString *AMapKey = @ "";
    [AMapServices sharedServices].apiKey = AMapKey;

Copy the code

1.2 Update the notification push certificate and aurora appKey

  1. “Keychain Access” on Mac Create Certificate Signing Request (CSR)

A. Enable Keystring Access in /Applications/Utilities.

B. Choose Keychain Access > Certificate Assistant > Request a Certificate from a Certificate Authority.

C. In the Certificate Assistant dialog box, enter an email address in the User Email Address column.

D. In common Name, enter the name of the Key (for example, Gita Kumar Dev Key).

E. Leave CA Email Address blank.

F. Select Save to Disk and click Continue.

Help.apple.com/developer-a…

  1. Find the corresponding Identifiers from the developer.apple.com backend to create a push certificate, double-click aps.cer to install it on your local Mac, and then export the P12’s official upload from the keystring to the aurora backend.

Docs. Jiguang. Cn / / jpush/clie…

  1. Replace appKey (unique identifier for Aurora Platform applications)
        [JPUSHService setupWithOption:launchOptions appKey:@ ""
                              channel:@"App Store"
                     apsForProduction:YES
                advertisingIdentifier:nil];

Copy the code

www.jiguang.cn/accounts/lo…

1.3 Replacing the APPId of Bugly

    [Bugly startWithAppId:@ ""];// An exception is reported

Copy the code

1.4 Prompt for the new version of app startup

Replace the appid

    [self checkTheVersionWithappid:@ ""];

Copy the code

Check the version


- (void)checkTheVersionWithappid:(NSString*)appid{


    [QCTNetworkHelper getWithUrl:[NSString stringWithFormat:@"http://itunes.apple.com/cn/lookup?id=%@",appid] params:nil successBlock:^(NSDictionary *result) {
        if ([[result objectForKey:@"results"] isKindOfClass:[NSArray class]]) {
            NSArray *tempArr = [result objectForKey:@"results"];
            if (tempArr.count) {
                
                
                NSString *versionStr =[[tempArr objectAtIndex:0] valueForKey:@"version"];
                NSString *appStoreVersion = [versionStr stringByReplacingOccurrencesOfString:@ "." withString:@ ""];if (appStoreVersion.length==2) {
                    appStoreVersion  = [appStoreVersion stringByAppendingString:@ "0"];
                }else if (appStoreVersion.length==1){
                    appStoreVersion  = [appStoreVersion stringByAppendingString:@ "00"];
                }

                NSDictionary *infoDic=[[NSBundle mainBundle] infoDictionary];
                NSString* currentVersion = [[infoDic valueForKey:@"CFBundleShortVersionString"] stringByReplacingOccurrencesOfString:@ "." withString:@ ""];
                
                currentVersion = [currentVersion stringByReplacingOccurrencesOfString:@ "." withString:@ ""];
                if (currentVersion.length==2) {
                    currentVersion  = [currentVersion stringByAppendingString:@ "0"];
                }else if (currentVersion.length==1){
                    currentVersion  = [currentVersion stringByAppendingString:@ "00"];
                }



                NSLog(@"currentVersion: %@",currentVersion);
                
                
                if([self compareVesionWithServerVersion:versionStr]){

                
                    
                    UIAlertController *alertController = [UIAlertController alertControllerWithTitle:[NSString stringWithFormat:@ % @ % @ "",QCTLocal(@"Discover_a_new_version"),versionStr] message:QCTLocal(@"Whethertoupdate") preferredStyle:UIAlertControllerStyleAlert];
                    //                "Illtalkaboutitlater"= "稍后再说";
                    // "Update now" = "Update now";
                    // "Unupdate"= "cancel update";

                    [alertController addAction:[UIAlertAction actionWithTitle:QCTLocal(@"Illtalkaboutitlater") style:UIAlertActionStyleCancel handler:^(UIAlertAction * _Nonnull action) {
                        NSLog(@" Unupdate");
                    }]];
                    [alertController addAction:[UIAlertAction actionWithTitle:QCTLocal(@"Updatenow") style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
                        NSURL *url = [NSURL URLWithString:[NSString stringWithFormat:@"itms-apps://itunes.apple.com/app/id%@",appid]];
                        if (@available(iOS 10.0, *)) {[[UIApplication sharedApplication] openURL:url options:@{} completionHandler:^(BOOL success) {
                            }];
                        } else {
                            // Fallback on earlier vesions
                            [[UIApplicationsharedApplication] openURL:url]; }}]]; [[QCT_Common getCurrentVC] presentViewController:alertController animated:YES completion:nil];
                }
            }
        }
    } failureBlock:^(NSError *error) {
        NSLog(@" Check version error: %@",error);
    }];
}

Copy the code

see also

More content please pay attention to # applets: iOS Reverse, only to present valuable information for you, focus on mobile technology research field; For more services and advice, please follow # publicid: iOS Reverse.