Unverified Commit 27e0f467 authored by Zach Knox's avatar Zach Knox
Browse files

model for Alerts

parent 6cfb20ae
......@@ -210,6 +210,30 @@ class OpenTimes: Object, Mappable {
}
class Alert: Object, Mappable {
@objc dynamic var id = 0
@objc dynamic var created = ""
@objc dynamic var lastModified = ""
@objc dynamic var urgency = ""
@objc dynamic var message = ""
@objc dynamic var startDate = ""
@objc dynamic var endDate = ""
convenience required init?(map: Map) {
self.init()
}
func mapping(map: Map){
id <- map["id"]
created <- map["created"]
lastModified <- map["modified"]
urgency <- map["urgency_tag"]
message <- map["message"]
startDate <- map["start_datetime"]
endDate <- map["end_datetime"]
}
}
/**struct OpenTimes: CreatableFromJSON { // TODO: Rename this struct
let endDay: Int
let endTime: Date
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment