2025.9.3 今天一天的bug
parent
2309267b63
commit
b6334867c5
|
|
@ -23,11 +23,11 @@ import 'package:shared_preferences/shared_preferences.dart';
|
||||||
import '../../../customWidget/photo_picker_row.dart';
|
import '../../../customWidget/photo_picker_row.dart';
|
||||||
import '../../../http/ApiService.dart';
|
import '../../../http/ApiService.dart';
|
||||||
|
|
||||||
class ImgData {
|
class ImgDataTwo {
|
||||||
final String path;
|
final String path;
|
||||||
final String id;
|
final String id;
|
||||||
|
|
||||||
const ImgData({
|
const ImgDataTwo({
|
||||||
required this.path,
|
required this.path,
|
||||||
required this.id,
|
required this.id,
|
||||||
});
|
});
|
||||||
|
|
@ -61,8 +61,8 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
List<Map<String, dynamic>> _personCache = [];
|
List<Map<String, dynamic>> _personCache = [];
|
||||||
|
|
||||||
|
|
||||||
List<ImgData> _yinHuanImages = [];
|
List<ImgDataTwo> _yinHuanImages = [];
|
||||||
List<ImgData> _yinHuanVido = [];
|
List<ImgDataTwo> _yinHuanVido = [];
|
||||||
// String _yinHuanVido="";
|
// String _yinHuanVido="";
|
||||||
dynamic _hazardLeve;
|
dynamic _hazardLeve;
|
||||||
String yinHuanId = "";
|
String yinHuanId = "";
|
||||||
|
|
@ -74,7 +74,7 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
String responsibleName="";
|
String responsibleName="";
|
||||||
String dataTime = "";
|
String dataTime = "";
|
||||||
|
|
||||||
List<ImgData> _zhengGaiImages = [];
|
List<ImgDataTwo> _zhengGaiImages = [];
|
||||||
List<String> _yinHuanTypeIds = [];
|
List<String> _yinHuanTypeIds = [];
|
||||||
List<String> _yinHuanTypeNames = [];
|
List<String> _yinHuanTypeNames = [];
|
||||||
|
|
||||||
|
|
@ -94,12 +94,19 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
dynamic pd=widget.result["pd"];
|
dynamic pd=widget.result["pd"];
|
||||||
|
|
||||||
for(int i=0;i<hImgs.length;i++){
|
for(int i=0;i<hImgs.length;i++){
|
||||||
final ImgData = hImgs[i];
|
final imgDataMap = hImgs[i]; // 这是一个Map,不是函数
|
||||||
if (ImgData['FILEPATH'].toString().endsWith('.mp4')) {
|
|
||||||
_yinHuanVido.add(ImgData(path: ApiService.baseImgPath +hImgs[i]['FILEPATH'], id: ImgData['IMGFILES_ID']));
|
|
||||||
} else {
|
|
||||||
_yinHuanImages.add(ImgData(path: ApiService.baseImgPath +hImgs[i]['FILEPATH'], id: ImgData['IMGFILES_ID']));
|
|
||||||
|
|
||||||
|
if (imgDataMap['FILEPATH'].toString().endsWith('.mp4')) {
|
||||||
|
// 使用模型类创建实例,而不是调用Map
|
||||||
|
_yinHuanVido.add(ImgDataTwo(
|
||||||
|
id: imgDataMap['IMGFILES_ID']?.toString() ?? '',
|
||||||
|
path: ApiService.baseImgPath + imgDataMap['FILEPATH'].toString()
|
||||||
|
));
|
||||||
|
} else {
|
||||||
|
_yinHuanImages.add(ImgDataTwo(
|
||||||
|
id: imgDataMap['IMGFILES_ID']?.toString() ?? '',
|
||||||
|
path: ApiService.baseImgPath + imgDataMap['FILEPATH'].toString()
|
||||||
|
));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// _yinHuanVido视频
|
// _yinHuanVido视频
|
||||||
|
|
@ -118,15 +125,15 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
_isDanger=false;
|
_isDanger=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
buMenId=pd["RECTIFICATIONDEPT"];
|
buMenId=pd["RECTIFICATIONDEPT"]??"";
|
||||||
buMenPDId=pd["HIDDENFINDDEPT"];
|
buMenPDId=pd["HIDDENFINDDEPT"]??"";
|
||||||
buMenName=pd["RECTIFICATIONDEPTNAME"];
|
buMenName=pd["RECTIFICATIONDEPTNAME"]??"";
|
||||||
responsibleId=pd["RECTIFICATIONOR"];
|
responsibleId=pd["RECTIFICATIONOR"]??"";
|
||||||
responsibleName=pd["RECTIFICATIONORNAME"];
|
responsibleName=pd["RECTIFICATIONORNAME"]??"";
|
||||||
dataTime=pd["RECTIFICATIONDEADLINE"];
|
dataTime=pd["RECTIFICATIONDEADLINE"]??"";
|
||||||
|
|
||||||
_dangerDetailController.text=pd["RECTIFYDESCR"];
|
_dangerDetailController.text=pd["RECTIFYDESCR"];
|
||||||
_zhengGaiImages= rImgs.map((e) => ImgData(path: ApiService.baseImgPath +e["FILEPATH"], id: e['IMGFILES_ID'])).toList();
|
_zhengGaiImages= rImgs.map((e) => ImgDataTwo(path: ApiService.baseImgPath +e["FILEPATH"], id: e['IMGFILES_ID'])).toList();
|
||||||
// _zhengGaiImages整改图片"rImgs" -> [_GrowableList]
|
// _zhengGaiImages整改图片"rImgs" -> [_GrowableList]
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
|
|
@ -183,8 +190,8 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
String _getIDForPath(String path, List<ImgData> imgList) {
|
String _getIDForPath(String path, List<ImgDataTwo> imgList) {
|
||||||
for (ImgData data in imgList) {
|
for (ImgDataTwo data in imgList) {
|
||||||
if (data.path == path) {
|
if (data.path == path) {
|
||||||
return data.id;
|
return data.id;
|
||||||
}
|
}
|
||||||
|
|
@ -203,13 +210,13 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
}
|
}
|
||||||
// return
|
// return
|
||||||
}
|
}
|
||||||
ImgData _getImageDataForPath(String path, List<ImgData> list) {
|
ImgDataTwo _getImageDataForPath(String path, List<ImgDataTwo> list) {
|
||||||
for (ImgData data in list) {
|
for (ImgDataTwo data in list) {
|
||||||
if (data.path == path) {
|
if (data.path == path) {
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ImgData(path: '', id: '');
|
return ImgDataTwo(path: '', id: '');
|
||||||
}
|
}
|
||||||
Widget _buildSectionContainer({required Widget child}) {
|
Widget _buildSectionContainer({required Widget child}) {
|
||||||
return Container(
|
return Container(
|
||||||
|
|
@ -244,7 +251,7 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
initialMediaPaths:_yinHuanImages.map((item) => item.path).toList(),
|
initialMediaPaths:_yinHuanImages.map((item) => item.path).toList(),
|
||||||
isShowAI: true,
|
isShowAI: true,
|
||||||
onMediaAdded: (value) {
|
onMediaAdded: (value) {
|
||||||
_yinHuanImages.add(ImgData(path: value, id: ''));
|
_yinHuanImages.add(ImgDataTwo(path: value, id: ''));
|
||||||
},
|
},
|
||||||
onMediaRemoved: (value) async {
|
onMediaRemoved: (value) async {
|
||||||
|
|
||||||
|
|
@ -285,7 +292,7 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
mediaType: MediaType.video,
|
mediaType: MediaType.video,
|
||||||
initialMediaPaths: _yinHuanVido.map((item) => item.path).toList(),
|
initialMediaPaths: _yinHuanVido.map((item) => item.path).toList(),
|
||||||
onMediaAdded: (value) {
|
onMediaAdded: (value) {
|
||||||
_yinHuanVido.add(ImgData(path: value, id: ''));
|
_yinHuanVido.add(ImgDataTwo(path: value, id: ''));
|
||||||
},
|
},
|
||||||
onMediaRemoved: (value) async {
|
onMediaRemoved: (value) async {
|
||||||
|
|
||||||
|
|
@ -432,7 +439,7 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
isShowAI: false,
|
isShowAI: false,
|
||||||
initialMediaPaths:_zhengGaiImages.map((item) => item.path).toList(),
|
initialMediaPaths:_zhengGaiImages.map((item) => item.path).toList(),
|
||||||
onMediaAdded: (value) {
|
onMediaAdded: (value) {
|
||||||
_zhengGaiImages.add(ImgData(path: value, id: ''));
|
_zhengGaiImages.add(ImgDataTwo(path: value, id: ''));
|
||||||
},
|
},
|
||||||
onMediaRemoved: (value) async {
|
onMediaRemoved: (value) async {
|
||||||
|
|
||||||
|
|
@ -755,14 +762,14 @@ class _CheckInformationOneItemState extends State<CheckInformationOneItem> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<bool> _addImgFiles(ImgData imgData,String type,String id) async {
|
Future<bool> _addImgFiles(ImgDataTwo imgData,String type,String id) async {
|
||||||
if (imgData.id.isEmpty) {
|
if (imgData.id.isEmpty) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
final raw = await ApiService.addImgFiles( imgData.path, type, id);
|
final raw = await ApiService.addImgFiles( imgData.path, type, id);
|
||||||
if (raw['result'] == 'success') {
|
if (raw['result'] == 'success') {
|
||||||
Map pd = raw['pd'];
|
Map pd = raw['pd'];
|
||||||
imgData = ImgData(path: pd['FILEPATH'], id: pd['IMGFILES_ID']);
|
imgData = ImgDataTwo(path: pd['FILEPATH'], id: pd['IMGFILES_ID']);
|
||||||
return true;
|
return true;
|
||||||
}else{
|
}else{
|
||||||
// _showMessage('反馈提交失败');
|
// _showMessage('反馈提交失败');
|
||||||
|
|
|
||||||
|
|
@ -144,7 +144,9 @@ class _CustomRecordDrawerState extends State<CustomRecordDrawer> {
|
||||||
_selectedZQTimeId= dangerWaitBean["selectedZQTimeId"];
|
_selectedZQTimeId= dangerWaitBean["selectedZQTimeId"];
|
||||||
|
|
||||||
startTime= dangerWaitBean["startTime"];
|
startTime= dangerWaitBean["startTime"];
|
||||||
|
_startDate = DateTime.parse(startTime);
|
||||||
endTime= dangerWaitBean["endTime"];
|
endTime= dangerWaitBean["endTime"];
|
||||||
|
_endDate = DateTime.parse(endTime);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -469,7 +469,10 @@ class _QuickReportPageState extends State<QuickReportPage> {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
buMenId = SessionService.instance.loginUser?["DEPARTMENT_ID"];
|
||||||
|
buMenName = SessionService.instance.loginUser?["DEPARTMENT_NAME"];
|
||||||
|
responsibleId=SessionService.instance.loginUser?["USER_ID"];
|
||||||
|
responsibleName=SessionService.instance.loginUser?["NAME"];
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
type="2";
|
type="2";
|
||||||
|
|
|
||||||
|
|
@ -46,7 +46,7 @@ class _ApplicationPageState extends State<ApplicationPage> {
|
||||||
|
|
||||||
}
|
}
|
||||||
void _onBadgeChanged() {
|
void _onBadgeChanged() {
|
||||||
setState(() {});
|
// setState(() {});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 处理项目点击事件
|
// 处理项目点击事件
|
||||||
|
|
@ -59,7 +59,9 @@ class _ApplicationPageState extends State<ApplicationPage> {
|
||||||
|
|
||||||
case AppItem.riskInspection:
|
case AppItem.riskInspection:
|
||||||
// 跳转到隐患排查页面
|
// 跳转到隐患排查页面
|
||||||
|
LoadingDialogHelper.show();
|
||||||
bool isRest= await _getIsRest();
|
bool isRest= await _getIsRest();
|
||||||
|
LoadingDialogHelper.hide();
|
||||||
if(isRest){
|
if(isRest){
|
||||||
ToastUtil.showNormal(context, "您已经处于离岗状态中");
|
ToastUtil.showNormal(context, "您已经处于离岗状态中");
|
||||||
return;
|
return;
|
||||||
|
|
@ -80,7 +82,9 @@ class _ApplicationPageState extends State<ApplicationPage> {
|
||||||
break;
|
break;
|
||||||
case AppItem.supervisionRectification:
|
case AppItem.supervisionRectification:
|
||||||
// 跳转到监管帮扶隐患整改页面
|
// 跳转到监管帮扶隐患整改页面
|
||||||
|
LoadingDialogHelper.show();
|
||||||
bool isRest= await _getIsRest();
|
bool isRest= await _getIsRest();
|
||||||
|
LoadingDialogHelper.hide();
|
||||||
if(isRest){
|
if(isRest){
|
||||||
ToastUtil.showNormal(context, "您已经处于离岗状态中");
|
ToastUtil.showNormal(context, "您已经处于离岗状态中");
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:qhd_prevention/customWidget/toast_util.dart';
|
||||||
import 'package:qhd_prevention/pages/app/pending_rectification_detail_page.dart';
|
import 'package:qhd_prevention/pages/app/pending_rectification_detail_page.dart';
|
||||||
import 'package:qhd_prevention/pages/home/work/custom_driver_drawer.dart';
|
import 'package:qhd_prevention/pages/home/work/custom_driver_drawer.dart';
|
||||||
import 'package:qhd_prevention/pages/home/risk/risk_detail_page.dart';
|
import 'package:qhd_prevention/pages/home/risk/risk_detail_page.dart';
|
||||||
|
|
@ -215,6 +216,10 @@ class _DangerWaitListPageState extends State<DangerWaitListPage> {
|
||||||
case 2://待整改隐患
|
case 2://待整改隐患
|
||||||
// _getDangerRecord(2,_page,"","","","","","","","",keyWord,addList);
|
// _getDangerRecord(2,_page,"","","","","","","","",keyWord,addList);
|
||||||
// pushPage(PendingRectificationDetailPage(widget.dangerType,item), context);
|
// pushPage(PendingRectificationDetailPage(widget.dangerType,item), context);
|
||||||
|
if('hiddenLevel0002'==item['HIDDENLEVEL']){
|
||||||
|
ToastUtil.showNormal(context, "管理人员未确认该隐患");
|
||||||
|
return;
|
||||||
|
}
|
||||||
Navigator.push(
|
Navigator.push(
|
||||||
context,
|
context,
|
||||||
MaterialPageRoute(
|
MaterialPageRoute(
|
||||||
|
|
|
||||||
|
|
@ -262,7 +262,7 @@ class DannerRepairState extends State<DannerRepair> {
|
||||||
// const SizedBox(height: 16),
|
// const SizedBox(height: 16),
|
||||||
if(acceptedPrepare)
|
if(acceptedPrepare)
|
||||||
RepairedPhotoSection(
|
RepairedPhotoSection(
|
||||||
horizontalPadding: 0,
|
horizontalPadding: 15,
|
||||||
title: "方案图片",
|
title: "方案图片",
|
||||||
maxCount: 4,
|
maxCount: 4,
|
||||||
mediaType: MediaType.image,
|
mediaType: MediaType.image,
|
||||||
|
|
|
||||||
|
|
@ -448,7 +448,6 @@ class _HiddenDangerAcceptancePageState extends State<HiddenDangerAcceptancePage>
|
||||||
Column(children: [
|
Column(children: [
|
||||||
Divider(),
|
Divider(),
|
||||||
Container(
|
Container(
|
||||||
height: 130,
|
|
||||||
padding: EdgeInsets.only(top: 15,bottom: 15),
|
padding: EdgeInsets.only(top: 15,bottom: 15),
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
|
|
@ -458,6 +457,7 @@ class _HiddenDangerAcceptancePageState extends State<HiddenDangerAcceptancePage>
|
||||||
TextField(
|
TextField(
|
||||||
controller: miaoShuController,
|
controller: miaoShuController,
|
||||||
keyboardType: TextInputType.multiline,
|
keyboardType: TextInputType.multiline,
|
||||||
|
minLines: 3,
|
||||||
maxLines: null, // 不限制行数,输入多少文字就撑开多少行
|
maxLines: null, // 不限制行数,输入多少文字就撑开多少行
|
||||||
style: TextStyle(fontSize: 15),
|
style: TextStyle(fontSize: 15),
|
||||||
decoration: InputDecoration(
|
decoration: InputDecoration(
|
||||||
|
|
|
||||||
|
|
@ -373,7 +373,7 @@ class _HiddenRecordDetailPageState extends State<HiddenRecordDetailPage> {
|
||||||
|
|
||||||
|
|
||||||
// 验收信息部分
|
// 验收信息部分
|
||||||
if (6==widget.dangerType.index&&checkList.isNotEmpty) ...[
|
if ((6==widget.dangerType.index||1==widget.dangerType.index||0==widget.dangerType.index)&&checkList.isNotEmpty) ...[
|
||||||
// const Divider(height: 10,color: Colors.grey,),
|
// const Divider(height: 10,color: Colors.grey,),
|
||||||
SizedBox(height: 10,),
|
SizedBox(height: 10,),
|
||||||
Row(
|
Row(
|
||||||
|
|
|
||||||
|
|
@ -51,10 +51,10 @@ class _HomeDangerPageState extends State<HomeDangerPage>
|
||||||
listDates.clear();
|
listDates.clear();
|
||||||
setState(() {
|
setState(() {
|
||||||
if(_selectedTab==0){
|
if(_selectedTab==0){
|
||||||
listDates.addAll(listOne);
|
getListData();
|
||||||
showBottomTags=true;
|
showBottomTags=true;
|
||||||
}else{
|
}else{
|
||||||
listDates.addAll(listTwo);
|
getListData();
|
||||||
showBottomTags=false;
|
showBottomTags=false;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -73,8 +73,13 @@ class _HomeDangerPageState extends State<HomeDangerPage>
|
||||||
listOne.clear();
|
listOne.clear();
|
||||||
listTwo.clear();
|
listTwo.clear();
|
||||||
appBarTitle="待排查";
|
appBarTitle="待排查";
|
||||||
|
if(_selectedTab==0){
|
||||||
_getHazardInvestigationList();
|
_getHazardInvestigationList();
|
||||||
|
}else{
|
||||||
_getStandardInvestigationList();
|
_getStandardInvestigationList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// case 3://首页-待排查
|
// case 3://首页-待排查
|
||||||
// appBarTitle="待排查";
|
// appBarTitle="待排查";
|
||||||
// // _getStandardInvestigationRecordList(_page,keyWord,"","","","","","",addList);
|
// // _getStandardInvestigationRecordList(_page,keyWord,"","","","","","",addList);
|
||||||
|
|
@ -127,7 +132,7 @@ class _HomeDangerPageState extends State<HomeDangerPage>
|
||||||
listTwo.add(newList[i]);
|
listTwo.add(newList[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
listDates.addAll(listOne);
|
listDates.addAll(listTwo);
|
||||||
});
|
});
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
|
|
@ -196,19 +201,19 @@ class _HomeDangerPageState extends State<HomeDangerPage>
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
appBar: MyAppbar(
|
appBar: MyAppbar(
|
||||||
title: "隐患排查",
|
title: appBarTitle,
|
||||||
actions: [
|
// actions: [
|
||||||
TextButton(
|
// TextButton(
|
||||||
onPressed: () {
|
// onPressed: () {
|
||||||
// pushPage(ScanPage(), context);
|
// // pushPage(ScanPage(), context);
|
||||||
_goScan();
|
// _goScan();
|
||||||
},
|
// },
|
||||||
child: Text(
|
// child: Text(
|
||||||
"清单扫描",
|
// "清单扫描",
|
||||||
style: TextStyle(color: Colors.white, fontSize: 16),
|
// style: TextStyle(color: Colors.white, fontSize: 16),
|
||||||
),
|
// ),
|
||||||
),
|
// ),
|
||||||
],
|
// ],
|
||||||
),
|
),
|
||||||
body: SafeArea(
|
body: SafeArea(
|
||||||
child: Column(
|
child: Column(
|
||||||
|
|
@ -223,7 +228,7 @@ class _HomeDangerPageState extends State<HomeDangerPage>
|
||||||
),
|
),
|
||||||
labelColor: Colors.blue,
|
labelColor: Colors.blue,
|
||||||
unselectedLabelColor: Colors.grey,
|
unselectedLabelColor: Colors.grey,
|
||||||
tabs: const [Tab(text: '待排查'), Tab(text: '已排查')],
|
tabs: const [Tab(text: '隐患排查'), Tab(text: '标准排查')],
|
||||||
),
|
),
|
||||||
|
|
||||||
Container(
|
Container(
|
||||||
|
|
@ -243,6 +248,13 @@ class _HomeDangerPageState extends State<HomeDangerPage>
|
||||||
// searchKey=text;
|
// searchKey=text;
|
||||||
// getListData();
|
// getListData();
|
||||||
},
|
},
|
||||||
|
onReset: () {
|
||||||
|
setState(() {
|
||||||
|
searchKey="";
|
||||||
|
searchName="";
|
||||||
|
});
|
||||||
|
getListData();
|
||||||
|
},
|
||||||
controller: _searchController,
|
controller: _searchController,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -42,11 +42,6 @@ class _WorkTabListPageState extends State<WorkTabListPage> {
|
||||||
"title": "高处作业",
|
"title": "高处作业",
|
||||||
"unreadCount": eight_work_count['HIGHWORK_COUNT'],
|
"unreadCount": eight_work_count['HIGHWORK_COUNT'],
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon": "assets/icon-apps/icon-806.png",
|
|
||||||
"title": "受限空间\n安全作业",
|
|
||||||
"unreadCount": eight_work_count['CONFINEDSPACE_COUNT'],
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon": "assets/icon-apps/icon-804.png",
|
"icon": "assets/icon-apps/icon-804.png",
|
||||||
"title": "吊装作业",
|
"title": "吊装作业",
|
||||||
|
|
@ -57,16 +52,25 @@ class _WorkTabListPageState extends State<WorkTabListPage> {
|
||||||
"title": "动土作业",
|
"title": "动土作业",
|
||||||
"unreadCount": eight_work_count['BREAKGROUND_COUNT'],
|
"unreadCount": eight_work_count['BREAKGROUND_COUNT'],
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon": "assets/icon-apps/icon-805.png",
|
|
||||||
"title": "临时用电作业",
|
|
||||||
"unreadCount": eight_work_count['ELECTRICITY_COUNT'],
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon": "assets/icon-apps/open-circuit.png",
|
"icon": "assets/icon-apps/open-circuit.png",
|
||||||
"title": "断路作业",
|
"title": "断路作业",
|
||||||
"unreadCount": eight_work_count['OPEN_CIRCUIT_COUNT'],
|
"unreadCount": eight_work_count['OPEN_CIRCUIT_COUNT'],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"icon": "assets/icon-apps/icon-805.png",
|
||||||
|
"title": "临时用电作业",
|
||||||
|
"unreadCount": eight_work_count['ELECTRICITY_COUNT'],
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
"icon": "assets/icon-apps/icon-806.png",
|
||||||
|
"title": "受限空间\n安全作业",
|
||||||
|
"unreadCount": eight_work_count['CONFINEDSPACE_COUNT'],
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
{
|
{
|
||||||
"icon": "assets/icon-apps/icon-801.png",
|
"icon": "assets/icon-apps/icon-801.png",
|
||||||
"title": "盲板抽堵作业",
|
"title": "盲板抽堵作业",
|
||||||
|
|
@ -79,11 +83,11 @@ class _WorkTabListPageState extends State<WorkTabListPage> {
|
||||||
switch (index) {
|
switch (index) {
|
||||||
case 0:await pushPage(WorkTabDhList(), context); break;
|
case 0:await pushPage(WorkTabDhList(), context); break;
|
||||||
case 1:await pushPage(WorkTabGcList(), context); break;
|
case 1:await pushPage(WorkTabGcList(), context); break;
|
||||||
case 2:await pushPage(WorkTabSxkjList(), context); break;
|
case 2:await pushPage(WorkTabDzList(), context); break;
|
||||||
case 3:await pushPage(WorkTabDzList(), context); break;
|
case 3:await pushPage(WorkTabDtList(), context); break;
|
||||||
case 4:await pushPage(WorkTabDtList(), context); break;
|
case 4:await pushPage(WorkTabDlList(), context); break;
|
||||||
case 5:await pushPage(WorkTabLsydList(), context); break;
|
case 5:await pushPage(WorkTabLsydList(), context); break;
|
||||||
case 6:await pushPage(WorkTabDlList(), context); break;
|
case 6:await pushPage(WorkTabSxkjList(), context); break;
|
||||||
case 7:await pushPage(WorkTabMbcdList(), context); break;
|
case 7:await pushPage(WorkTabMbcdList(), context); break;
|
||||||
}
|
}
|
||||||
_getData();
|
_getData();
|
||||||
|
|
|
||||||
|
|
@ -126,7 +126,11 @@ class _DangerPageState extends State<DangerPage>
|
||||||
listTwo.add(newList[i]);
|
listTwo.add(newList[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(_selectedTab==0) {
|
||||||
listDates.addAll(listOne);
|
listDates.addAll(listOne);
|
||||||
|
}else{
|
||||||
|
listDates.addAll(listTwo);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
|
|
@ -154,7 +158,11 @@ class _DangerPageState extends State<DangerPage>
|
||||||
listTwo.add(newList[i]);
|
listTwo.add(newList[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(_selectedTab==0) {
|
||||||
listDates.addAll(listOne);
|
listDates.addAll(listOne);
|
||||||
|
}else{
|
||||||
|
listDates.addAll(listTwo);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
|
|
@ -270,6 +278,13 @@ class _DangerPageState extends State<DangerPage>
|
||||||
// searchKey=text;
|
// searchKey=text;
|
||||||
// getListData();
|
// getListData();
|
||||||
},
|
},
|
||||||
|
onReset: () {
|
||||||
|
setState(() {
|
||||||
|
searchKey="";
|
||||||
|
searchName="";
|
||||||
|
});
|
||||||
|
getListData();
|
||||||
|
},
|
||||||
controller: _searchController,
|
controller: _searchController,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -93,6 +93,7 @@ class _DangerProjectPageState extends State<DangerProjectPage> {
|
||||||
for (int m = 0; m < newListTwo.length; m++) {
|
for (int m = 0; m < newListTwo.length; m++) {
|
||||||
if (newListTwo.isNotEmpty && newListTwo[m]["LISTCHECKITEM_ID"] != null) {
|
if (newListTwo.isNotEmpty && newListTwo[m]["LISTCHECKITEM_ID"] != null) {
|
||||||
if (newListTwo[m]["LISTCHECKITEM_ID"] == listDates[i]["LISTCHECKITEM_ID"]) {
|
if (newListTwo[m]["LISTCHECKITEM_ID"] == listDates[i]["LISTCHECKITEM_ID"]) {
|
||||||
|
listDates[i]["RECORDITEM_ID"]=newListTwo[m]["RECORDITEM_ID"];
|
||||||
if (listDatesSelect.isNotEmpty) {
|
if (listDatesSelect.isNotEmpty) {
|
||||||
switch (listDatesSelect[m]["ISNORMAL"]) {
|
switch (listDatesSelect[m]["ISNORMAL"]) {
|
||||||
case 0:
|
case 0:
|
||||||
|
|
@ -153,6 +154,7 @@ class _DangerProjectPageState extends State<DangerProjectPage> {
|
||||||
for (int m = 0; m < newListTwo.length; m++) {
|
for (int m = 0; m < newListTwo.length; m++) {
|
||||||
if (newListTwo.isNotEmpty && newListTwo[m]["CUSTOM_ITEM_ID"] != null) {
|
if (newListTwo.isNotEmpty && newListTwo[m]["CUSTOM_ITEM_ID"] != null) {
|
||||||
if (newListTwo[m]["CUSTOM_ITEM_ID"] == listDates[i]["CUSTOM_ITEM_ID"]) {
|
if (newListTwo[m]["CUSTOM_ITEM_ID"] == listDates[i]["CUSTOM_ITEM_ID"]) {
|
||||||
|
listDates[i]["RECORDITEM_ID"]=newListTwo[m]["RECORDITEM_ID"];
|
||||||
if (listDatesSelect.isNotEmpty) {
|
if (listDatesSelect.isNotEmpty) {
|
||||||
switch (listDatesSelect[m]["ISNORMAL"]) {
|
switch (listDatesSelect[m]["ISNORMAL"]) {
|
||||||
case 0:
|
case 0:
|
||||||
|
|
|
||||||
|
|
@ -147,7 +147,9 @@ class DangerWaitDrawerState extends State<DangerWaitDrawer> {
|
||||||
_dangerStatusOption= dangerWaitBean["dangerStatusOption"];
|
_dangerStatusOption= dangerWaitBean["dangerStatusOption"];
|
||||||
|
|
||||||
startTime= dangerWaitBean["startTime"];
|
startTime= dangerWaitBean["startTime"];
|
||||||
|
_startDate = DateTime.parse(startTime);
|
||||||
endTime= dangerWaitBean["endTime"];
|
endTime= dangerWaitBean["endTime"];
|
||||||
|
_endDate = DateTime.parse(endTime);
|
||||||
itemNameOne= dangerWaitBean["itemNameOne"];
|
itemNameOne= dangerWaitBean["itemNameOne"];
|
||||||
itemNameTwo= dangerWaitBean["itemNameTwo"];
|
itemNameTwo= dangerWaitBean["itemNameTwo"];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -224,11 +224,12 @@ class _riskListPageState extends State<RiskListPage> {
|
||||||
children: [
|
children: [
|
||||||
Image.asset(item["checkmap"].toString().isEmpty?"assets/images/zt-ing.png":"assets/images/zt-over.png", width: 50, height: 50,),
|
Image.asset(item["checkmap"].toString().isEmpty?"assets/images/zt-ing.png":"assets/images/zt-over.png", width: 50, height: 50,),
|
||||||
const SizedBox(width: 10), // 添加间距
|
const SizedBox(width: 10), // 添加间距
|
||||||
Column(
|
|
||||||
children: [
|
|
||||||
Expanded( // 修复3: 文本过长时自动换行
|
Expanded( // 修复3: 文本过长时自动换行
|
||||||
child:
|
child: Column(
|
||||||
Center(child:
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
|
||||||
Text(
|
Text(
|
||||||
_getTitle(item),
|
_getTitle(item),
|
||||||
// item.title,
|
// item.title,
|
||||||
|
|
@ -236,10 +237,9 @@ class _riskListPageState extends State<RiskListPage> {
|
||||||
maxLines: 2, // 限制两行
|
maxLines: 2, // 限制两行
|
||||||
overflow: TextOverflow.ellipsis,
|
overflow: TextOverflow.ellipsis,
|
||||||
),
|
),
|
||||||
),
|
|
||||||
|
|
||||||
),
|
|
||||||
],
|
],
|
||||||
|
),
|
||||||
)
|
)
|
||||||
|
|
||||||
],
|
],
|
||||||
|
|
@ -253,7 +253,7 @@ class _riskListPageState extends State<RiskListPage> {
|
||||||
if(widget.type==1 ){
|
if(widget.type==1 ){
|
||||||
return "${item["DEPT_NAME"]}--${item["RISKUNITNAME"]}--${item["PARTSNAME"]}${_dianZiString(item)}";
|
return "${item["DEPT_NAME"]}--${item["RISKUNITNAME"]}--${item["PARTSNAME"]}${_dianZiString(item)}";
|
||||||
}else{
|
}else{
|
||||||
return item["DICTIONARY_NAMES"];
|
return item["DICTIONARY_NAMES"].replaceAll(",", "--");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue