import 'dart:convert';

class GetGreetingCardsModelResponse {
  List<GetGreetingCardsModelResponseElement>? getGreetingCardsModelResponse;

  GetGreetingCardsModelResponse({
    this.getGreetingCardsModelResponse,
  });

  factory GetGreetingCardsModelResponse.fromRawJson(String str) => GetGreetingCardsModelResponse.fromJson(json.decode(str));

  String toRawJson() => json.encode(toJson());

  factory GetGreetingCardsModelResponse.fromJson(Map<String, dynamic> json) => GetGreetingCardsModelResponse(
    getGreetingCardsModelResponse: json["Get_GreetingCardsModel_Response"] == null ? [] : List<GetGreetingCardsModelResponseElement>.from(json["Get_GreetingCardsModel_Response"]!.map((x) => GetGreetingCardsModelResponseElement.fromJson(x))),
  );

  Map<String, dynamic> toJson() => {
    "Get_GreetingCardsModel_Response": getGreetingCardsModelResponse == null ? [] : List<dynamic>.from(getGreetingCardsModelResponse!.map((x) => x.toJson())),
  };
}

class GetGreetingCardsModelResponseElement {
  String? backgroundImageUrlAr;
  String? backgroundImageUrlEn;
  String? buttonBgColor;
  String? buttonText;
  String? buttonTextN;
  int? cardType;
  int? categoryId;
  String? categoryNameAr;
  String? categoryNameEn;
  int? channel;
  String? createdOn;
  String? descriptionAr;
  String? descriptionEn;
  String? endDate;
  bool? hasButton;
  int? id;
  bool? isActive;
  int? moduleId;
  String? moduleName;
  String? moduleNameN;
  String? startDate;
  String? textColor;
  String? titleAr;
  String? titleEn;
  String? urlAr;
  String? urlEn;

  GetGreetingCardsModelResponseElement({
    this.backgroundImageUrlAr,
    this.backgroundImageUrlEn,
    this.buttonBgColor,
    this.buttonText,
    this.buttonTextN,
    this.cardType,
    this.categoryId,
    this.categoryNameAr,
    this.categoryNameEn,
    this.channel,
    this.createdOn,
    this.descriptionAr,
    this.descriptionEn,
    this.endDate,
    this.hasButton,
    this.id,
    this.isActive,
    this.moduleId,
    this.moduleName,
    this.moduleNameN,
    this.startDate,
    this.textColor,
    this.titleAr,
    this.titleEn,
    this.urlAr,
    this.urlEn,
  });

  factory GetGreetingCardsModelResponseElement.fromRawJson(String str) => GetGreetingCardsModelResponseElement.fromJson(json.decode(str));

  String toRawJson() => json.encode(toJson());

  factory GetGreetingCardsModelResponseElement.fromJson(Map<String, dynamic> json) => GetGreetingCardsModelResponseElement(
    backgroundImageUrlAr: json["BackgroundImageUrlAr"],
    backgroundImageUrlEn: json["BackgroundImageUrlEn"],
    buttonBgColor: json["ButtonBgColor"],
    buttonText: json["ButtonText"],
    buttonTextN: json["ButtonTextN"],
    cardType: json["CardType"],
    categoryId: json["CategoryID"],
    categoryNameAr: json["CategoryNameAr"],
    categoryNameEn: json["CategoryNameEn"],
    channel: json["Channel"],
    createdOn: json["CreatedOn"],
    descriptionAr: json["DescriptionAr"],
    descriptionEn: json["DescriptionEn"],
    endDate: json["EndDate"],
    hasButton: json["HasButton"],
    id: json["ID"],
    isActive: json["IsActive"],
    moduleId: json["ModuleID"],
    moduleName: json["ModuleName"],
    moduleNameN: json["ModuleNameN"],
    startDate: json["StartDate"],
    textColor: json["TextColor"],
    titleAr: json["TitleAr"],
    titleEn: json["TitleEn"],
    urlAr: json["UrlAr"],
    urlEn: json["UrlEn"],
  );

  Map<String, dynamic> toJson() => {
    "BackgroundImageUrlAr": backgroundImageUrlAr,
    "BackgroundImageUrlEn": backgroundImageUrlEn,
    "ButtonBgColor": buttonBgColor,
    "ButtonText": buttonText,
    "ButtonTextN": buttonTextN,
    "CardType": cardType,
    "CategoryID": categoryId,
    "CategoryNameAr": categoryNameAr,
    "CategoryNameEn": categoryNameEn,
    "Channel": channel,
    "CreatedOn": createdOn,
    "DescriptionAr": descriptionAr,
    "DescriptionEn": descriptionEn,
    "EndDate": endDate,
    "HasButton": hasButton,
    "ID": id,
    "IsActive": isActive,
    "ModuleID": moduleId,
    "ModuleName": moduleName,
    "ModuleNameN": moduleNameN,
    "StartDate": startDate,
    "TextColor": textColor,
    "TitleAr": titleAr,
    "TitleEn": titleEn,
    "UrlAr": urlAr,
    "UrlEn": urlEn,
  };
}

