valeriyvan / ios-receipt-scan-example

White label app that integrates with nfscan API calls

Home Page:http://nfscan.cc/docs/ios-receipt-scan-example/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ios-receipt-scan-example

Build Status GitHub license

Simple iOS client white label for nfscan

Usage

1) Download the repository

$ git clone https://github.com/nfscan/ios-receipt-scan-example.git
$ cd ios-receipt-scan-example

2) Run CocoaPods

$ pod install

3) Open the project in Xcode

$ open ios-receipt-scan-example.xcworkspace

4) Change nfscan service address on Constants.m

+(NSString*) HOST{
    static NSString* baseUrl;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        NSDictionary *env = [[NSProcessInfo processInfo] environment];
        NSString *overrideBaseUrl = [env valueForKey:@"BASE_URL"];
        if(overrideBaseUrl && ![overrideBaseUrl isEqualToString:@""]){
            baseUrl = overrideBaseUrl;
        }else{
#ifdef DEBUG
            NSLog(@"%s BASE_URL ENVIRONMENTAL VARIABLES ISN'T SET",__PRETTY_FUNCTION__);
#endif
            baseUrl = @"http://youripaddress:8080/nfscan-server/";
        }
    });
    return baseUrl;
}

5) Compile and run the app in your simulator

Requirements

  • Xcode 6.3
  • iOS 8

Contributing

You're encouraged to contribute to nfscan. Fork the code from https://github.com/nfscan/ios-receipt-scan-example and submit pull requests.

Make sure you're following the contributing guidelines for this project.

Credits

About

White label app that integrates with nfscan API calls

http://nfscan.cc/docs/ios-receipt-scan-example/

License:MIT License


Languages

Language:Objective-C 99.9%Language:Ruby 0.1%