|
...
|
...
|
@@ -175,11 +175,14 @@ class WineManageSunModel { |
|
|
|
String wineAmount;
|
|
|
|
String unit;
|
|
|
|
String wineNumber;
|
|
|
|
String remark;
|
|
|
|
String wineSave;
|
|
|
|
List<UploadImgModel> img = [];
|
|
|
|
TextEditingController wineNameC = TextEditingController(); //酒品名称
|
|
|
|
TextEditingController wineNumC = TextEditingController(); //存酒数量
|
|
|
|
TextEditingController wineUnitC = TextEditingController(); //计量单位
|
|
|
|
TextEditingController wineSerialC = TextEditingController(); //存酒编号
|
|
|
|
TextEditingController wineRemarkC = TextEditingController(); //存酒备注
|
|
|
|
String wineStock;
|
|
|
|
|
|
|
|
String cdate;
|
|
...
|
...
|
@@ -194,19 +197,25 @@ class WineManageSunModel { |
|
|
|
this.wineAmount,
|
|
|
|
this.unit,
|
|
|
|
this.wineNumber,
|
|
|
|
this.remark,
|
|
|
|
this.wineSave,
|
|
|
|
this.img,
|
|
|
|
this.wineStock,
|
|
|
|
this.cdate});
|
|
|
|
|
|
|
|
WineManageSunModel.fromJson(Map<String, dynamic> json) {
|
|
|
|
wineName = json['wine_name'];
|
|
|
|
wineAmount = double.parse(json['wine_amount'] == '' || json['wine_amount'] == null
|
|
|
|
wineAmount = double.parse(
|
|
|
|
json['wine_amount'] == '' || json['wine_amount'] == null
|
|
|
|
? '0'
|
|
|
|
: json['wine_amount'])
|
|
|
|
.toInt()
|
|
|
|
.toString();
|
|
|
|
.toInt()
|
|
|
|
.toString();
|
|
|
|
unit = json['unit'];
|
|
|
|
wineNumber = json['wine_number']?? "";
|
|
|
|
wineNumber = json['wine_number'] ?? "";
|
|
|
|
remark = json['remark'] ?? '';
|
|
|
|
wineSave = json['wine_save'] ?? '';
|
|
|
|
|
|
|
|
// wineStock = json['wine_stock'] ?? "";
|
|
|
|
wineStock = double.parse(
|
|
|
|
json['wine_stock'] == '' || json['wine_stock'] == null
|
|
...
|
...
|
@@ -243,6 +252,9 @@ class WineManageSunModel { |
|
|
|
data['wine_amount'] = this.wineAmount;
|
|
|
|
data['unit'] = this.unit;
|
|
|
|
data['wine_number'] = this.wineNumber;
|
|
|
|
data['remark'] = this.remark;
|
|
|
|
data['wine_save'] = this.wineSave;
|
|
|
|
|
|
|
|
data['img'] = this.img;
|
|
|
|
data['wine_stock'] = this.wineStock;
|
|
|
|
data['cdate'] = this.cdate;
|
|
...
|
...
|
@@ -256,6 +268,8 @@ class WineManageSunMoveModel { |
|
|
|
String wineAmount;
|
|
|
|
String unit;
|
|
|
|
String wineNumber;
|
|
|
|
String remark;
|
|
|
|
String wineSave;
|
|
|
|
List<String> img;
|
|
|
|
String checkAmount;
|
|
|
|
String wineStock;
|
|
...
|
...
|
@@ -275,6 +289,8 @@ class WineManageSunMoveModel { |
|
|
|
this.wineAmount,
|
|
|
|
this.unit,
|
|
|
|
this.wineNumber,
|
|
|
|
this.remark,
|
|
|
|
this.wineSave,
|
|
|
|
this.checkAmount,
|
|
|
|
this.img,
|
|
|
|
this.wineStock,
|
|
...
|
...
|
@@ -291,6 +307,9 @@ class WineManageSunMoveModel { |
|
|
|
// wineNumC.text = wineAmount ?? '';
|
|
|
|
unit = json['unit'];
|
|
|
|
wineNumber = json['wine_number'] ?? "";
|
|
|
|
remark = json['remark'] ?? '';
|
|
|
|
|
|
|
|
wineSave = json['wine_save'] ?? '';
|
|
|
|
// checkAmount = json['check_amount'] ?? '';
|
|
|
|
checkAmount = double.parse(
|
|
|
|
json['check_amount'] == '' || json['check_amount'] == null
|
|
...
|
...
|
@@ -329,6 +348,9 @@ class WineManageSunMoveModel { |
|
|
|
data['wine_amount'] = this.wineAmount;
|
|
|
|
data['unit'] = this.unit;
|
|
|
|
data['wine_number'] = this.wineNumber;
|
|
|
|
data['remark'] = this.remark;
|
|
|
|
data['wine_save'] = this.wineSave;
|
|
|
|
|
|
|
|
data['check_amount'] = this.checkAmount;
|
|
|
|
data['img'] = this.img;
|
|
|
|
data['wine_stock'] = this.wineStock;
|
|
...
|
...
|
@@ -342,12 +364,15 @@ class WineCheckModel { |
|
|
|
String wineName;
|
|
|
|
String unit;
|
|
|
|
String wineNumber;
|
|
|
|
String remark;
|
|
|
|
String wineSave;
|
|
|
|
List<String> img;
|
|
|
|
String checkAmount;
|
|
|
|
WineCheckModel({
|
|
|
|
this.wineName,
|
|
|
|
this.unit,
|
|
|
|
this.wineNumber,
|
|
|
|
this.remark,
|
|
|
|
this.checkAmount,
|
|
|
|
this.img,
|
|
|
|
});
|
|
...
|
...
|
@@ -356,6 +381,9 @@ class WineCheckModel { |
|
|
|
wineName = json['wine_name'];
|
|
|
|
unit = json['unit'];
|
|
|
|
wineNumber = json['wine_number'] ?? "";
|
|
|
|
remark = json['remark'] ?? '';
|
|
|
|
|
|
|
|
wineSave = json['wine_save'] ?? '';
|
|
|
|
checkAmount = json['check_amount'] ?? "";
|
|
|
|
|
|
|
|
// wineNumC.text = wineNumber;
|
|
...
|
...
|
@@ -379,6 +407,10 @@ class WineCheckModel { |
|
|
|
data['wine_name'] = this.wineName;
|
|
|
|
data['unit'] = this.unit;
|
|
|
|
data['wine_number'] = this.wineNumber;
|
|
|
|
data['remark'] = this.remark;
|
|
|
|
|
|
|
|
data['wine_save'] = this.wineSave;
|
|
|
|
|
|
|
|
data['check_amount'] = this.checkAmount;
|
|
|
|
data['img'] = this.img;
|
|
|
|
return data;
|
...
|
...
|
|