Open
Conversation
- 수정 버튼 옆의 '가' 지우기
- 질문 데이터가 보유한 모든 답변 데이터의 삭제 상태가 true를 가지는 경우
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
현재의 요구사항 정리
현재의 요구사항을 고려했을 때 질문데이터와 답변데이터는 완전한 삭제가 아닌 삭제 상태를 갖는다. 그렇기 때문에 데이터는 삭제라는 '상태'를 가지고, view에서 보여질 때는 삭제 상태인지 아닌지를 판단 후 보여져야 한다. 데이터의 완전한 삭제를 고려하지 않으니 영속성 전이 속성 또한 아직은 필요하지 않을 것 같다.
질문 데이터가 삭제될 수 있는 선택지에는
기존 구현에서 수정되어야 할 부분
댓글을 생성 후 해당 사용자인지 아닌지를 검사 후 해당 사용자일 경우 댓글 삭제 버튼이 보이도록 구현을 생각했음. 생각을 다시해보니 댓글을 작성할 수 있는 권한은 해당 사용자에게만 있는데 작성 후 보여지는 페이지에서 작성자인지 아닌지를 검사할 필요가 없다고 생각함. -> (추후 수정 예정)
e.preventDefault() : 서버로 데이터 전송 기능을 막음