forked from mirrors/linphone-iphone
Reset scheduler data when opening a new conf scheduling view
This commit is contained in:
parent
4647b00b9e
commit
9bdd3c088e
2 changed files with 21 additions and 0 deletions
|
|
@ -20,6 +20,7 @@ struct MeetingsView: View {
|
|||
|
||||
Button {
|
||||
withAnimation {
|
||||
scheduleMeetingViewModel.resetViewModelData()
|
||||
isShowScheduleMeetingFragment.toggle()
|
||||
}
|
||||
} label: {
|
||||
|
|
|
|||
|
|
@ -62,7 +62,27 @@ class ScheduleMeetingViewModel: ObservableObject {
|
|||
init() {
|
||||
fromDate = Calendar.current.date(byAdding: .hour, value: 1, to: Date.now)!
|
||||
toDate = Calendar.current.date(byAdding: .hour, value: 2, to: Date.now)!
|
||||
computeDateLabels()
|
||||
computeTimeLabels()
|
||||
updateTimezone()
|
||||
}
|
||||
|
||||
func resetViewModelData() {
|
||||
isBroadcastSelected = false
|
||||
showBroadcastHelp = false
|
||||
subject = ""
|
||||
description = ""
|
||||
allDayMeeting = false
|
||||
timezone = ""
|
||||
sendInvitations = true
|
||||
participantsToAdd = []
|
||||
participants = []
|
||||
operationInProgress = false
|
||||
conferenceCreatedEvent = false
|
||||
searchField = ""
|
||||
|
||||
fromDate = Calendar.current.date(byAdding: .hour, value: 1, to: Date.now)!
|
||||
toDate = Calendar.current.date(byAdding: .hour, value: 2, to: Date.now)!
|
||||
computeDateLabels()
|
||||
computeTimeLabels()
|
||||
updateTimezone()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue