Need help adding two UIPickers to one view

This commit is contained in:
Andrew
2021-01-27 00:09:48 -05:00
parent 1b8ba32c3f
commit fcf3c6d312
2 changed files with 8 additions and 3 deletions
+2 -1
View File
@@ -93,7 +93,8 @@ class AlarmTableCell: UITableViewCell
// Display Hour, Minute, and AM or PM
ampm.text = alarm.hour < 12 || alarm.hour == 24 ? "AM" : "PM"
let hour = alarm.hour <= 12 ? alarm.hour : alarm.hour - 12
var hour = alarm.hour <= 12 ? alarm.hour : alarm.hour - 12
hour = alarm.hour == 0 ? 12 : alarm.hour
time.text = String(format: "%i:%02i", hour, alarm.minute)
// displays the specific days alarm is activated