123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129 |
- /// code : "OK"
- /// data : {"list":[{"backgroundId":29,"backgroundName":"拍卖","backgroundIsDynamic":0,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1627720828463.png","dynamicFile":null},{"backgroundId":24,"backgroundName":"2111","backgroundIsDynamic":1,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1616038846512.png","dynamicFile":"http://media.qn.timichat.net/rtc/background/1616038846512.png"},{"backgroundId":28,"backgroundName":"2","backgroundIsDynamic":0,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1619090342605.png","dynamicFile":null},{"backgroundId":27,"backgroundName":"1","backgroundIsDynamic":0,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1619090327535.png","dynamicFile":null}]}
- /// msg : ""
- /// success : true
- class ChatRoomBackgroundsModel {
- String? _code;
- Data? _data;
- String? _msg;
- bool? _success;
- String? get code => _code;
- Data? get data => _data;
- String? get msg => _msg;
- bool? get success => _success;
- ChatRoomBackgroundsModel({
- String? code,
- Data? data,
- String? msg,
- bool? success}){
- _code = code;
- _data = data;
- _msg = msg;
- _success = success;
- }
- ChatRoomBackgroundsModel.fromJson(dynamic json) {
- _code = json['code'];
- _data = json['data'] != null ? Data.fromJson(json['data']) : null;
- _msg = json['msg'];
- _success = json['success'];
- }
- Map<String, dynamic> toJson() {
- var map = <String, dynamic>{};
- map['code'] = _code;
- if (_data != null) {
- map['data'] = _data?.toJson();
- }
- map['msg'] = _msg;
- map['success'] = _success;
- return map;
- }
- }
- /// list : [{"backgroundId":29,"backgroundName":"拍卖","backgroundIsDynamic":0,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1627720828463.png","dynamicFile":null},{"backgroundId":24,"backgroundName":"2111","backgroundIsDynamic":1,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1616038846512.png","dynamicFile":"http://media.qn.timichat.net/rtc/background/1616038846512.png"},{"backgroundId":28,"backgroundName":"2","backgroundIsDynamic":0,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1619090342605.png","dynamicFile":null},{"backgroundId":27,"backgroundName":"1","backgroundIsDynamic":0,"backgroundUrl":"http://media.qn.timichat.net/rtc/background/1619090327535.png","dynamicFile":null}]
- class Data {
- List<BackGroundInfo>? _list;
- List<BackGroundInfo>? get list => _list;
- Data({
- List<BackGroundInfo>? list}){
- _list = list;
- }
- Data.fromJson(dynamic json) {
- if (json['list'] != null) {
- _list = [];
- json['list'].forEach((v) {
- _list?.add(BackGroundInfo.fromJson(v));
- });
- }
- }
- Map<String, dynamic> toJson() {
- var map = <String, dynamic>{};
- if (_list != null) {
- map['list'] = _list?.map((v) => v.toJson()).toList();
- }
- return map;
- }
- }
- /// backgroundId : 29
- /// backgroundName : "拍卖"
- /// backgroundIsDynamic : 0
- /// backgroundUrl : "http://media.qn.timichat.net/rtc/background/1627720828463.png"
- /// dynamicFile : null
- class BackGroundInfo {
- int? _backgroundId;
- String? _backgroundName;
- int? _backgroundIsDynamic;
- String? _backgroundUrl;
- dynamic? _dynamicFile;
- int? get backgroundId => _backgroundId;
- String? get backgroundName => _backgroundName;
- int? get backgroundIsDynamic => _backgroundIsDynamic;
- String? get backgroundUrl => _backgroundUrl;
- dynamic? get dynamicFile => _dynamicFile;
- BackGroundInfo({
- int? backgroundId,
- String? backgroundName,
- int? backgroundIsDynamic,
- String? backgroundUrl,
- dynamic? dynamicFile}){
- _backgroundId = backgroundId;
- _backgroundName = backgroundName;
- _backgroundIsDynamic = backgroundIsDynamic;
- _backgroundUrl = backgroundUrl;
- _dynamicFile = dynamicFile;
- }
- BackGroundInfo.fromJson(dynamic json) {
- _backgroundId = json['backgroundId'];
- _backgroundName = json['backgroundName'];
- _backgroundIsDynamic = json['backgroundIsDynamic'];
- _backgroundUrl = json['backgroundUrl'];
- _dynamicFile = json['dynamicFile'];
- }
- Map<String, dynamic> toJson() {
- var map = <String, dynamic>{};
- map['backgroundId'] = _backgroundId;
- map['backgroundName'] = _backgroundName;
- map['backgroundIsDynamic'] = _backgroundIsDynamic;
- map['backgroundUrl'] = _backgroundUrl;
- map['dynamicFile'] = _dynamicFile;
- return map;
- }
- }
|