Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4/12] Kan 22 Connect API (login, signup, autoLogin) #6

Merged
merged 3 commits into from
Apr 12, 2024
Merged

Conversation

sjsjmine129
Copy link
Collaborator

만들어두었던 회원가입, 로그인 API들 연결 성공

현재 회원가입, 로그인 됩니다!
회원가입, 로그인 하면 토큰이 기기에 저장되서 앱켜면 자동으로 로그인 되도록 해두었습니다!

Copy link
Collaborator

@m1nse0kim m1nse0kim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고하셨습니다!

Copy link
Member

@sinkyoungdeok sinkyoungdeok left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Comment on lines +20 to +37
const context = useContext(AppContext);

const helloAPI = async () => {
try {
const response = await axios.get(`${API_URL}/hello/security-test`, {
headers: {Authorization: `Bearer ${context.accessToken}`},
});

console.log('response:', response.data.data);

if (!response.data.data) {
console.log('Error: No return data');
return;
}
} catch (e) {
console.log('error', e);
}
};
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

해당 api는 나중에 제거할 예정인가여?
hello api들은 테스트용도로 둔거였어서 ㅎㅎ 어떤용도로 사용할지 궁금해서 여쭤봅니다

Copy link
Collaborator Author

@sjsjmine129 sjsjmine129 Apr 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

앱에 저장되어 있는 토큰이 있으면 이게 맞는 토큰인지 확인을 하는 부분입니다.
따로 API요청드릴까 했는데 토큰 보내고 맞으면 리턴주는 저 Hello가 있길래 저걸로 해뒀습니다.

나중에 진짜 확인용 API 로 교체하면 될거 같습니다

ps 기능은 그대로라 이대로 사용해도 무관합니다

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

아하 넵 그용도로 쓰셔도 괜찮습니다. 넵 그럼 그걸로생각하고 납둘게요.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

가 아니라 홈이네요 ㅋㅋㅋㅋㅋ

네 나중에 삭제할 예정입니다
다른 분들 APi쏘는 확인용으로 뒀습니다

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

위에 댓글에 내용은 Splash 스크린에 있습니다

코멘트 주신 부분은 나중에 삭제할 부분입니다!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

아 ㅎㅎ 넵넵 !

@sjsjmine129 sjsjmine129 merged commit cc2b3c7 into main Apr 12, 2024
1 check passed
@sjsjmine129 sjsjmine129 deleted the KAN-22 branch April 12, 2024 14:32
sjsjmine129 added a commit that referenced this pull request May 18, 2024
* Feat/APIconnect

* Feat/Auto Login with token

* Add/annotation
sjsjmine129 added a commit that referenced this pull request May 19, 2024
* Initial commit

* feat: auto assign (#1)

* Add/FirstSetting (#2)

* [4/7] Add/ screen folders and navigation controls (#3)

* Fi/gitignore

* Add/NavigationSetting_1

* Add/navigation_2

* Add/react-native-svg

* Add/Navigator_done

* [4/8] Fix navigation, Add env setting, Test axios (#4)

* Fi/gitignore

* Add/NavigationSetting_1

* Add/navigation_2

* Add/react-native-svg

* Add/Navigator_done

* Add/Header

* Add/env

* Fix

* Add/axios&Test

* [4/11] Kan 20 회원가입/로그인 화면 & 로직 구현 (#5)

* Add/loginScreen

* Add/signup screen

* Feat/loginAPI

* feat/sutoLogin

* Feat/Context -> 토큰을 전역변수로 사용하도록

* Fix/disablebutton

* Fix

* [4/12] Kan 22 Connect API (login, signup, autoLogin) (#6)

* Feat/APIconnect

* Feat/Auto Login with token

* Add/annotation

* [4/23 Kan 23] 홈 화면 UI 구현 (#7)

* Fix/ splash Font

* Add/ image

* Fix

* Add/Slider

* Add/ 오늘의 픽 창 UI

* Add/ 카테고리

* Fix/ compo set

* Add/ kingo Pass UI

* [4/27 Kan 27] 맵 스크린 UI 구현 (#8)

* [4/30] Add/ list screen UI (#9)

* Add/ list screen UI

* Add/category select in list

* Add/ category Fillter in map

* [5/10 Kan 43] 검색, 상세페이지들 페이지 구현 (#10)

* Add/SearchScreen

* Add/Store Detail, ReviewWrite Screen

* Add/userDataChangeScreen

* Fix/ ui Bug

* Fix/ ui Bug

* Add/passwordCheck

* Add/passwordCheck

* Fix/env

* Fix/env

* Fix

* Fix

* Add/email and validation

* Add/email and validation

* Add/ profileSetScreen

* Add/ profileSetScreen

* Fix

* Fix

* Add/ image picker

* Add/ image picker

* Fix

* Fix

* Add/signup

* Add/signup

* Add/resetPassword

* Add/resetPassword

* Fix/env

* Fix/env

* Delete/env,url data

* Fix/test

* Fix/ image

* Add/ImageModal

---------

Co-authored-by: Bob Sin <[email protected]>
Co-authored-by: Bob Sin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants