Commit 9dae68ee7c0bc018fbc7e31d31a2f031dd645c03

Authored by wdn127929
1 parent 189a63b4

客情限制天数

@@ -128,6 +128,9 @@ class SellerList extends Object { @@ -128,6 +128,9 @@ class SellerList extends Object {
128 @JsonKey(name: 'cdate') 128 @JsonKey(name: 'cdate')
129 String cdate; 129 String cdate;
130 130
  131 + @JsonKey(name: 'remaining_time')
  132 + int remainingTime;
  133 +
131 String get cdateStr { 134 String get cdateStr {
132 if (cdate != null) { 135 if (cdate != null) {
133 DateTime dateTime = DateTime.fromMillisecondsSinceEpoch( 136 DateTime dateTime = DateTime.fromMillisecondsSinceEpoch(
@@ -145,18 +148,18 @@ class SellerList extends Object { @@ -145,18 +148,18 @@ class SellerList extends Object {
145 } 148 }
146 149
147 SellerList( 150 SellerList(
148 - this.id,  
149 - this.sellerid,  
150 - this.createUser,  
151 - this.uid,  
152 - this.aid,  
153 - this.gid,  
154 - this.content,  
155 - this.isUpdate,  
156 - this.finishedStatus,  
157 - this.edate,  
158 - this.cdate,  
159 - ); 151 + this.id,
  152 + this.sellerid,
  153 + this.createUser,
  154 + this.uid,
  155 + this.aid,
  156 + this.gid,
  157 + this.content,
  158 + this.isUpdate,
  159 + this.finishedStatus,
  160 + this.edate,
  161 + this.cdate,
  162 + this.remainingTime);
160 163
161 factory SellerList.fromJson(Map<String, dynamic> srcJson) => 164 factory SellerList.fromJson(Map<String, dynamic> srcJson) =>
162 _$SellerListFromJson(srcJson); 165 _$SellerListFromJson(srcJson);
@@ -79,6 +79,7 @@ SellerList _$SellerListFromJson(Map<String, dynamic> json) { @@ -79,6 +79,7 @@ SellerList _$SellerListFromJson(Map<String, dynamic> json) {
79 json['finished_status'] as String, 79 json['finished_status'] as String,
80 json['edate'] as String, 80 json['edate'] as String,
81 json['cdate'] as String, 81 json['cdate'] as String,
  82 + json['remaining_time'] as int,
82 ); 83 );
83 } 84 }
84 85
@@ -95,4 +96,5 @@ Map<String, dynamic> _$SellerListToJson(SellerList instance) => @@ -95,4 +96,5 @@ Map<String, dynamic> _$SellerListToJson(SellerList instance) =>
95 'finished_status': instance.finishedStatus, 96 'finished_status': instance.finishedStatus,
96 'edate': instance.edate, 97 'edate': instance.edate,
97 'cdate': instance.cdate, 98 'cdate': instance.cdate,
  99 + 'remaining_time': instance.remainingTime,
98 }; 100 };
@@ -146,9 +146,9 @@ class _MyMarketingRecordsPageState extends State<MyMarketingRecordsPage> { @@ -146,9 +146,9 @@ class _MyMarketingRecordsPageState extends State<MyMarketingRecordsPage> {
146 HEmptyView(10), 146 HEmptyView(10),
147 Expanded( 147 Expanded(
148 child: Text( 148 child: Text(
149 - data.edate == null 149 + data.remainingTime == null
150 ? '无限制' 150 ? '无限制'
151 - : '剩余${11111}天', 151 + : '剩余${data.remainingTime}天',
152 overflow: TextOverflow.ellipsis, 152 overflow: TextOverflow.ellipsis,
153 style: TextStyle( 153 style: TextStyle(
154 color: MyColours.color_333333, 154 color: MyColours.color_333333,