-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathServerceInterfaceManager+Account.m
58 lines (46 loc) · 2.15 KB
/
ServerceInterfaceManager+Account.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
//
// ServerceInterfaceManager+Account.m
//
//
// Created by LEI.FY on 2019/8/26.
// Copyright LEI.FY. All rights reserved.
//
#import "ServerceInterfaceManager+Account.h"
@implementation ServerceInterfaceManager (Account)
-(id)userRegisterByPhone:(NSString *)phoneNum
password:(NSString *)password
msgAuthCode:(NSString *)msgAuthCode
nickName:(NSString *)nickName
country:(NSString *)country
finishBlock:(ServiceFinishBlock)finishBlock
failedBlock:(ServiceFailedBlock)failedBlock
businesBlock:(ServiceBusinesFailedBlock)businesBlock{
NSMutableDictionary *dic = [NSMutableDictionary dictionaryWithCapacity:4];
[dic setObject:phoneNum forKey:@"phoneNum"];
[dic setObject:password forKey:@"password"];
[dic setObject:nickName forKey:@"nickName"];
[dic setObject:country forKey:@"country"];
[dic setObject:msgAuthCode forKey:@"msgAuthCode"];
id operation = [self JSONPostWithUrl:self.apiList.acountRegister
dict:dic
finishBlock:finishBlock
failedBlock:failedBlock
businesBlock:businesBlock];
return operation;
}
-(id)userLoginByPhone:(NSString *)phoneNum
password:(NSString *)password
finishBlock:(ServiceFinishBlock)finishBlock
failedBlock:(ServiceFailedBlock)failedBlock
businesBlock:(ServiceBusinesFailedBlock)businesBlock{
NSMutableDictionary *dic = [NSMutableDictionary dictionaryWithCapacity:4];
[dic setObject:phoneNum forKey:@"phoneNum"];
[dic setObject:password forKey:@"password"];
id operation = [self JSONPostWithUrl:self.apiList.userLogin
dict:dic
finishBlock:finishBlock
failedBlock:failedBlock
businesBlock:businesBlock];
return operation;
}
@end