rts2003-so 1.4.1 → 1.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -6
- package/index.js +12 -11
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -61,12 +61,9 @@ const result = sso.userDelete({
|
|
|
61
61
|
});
|
|
62
62
|
|
|
63
63
|
// user get user for api
|
|
64
|
-
const result = sso.
|
|
65
|
-
"email": "string"
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
const result = sso.getOne({
|
|
69
|
-
"id": "string"
|
|
64
|
+
const result = sso.userGetOne({
|
|
65
|
+
"email": "string",
|
|
66
|
+
"id": 0
|
|
70
67
|
});
|
|
71
68
|
|
|
72
69
|
// user update password for api
|
package/index.js
CHANGED
|
@@ -31,16 +31,16 @@ class SingleSignOn {
|
|
|
31
31
|
if (!dataToSend.email) {
|
|
32
32
|
return { message: "Field email not found", statusCode: 400, error: false };
|
|
33
33
|
}
|
|
34
|
-
if (!
|
|
34
|
+
if (!dataToSend.first_name) {
|
|
35
35
|
return { message: "Field first_name not found", statusCode: 400, error: false };
|
|
36
36
|
}
|
|
37
|
-
if (!
|
|
37
|
+
if (!dataToSend.last_name) {
|
|
38
38
|
return { message: "Field last_name not found", statusCode: 400, error: false };
|
|
39
39
|
}
|
|
40
|
-
if (!
|
|
40
|
+
if (!dataToSend.is_active) {
|
|
41
41
|
return { message: "Field is_active not found", statusCode: 400, error: false };
|
|
42
42
|
}
|
|
43
|
-
if (!
|
|
43
|
+
if (!dataToSend.created_by) {
|
|
44
44
|
return { message: "Field created_by not found", statusCode: 400, error: false };
|
|
45
45
|
}
|
|
46
46
|
|
|
@@ -77,16 +77,16 @@ class SingleSignOn {
|
|
|
77
77
|
if (!dataToSend.id) {
|
|
78
78
|
return { message: "Field id not found", statusCode: 400, error: false };
|
|
79
79
|
}
|
|
80
|
-
if (!
|
|
80
|
+
if (!dataToSend.first_name) {
|
|
81
81
|
return { message: "Field first_name not found", statusCode: 400, error: false };
|
|
82
82
|
}
|
|
83
|
-
if (!
|
|
83
|
+
if (!dataToSend.last_name) {
|
|
84
84
|
return { message: "Field last_name not found", statusCode: 400, error: false };
|
|
85
85
|
}
|
|
86
|
-
if (!
|
|
86
|
+
if (!dataToSend.is_active) {
|
|
87
87
|
return { message: "Field is_active not found", statusCode: 400, error: false };
|
|
88
88
|
}
|
|
89
|
-
if (!
|
|
89
|
+
if (!dataToSend.updated_by) {
|
|
90
90
|
return { message: "Field updated_by not found", statusCode: 400, error: false };
|
|
91
91
|
}
|
|
92
92
|
|
|
@@ -120,7 +120,7 @@ class SingleSignOn {
|
|
|
120
120
|
if (!dataToSend.id) {
|
|
121
121
|
return { message: "Field id not found", statusCode: 400, error: false };
|
|
122
122
|
}
|
|
123
|
-
if (!
|
|
123
|
+
if (!dataToSend.deleted_by) {
|
|
124
124
|
return { message: "Field deleted_by not found", statusCode: 400, error: false };
|
|
125
125
|
}
|
|
126
126
|
|
|
@@ -140,8 +140,9 @@ class SingleSignOn {
|
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
|
|
143
|
-
async
|
|
144
|
-
email
|
|
143
|
+
async userGetOne(dataToSend = {
|
|
144
|
+
email,
|
|
145
|
+
id
|
|
145
146
|
}) {
|
|
146
147
|
try {
|
|
147
148
|
if (!this.endpoint) {
|
package/package.json
CHANGED