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.
 
 
 
 
 
 

83 lines
2.3 KiB

class Goods {
String? id;
String? createTime;
String? createUser;
String? updateTime;
String? updateUser;
String? categoryId;
String? storeId;
String? name;
String? description;
String? worth;
String? price;
String? detail;
int? stock;
int? sales;
bool? isHot;
int? sortOrder;
int? state;
bool? canPick;
bool? canDelivery;
int? isDelete;
dynamic? categoryName;
String? mainImgPath;
List<String>? viceImgPaths;
Goods();
Goods.fromJson(dynamic json) {
this.id = json["id"];
this.createTime = json["createTime"];
this.createUser = json["createUser"];
this.updateTime = json["updateTime"];
this.updateUser = json["updateUser"];
this.categoryId = json["categoryId"];
this.storeId = json["storeId"];
this.name = json["name"];
this.description = json["description"];
this.worth = json["worth"];
this.price = json["price"];
this.detail = json["detail"];
this.stock = json["stock"];
this.sales = json["sales"];
this.isHot = json["isHot"];
this.sortOrder = json["sortOrder"];
this.state = json["state"];
this.canPick = json["canPick"];
this.canDelivery = json["canDelivery"];
this.isDelete = json["isDelete"];
this.categoryName = json["categoryName"];
this.mainImgPath = json["mainImgPath"];
this.viceImgPaths = json["viceImgPaths"] != null ? json["viceImgPaths"].cast<String>() : [];
}
Map<String, dynamic> toJson() {
var map = <String, dynamic>{};
map["id"] = this.id;
map["createTime"] = this.createTime;
map["createUser"] = this.createUser;
map["updateTime"] = this.updateTime;
map["updateUser"] = this.updateUser;
map["categoryId"] = this.categoryId;
map["storeId"] = this.storeId;
map["name"] = this.name;
map["description"] = this.description;
map["worth"] = this.worth;
map["price"] = this.price;
map["detail"] = this.detail;
map["stock"] = this.stock;
map["sales"] = this.sales;
map["isHot"] = this.isHot;
map["sortOrder"] = this.sortOrder;
map["state"] = this.state;
map["canPick"] = this.canPick;
map["canDelivery"] = this.canDelivery;
map["isDelete"] = this.isDelete;
map["categoryName"] = this.categoryName;
map["mainImgPath"] = this.mainImgPath;
map["viceImgPaths"] = this.viceImgPaths;
return map;
}
}