using Newtonsoft.Json; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace KdanCommon.CMSCollection.Data { public partial class ViewerEventBarSettingResponse { [JsonProperty("data")] public ViewerEventBarSetting[] Data { get; set; } } public partial class ViewerEventBarSetting : ISetting { public string SettingName { get { return "ViewerEventBarSetting"; } } [JsonProperty("id")] public long Id { get; set; } [JsonProperty("event_name")] public string EventName { get; set; } [JsonProperty("target_user")] public string TargetUser { get; set; } [JsonProperty("start_time")] public long StartTime { get; set; } [JsonProperty("end_time")] public long EndTime { get; set; } [JsonProperty("event_bar_text_color")] public string EventBarTextColor { get; set; } [JsonProperty("event_bar_background_color")] public string EventBarBackgroundColor { get; set; } [JsonProperty("event_bar_link_url")] public Uri EventBarLinkUrl { get; set; } [JsonProperty("event_bar_icon_image")] public string EventBarIconImage { get; set; } public string EventBarIconImageUrlStr { get { if (string.IsNullOrEmpty(EventBarIconImage)) return null; return $"{CMSCollection.CMSDomain}/assets/{EventBarIconImage}"; } } [JsonProperty("event_bar_close_button_image")] public string EventBarCloseButtonImage { get; set; } public string EventBarCloseButtonImageUrlStr { get { if (string.IsNullOrEmpty(EventBarCloseButtonImage)) return null; return $"{CMSCollection.CMSDomain}/assets/{EventBarCloseButtonImage}"; } } [JsonProperty("event_bar_icon_visible")] public bool EventBarIconVisible { get; set; } [JsonProperty("event_bar_close_button_visible")] public bool EventBarCloseButtonVisible { get; set; } [JsonProperty("dialog_text_color")] public string DialogTextColor { get; set; } [JsonProperty("dialog_background_color")] public string DialogBackgroundColor { get; set; } [JsonProperty("dialog_image")] public string DialogImage { get; set; } public string DialogImageUrlStr { get { if (string.IsNullOrEmpty(DialogImage)) return null; return $"{CMSCollection.CMSDomain}/assets/{DialogImage}"; } } [JsonProperty("dialog_close_icon_image")] public string DialogCloseIconImage { get; set; } public string DialogCloseIconImageUrlStr { get { if (string.IsNullOrEmpty(DialogCloseIconImage)) return null; return $"{CMSCollection.CMSDomain}/assets/{DialogCloseIconImage}"; } } [JsonProperty("dialog_close_button_visible")] public bool DialogCloseButtonVisible { get; set; } [JsonProperty("do_not_show_checkbox_checked_color")] public string DoNotShowCheckboxCheckedColor { get; set; } [JsonProperty("do_not_show_checkbox_unchecked_color")] public string DoNotShowCheckboxUncheckedColor { get; set; } [JsonProperty("do_not_show_visible")] public bool DoNotShowVisible { get; set; } [JsonProperty("event_visible")] public bool EventVisible { get; set; } [JsonProperty("platform")] public string Platform { get; set; } [JsonProperty("do_not_show_checkbox_text_color")] public string DoNotShowCheckboxTextColor { get; set; } [JsonProperty("evnet_bar_text_translations")] public Translation[] EvnetBarTextTranslations { get; set; } [JsonProperty("dialog_text_translations")] public Translation[] DialogTextTranslations { get; set; } [JsonProperty("dialog_button")] public DialogButton[] DialogButton { get; set; } [JsonProperty("do_not_show_translations")] public Translation[] DoNotShowTranslations { get; set; } [JsonProperty("do_not_show_dialog")] public bool DoNotShowDialog { get; set; } [JsonProperty("regions")] public string[] Regions { get; set; } } public partial class DialogButton { [JsonProperty("id")] public long Id { get; set; } [JsonProperty("dialog_button_text_color")] public string DialogButtonTextColor { get; set; } [JsonProperty("dialog_button_background_color")] public string DialogButtonBackgroundColor { get; set; } [JsonProperty("dialog_button_url")] public Uri DialogButtonUrl { get; set; } [JsonProperty("dialog_button_border_color")] public string DialogButtonBorderColor { get; set; } [JsonProperty("dialog_button_sort")] public long DialogButtonSort { get; set; } [JsonProperty("dialog_button_translations")] public Translation[] DialogButtonTranslations { get; set; } } public partial class Translation { [JsonProperty("id")] public long Id { get; set; } [JsonProperty("languages_code")] public string LanguagesCode { get; set; } [JsonProperty("content")] public string Content { get; set; } } }