Commit b93f2f290a6c4a06890487834caff0cd7c04933e
1 parent
c48decfb
宴会创建图片上传完成bug,只保存了last ,可能会丢数据和保存进去null,因为数组里面包含了要上传图片的数据,包括process<1的数据
Showing
1 changed file
with
55 additions
and
18 deletions
| @@ -455,7 +455,7 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -455,7 +455,7 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 455 | } | 455 | } |
| 456 | String numStr = ConvertNumberToChineseMoneyWords.toChinese(index); | 456 | String numStr = ConvertNumberToChineseMoneyWords.toChinese(index); |
| 457 | setXuanTaiModel.reserveOrder = '第${numStr}场'; | 457 | setXuanTaiModel.reserveOrder = '第${numStr}场'; |
| 458 | - | 458 | + |
| 459 | return setXuanTaiModel; | 459 | return setXuanTaiModel; |
| 460 | } | 460 | } |
| 461 | 461 | ||
| @@ -766,7 +766,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -766,7 +766,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 766 | recognizer: TapGestureRecognizer() | 766 | recognizer: TapGestureRecognizer() |
| 767 | ..onTap = () {}), | 767 | ..onTap = () {}), |
| 768 | ], | 768 | ], |
| 769 | - ), textScaler: TextScaler.linear(1))), | 769 | + ), |
| 770 | + textScaler: TextScaler.linear(1))), | ||
| 770 | Expanded( | 771 | Expanded( |
| 771 | child: Text( | 772 | child: Text( |
| 772 | labelShow ?? "", | 773 | labelShow ?? "", |
| @@ -853,7 +854,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -853,7 +854,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 853 | recognizer: TapGestureRecognizer() | 854 | recognizer: TapGestureRecognizer() |
| 854 | ..onTap = () {}), | 855 | ..onTap = () {}), |
| 855 | ], | 856 | ], |
| 856 | - ), textScaler: TextScaler.linear(1))), | 857 | + ), |
| 858 | + textScaler: TextScaler.linear(1))), | ||
| 857 | Expanded( | 859 | Expanded( |
| 858 | child: Container( | 860 | child: Container( |
| 859 | height: h(40), | 861 | height: h(40), |
| @@ -1255,7 +1257,14 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -1255,7 +1257,14 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 1255 | mainAxisSpacing: 72, | 1257 | mainAxisSpacing: 72, |
| 1256 | crossAxisSpacing: 56, | 1258 | crossAxisSpacing: 56, |
| 1257 | callback: () { | 1259 | callback: () { |
| 1258 | - imgAllYx.add(model.feastRemarkImageList.last.qiniuUrl); | 1260 | + model.feastRemarkImageList.forEach((element) { |
| 1261 | + if (element.qiniuUrl != null) { | ||
| 1262 | + imgAllYx.add(element.qiniuUrl); | ||
| 1263 | + } | ||
| 1264 | + }); | ||
| 1265 | + imgAllYx = imgAllYx.toSet().toList(); | ||
| 1266 | + | ||
| 1267 | + print(imgAllYx); | ||
| 1259 | print('完成'); | 1268 | print('完成'); |
| 1260 | }, | 1269 | }, |
| 1261 | ); | 1270 | ); |
| @@ -2313,11 +2322,10 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -2313,11 +2322,10 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 2313 | xuantaiData[xuantaiSelIndex].endDate != '' && | 2322 | xuantaiData[xuantaiSelIndex].endDate != '' && |
| 2314 | xuantaiData[xuantaiSelIndex].dateTimeShowxt != | 2323 | xuantaiData[xuantaiSelIndex].dateTimeShowxt != |
| 2315 | '请选择' && | 2324 | '请选择' && |
| 2316 | - xuantaiData[xuantaiSelIndex].tableList != | ||
| 2317 | - null) { | 2325 | + xuantaiData[xuantaiSelIndex].tableList != null) { |
| 2318 | _getTableList(); | 2326 | _getTableList(); |
| 2319 | } | 2327 | } |
| 2320 | - }); | 2328 | + }); |
| 2321 | // DialogUtil.showSelectCusmanDialog( | 2329 | // DialogUtil.showSelectCusmanDialog( |
| 2322 | // context, | 2330 | // context, |
| 2323 | // feastModel.sellerManageList.map((item) { | 2331 | // feastModel.sellerManageList.map((item) { |
| @@ -2373,7 +2381,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -2373,7 +2381,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 2373 | recognizer: TapGestureRecognizer() | 2381 | recognizer: TapGestureRecognizer() |
| 2374 | ..onTap = () {}), | 2382 | ..onTap = () {}), |
| 2375 | ], | 2383 | ], |
| 2376 | - ), textScaler: TextScaler.linear(1)), | 2384 | + ), |
| 2385 | + textScaler: TextScaler.linear(1)), | ||
| 2377 | ListView.builder( | 2386 | ListView.builder( |
| 2378 | itemCount: | 2387 | itemCount: |
| 2379 | xuantaiData[xuantaiSelIndex].tids!.length, | 2388 | xuantaiData[xuantaiSelIndex].tids!.length, |
| @@ -3611,7 +3620,14 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -3611,7 +3620,14 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 3611 | mainAxisSpacing: 72, | 3620 | mainAxisSpacing: 72, |
| 3612 | crossAxisSpacing: 56, | 3621 | crossAxisSpacing: 56, |
| 3613 | callback: () { | 3622 | callback: () { |
| 3614 | - imgAllDj.add(model.feastRemarkDjImageList.last.qiniuUrl); | 3623 | + model.feastRemarkDjImageList.forEach((element) { |
| 3624 | + if (element.qiniuUrl != null) { | ||
| 3625 | + imgAllDj.add(element.qiniuUrl); | ||
| 3626 | + } | ||
| 3627 | + }); | ||
| 3628 | + imgAllDj = imgAllDj.toSet().toList(); | ||
| 3629 | + | ||
| 3630 | + print(imgAllDj); | ||
| 3615 | print('完成'); | 3631 | print('完成'); |
| 3616 | }, | 3632 | }, |
| 3617 | ); | 3633 | ); |
| @@ -4611,7 +4627,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -4611,7 +4627,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 4611 | recognizer: TapGestureRecognizer() | 4627 | recognizer: TapGestureRecognizer() |
| 4612 | ..onTap = () {}), | 4628 | ..onTap = () {}), |
| 4613 | ], | 4629 | ], |
| 4614 | - ), textScaler: TextScaler.linear(1)), | 4630 | + ), |
| 4631 | + textScaler: TextScaler.linear(1)), | ||
| 4615 | HEmptyView(12), | 4632 | HEmptyView(12), |
| 4616 | _textfield( | 4633 | _textfield( |
| 4617 | '请输入', | 4634 | '请输入', |
| @@ -4652,8 +4669,16 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -4652,8 +4669,16 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 4652 | mainAxisSpacing: 72, | 4669 | mainAxisSpacing: 72, |
| 4653 | crossAxisSpacing: 56, | 4670 | crossAxisSpacing: 56, |
| 4654 | callback: () { | 4671 | callback: () { |
| 4655 | - imgAllHt.add(_uploadImageProvider | ||
| 4656 | - .feastRemarkContractImageList.last.qiniuUrl); | 4672 | + _uploadImageProvider.feastRemarkContractImageList |
| 4673 | + .forEach((element) { | ||
| 4674 | + if (element.qiniuUrl != null) { | ||
| 4675 | + imgAllHt.add(element.qiniuUrl); | ||
| 4676 | + } | ||
| 4677 | + }); | ||
| 4678 | + imgAllHt = imgAllHt.toSet().toList(); | ||
| 4679 | + | ||
| 4680 | + print(imgAllHt); | ||
| 4681 | + print('完成'); | ||
| 4657 | }, | 4682 | }, |
| 4658 | ); | 4683 | ); |
| 4659 | }), | 4684 | }), |
| @@ -4920,8 +4945,16 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -4920,8 +4945,16 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 4920 | mainAxisSpacing: 72, | 4945 | mainAxisSpacing: 72, |
| 4921 | crossAxisSpacing: 56, | 4946 | crossAxisSpacing: 56, |
| 4922 | callback: () { | 4947 | callback: () { |
| 4923 | - imgAllFp.add(_uploadImageProvider | ||
| 4924 | - .feastRemarkInvoiceImageList.last.qiniuUrl); | 4948 | + _uploadImageProvider.feastRemarkInvoiceImageList |
| 4949 | + .forEach((element) { | ||
| 4950 | + if (element.qiniuUrl != null) { | ||
| 4951 | + imgAllFp.add(element.qiniuUrl); | ||
| 4952 | + } | ||
| 4953 | + }); | ||
| 4954 | + imgAllFp = imgAllFp.toSet().toList(); | ||
| 4955 | + | ||
| 4956 | + print(imgAllFp); | ||
| 4957 | + print('完成'); | ||
| 4925 | }, | 4958 | }, |
| 4926 | ); | 4959 | ); |
| 4927 | }), | 4960 | }), |
| @@ -5327,7 +5360,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -5327,7 +5360,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 5327 | //点击事件 | 5360 | //点击事件 |
| 5328 | recognizer: TapGestureRecognizer()..onTap = () {}), | 5361 | recognizer: TapGestureRecognizer()..onTap = () {}), |
| 5329 | ], | 5362 | ], |
| 5330 | - ), textScaler: TextScaler.linear(1)); | 5363 | + ), |
| 5364 | + textScaler: TextScaler.linear(1)); | ||
| 5331 | } | 5365 | } |
| 5332 | 5366 | ||
| 5333 | Widget taocanText(String? title, String per) { | 5367 | Widget taocanText(String? title, String per) { |
| @@ -5351,7 +5385,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -5351,7 +5385,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 5351 | //点击事件 | 5385 | //点击事件 |
| 5352 | recognizer: TapGestureRecognizer()..onTap = () {}), | 5386 | recognizer: TapGestureRecognizer()..onTap = () {}), |
| 5353 | ], | 5387 | ], |
| 5354 | - ), textScaler: TextScaler.linear(1)); | 5388 | + ), |
| 5389 | + textScaler: TextScaler.linear(1)); | ||
| 5355 | } | 5390 | } |
| 5356 | 5391 | ||
| 5357 | Widget djTextType1(String title, String data, String per) { | 5392 | Widget djTextType1(String title, String data, String per) { |
| @@ -5381,7 +5416,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -5381,7 +5416,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 5381 | //点击事件 | 5416 | //点击事件 |
| 5382 | recognizer: TapGestureRecognizer()..onTap = () {}), | 5417 | recognizer: TapGestureRecognizer()..onTap = () {}), |
| 5383 | ], | 5418 | ], |
| 5384 | - ), textScaler: TextScaler.linear(1)); | 5419 | + ), |
| 5420 | + textScaler: TextScaler.linear(1)); | ||
| 5385 | } | 5421 | } |
| 5386 | 5422 | ||
| 5387 | Widget djText(String title, String per) { | 5423 | Widget djText(String title, String per) { |
| @@ -5405,7 +5441,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | @@ -5405,7 +5441,8 @@ class _FeastCreatePageState extends State<FeastCreatePage> { | ||
| 5405 | //点击事件 | 5441 | //点击事件 |
| 5406 | recognizer: TapGestureRecognizer()..onTap = () {}), | 5442 | recognizer: TapGestureRecognizer()..onTap = () {}), |
| 5407 | ], | 5443 | ], |
| 5408 | - ), textScaler: TextScaler.linear(1)); | 5444 | + ), |
| 5445 | + textScaler: TextScaler.linear(1)); | ||
| 5409 | } | 5446 | } |
| 5410 | 5447 | ||
| 5411 | @override | 5448 | @override |
-
Please register or login to post a comment