You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
577 B

4 years ago
3 years ago
import 'package:json_annotation/json_annotation.dart';
part 'page.g.dart';
@JsonSerializable(genericArgumentFactories: true)
class PageInfo<D> {
PageInfo();
4 years ago
int pageNum;
4 years ago
dynamic current;
4 years ago
int pageSize;
4 years ago
dynamic size;
dynamic pages;
4 years ago
bool hasPreviousPage;
bool hasNextPage;
String total;
3 years ago
List<D> list;
List<D> records;
factory PageInfo.fromJson(Map<String, dynamic> json, D Function(dynamic d) fromJsonD) => _$PageInfoFromJson(json, fromJsonD);
Map<String, dynamic> toJson(Object Function(D value) toJsonD) => _$PageInfoToJson(this, toJsonD);
}