hyzp_ybqx-Commit106:版本号更新为1.4.17+20220227,优化统计数据getAllStatisData为空时报错的问题
This commit is contained in:
@@ -488,7 +488,15 @@ Future getAllStatisData({String ip = '', String date = ''}) async {
|
||||
|
||||
if (response.statusCode == 200) {
|
||||
Map _mapStatisDataRet = await getMapFromJson(response.data);
|
||||
print('_mapStatisDataRet = ${_mapStatisDataRet}');
|
||||
print('_mapStatisDataRet[\'data\'] = ${_mapStatisDataRet['data']}');
|
||||
// _mapStatisDataRet = {ret: 200, data: {}, msg: }
|
||||
// _mapStatisDataRet['data'] = {}
|
||||
// 避免统计数据为空时报错:
|
||||
// getAllStatisData 网络请求过程异常e:type '_InternalLinkedHashMap<String, dynamic>' is not a subtype of type 'List<dynamic>'
|
||||
if (_mapStatisDataRet['data'].length > 0) {
|
||||
_listAllStatisData = _mapStatisDataRet['data'];
|
||||
}
|
||||
print('getAllStatisData 网络请求过程正常完成');
|
||||
} else {
|
||||
throw Exception('getAllStatisData 后端接口出现异常,请检测代码和服务器情况.........');
|
||||
@@ -1983,7 +1991,7 @@ Future getThePageList(
|
||||
print(mapGetData.toString());
|
||||
//第一次必须先进行listWzxxGetList2.clear(),否则addAll报错终止
|
||||
print('mapGetData[' 'data' '][' 'items' '].length = ${mapGetData['data']['items'].length}');
|
||||
if (bShowToast && 0 == mapGetData['data']['items'].length) {
|
||||
if (page > 1 && bShowToast && 0 == mapGetData['data']['items'].length) {
|
||||
Fluttertoast.showToast(
|
||||
msg: '没有更多了!',
|
||||
toastLength: Toast.LENGTH_SHORT,
|
||||
|
||||
+2
-1
@@ -56,7 +56,8 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
||||
#version: 1.4.14+20220124 # 無法獲取flutter编译时间,只有通过这种方式获取,所以还是保留后面的 +20220124。
|
||||
# 上传软件时可以不加后面的 +20220124,否则二维码扫码后无法直接下载
|
||||
#version: 1.4.15+20220124
|
||||
version: 1.4.16+20220126
|
||||
#version: 1.4.16+20220126
|
||||
version: 1.4.17+20220227
|
||||
|
||||
environment:
|
||||
sdk: ">=2.7.0 <3.0.0"
|
||||
|
||||
Reference in New Issue
Block a user