Skip to content

feat: 어드민 전용 API에 인증 로직 추가#350

Merged
kdkdhoho merged 2 commits intodevfrom
feat/349
Jan 28, 2025
Merged

feat: 어드민 전용 API에 인증 로직 추가#350
kdkdhoho merged 2 commits intodevfrom
feat/349

Conversation

@kdkdhoho
Copy link
Collaborator

Description

Notice와 Topic 관련, 어드민 전용 API에 인증 로직을 적용했습니다.
Controller에서 @Auth 를 적용해서 인증 로직을 타도록 했습니다.

인증만하고 끝내기는 심심해서 Notice의 경우에는 createAdminlastUpdateAdmin 필드를 추가하여 누가 생성하고 마지막으로 수정했는지 기록을 남도록 구현했습니다.

Topic은 관리자의 정보를 저장해도 유용하지 않을 것 같아 그냥 두었습니다.

Relation Issues

@kdkdhoho kdkdhoho self-assigned this Jan 27, 2025
@kdkdhoho kdkdhoho requested a review from pparkjs as a code owner January 27, 2025 04:28
@kdkdhoho kdkdhoho linked an issue Jan 27, 2025 that may be closed by this pull request
Copy link
Collaborator

@pparkjs pparkjs 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 +53 to +58
public Notice(NoticeType type, NoticeTitle title, NoticeDescription description, Admin createAdmin) {
this.type = type;
this.title = title;
this.description = description;
this.createAdmin = createAdmin;
this.lastUpdateAdmin = createAdmin;
Copy link
Collaborator

Choose a reason for hiding this comment

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

맞아요 어드민은 무조건 어떤 관리자가 수정했는지 기록이 남아야한다고 하더라고여 책임 때문에

@kdkdhoho kdkdhoho merged commit acd9a7d into dev Jan 28, 2025
1 check passed
@kdkdhoho kdkdhoho deleted the feat/349 branch January 28, 2025 05:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

어드민 전용 API에 인증 로직을 적용합니다.

2 participants