-
Notifications
You must be signed in to change notification settings - Fork 15
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
Shared Status 이동 #639
Shared Status 이동 #639
Conversation
Co-authored-by: hgo641 <hgo641@gmail.com>
📝 Jacoco Test Coverage
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FIxture 네이밍 쯤이야..
if (this.sharedStatus.equals(SharedStatusType.SHARED)) { | ||
return Optional.empty(); | ||
} | ||
return Optional.of(sharedTrip.getSharedCode()); | ||
} | ||
|
||
public Boolean isShared() { | ||
return this.sharedStatus.equals(SharedStatusType.SHARED); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
아래에 만든 isShared()를 if문에 넣어도 될 듯 합니다.!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
사실 넣었었는데 소나린트가 저렇게 하라고 추천해주더라구요? 깔끔하게 isShared 갈까요?!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UNSHARED 아닌가용 ????
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
진짜 충격적 삼보일배하고 가겠습니다 라온
ALTER TABLE trip ADD COLUMN shared_status ENUM ('SHARED','UNSHARED'); | ||
UPDATE trip SET shared_status = 'UNSHARED'; | ||
ALTER TABLE trip MODIFY COLUMN shared_status ENUM ('SHARED','UNSHARED') NOT NULL; | ||
|
||
CREATE TABLE copy_shared_trip AS SELECT * FROM shared_trip; | ||
|
||
UPDATE trip INNER JOIN shared_trip ON trip.id = shared_trip.trip_id | ||
SET trip.shared_status = shared_trip.shared_status; | ||
|
||
ALTER TABLE shared_trip DROP COLUMN shared_status; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ㄷㄷ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍👍👍
* chore: shared_status 이동 쿼리 작성 Co-authored-by: hgo641 <hgo641@gmail.com> * refactor: shared_status 이동에 따른 프로덕션 코드 수정 * refactor: boolean primitive 타입으로 변경 * fix: if 조건 수정 --------- Co-authored-by: hgo641 <hgo641@gmail.com>
📄 Summary
#638
🙋🏻 More