KMAdvertisementModel.swift 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. //
  2. // KMAdvertisementModel.swift
  3. // KMAdvertisement
  4. //
  5. // Created by lizhe on 2022/11/30.
  6. //
  7. @objcMembers public class KMAdvertisementInfo: NSObject, Codable {
  8. public var recommondContent: KMAdvertisementContent?
  9. public var advertisement: KMAdvertisementItem?
  10. public var remoteControl: KMAdvertisementRemoteControl?
  11. public var discountContent: KMAdvertisementItem?
  12. public var popWindowContent: KMAdvertisementItem?
  13. public var StoreUserRecovery: KMAdvertisementItem?
  14. }
  15. @objcMembers public class KMAdvertisementContent: NSObject, Codable {
  16. public var recommondContentOther: KMAdvertisementItem?
  17. public var recommondContentPDFPro: KMAdvertisementItem?
  18. }
  19. @objcMembers public class KMAdvertisementItem: NSObject, Codable {
  20. public var version: String?
  21. public var name: Language?
  22. public var content: [KMAdvertisementItemInfo]?
  23. }
  24. @objcMembers public class KMAdvertisementRemoteControl: NSObject, Codable {
  25. var showMenuHelpInfo: String?
  26. }
  27. @objcMembers public class KMAdvertisementItemInfo: NSObject, Codable {
  28. var index: Int?
  29. var show: String? //是否显示,内部有做了时间区间判断
  30. var subscriptionType: String? //类型
  31. var showType: KMAdvertisementShowType?
  32. var startTime: String?
  33. var endTime: String?
  34. var version: String? //版本号,唯一标识符
  35. var showCloseBtn: String? //是否显示关闭按钮,(左下角广告需要)
  36. var image: Image? //APP互推,常规状态下的图片
  37. var saleImage: Image? // 订阅折扣图片
  38. var iconImage: String? //广告显示图片(自适应多语)
  39. var name: Language? //名称(自适应多语)
  40. var tooltip: Language? //提示语(自适应多语)
  41. var linkURL: Language? //跳转链接(自适应多语)
  42. var subTitle: Language? //名称(自适应多语)
  43. var otherTitle: Language? //名称(自适应多语)
  44. var btnTitle: Language? //名称(自适应多语)
  45. //Firebase
  46. var firebase: firebaseInfo?
  47. var firebaseEvent: String?
  48. var firebasePropertyKey: String?
  49. var firebasePropertyValue: String?
  50. public class Image: NSObject, Codable {
  51. public let zh_TW: String?
  52. public let hover_Dark: String?
  53. public let hover_Light: String?
  54. public let zh_CN: String?
  55. public let normal_Light: String?
  56. public let normal_Dark: String?
  57. public let en: String?
  58. }
  59. }
  60. public class firebaseInfo: NSObject, Codable {
  61. var event: String?
  62. var propertyKey: String?
  63. var propertyValue: String?
  64. }
  65. public class Language: NSObject, Codable {
  66. var en: String?
  67. var zh_TW: String?
  68. var zh_CN: String?
  69. }