@daeryun/dr_components 1.2.79 → 1.2.81
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.
|
@@ -225,19 +225,26 @@ const StepOne = () => {
|
|
|
225
225
|
uuid: bodyData.uuid
|
|
226
226
|
})
|
|
227
227
|
});
|
|
228
|
+
// PATCH 성공 후 GET으로 상세 정보 조회
|
|
229
|
+
const userGetResponse = yield fetch(`/api/lawfirm/app/user`, {
|
|
230
|
+
method: 'GET',
|
|
231
|
+
headers: { 'Content-Type': 'application/json' },
|
|
232
|
+
credentials: 'include'
|
|
233
|
+
});
|
|
228
234
|
if (!userResponse.ok) {
|
|
229
235
|
throw new Error('사용자 정보 API 호출 실패');
|
|
230
236
|
}
|
|
237
|
+
const userData = yield userGetResponse.json();
|
|
231
238
|
return {
|
|
232
239
|
marketing: yield marketingResponse.json(),
|
|
233
|
-
user:
|
|
240
|
+
user: userData
|
|
234
241
|
};
|
|
235
242
|
}),
|
|
236
243
|
onSuccess: (data) => {
|
|
237
244
|
var _a, _b;
|
|
238
245
|
console.log('data: ', data);
|
|
239
246
|
const redirect = decodeURIComponent(getCookie('redirect')) || '/';
|
|
240
|
-
const newRedirect = appendUuidToRedirect(redirect, (_a = data === null || data === void 0 ? void 0 : data.user) === null || _a === void 0 ? void 0 : _a.
|
|
247
|
+
const newRedirect = appendUuidToRedirect(redirect, (_a = data === null || data === void 0 ? void 0 : data.user) === null || _a === void 0 ? void 0 : _a.data.idx);
|
|
241
248
|
setCookie({ key: 'redirect', value: newRedirect });
|
|
242
249
|
setModalObj({ title: '회원가입이 완료되었습니다.', subTitle: '' });
|
|
243
250
|
setIsModal(true);
|
|
@@ -291,19 +291,28 @@ const StepOne = () => {
|
|
|
291
291
|
})
|
|
292
292
|
});
|
|
293
293
|
|
|
294
|
+
// PATCH 성공 후 GET으로 상세 정보 조회
|
|
295
|
+
const userGetResponse = await fetch(`/api/lawfirm/app/user`, {
|
|
296
|
+
method: 'GET',
|
|
297
|
+
headers: { 'Content-Type': 'application/json' },
|
|
298
|
+
credentials: 'include'
|
|
299
|
+
});
|
|
300
|
+
|
|
294
301
|
if (!userResponse.ok) {
|
|
295
302
|
throw new Error('사용자 정보 API 호출 실패');
|
|
296
303
|
}
|
|
297
304
|
|
|
305
|
+
const userData = await userGetResponse.json()
|
|
306
|
+
|
|
298
307
|
return {
|
|
299
308
|
marketing: await marketingResponse.json(),
|
|
300
|
-
user:
|
|
309
|
+
user: userData
|
|
301
310
|
};
|
|
302
311
|
},
|
|
303
312
|
onSuccess: (data) => {
|
|
304
313
|
console.log('data: ', data);
|
|
305
314
|
const redirect = decodeURIComponent(getCookie('redirect')) || '/';
|
|
306
|
-
const newRedirect = appendUuidToRedirect(redirect, data?.user?.
|
|
315
|
+
const newRedirect = appendUuidToRedirect(redirect, data?.user?.data.idx);
|
|
307
316
|
setCookie({ key: 'redirect', value: newRedirect });
|
|
308
317
|
setModalObj({ title: '회원가입이 완료되었습니다.', subTitle: '' });
|
|
309
318
|
setIsModal(true);
|