diff --git a/lib/data/invoices_history_list.dart b/lib/data/invoices_history_list.dart deleted file mode 100644 index bcb557ca..00000000 --- a/lib/data/invoices_history_list.dart +++ /dev/null @@ -1,385 +0,0 @@ -/// records : [{"id":"1823231566596276224","createTime":"2024-08-13 13:34:14","createUser":"1379254113602109440","updateTime":"2024-08-13 13:34:14","updateUser":"1379254113602109440","phone":"","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816764013200015360"],"money":"2.00","type":"ELECTRONIC","headerId":"1818128371540819968","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"彗星","invoiceHeaderCode":"123568986457","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1820730457528991744","createTime":"2024-08-06 15:55:43","createUser":"1379254113602109440","updateTime":"2024-08-06 15:55:43","updateUser":"1379254113602109440","phone":"","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816724620737249280"],"money":"0.02","type":"ELECTRONIC","headerId":"1818128371540819968","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"彗星","invoiceHeaderCode":"123568986457","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1820730164074512384","createTime":"2024-08-06 15:54:33","createUser":"1379254113602109440","updateTime":"2024-08-06 15:54:33","updateUser":"1379254113602109440","phone":"","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816724573748461568"],"money":"0.01","type":"ELECTRONIC","headerId":"1818128371540819968","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"彗星","invoiceHeaderCode":"123568986457","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1818128393347006464","createTime":"2024-07-30 11:36:03","createUser":"1379254113602109440","updateTime":"2024-07-30 11:36:03","updateUser":"1379254113602109440","phone":"","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816763957935865856"],"money":"1.00","type":"ELECTRONIC","headerId":"1818128371540819968","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"彗星","invoiceHeaderCode":"123568986457","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1816688308449705984","createTime":"2024-07-26 12:13:40","createUser":"1379254113602109440","updateTime":"2024-07-26 12:13:40","updateUser":"1379254113602109440","phone":"","receivingPhone":"UI","mid":"1379254113602109440","orderIds":["1816406896014262272"],"money":"0.14","type":"ELECTRONIC","headerId":"1816688003569942528","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"顾好","invoiceHeaderCode":"","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1816683371409965056","createTime":"2024-07-26 11:54:03","createUser":"1379254113602109440","updateTime":"2024-07-26 11:54:03","updateUser":"1379254113602109440","phone":"12547896","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816406781086138368"],"money":"0.11","type":"ELECTRONIC","headerId":"1816683354544668672","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"华夏","invoiceHeaderCode":"22336559955","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1816681820477980672","createTime":"2024-07-26 11:47:53","createUser":"1379254113602109440","updateTime":"2024-07-26 11:47:53","updateUser":"1379254113602109440","phone":"","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816681463005839360","1816681276996845568"],"money":"0.25","type":"ELECTRONIC","headerId":"1816681805231685632","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"呜呜","invoiceHeaderCode":"","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1816664893273669632","createTime":"2024-07-26 10:40:37","createUser":"1379254113602109440","updateTime":"2024-07-26 10:40:37","updateUser":"1379254113602109440","phone":"13864536699","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816298665912827904"],"money":"0.01","type":"ELECTRONIC","headerId":"1816663221906440192","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"回血","invoiceHeaderCode":"1325566645499","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1816664648762523648","createTime":"2024-07-26 10:39:39","createUser":"1379254113602109440","updateTime":"2024-07-26 10:39:39","updateUser":"1379254113602109440","phone":"13864536699","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816028241291378688"],"money":"0.01","type":"ELECTRONIC","headerId":"1816663221906440192","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"回血","invoiceHeaderCode":"1325566645499","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null},{"id":"1816664088302845952","createTime":"2024-07-26 10:37:25","createUser":"1379254113602109440","updateTime":"2024-07-26 10:37:25","updateUser":"1379254113602109440","phone":"13864536699","receivingPhone":"13052919193","mid":"1379254113602109440","orderIds":["1816409113630867456","1816406953434284032","1816406830440513536"],"money":"0.32","type":"ELECTRONIC","headerId":"1816663221906440192","state":"UN_AUDIT","reviewerTime":null,"reviewerBy":"0","ossUrl":null,"reason":"","isDelete":0,"invoiceHeaderName":"回血","invoiceHeaderCode":"1325566645499","orderList":null,"headertype":null,"companyAddr":null,"companyPhone":null,"bank":null,"bankNumber":null}] -/// total : "14" -/// size : "10" -/// current : "1" -/// orders : [{"column":"id","asc":false}] -/// hitCount : false -/// searchCount : true -/// pages : "2" - -class InvoicesHistoryList { - InvoicesHistoryList({ - List? records, - String? total, - String? size, - String? current, - List? orders, - bool? hitCount, - bool? searchCount, - String? pages,}){ - _records = records; - _total = total; - _size = size; - _current = current; - _orders = orders; - _hitCount = hitCount; - _searchCount = searchCount; - _pages = pages; -} - - InvoicesHistoryList.fromJson(dynamic json) { - if (json['records'] != null) { - _records = []; - json['records'].forEach((v) { - _records?.add(Records.fromJson(v)); - }); - } - _total = json['total']; - _size = json['size']; - _current = json['current']; - if (json['orders'] != null) { - _orders = []; - json['orders'].forEach((v) { - _orders?.add(Orders.fromJson(v)); - }); - } - _hitCount = json['hitCount']; - _searchCount = json['searchCount']; - _pages = json['pages']; - } - List? _records; - String? _total; - String? _size; - String? _current; - List? _orders; - bool? _hitCount; - bool? _searchCount; - String? _pages; -InvoicesHistoryList copyWith({ List? records, - String? total, - String? size, - String? current, - List? orders, - bool? hitCount, - bool? searchCount, - String? pages, -}) => InvoicesHistoryList( records: records ?? _records, - total: total ?? _total, - size: size ?? _size, - current: current ?? _current, - orders: orders ?? _orders, - hitCount: hitCount ?? _hitCount, - searchCount: searchCount ?? _searchCount, - pages: pages ?? _pages, -); - List? get records => _records; - String? get total => _total; - String? get size => _size; - String? get current => _current; - List? get orders => _orders; - bool? get hitCount => _hitCount; - bool? get searchCount => _searchCount; - String? get pages => _pages; - - Map toJson() { - final map = {}; - if (_records != null) { - map['records'] = _records?.map((v) => v.toJson()).toList(); - } - map['total'] = _total; - map['size'] = _size; - map['current'] = _current; - if (_orders != null) { - map['orders'] = _orders?.map((v) => v.toJson()).toList(); - } - map['hitCount'] = _hitCount; - map['searchCount'] = _searchCount; - map['pages'] = _pages; - return map; - } - -} - -/// column : "id" -/// asc : false - -class Orders { - Orders({ - String? column, - bool? asc,}){ - _column = column; - _asc = asc; -} - - Orders.fromJson(dynamic json) { - _column = json['column']; - _asc = json['asc']; - } - String? _column; - bool? _asc; -Orders copyWith({ String? column, - bool? asc, -}) => Orders( column: column ?? _column, - asc: asc ?? _asc, -); - String? get column => _column; - bool? get asc => _asc; - - Map toJson() { - final map = {}; - map['column'] = _column; - map['asc'] = _asc; - return map; - } - -} - -/// id : "1823231566596276224" -/// createTime : "2024-08-13 13:34:14" -/// createUser : "1379254113602109440" -/// updateTime : "2024-08-13 13:34:14" -/// updateUser : "1379254113602109440" -/// phone : "" -/// receivingPhone : "13052919193" -/// mid : "1379254113602109440" -/// orderIds : ["1816764013200015360"] -/// money : "2.00" -/// type : "ELECTRONIC" -/// headerId : "1818128371540819968" -/// state : "UN_AUDIT" -/// reviewerTime : null -/// reviewerBy : "0" -/// ossUrl : null -/// reason : "" -/// isDelete : 0 -/// invoiceHeaderName : "彗星" -/// invoiceHeaderCode : "123568986457" -/// orderList : null -/// headertype : null -/// companyAddr : null -/// companyPhone : null -/// bank : null -/// bankNumber : null - -class Records { - Records({ - String? id, - String? createTime, - String? createUser, - String? updateTime, - String? updateUser, - String? phone, - String? receivingPhone, - String? mid, - List? orderIds, - String? money, - String? type, - String? headerId, - String? state, - dynamic reviewerTime, - String? reviewerBy, - dynamic ossUrl, - String? reason, - num? isDelete, - String? invoiceHeaderName, - String? invoiceHeaderCode, - dynamic orderList, - dynamic headertype, - dynamic companyAddr, - dynamic companyPhone, - dynamic bank, - dynamic bankNumber,}){ - _id = id; - _createTime = createTime; - _createUser = createUser; - _updateTime = updateTime; - _updateUser = updateUser; - _phone = phone; - _receivingPhone = receivingPhone; - _mid = mid; - _orderIds = orderIds; - _money = money; - _type = type; - _headerId = headerId; - _state = state; - _reviewerTime = reviewerTime; - _reviewerBy = reviewerBy; - _ossUrl = ossUrl; - _reason = reason; - _isDelete = isDelete; - _invoiceHeaderName = invoiceHeaderName; - _invoiceHeaderCode = invoiceHeaderCode; - _orderList = orderList; - _headertype = headertype; - _companyAddr = companyAddr; - _companyPhone = companyPhone; - _bank = bank; - _bankNumber = bankNumber; -} - - Records.fromJson(dynamic json) { - _id = json['id']; - _createTime = json['createTime']; - _createUser = json['createUser']; - _updateTime = json['updateTime']; - _updateUser = json['updateUser']; - _phone = json['phone']; - _receivingPhone = json['receivingPhone']; - _mid = json['mid']; - _orderIds = json['orderIds'] != null ? json['orderIds'].cast() : []; - _money = json['money']; - _type = json['type']; - _headerId = json['headerId']; - _state = json['state']; - _reviewerTime = json['reviewerTime']; - _reviewerBy = json['reviewerBy']; - _ossUrl = json['ossUrl']; - _reason = json['reason']; - _isDelete = json['isDelete']; - _invoiceHeaderName = json['invoiceHeaderName']; - _invoiceHeaderCode = json['invoiceHeaderCode']; - _orderList = json['orderList']; - _headertype = json['headertype']; - _companyAddr = json['companyAddr']; - _companyPhone = json['companyPhone']; - _bank = json['bank']; - _bankNumber = json['bankNumber']; - } - String? _id; - String? _createTime; - String? _createUser; - String? _updateTime; - String? _updateUser; - String? _phone; - String? _receivingPhone; - String? _mid; - List? _orderIds; - String? _money; - String? _type; - String? _headerId; - String? _state; - dynamic _reviewerTime; - String? _reviewerBy; - dynamic _ossUrl; - String? _reason; - num? _isDelete; - String? _invoiceHeaderName; - String? _invoiceHeaderCode; - dynamic _orderList; - dynamic _headertype; - dynamic _companyAddr; - dynamic _companyPhone; - dynamic _bank; - dynamic _bankNumber; -Records copyWith({ String? id, - String? createTime, - String? createUser, - String? updateTime, - String? updateUser, - String? phone, - String? receivingPhone, - String? mid, - List? orderIds, - String? money, - String? type, - String? headerId, - String? state, - dynamic reviewerTime, - String? reviewerBy, - dynamic ossUrl, - String? reason, - num? isDelete, - String? invoiceHeaderName, - String? invoiceHeaderCode, - dynamic orderList, - dynamic headertype, - dynamic companyAddr, - dynamic companyPhone, - dynamic bank, - dynamic bankNumber, -}) => Records( id: id ?? _id, - createTime: createTime ?? _createTime, - createUser: createUser ?? _createUser, - updateTime: updateTime ?? _updateTime, - updateUser: updateUser ?? _updateUser, - phone: phone ?? _phone, - receivingPhone: receivingPhone ?? _receivingPhone, - mid: mid ?? _mid, - orderIds: orderIds ?? _orderIds, - money: money ?? _money, - type: type ?? _type, - headerId: headerId ?? _headerId, - state: state ?? _state, - reviewerTime: reviewerTime ?? _reviewerTime, - reviewerBy: reviewerBy ?? _reviewerBy, - ossUrl: ossUrl ?? _ossUrl, - reason: reason ?? _reason, - isDelete: isDelete ?? _isDelete, - invoiceHeaderName: invoiceHeaderName ?? _invoiceHeaderName, - invoiceHeaderCode: invoiceHeaderCode ?? _invoiceHeaderCode, - orderList: orderList ?? _orderList, - headertype: headertype ?? _headertype, - companyAddr: companyAddr ?? _companyAddr, - companyPhone: companyPhone ?? _companyPhone, - bank: bank ?? _bank, - bankNumber: bankNumber ?? _bankNumber, -); - String? get id => _id; - String? get createTime => _createTime; - String? get createUser => _createUser; - String? get updateTime => _updateTime; - String? get updateUser => _updateUser; - String? get phone => _phone; - String? get receivingPhone => _receivingPhone; - String? get mid => _mid; - List? get orderIds => _orderIds; - String? get money => _money; - String? get type => _type; - String? get headerId => _headerId; - String? get state => _state; - dynamic get reviewerTime => _reviewerTime; - String? get reviewerBy => _reviewerBy; - dynamic get ossUrl => _ossUrl; - String? get reason => _reason; - num? get isDelete => _isDelete; - String? get invoiceHeaderName => _invoiceHeaderName; - String? get invoiceHeaderCode => _invoiceHeaderCode; - dynamic get orderList => _orderList; - dynamic get headertype => _headertype; - dynamic get companyAddr => _companyAddr; - dynamic get companyPhone => _companyPhone; - dynamic get bank => _bank; - dynamic get bankNumber => _bankNumber; - - Map toJson() { - final map = {}; - map['id'] = _id; - map['createTime'] = _createTime; - map['createUser'] = _createUser; - map['updateTime'] = _updateTime; - map['updateUser'] = _updateUser; - map['phone'] = _phone; - map['receivingPhone'] = _receivingPhone; - map['mid'] = _mid; - map['orderIds'] = _orderIds; - map['money'] = _money; - map['type'] = _type; - map['headerId'] = _headerId; - map['state'] = _state; - map['reviewerTime'] = _reviewerTime; - map['reviewerBy'] = _reviewerBy; - map['ossUrl'] = _ossUrl; - map['reason'] = _reason; - map['isDelete'] = _isDelete; - map['invoiceHeaderName'] = _invoiceHeaderName; - map['invoiceHeaderCode'] = _invoiceHeaderCode; - map['orderList'] = _orderList; - map['headertype'] = _headertype; - map['companyAddr'] = _companyAddr; - map['companyPhone'] = _companyPhone; - map['bank'] = _bank; - map['bankNumber'] = _bankNumber; - return map; - } - -} \ No newline at end of file diff --git a/lib/generated/json/address.g.dart b/lib/generated/json/address.g.dart index 2dea3dfc..4c9b5618 100644 --- a/lib/generated/json/address.g.dart +++ b/lib/generated/json/address.g.dart @@ -4,7 +4,7 @@ import 'package:huixiang/data/address.dart'; Address $AddressFromJson(Map json) { final Address address = Address(); final String? addressStr = jsonConvert.convert(json['address']); - if (address != null) { + if (addressStr != null) { address.addressStr = addressStr; } final String? area = jsonConvert.convert(json['area']); @@ -27,11 +27,11 @@ Address $AddressFromJson(Map json) { if (isDefault != null) { address.isDefault = isDefault; } - final String? latitude = jsonConvert.convert(json['latitude']); + final dynamic latitude = json['latitude']; if (latitude != null) { address.latitude = latitude; } - final String? longitude = jsonConvert.convert(json['longitude']); + final dynamic longitude = json['longitude']; if (longitude != null) { address.longitude = longitude; } @@ -78,14 +78,14 @@ Map $AddressToJson(Address entity) { extension AddressExtension on Address { Address copyWith({ - String? address, + String? addressStr, String? area, String? city, String? cityInfo, String? id, bool? isDefault, - String? latitude, - String? longitude, + dynamic latitude, + dynamic longitude, String? mid, String? phone, String? province, diff --git a/lib/generated/json/invoices_history_list_entity.g.dart b/lib/generated/json/invoices_history_list_entity.g.dart new file mode 100644 index 00000000..54ceb36d --- /dev/null +++ b/lib/generated/json/invoices_history_list_entity.g.dart @@ -0,0 +1,323 @@ +import 'package:huixiang/generated/json/base/json_convert_content.dart'; +import 'package:huixiang/data/invoices_history_list_entity.dart'; + +InvoicesHistoryListEntity $InvoicesHistoryListEntityFromJson( + Map json) { + final InvoicesHistoryListEntity invoicesHistoryListEntity = InvoicesHistoryListEntity(); + final List? records = (json['records'] as List< + dynamic>?)?.map( + (e) => + jsonConvert.convert( + e) as InvoicesHistoryListRecords).toList(); + if (records != null) { + invoicesHistoryListEntity.records = records; + } + final String? total = jsonConvert.convert(json['total']); + if (total != null) { + invoicesHistoryListEntity.total = total; + } + final String? size = jsonConvert.convert(json['size']); + if (size != null) { + invoicesHistoryListEntity.size = size; + } + final String? current = jsonConvert.convert(json['current']); + if (current != null) { + invoicesHistoryListEntity.current = current; + } + final List? orders = (json['orders'] as List< + dynamic>?)?.map( + (e) => + jsonConvert.convert( + e) as InvoicesHistoryListOrders).toList(); + if (orders != null) { + invoicesHistoryListEntity.orders = orders; + } + final bool? hitCount = jsonConvert.convert(json['hitCount']); + if (hitCount != null) { + invoicesHistoryListEntity.hitCount = hitCount; + } + final bool? searchCount = jsonConvert.convert(json['searchCount']); + if (searchCount != null) { + invoicesHistoryListEntity.searchCount = searchCount; + } + final String? pages = jsonConvert.convert(json['pages']); + if (pages != null) { + invoicesHistoryListEntity.pages = pages; + } + return invoicesHistoryListEntity; +} + +Map $InvoicesHistoryListEntityToJson( + InvoicesHistoryListEntity entity) { + final Map data = {}; + data['records'] = entity.records?.map((v) => v.toJson()).toList(); + data['total'] = entity.total; + data['size'] = entity.size; + data['current'] = entity.current; + data['orders'] = entity.orders?.map((v) => v.toJson()).toList(); + data['hitCount'] = entity.hitCount; + data['searchCount'] = entity.searchCount; + data['pages'] = entity.pages; + return data; +} + +extension InvoicesHistoryListEntityExtension on InvoicesHistoryListEntity { + InvoicesHistoryListEntity copyWith({ + List? records, + String? total, + String? size, + String? current, + List? orders, + bool? hitCount, + bool? searchCount, + String? pages, + }) { + return InvoicesHistoryListEntity() + ..records = records ?? this.records + ..total = total ?? this.total + ..size = size ?? this.size + ..current = current ?? this.current + ..orders = orders ?? this.orders + ..hitCount = hitCount ?? this.hitCount + ..searchCount = searchCount ?? this.searchCount + ..pages = pages ?? this.pages; + } +} + +InvoicesHistoryListRecords $InvoicesHistoryListRecordsFromJson( + Map json) { + final InvoicesHistoryListRecords invoicesHistoryListRecords = InvoicesHistoryListRecords(); + final String? id = jsonConvert.convert(json['id']); + if (id != null) { + invoicesHistoryListRecords.id = id; + } + final String? createTime = jsonConvert.convert(json['createTime']); + if (createTime != null) { + invoicesHistoryListRecords.createTime = createTime; + } + final String? createUser = jsonConvert.convert(json['createUser']); + if (createUser != null) { + invoicesHistoryListRecords.createUser = createUser; + } + final String? updateTime = jsonConvert.convert(json['updateTime']); + if (updateTime != null) { + invoicesHistoryListRecords.updateTime = updateTime; + } + final String? updateUser = jsonConvert.convert(json['updateUser']); + if (updateUser != null) { + invoicesHistoryListRecords.updateUser = updateUser; + } + final String? phone = jsonConvert.convert(json['phone']); + if (phone != null) { + invoicesHistoryListRecords.phone = phone; + } + final String? receivingPhone = jsonConvert.convert( + json['receivingPhone']); + if (receivingPhone != null) { + invoicesHistoryListRecords.receivingPhone = receivingPhone; + } + final String? mid = jsonConvert.convert(json['mid']); + if (mid != null) { + invoicesHistoryListRecords.mid = mid; + } + final List? orderIds = (json['orderIds'] as List?)?.map( + (e) => jsonConvert.convert(e) as String).toList(); + if (orderIds != null) { + invoicesHistoryListRecords.orderIds = orderIds; + } + final String? money = jsonConvert.convert(json['money']); + if (money != null) { + invoicesHistoryListRecords.money = money; + } + final String? type = jsonConvert.convert(json['type']); + if (type != null) { + invoicesHistoryListRecords.type = type; + } + final String? headerId = jsonConvert.convert(json['headerId']); + if (headerId != null) { + invoicesHistoryListRecords.headerId = headerId; + } + final String? state = jsonConvert.convert(json['state']); + if (state != null) { + invoicesHistoryListRecords.state = state; + } + final dynamic reviewerTime = json['reviewerTime']; + if (reviewerTime != null) { + invoicesHistoryListRecords.reviewerTime = reviewerTime; + } + final String? reviewerBy = jsonConvert.convert(json['reviewerBy']); + if (reviewerBy != null) { + invoicesHistoryListRecords.reviewerBy = reviewerBy; + } + final dynamic ossUrl = json['ossUrl']; + if (ossUrl != null) { + invoicesHistoryListRecords.ossUrl = ossUrl; + } + final String? reason = jsonConvert.convert(json['reason']); + if (reason != null) { + invoicesHistoryListRecords.reason = reason; + } + final int? isDelete = jsonConvert.convert(json['isDelete']); + if (isDelete != null) { + invoicesHistoryListRecords.isDelete = isDelete; + } + final String? invoiceHeaderName = jsonConvert.convert( + json['invoiceHeaderName']); + if (invoiceHeaderName != null) { + invoicesHistoryListRecords.invoiceHeaderName = invoiceHeaderName; + } + final String? invoiceHeaderCode = jsonConvert.convert( + json['invoiceHeaderCode']); + if (invoiceHeaderCode != null) { + invoicesHistoryListRecords.invoiceHeaderCode = invoiceHeaderCode; + } + final dynamic orderList = json['orderList']; + if (orderList != null) { + invoicesHistoryListRecords.orderList = orderList; + } + final dynamic headertype = json['headertype']; + if (headertype != null) { + invoicesHistoryListRecords.headertype = headertype; + } + final dynamic companyAddr = json['companyAddr']; + if (companyAddr != null) { + invoicesHistoryListRecords.companyAddr = companyAddr; + } + final dynamic companyPhone = json['companyPhone']; + if (companyPhone != null) { + invoicesHistoryListRecords.companyPhone = companyPhone; + } + final dynamic bank = json['bank']; + if (bank != null) { + invoicesHistoryListRecords.bank = bank; + } + final dynamic bankNumber = json['bankNumber']; + if (bankNumber != null) { + invoicesHistoryListRecords.bankNumber = bankNumber; + } + return invoicesHistoryListRecords; +} + +Map $InvoicesHistoryListRecordsToJson( + InvoicesHistoryListRecords entity) { + final Map data = {}; + data['id'] = entity.id; + data['createTime'] = entity.createTime; + data['createUser'] = entity.createUser; + data['updateTime'] = entity.updateTime; + data['updateUser'] = entity.updateUser; + data['phone'] = entity.phone; + data['receivingPhone'] = entity.receivingPhone; + data['mid'] = entity.mid; + data['orderIds'] = entity.orderIds; + data['money'] = entity.money; + data['type'] = entity.type; + data['headerId'] = entity.headerId; + data['state'] = entity.state; + data['reviewerTime'] = entity.reviewerTime; + data['reviewerBy'] = entity.reviewerBy; + data['ossUrl'] = entity.ossUrl; + data['reason'] = entity.reason; + data['isDelete'] = entity.isDelete; + data['invoiceHeaderName'] = entity.invoiceHeaderName; + data['invoiceHeaderCode'] = entity.invoiceHeaderCode; + data['orderList'] = entity.orderList; + data['headertype'] = entity.headertype; + data['companyAddr'] = entity.companyAddr; + data['companyPhone'] = entity.companyPhone; + data['bank'] = entity.bank; + data['bankNumber'] = entity.bankNumber; + return data; +} + +extension InvoicesHistoryListRecordsExtension on InvoicesHistoryListRecords { + InvoicesHistoryListRecords copyWith({ + String? id, + String? createTime, + String? createUser, + String? updateTime, + String? updateUser, + String? phone, + String? receivingPhone, + String? mid, + List? orderIds, + String? money, + String? type, + String? headerId, + String? state, + dynamic reviewerTime, + String? reviewerBy, + dynamic ossUrl, + String? reason, + int? isDelete, + String? invoiceHeaderName, + String? invoiceHeaderCode, + dynamic orderList, + dynamic headertype, + dynamic companyAddr, + dynamic companyPhone, + dynamic bank, + dynamic bankNumber, + }) { + return InvoicesHistoryListRecords() + ..id = id ?? this.id + ..createTime = createTime ?? this.createTime + ..createUser = createUser ?? this.createUser + ..updateTime = updateTime ?? this.updateTime + ..updateUser = updateUser ?? this.updateUser + ..phone = phone ?? this.phone + ..receivingPhone = receivingPhone ?? this.receivingPhone + ..mid = mid ?? this.mid + ..orderIds = orderIds ?? this.orderIds + ..money = money ?? this.money + ..type = type ?? this.type + ..headerId = headerId ?? this.headerId + ..state = state ?? this.state + ..reviewerTime = reviewerTime ?? this.reviewerTime + ..reviewerBy = reviewerBy ?? this.reviewerBy + ..ossUrl = ossUrl ?? this.ossUrl + ..reason = reason ?? this.reason + ..isDelete = isDelete ?? this.isDelete + ..invoiceHeaderName = invoiceHeaderName ?? this.invoiceHeaderName + ..invoiceHeaderCode = invoiceHeaderCode ?? this.invoiceHeaderCode + ..orderList = orderList ?? this.orderList + ..headertype = headertype ?? this.headertype + ..companyAddr = companyAddr ?? this.companyAddr + ..companyPhone = companyPhone ?? this.companyPhone + ..bank = bank ?? this.bank + ..bankNumber = bankNumber ?? this.bankNumber; + } +} + +InvoicesHistoryListOrders $InvoicesHistoryListOrdersFromJson( + Map json) { + final InvoicesHistoryListOrders invoicesHistoryListOrders = InvoicesHistoryListOrders(); + final String? column = jsonConvert.convert(json['column']); + if (column != null) { + invoicesHistoryListOrders.column = column; + } + final bool? asc = jsonConvert.convert(json['asc']); + if (asc != null) { + invoicesHistoryListOrders.asc = asc; + } + return invoicesHistoryListOrders; +} + +Map $InvoicesHistoryListOrdersToJson( + InvoicesHistoryListOrders entity) { + final Map data = {}; + data['column'] = entity.column; + data['asc'] = entity.asc; + return data; +} + +extension InvoicesHistoryListOrdersExtension on InvoicesHistoryListOrders { + InvoicesHistoryListOrders copyWith({ + String? column, + bool? asc, + }) { + return InvoicesHistoryListOrders() + ..column = column ?? this.column + ..asc = asc ?? this.asc; + } +} \ No newline at end of file diff --git a/lib/order/invoices_manage/invoices_history.dart b/lib/order/invoices_manage/invoices_history.dart index b21a0988..e413eaa4 100644 --- a/lib/order/invoices_manage/invoices_history.dart +++ b/lib/order/invoices_manage/invoices_history.dart @@ -242,7 +242,7 @@ class _InvoicesHistory extends State { children: [ Expanded( child: Text( - records?.invoiceHeaderName ?? "", + records.invoiceHeaderName ?? "", style: TextStyle( color: Colors.black, fontSize: 14.sp, @@ -250,7 +250,7 @@ class _InvoicesHistory extends State { ), )), Text( - invoicesStatus(records?.state ?? ""), + invoicesStatus(records.state ?? ""), style: TextStyle( color: Color(0xff32A060), fontSize: 14.sp, @@ -266,7 +266,7 @@ class _InvoicesHistory extends State { Padding( padding: EdgeInsets.only(right: 16.w), child: Text( - "¥${records?.money ?? ""}", + "¥${records.money ?? ""}", style: TextStyle( color: Color(0xff32A060), fontSize: 16.sp, @@ -283,7 +283,7 @@ class _InvoicesHistory extends State { ), )), Text( - records?.reviewerTime ?? records?.createTime ?? "", + records.reviewerTime ?? records.createTime ?? "", style: TextStyle( color: Color(0xff4D4D4D), fontSize: 14.sp,