Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

你好 请问 #11

Open
jj89757hhb opened this issue Oct 17, 2016 · 0 comments
Open

你好 请问 #11

jj89757hhb opened this issue Oct 17, 2016 · 0 comments

Comments

@jj89757hhb
Copy link

这个SMKAction是你自己封装的 还是 第三方的呢?
[[SMKAction sharedAction] sendRequestBlock:^(NSObject *request) {

// // 方式2
// return [[FirstRequest alloc]init];

    // 方式3
    //smk_url (如果设置了url,则不需要在设置scheme,host,path 属性)
    request.smk_scheme = @"https";
    request.smk_host = @"api.douban.com";
    request.smk_path = @"/v2/book/search";
    request.smk_method = SMKRequestMethodGET;     // default
    request.smk_params = @{@"q": @"基础"};

    return request;

} progress:nil success:^(id responseObject) {
    if (responseObject) {
        NSArray *modelArray = [FirstModel mj_objectArrayWithKeyValuesArray:responseObject[@"books"]];
        success(modelArray);
    }
} failure:nil]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant