-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathSitePage.swift
More file actions
63 lines (58 loc) · 1.33 KB
/
SitePage.swift
File metadata and controls
63 lines (58 loc) · 1.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
//
// SitePage.swift
// Sakai
//
// Created by Alastair Hendricks on 2020/03/15.
//
import Foundation
public struct SitePage: Decodable {
public let id: String
public let siteID: String
public let position: Int?
public let url: URL
public let title: String?
public let skin: String?
public let layoutTitle: String?
public let tools: [SitePageTool]?
enum CodingKeys: String, CodingKey {
case id
case siteID = "siteId"
case position
case url
case title
case skin
case layoutTitle
case tools
}
}
public struct SitePageTool: Decodable {
public let toolId: String?
public let pageOrder: Int?
public let placementId: String?
public let context: String?
public let description: String?
public let siteId: String?
public let id: String
public let title: String?
public let pageId: String?
public let url : URL?
public let home: Bool?
public var toolPath: String {
get {
return "/portal/tool-reset/\(id)"
}
}
enum CodingKeys: String, CodingKey {
case toolId
case pageOrder
case siteId
case id
case title
case pageId
case url
case placementId
case context
case description
case home
}
}