Latest 0.1.0
Homepage https://github.com/anthann/GPRChinaAddressIndex
License MIT
Platforms ios 8.0
Dependencies FMDB
Authors

CI Status
Version
License
Platform

中国行政区划,方便开发者制作用于选择省、市、区的控件。
常见的场景是方便电商app的用户编辑收货地址。

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

GPRChinaAddressIndex is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "GPRChinaAddressIndex"

Usage

“`省
NSArray <GPRAddressModel >provinces = [[GPRChinaAddressIndex sharedInstance] getProvince];


```市
NSArray <GPRAddressModel *>*cities = [[GPRChinaAddressIndex sharedInstance] getCityByProvinceID:@"110000"];
//110000是北京市(省级单位)的id,可以用过上一级列表检索到。接口返回北京市(省级)下属的市(因为是直辖市,cities.count == 1)。

“`市
NSArray <GPRAddressModel >cities = [[GPRChinaAddressIndex sharedInstance] getTownByCityID:@"110100"];
//110100是北京市(市级单位)的id,可以用过上一级列表检索到。接口返回北京市下属各个区。



## Author

anthann, [email protected]

## License

GPRChinaAddressIndex is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "GPRChinaAddressIndex",
    "version": "0.1.0",
    "summary": "A index of China's top three levels of address",
    "description": "A index of China's top three levels of address: province, city, town.nThe example of this lib is a address picker, to indicate how it works.",
    "homepage": "https://github.com/anthann/GPRChinaAddressIndex",
    "license": "MIT",
    "authors": {
        "anthann": "[email protected]"
    },
    "source": {
        "git": "https://github.com/anthann/GPRChinaAddressIndex.git",
        "tag": "0.1.0"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source_files": "GPRChinaAddressIndex/Classes/*",
    "resource_bundles": {
        "GPRChinaAddressIndex": [
            "GPRChinaAddressIndex/Assets/*.db"
        ]
    },
    "dependencies": {
        "FMDB": [
            "2.6.2"
        ]
    }
}

Pin It on Pinterest

Share This