@@ -176,49 +176,6 @@ - (void)request_CheckPhoneCodeWithPhone:(NSString *)phone code:(NSString *)code
176
176
block (data, error);
177
177
}];
178
178
}
179
-
180
- - (void )request_SetPasswordWithEmail : (NSString *)email captcha : (NSString *)captcha type : (PurposeType)type block : (void (^)(id data, NSError *error))block {
181
- NSString *path;
182
- NSDictionary *params = @{@" email" : email,
183
- @" j_captcha" : captcha};
184
- switch (type) {
185
- case PurposeToPasswordActivate:
186
- path = @" api/activate" ;
187
- break ;
188
- case PurposeToPasswordReset:
189
- path = @" api/resetPassword" ;
190
- break ;
191
- default :
192
- path = nil ;
193
- break ;
194
- }
195
- [[CodingNetAPIClient sharedJsonClient ] requestJsonDataWithPath: path withParams: params withMethodType: Get andBlock: ^(id data, NSError *error) {
196
- if (data) {
197
- [MobClick event: kUmeng_Event_Request_Get label: @" 发激活or重置密码邮件" ];
198
- }
199
- block (data, nil );
200
- }];
201
- }
202
- - (void )request_ActivateByPhone : (NSString *)phone setEmail : (NSString *)email global_key : (NSString *)global_key block : (void (^)(id data, NSError *error))block {
203
- NSString *path = @" api/account/activate/phone" ;
204
- NSDictionary *params = @{@" phone" : phone,
205
- @" email" : email,
206
- @" global_key" : global_key};
207
- [[CodingNetAPIClient sharedJsonClient ] requestJsonDataWithPath: path withParams: params withMethodType: Post andBlock: ^(id data, NSError *error) {
208
- id resultData = [data valueForKeyPath: @" data" ];
209
- if (resultData) {
210
- [MobClick event: kUmeng_Event_Request_ActionOfServer label: @" 激活账号_设置邮箱KEY" ];
211
-
212
- User *curLoginUser = [NSObject objectOfClass: @" User" fromJSON: resultData];
213
- if (curLoginUser) {
214
- [Login doLogin: resultData];
215
- }
216
- block (curLoginUser, nil );
217
- }else {
218
- block (nil , error);
219
- }
220
- }];
221
- }
222
179
- (void )request_ActivateBySetGlobal_key : (NSString *)global_key block : (void (^)(id data, NSError *error))block {
223
180
NSString *path = @" api/account/global_key/acitvate" ;
224
181
NSDictionary *params = @{@" global_key" : global_key};
0 commit comments