class BilDetailStyleModel {
  String appBarName;
  String appBarNameColor;
  String appBarBgImg;
  String appBarBgColor;
  String tabLineColor;
  String tabNoSeletedColor;
  String tabSeletedColor;
  List<TabList> tabList;
  String timeSelectColor;
  String btnNoSelectedColor;
  String btnSelectedColor;
  List<InputTabViewBtns> inputTabViewBtns;
  List<InputTabViewBtns> outTabViewBtns;
  InputItemStyle inputItemStyle;
  OutputItemStyle outputItemStyle;

  BilDetailStyleModel(
      {this.appBarName,
        this.appBarNameColor,
        this.appBarBgImg,
        this.appBarBgColor,
        this.tabLineColor,
        this.tabNoSeletedColor,
        this.tabSeletedColor,
        this.tabList,
        this.timeSelectColor,
        this.btnNoSelectedColor,
        this.btnSelectedColor,
        this.inputTabViewBtns,
        this.outTabViewBtns,
        this.inputItemStyle,
        this.outputItemStyle});

  BilDetailStyleModel.fromJson(Map<String, dynamic> json) {
    appBarName = json['app_bar_name'];
    appBarNameColor = json['app_bar_name_color'];
    appBarBgImg = json['app_bar_bg_img'];
    appBarBgColor = json['app_bar_bg_color'];
    tabLineColor = json['tab_line_color'];
    tabNoSeletedColor = json['tab_no_seleted_color'];
    tabSeletedColor = json['tab_seleted_color'];
    if (json['tab_list'] != null) {
      tabList = new List<TabList>();
      json['tab_list'].forEach((v) {
        tabList.add(new TabList.fromJson(v));
      });
    }
    timeSelectColor = json['time_select_color'];
    btnNoSelectedColor = json['btn_no_selected_color'];
    btnSelectedColor = json['btn_selected_color'];
    if (json['input_tab_view_btns'] != null) {
      inputTabViewBtns = new List<InputTabViewBtns>();
      json['input_tab_view_btns'].forEach((v) {
        inputTabViewBtns.add(new InputTabViewBtns.fromJson(v));
      });
    }
    if (json['out_tab_view_btns'] != null) {
      outTabViewBtns = new List<InputTabViewBtns>();
      json['out_tab_view_btns'].forEach((v) {
        outTabViewBtns.add(new InputTabViewBtns.fromJson(v));
      });
    }
    inputItemStyle = json['input_item_style'] != null
        ? new InputItemStyle.fromJson(json['input_item_style'])
        : null;
    outputItemStyle = json['output_item_style'] != null
        ? new OutputItemStyle.fromJson(json['output_item_style'])
        : null;
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['app_bar_name'] = this.appBarName;
    data['app_bar_name_color'] = this.appBarNameColor;
    data['app_bar_bg_img'] = this.appBarBgImg;
    data['app_bar_bg_color'] = this.appBarBgColor;
    data['tab_line_color'] = this.tabLineColor;
    data['tab_no_seleted_color'] = this.tabNoSeletedColor;
    data['tab_seleted_color'] = this.tabSeletedColor;
    if (this.tabList != null) {
      data['tab_list'] = this.tabList.map((v) => v.toJson()).toList();
    }
    data['time_select_color'] = this.timeSelectColor;
    data['btn_no_selected_color'] = this.btnNoSelectedColor;
    data['btn_selected_color'] = this.btnSelectedColor;
    if (this.inputTabViewBtns != null) {
      data['input_tab_view_btns'] =
          this.inputTabViewBtns.map((v) => v.toJson()).toList();
    }
    if (this.outTabViewBtns != null) {
      data['out_tab_view_btns'] =
          this.outTabViewBtns.map((v) => v.toJson()).toList();
    }
    if (this.inputItemStyle != null) {
      data['input_item_style'] = this.inputItemStyle.toJson();
    }
    if (this.outputItemStyle != null) {
      data['output_item_style'] = this.outputItemStyle.toJson();
    }
    return data;
  }
}

class TabList {
  String type;
  String name;

  TabList({this.type, this.name});

  TabList.fromJson(Map<String, dynamic> json) {
    type = json['type'];
    name = json['name'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['type'] = this.type;
    data['name'] = this.name;
    return data;
  }
}

class InputItemStyle {
  String typeNameColor;
  String titleColor;
  String amountColor;
  String contentColor;
  String copyBtnText;
  String copyBtnTextColor;
  String copyBtnBgColor;
  String orderIdText;
  String orderTypeText;
  String amountText;
  String timeText;
  String settleTimeText;
  List<String> keys;

  InputItemStyle(
      {this.typeNameColor,
        this.titleColor,
        this.amountColor,
        this.contentColor,
        this.copyBtnText,
        this.copyBtnTextColor,
        this.copyBtnBgColor,
        this.orderIdText,
        this.orderTypeText,
        this.amountText,
        this.timeText,
        this.settleTimeText,
        this.keys});

  InputItemStyle.fromJson(Map<String, dynamic> json) {
    typeNameColor = json['type_name_color'];
    titleColor = json['title_color'];
    amountColor = json['amount_color'];
    contentColor = json['content_color'];
    copyBtnText = json['copy_btn_text'];
    copyBtnTextColor = json['copy_btn_text_color'];
    copyBtnBgColor = json['copy_btn_bg_color'];
    orderIdText = json['order_id_text'];
    orderTypeText = json['order_type_text'];
    amountText = json['amount_text'];
    timeText = json['time_text'];
    settleTimeText = json['settle_time_text'];
    keys = json['keys'].cast<String>();
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['type_name_color'] = this.typeNameColor;
    data['title_color'] = this.titleColor;
    data['amount_color'] = this.amountColor;
    data['content_color'] = this.contentColor;
    data['copy_btn_text'] = this.copyBtnText;
    data['copy_btn_text_color'] = this.copyBtnTextColor;
    data['copy_btn_bg_color'] = this.copyBtnBgColor;
    data['order_id_text'] = this.orderIdText;
    data['order_type_text'] = this.orderTypeText;
    data['amount_text'] = this.amountText;
    data['time_text'] = this.timeText;
    data['settle_time_text'] = this.settleTimeText;
    data['keys'] = this.keys;
    return data;
  }
}

class OutputItemStyle {
  String typeNameColor;
  String titleColor;
  String amountColor;
  String contentColor;
  String copyBtnTextColor;
  String copyBtnText;
  String copyBtnBgColor;
  String orderIdText;
  String withdrawAccountText;
  String withdrawAmountText;
  String withdrawTimeText;
  String withdrawOrderStatusText;
  String consumeOrderTypeText;
  String consumeAmountText;
  String consumeTimeText;
  List<String> withdrawKeys;
  List<String> consumeKeys;

  OutputItemStyle(
      {this.typeNameColor,
        this.titleColor,
        this.amountColor,
        this.contentColor,
        this.copyBtnTextColor,
        this.copyBtnBgColor,
        this.orderIdText,
        this.withdrawAccountText,
        this.withdrawAmountText,
        this.withdrawTimeText,
        this.withdrawOrderStatusText,
        this.consumeOrderTypeText,
        this.consumeAmountText,
        this.consumeTimeText,
        this.withdrawKeys,
        this.consumeKeys});

  OutputItemStyle.fromJson(Map<String, dynamic> json) {
    typeNameColor = json['type_name_color'];
    titleColor = json['title_color'];
    amountColor = json['amount_color'];
    contentColor = json['content_color'];
    copyBtnTextColor = json['copy_btn_text_color'];
    copyBtnText=json['copy_btn_text'];
    copyBtnBgColor = json['copy_btn_bg_color'];
    orderIdText = json['order_id_text'];
    withdrawAccountText = json['withdraw_account_text'];
    withdrawAmountText = json['withdraw_amount_text'];
    withdrawTimeText = json['withdraw_time_text'];
    withdrawOrderStatusText = json['withdraw_order_status_text'];
    consumeOrderTypeText = json['consume_order_type_text'];
    consumeAmountText = json['consume_amount_text'];
    consumeTimeText = json['consume_time_text'];
    withdrawKeys = json['withdraw_keys'].cast<String>();
    consumeKeys = json['consume_keys'].cast<String>();
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['type_name_color'] = this.typeNameColor;
    data['title_color'] = this.titleColor;
    data['amount_color'] = this.amountColor;
    data['content_color'] = this.contentColor;
    data['copy_btn_text_color'] = this.copyBtnTextColor;
    data['copy_btn_bg_color'] = this.copyBtnBgColor;
    data['order_id_text'] = this.orderIdText;
    data['withdraw_account_text'] = this.withdrawAccountText;
    data['withdraw_amount_text'] = this.withdrawAmountText;
    data['withdraw_time_text'] = this.withdrawTimeText;
    data['withdraw_order_status_text'] = this.withdrawOrderStatusText;
    data['consume_order_type_text'] = this.consumeOrderTypeText;
    data['consume_amount_text'] = this.consumeAmountText;
    data['consume_time_text'] = this.consumeTimeText;
    data['withdraw_keys'] = this.withdrawKeys;
    data['consume_keys'] = this.consumeKeys;
    return data;
  }
}

class InputTabViewBtns {
  String type;
  String name;


  InputTabViewBtns(
      {this.type,this.name});

  InputTabViewBtns.fromJson(Map<String, dynamic> json) {
    type=json['type'];
    name=json['name'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['name']=name;
    data['type']=type;
    return data;
  }
}