mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 02:58:07 +00:00
Fix "No meeting today" line not appearing if all meetings in the list are in the past
This commit is contained in:
parent
0b28aa5179
commit
00187e97a2
2 changed files with 7 additions and 1 deletions
|
|
@ -137,7 +137,7 @@ struct MeetingsFragment: View {
|
|||
Text("No meeting today")
|
||||
.fontWeight(.bold)
|
||||
.padding(.leading, 20)
|
||||
.padding(.top, 10)
|
||||
.padding(.top, 15)
|
||||
.default_text_style_500(styleSize: 15)
|
||||
} else {
|
||||
createMeetingLine(model: itemModel)
|
||||
|
|
|
|||
|
|
@ -108,6 +108,12 @@ class MeetingsListViewModel: ObservableObject {
|
|||
}
|
||||
}
|
||||
|
||||
if !meetingForTodayFound && !meetingsListTmp.isEmpty {
|
||||
// All meetings in the list happened in the past, add "Today" fake model at the end
|
||||
meetingsListTmp.append(MeetingsListItemModel(meetingModel: nil))
|
||||
todayIdx = currentIdx
|
||||
}
|
||||
|
||||
DispatchQueue.main.sync {
|
||||
self.todayIdx = todayIdx
|
||||
self.meetingsList = meetingsListTmp
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue