3d36a443
Nattapon Wongpaet
add constant
|
1
2
3
|
module.exports = Object.freeze({
REQUEST: 'Request',
RESPONSE: 'Response',
|
479b9d98
sumatek
update use constants
|
4
5
|
SUCCESS: 'Success',
ERROR: 'Error',
|
584b2672
Nattapon Wongpaet
update handler er...
|
6
|
FAIL: 'Fail',
|
3d36a443
Nattapon Wongpaet
add constant
|
7
8
9
10
11
12
|
METHOD:{
GET : 'GET',
POST : 'POST',
PUT : 'PUT',
DELETE : 'DELETE'
},
|
479b9d98
sumatek
update use constants
|
13
14
15
16
|
RESPONSECONN:{
STATS:{
ETIMEDOUT:'ETIMEDOUT',
ECONNREFUSED : 'ECONNREFUSED',
|
449b0a7c
Nattapon Wongpaet
fix bug vizcard
|
17
18
|
ESOCKETTIMEDOUT : 'ESOCKETTIMEDOUT',
MISSING : 'Missing'
|
479b9d98
sumatek
update use constants
|
19
20
21
22
23
24
25
26
27
28
|
},
MESSAGE:{
ETIMEDOUT:{
resultCode : '50003',
resultDescription : 'Timeout'
},
ECONNREFUSED:{
resultCode : '50002',
resultDescription : 'Reject'
},
|
449b0a7c
Nattapon Wongpaet
fix bug vizcard
|
29
30
31
32
|
ESOCKETTIMEDOUT:{
resultCode : '50003',
resultDescription : 'Timeout'
},
|
479b9d98
sumatek
update use constants
|
33
34
35
36
37
38
39
|
ERROR:{
resultCode : '50000',
resultDescription : 'System error'
},
SUCCESS:{
resultCode : '20000',
resultDescription : 'Success'
|
27aed231
Nattapon Wongpaet
update post membe...
|
40
41
42
43
|
}
}
},
RESPONSERESULT:{
|
479b9d98
sumatek
update use constants
|
44
45
46
|
SUCCESS:{
resultCode : '20000',
developerMessage : 'Success'
|
3d36a443
Nattapon Wongpaet
add constant
|
47
48
49
|
},
MISSING_INVALID:{
resultCode : '40300',
|
90f9d224
sumatek
update unknow req
|
50
|
developerMessage : 'Missing or invalid parameter'
|
3d36a443
Nattapon Wongpaet
add constant
|
51
52
53
|
},
DATA_NOT_FOUND:{
resultCode : '40401',
|
90f9d224
sumatek
update unknow req
|
54
|
developerMessage : 'Data Not Found'
|
3d36a443
Nattapon Wongpaet
add constant
|
55
56
57
|
},
DATA_EXIST:{
resultCode : '40301',
|
90f9d224
sumatek
update unknow req
|
58
|
developerMessage : 'Data Exist'
|
3d36a443
Nattapon Wongpaet
add constant
|
59
60
61
|
},
ERROR:{
resultCode : '50000',
|
90f9d224
sumatek
update unknow req
|
62
|
developerMessage : 'System error'
|
3d36a443
Nattapon Wongpaet
add constant
|
63
64
65
|
},
UNKNOW:{
resultCode : '40400',
|
90f9d224
sumatek
update unknow req
|
66
|
developerMessage : 'Unknown URL'
|
479b9d98
sumatek
update use constants
|
67
68
69
|
}
}
});
|
3d36a443
Nattapon Wongpaet
add constant
|
|
|