generated from pricelees/issue-pr-template
[#44] 매장 기능 도입 #45
@ -4,11 +4,8 @@ import jakarta.persistence.Column
|
||||
import jakarta.persistence.Entity
|
||||
import jakarta.persistence.EntityListeners
|
||||
import jakarta.persistence.Table
|
||||
import org.springframework.data.annotation.CreatedDate
|
||||
import org.springframework.data.annotation.LastModifiedDate
|
||||
import org.springframework.data.jpa.domain.support.AuditingEntityListener
|
||||
import roomescape.common.entity.PersistableBaseEntity
|
||||
import java.time.LocalDateTime
|
||||
import roomescape.common.entity.AuditingBaseEntity
|
||||
|
||||
@Entity
|
||||
@EntityListeners(AuditingEntityListener::class)
|
||||
@ -29,12 +26,4 @@ class StoreEntity(
|
||||
val businessRegNum: String,
|
||||
|
||||
val regionCode: String,
|
||||
) : PersistableBaseEntity(id) {
|
||||
|
||||
@CreatedDate
|
||||
@Column(updatable = false)
|
||||
lateinit var createdAt: LocalDateTime
|
||||
|
||||
@LastModifiedDate
|
||||
lateinit var updatedAt: LocalDateTime
|
||||
}
|
||||
) : AuditingBaseEntity(id)
|
||||
|
||||
@ -17,7 +17,9 @@ create table if not exists store(
|
||||
region_code varchar(10) not null,
|
||||
|
||||
created_at timestamp not null,
|
||||
created_by bigint not null,
|
||||
updated_at timestamp not null,
|
||||
updated_by bigint not null,
|
||||
|
||||
constraint uk_store__name unique (name),
|
||||
constraint uk_store__contact unique (contact),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user