예약 업로드 추가
This commit is contained in:
@@ -34,6 +34,7 @@ final class ContentCreateViewModel: ObservableObject {
|
||||
}
|
||||
|
||||
@Published var isAvailableComment = true
|
||||
@Published var isActiveReservation = false
|
||||
@Published var isAdult = false
|
||||
@Published var priceString = "0" {
|
||||
didSet {
|
||||
@@ -63,6 +64,20 @@ final class ContentCreateViewModel: ObservableObject {
|
||||
|
||||
@Published var previewStartTime: String = ""
|
||||
@Published var previewEndTime: String = ""
|
||||
@Published var releaseDateString: String = Date().convertDateFormat(dateFormat: "yyyy.MM.dd")
|
||||
@Published var releaseTimeString: String = Date().convertDateFormat(dateFormat: "a hh:mm")
|
||||
|
||||
var releaseDate = Date() {
|
||||
willSet {
|
||||
releaseDateString = newValue.convertDateFormat(dateFormat: "yyyy.MM.dd")
|
||||
}
|
||||
}
|
||||
|
||||
var releaseTime = Date() {
|
||||
willSet {
|
||||
releaseTimeString = newValue.convertDateFormat(dateFormat: "a hh:mm")
|
||||
}
|
||||
}
|
||||
|
||||
var placeholder = "내용을 입력하세요"
|
||||
|
||||
@@ -75,6 +90,8 @@ final class ContentCreateViewModel: ObservableObject {
|
||||
detail: detail,
|
||||
tags: hashtags,
|
||||
price: price,
|
||||
releaseDate: isActiveReservation ? "\(releaseDate.convertDateFormat(dateFormat: "yyyy-MM-dd")) \(releaseTime.convertDateFormat(dateFormat: "HH:mm"))" : nil,
|
||||
timezone: TimeZone.current.identifier,
|
||||
themeId: theme!.id,
|
||||
isAdult: isAdult,
|
||||
isOnlyRental: isOnlyRental,
|
||||
|
||||
Reference in New Issue
Block a user