@longvansoftware/storefront-js-client 2.2.5 → 2.2.7-beta.1

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.
@@ -2,298 +2,298 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.GET_PERSON_BY_PARTY_ID = exports.GET_WARDS = exports.GET_DISTRICTS = exports.GET_PROVINCES = exports.GET_CONTACT_INFOS_BY_COMPANY_ID = exports.GET_COMPANY_BY_CONTACT_INFO_ID = exports.GET_EMPLOYEES_BY_STORE_CHANEL_ID = exports.GET_STORE_CHANEL_IDS_BY_EMPLOYESS_ID = exports.GET_POSTIONS_BY_EMPLOYEES_ID = exports.SEARCH_EMPLOYEES = exports.SEARCH_CUSTOMER = exports.GET_CUSTOMER_BY_ID = exports.SEARCH_COMPANY = exports.GET_PERSON_BY_IDS_QUERY = void 0;
4
4
  const graphql_tag_1 = require("graphql-tag");
5
- exports.GET_PERSON_BY_IDS_QUERY = (0, graphql_tag_1.gql) `
6
- query GetPersonByIds($partyIds: [String!]!) {
7
- getPersonByPartyIds(partyIds: $partyIds) {
8
- status
9
- partyId
10
- fullName
11
- phone
12
- address
13
- gender
14
- birthDate
15
- email
16
- personalTitle
17
- imageUrl
18
- identityNumber
19
- id
20
- addressModel {
21
- id
22
- addressInfo
23
- provinceGeoId
24
- districtGeoId
25
- wardGeoId
26
- provinceName
27
- districtName
28
- wardName
29
- isDefault
30
- }
31
- }
32
- }
5
+ exports.GET_PERSON_BY_IDS_QUERY = (0, graphql_tag_1.gql) `
6
+ query GetPersonByIds($partyIds: [String!]!) {
7
+ getPersonByPartyIds(partyIds: $partyIds) {
8
+ status
9
+ partyId
10
+ fullName
11
+ phone
12
+ address
13
+ gender
14
+ birthDate
15
+ email
16
+ personalTitle
17
+ imageUrl
18
+ identityNumber
19
+ id
20
+ addressModel {
21
+ id
22
+ addressInfo
23
+ provinceGeoId
24
+ districtGeoId
25
+ wardGeoId
26
+ provinceName
27
+ districtName
28
+ wardName
29
+ isDefault
30
+ }
31
+ }
32
+ }
33
33
  `;
34
- exports.SEARCH_COMPANY = (0, graphql_tag_1.gql) `
35
- query SearchCompany($keyword: String, $orgId: String!, $limit: Int) {
36
- searchCompany(keyword: $keyword, orgId: $orgId, limit: $limit) {
37
- id
38
- name
39
- address
40
- gender
41
- identityNumber
42
- birthDate
43
- email
44
- phone
45
- createdStamp
46
- createdBy
47
- memberLevel
48
- }
49
- }
34
+ exports.SEARCH_COMPANY = (0, graphql_tag_1.gql) `
35
+ query SearchCompany($keyword: String, $orgId: String!, $limit: Int) {
36
+ searchCompany(keyword: $keyword, orgId: $orgId, limit: $limit) {
37
+ id
38
+ name
39
+ address
40
+ gender
41
+ identityNumber
42
+ birthDate
43
+ email
44
+ phone
45
+ createdStamp
46
+ createdBy
47
+ memberLevel
48
+ }
49
+ }
50
50
  `;
51
- exports.GET_CUSTOMER_BY_ID = (0, graphql_tag_1.gql) `
52
- query GetCustomerById($id: String!) {
53
- getCustomerById(id: $id) {
54
- id
55
- name
56
- address
57
- gender
58
- identityNumber
59
- birthDate
60
- email
61
- phone
62
- createdStamp
63
- createdBy
64
- memberLevel
65
- }
66
- }
51
+ exports.GET_CUSTOMER_BY_ID = (0, graphql_tag_1.gql) `
52
+ query GetCustomerById($id: String!) {
53
+ getCustomerById(id: $id) {
54
+ id
55
+ name
56
+ address
57
+ gender
58
+ identityNumber
59
+ birthDate
60
+ email
61
+ phone
62
+ createdStamp
63
+ createdBy
64
+ memberLevel
65
+ }
66
+ }
67
67
  `;
68
- exports.SEARCH_CUSTOMER = (0, graphql_tag_1.gql) `
69
- query SearchCustomers(
70
- $keyword: String
71
- $type: String
72
- $startCreatedDate: DateCustom
73
- $endCreatedDate: DateCustom
74
- $memberLevel: String
75
- $partnerId: String!
76
- $currentPage: Int!
77
- $pageSize: Int!
78
- $followSocialAppId: String
79
- ) {
80
- searchCustomers(
81
- keyword: $keyword
82
- type: $type
83
- startCreatedDate: $startCreatedDate
84
- endCreatedDate: $endCreatedDate
85
- memberLevel: $memberLevel
86
- partnerId: $partnerId
87
- currentPage: $currentPage
88
- pageSize: $pageSize
89
- followSocialAppId: $followSocialAppId
90
- ) {
91
- totalPages
92
- totalElements
93
- currentPage
94
- content {
95
- id
96
- name
97
- address
98
- gender
99
- identityNumber
100
- birthDate
101
- email
102
- phone
103
- createdStamp
104
- createdBy
105
- memberLevel
106
- }
107
- }
108
- }
68
+ exports.SEARCH_CUSTOMER = (0, graphql_tag_1.gql) `
69
+ query SearchCustomers(
70
+ $keyword: String
71
+ $type: String
72
+ $startCreatedDate: DateCustom
73
+ $endCreatedDate: DateCustom
74
+ $memberLevel: String
75
+ $partnerId: String!
76
+ $currentPage: Int!
77
+ $pageSize: Int!
78
+ $followSocialAppId: String
79
+ ) {
80
+ searchCustomers(
81
+ keyword: $keyword
82
+ type: $type
83
+ startCreatedDate: $startCreatedDate
84
+ endCreatedDate: $endCreatedDate
85
+ memberLevel: $memberLevel
86
+ partnerId: $partnerId
87
+ currentPage: $currentPage
88
+ pageSize: $pageSize
89
+ followSocialAppId: $followSocialAppId
90
+ ) {
91
+ totalPages
92
+ totalElements
93
+ currentPage
94
+ content {
95
+ id
96
+ name
97
+ address
98
+ gender
99
+ identityNumber
100
+ birthDate
101
+ email
102
+ phone
103
+ createdStamp
104
+ createdBy
105
+ memberLevel
106
+ }
107
+ }
108
+ }
109
109
  `;
110
- exports.SEARCH_EMPLOYEES = (0, graphql_tag_1.gql) `
111
- query SearchEmployees(
112
- $keyword: String
113
- $positionShortName: String
114
- $partnerId: String
115
- ) {
116
- searchEmployees(
117
- keyword: $keyword
118
- positionShortName: $positionShortName
119
- partnerId: $partnerId
120
- ) {
121
- id
122
- name
123
- address
124
- gender
125
- identityNumber
126
- birthDate
127
- email
128
- phone
129
- createdStamp
130
- createdBy
131
- memberLevel
132
- }
133
- }
110
+ exports.SEARCH_EMPLOYEES = (0, graphql_tag_1.gql) `
111
+ query SearchEmployees(
112
+ $keyword: String
113
+ $positionShortName: String
114
+ $partnerId: String
115
+ ) {
116
+ searchEmployees(
117
+ keyword: $keyword
118
+ positionShortName: $positionShortName
119
+ partnerId: $partnerId
120
+ ) {
121
+ id
122
+ name
123
+ address
124
+ gender
125
+ identityNumber
126
+ birthDate
127
+ email
128
+ phone
129
+ createdStamp
130
+ createdBy
131
+ memberLevel
132
+ }
133
+ }
134
134
  `;
135
- exports.GET_POSTIONS_BY_EMPLOYEES_ID = (0, graphql_tag_1.gql) `
136
- query GetPositionsByEmployeeId($employeeId: String!, $partnerId: String!) {
137
- getPositionsByEmployeeId(employeeId: $employeeId, partnerId: $partnerId)
138
- }
135
+ exports.GET_POSTIONS_BY_EMPLOYEES_ID = (0, graphql_tag_1.gql) `
136
+ query GetPositionsByEmployeeId($employeeId: String!, $partnerId: String!) {
137
+ getPositionsByEmployeeId(employeeId: $employeeId, partnerId: $partnerId)
138
+ }
139
139
  `;
140
- exports.GET_STORE_CHANEL_IDS_BY_EMPLOYESS_ID = (0, graphql_tag_1.gql) `
141
- query GetStoreChannelIdsByEmployeeId(
142
- $employeeId: String!
143
- $partnerId: String!
144
- ) {
145
- getStoreChannelIdsByEmployeeId(
146
- employeeId: $employeeId
147
- partnerId: $partnerId
148
- )
149
- }
140
+ exports.GET_STORE_CHANEL_IDS_BY_EMPLOYESS_ID = (0, graphql_tag_1.gql) `
141
+ query GetStoreChannelIdsByEmployeeId(
142
+ $employeeId: String!
143
+ $partnerId: String!
144
+ ) {
145
+ getStoreChannelIdsByEmployeeId(
146
+ employeeId: $employeeId
147
+ partnerId: $partnerId
148
+ )
149
+ }
150
150
  `;
151
- exports.GET_EMPLOYEES_BY_STORE_CHANEL_ID = (0, graphql_tag_1.gql) `
152
- query GetEmployeesByStoreChannelId(
153
- $storeChannelId: String!
154
- $partnerId: String!
155
- ) {
156
- getEmployeesByStoreChannelId(
157
- storeChannelId: $storeChannelId
158
- partnerId: $partnerId
159
- ) {
160
- id
161
- name
162
- address
163
- gender
164
- identityNumber
165
- birthDate
166
- email
167
- phone
168
- createdStamp
169
- createdBy
170
- memberLevel
171
- }
172
- }
151
+ exports.GET_EMPLOYEES_BY_STORE_CHANEL_ID = (0, graphql_tag_1.gql) `
152
+ query GetEmployeesByStoreChannelId(
153
+ $storeChannelId: String!
154
+ $partnerId: String!
155
+ ) {
156
+ getEmployeesByStoreChannelId(
157
+ storeChannelId: $storeChannelId
158
+ partnerId: $partnerId
159
+ ) {
160
+ id
161
+ name
162
+ address
163
+ gender
164
+ identityNumber
165
+ birthDate
166
+ email
167
+ phone
168
+ createdStamp
169
+ createdBy
170
+ memberLevel
171
+ }
172
+ }
173
173
  `;
174
- exports.GET_COMPANY_BY_CONTACT_INFO_ID = (0, graphql_tag_1.gql) `
175
- query GetCompanyByContactInfoId($contactId: String!, $partnerId: String!) {
176
- getCompanyByContactInfoId(contactId: $contactId, partnerId: $partnerId) {
177
- id
178
- name
179
- address
180
- gender
181
- identityNumber
182
- birthDate
183
- email
184
- phone
185
- createdStamp
186
- createdBy
187
- memberLevel
188
- }
189
- }
174
+ exports.GET_COMPANY_BY_CONTACT_INFO_ID = (0, graphql_tag_1.gql) `
175
+ query GetCompanyByContactInfoId($contactId: String!, $partnerId: String!) {
176
+ getCompanyByContactInfoId(contactId: $contactId, partnerId: $partnerId) {
177
+ id
178
+ name
179
+ address
180
+ gender
181
+ identityNumber
182
+ birthDate
183
+ email
184
+ phone
185
+ createdStamp
186
+ createdBy
187
+ memberLevel
188
+ }
189
+ }
190
190
  `;
191
- exports.GET_CONTACT_INFOS_BY_COMPANY_ID = (0, graphql_tag_1.gql) `
192
- query GetContactInfosByCompanyId($companyId: String!, $partnerId: String!) {
193
- getContactInfosByCompanyId(companyId: $companyId, partnerId: $partnerId) {
194
- id
195
- name
196
- address
197
- gender
198
- identityNumber
199
- birthDate
200
- email
201
- phone
202
- createdStamp
203
- createdBy
204
- memberLevel
205
- }
206
- }
191
+ exports.GET_CONTACT_INFOS_BY_COMPANY_ID = (0, graphql_tag_1.gql) `
192
+ query GetContactInfosByCompanyId($companyId: String!, $partnerId: String!) {
193
+ getContactInfosByCompanyId(companyId: $companyId, partnerId: $partnerId) {
194
+ id
195
+ name
196
+ address
197
+ gender
198
+ identityNumber
199
+ birthDate
200
+ email
201
+ phone
202
+ createdStamp
203
+ createdBy
204
+ memberLevel
205
+ }
206
+ }
207
207
  `;
208
- exports.GET_PROVINCES = (0, graphql_tag_1.gql) `
209
- query GetProvinces {
210
- getProvinces {
211
- geoId
212
- geoTypeId
213
- geoName
214
- geoNameLocal
215
- geoCode
216
- geoSecCode
217
- abbreviation
218
- vnPostId
219
- jtExpressId
220
- vnPostRegion
221
- inetId
222
- lastUpdatedStamp
223
- lastUpdatedTxStamp
224
- createdStamp
225
- createdTxStamp
226
- }
227
- }
208
+ exports.GET_PROVINCES = (0, graphql_tag_1.gql) `
209
+ query GetProvinces {
210
+ getProvinces {
211
+ geoId
212
+ geoTypeId
213
+ geoName
214
+ geoNameLocal
215
+ geoCode
216
+ geoSecCode
217
+ abbreviation
218
+ vnPostId
219
+ jtExpressId
220
+ vnPostRegion
221
+ inetId
222
+ lastUpdatedStamp
223
+ lastUpdatedTxStamp
224
+ createdStamp
225
+ createdTxStamp
226
+ }
227
+ }
228
228
  `;
229
- exports.GET_DISTRICTS = (0, graphql_tag_1.gql) `
230
- query GetDistricts($provinceId: String!) {
231
- getDistricts(provinceId: $provinceId) {
232
- geoId
233
- geoTypeId
234
- geoName
235
- geoNameLocal
236
- geoCode
237
- geoSecCode
238
- abbreviation
239
- vnPostId
240
- jtExpressId
241
- vnPostRegion
242
- inetId
243
- lastUpdatedStamp
244
- lastUpdatedTxStamp
245
- createdStamp
246
- createdTxStamp
247
- }
248
- }
229
+ exports.GET_DISTRICTS = (0, graphql_tag_1.gql) `
230
+ query GetDistricts($provinceId: String!) {
231
+ getDistricts(provinceId: $provinceId) {
232
+ geoId
233
+ geoTypeId
234
+ geoName
235
+ geoNameLocal
236
+ geoCode
237
+ geoSecCode
238
+ abbreviation
239
+ vnPostId
240
+ jtExpressId
241
+ vnPostRegion
242
+ inetId
243
+ lastUpdatedStamp
244
+ lastUpdatedTxStamp
245
+ createdStamp
246
+ createdTxStamp
247
+ }
248
+ }
249
249
  `;
250
- exports.GET_WARDS = (0, graphql_tag_1.gql) `
251
- query GetWards($districtId: String!) {
252
- getWards(districtId: $districtId) {
253
- geoId
254
- geoTypeId
255
- geoName
256
- geoNameLocal
257
- geoCode
258
- geoSecCode
259
- abbreviation
260
- vnPostId
261
- jtExpressId
262
- vnPostRegion
263
- inetId
264
- lastUpdatedStamp
265
- lastUpdatedTxStamp
266
- createdStamp
267
- createdTxStamp
268
- }
269
- }
250
+ exports.GET_WARDS = (0, graphql_tag_1.gql) `
251
+ query GetWards($districtId: String!) {
252
+ getWards(districtId: $districtId) {
253
+ geoId
254
+ geoTypeId
255
+ geoName
256
+ geoNameLocal
257
+ geoCode
258
+ geoSecCode
259
+ abbreviation
260
+ vnPostId
261
+ jtExpressId
262
+ vnPostRegion
263
+ inetId
264
+ lastUpdatedStamp
265
+ lastUpdatedTxStamp
266
+ createdStamp
267
+ createdTxStamp
268
+ }
269
+ }
270
270
  `;
271
- exports.GET_PERSON_BY_PARTY_ID = (0, graphql_tag_1.gql) `
272
- query GetPersonByPartyId($partyId: String!) {
273
- getPersonByPartyId(partyId: $partyId) {
274
- status
275
- partyId
276
- fullName
277
- phone
278
- address
279
- gender
280
- birthDate
281
- email
282
- personalTitle
283
- imageUrl
284
- identityNumber
285
- id
286
- addressModel {
287
- id
288
- addressInfo
289
- provinceGeoId
290
- districtGeoId
291
- wardGeoId
292
- provinceName
293
- districtName
294
- wardName
295
- isDefault
296
- }
297
- }
298
- }
271
+ exports.GET_PERSON_BY_PARTY_ID = (0, graphql_tag_1.gql) `
272
+ query GetPersonByPartyId($partyId: String!) {
273
+ getPersonByPartyId(partyId: $partyId) {
274
+ status
275
+ partyId
276
+ fullName
277
+ phone
278
+ address
279
+ gender
280
+ birthDate
281
+ email
282
+ personalTitle
283
+ imageUrl
284
+ identityNumber
285
+ id
286
+ addressModel {
287
+ id
288
+ addressInfo
289
+ provinceGeoId
290
+ districtGeoId
291
+ wardGeoId
292
+ provinceName
293
+ districtName
294
+ wardName
295
+ isDefault
296
+ }
297
+ }
298
+ }
299
299
  `;
@@ -24,4 +24,17 @@ export declare class AuthService extends Service {
24
24
  */
25
25
  register(registerRequest: RegisterRequest): Promise<void>;
26
26
  getUserDetail(accessToken: string): Promise<any>;
27
+ /**
28
+ * Retrieves user login information using the provided access token.
29
+ *
30
+ * @param {string} accessToken - The access token used to authenticate the request.
31
+ * @returns {Promise<any>} A promise that resolves to the user login information.
32
+ * @throws Will throw an error if the GraphQL query fails.
33
+ */
34
+ getUserLoginByToken(accessToken: string): Promise<any>;
35
+ updateProfile(userLoginId: string, name: string, phone: string, email: string): Promise<any>;
36
+ getUserLoginByUserLoginId(userLoginId: string): Promise<any>;
37
+ checkUsernameExisted(username: string): Promise<any>;
38
+ linkingUserLoginAndUserDetail(userLoginId: string, partyId: string): Promise<any>;
39
+ createUserDetail(userLoginId: string): Promise<any>;
27
40
  }