2026.6.25 口门门禁bug

master
xufei 2026-06-25 17:53:07 +08:00
parent 6ea2560100
commit ada70a1713
5 changed files with 26 additions and 10 deletions

View File

@ -109,8 +109,18 @@ class _DepartmentPickerEnterpriseState extends State<DepartmentPickerEnterprise>
final result = await DoorAndCarApi.getJurisdictionalAuthorityListTree(widget.jurisdictionalAuthorityId); final result = await DoorAndCarApi.getJurisdictionalAuthorityListTree(widget.jurisdictionalAuthorityId);
raw = result['data']; raw = result['data'];
// jurisdictionalCorpId
List<dynamic> uniqueData = raw.fold([], (List<dynamic> acc, item) {
String corpId = item['jurisdictionalCorpId']?.toString() ?? '';
bool exists = acc.any((element) => element['jurisdictionalCorpId']?.toString() == corpId);
if (!exists && corpId.isNotEmpty) {
acc.add(item);
}
return acc;
});
setState(() { setState(() {
raw =uniqueData;
original = raw.map((e) => CategoryEnterpriseType.fromJson(e as Map<String, dynamic>)).toList(); original = raw.map((e) => CategoryEnterpriseType.fromJson(e as Map<String, dynamic>)).toList();
filtered = original; filtered = original;
loading = false; loading = false;

View File

@ -772,8 +772,8 @@ class _FirstlevelCarAddPageState extends State<FirstlevelCarAddPage> {
return; return;
} }
addData['drivingUserId']=_personList[0].userPhone; addData['drivingUserId']=_personList[0].employeePersonUserId;
addData['drivingUserName']=_personList[0].userCard; addData['drivingUserName']=_personList[0].employeePersonUserName;
addData['lsUserPhone']=_personList[0].userPhone; addData['lsUserPhone']=_personList[0].userPhone;
addData['lsUserIdcard']=_personList[0].userCard; addData['lsUserIdcard']=_personList[0].userCard;

View File

@ -197,7 +197,7 @@ class _OnlylookCarApplicationState extends State<OnlylookCarApplication> {
label: '驾驶人姓名:', label: '驾驶人姓名:',
isEditable: false, isEditable: false,
horizontalnum: 0, horizontalnum: 0,
text: info['employeeVehicleUserName'] ?? '', text: info['drivingUserName'] ?? '',
onTap: () {}, onTap: () {},
), ),
const Divider(), const Divider(),

View File

@ -400,7 +400,7 @@ class _DoorareaPersonRecordPageState extends State<DoorareaPersonRecordPage> {
Expanded( Expanded(
child: SearchBarWidget( child: SearchBarWidget(
showResetButton: true, showResetButton: true,
hintText: '请输入关键字', hintText: '请输入项目名称',
resetButtonText: '重置', resetButtonText: '重置',
onReset: () { onReset: () {
FocusScope.of(context).unfocus(); FocusScope.of(context).unfocus();
@ -453,7 +453,7 @@ class _DoorareaPersonRecordPageState extends State<DoorareaPersonRecordPage> {
// int type = item['auditFlag']??""; // int type = item['auditFlag']??"";
int type =0; int type =0;
if(widget.type==1||widget.type==2||widget.type==3||widget.type==4){ if(widget.type==1||widget.type==2||widget.type==3||widget.type==4||widget.type==7){
type = int.tryParse(item['auditFlag']?.toString() ?? '') ?? 0; type = int.tryParse(item['auditFlag']?.toString() ?? '') ?? 0;
}else{ }else{
type = int.tryParse(item['auditStatus']?.toString() ?? '') ?? 0; type = int.tryParse(item['auditStatus']?.toString() ?? '') ?? 0;
@ -467,7 +467,7 @@ class _DoorareaPersonRecordPageState extends State<DoorareaPersonRecordPage> {
} else if (4 == type) { } else if (4 == type) {
return "无需审批(长期人员)"; return "无需审批(长期人员)";
} else { } else {
return "无需审批"; return "";
} }
} }

View File

@ -261,7 +261,7 @@ class _OnlylookDoorareaPersonState extends State<OnlylookDoorareaPerson> {
} }
Widget _buildPersonCard(Map<String, String> person) { Widget _buildPersonCard(Map<String, dynamic> person) {
return Card( return Card(
margin: EdgeInsets.only(bottom: 12), margin: EdgeInsets.only(bottom: 12),
color: Colors.white, color: Colors.white,
@ -279,7 +279,7 @@ class _OnlylookDoorareaPersonState extends State<OnlylookDoorareaPerson> {
children: [ children: [
Expanded( Expanded(
child: Text( child: Text(
'姓名: ${person['employeePersonUserName']}', '姓名: ${person['employeePersonUserName']??''}',
style: TextStyle( style: TextStyle(
fontSize: 14, fontSize: 14,
color: Colors.grey[700], color: Colors.grey[700],
@ -290,7 +290,7 @@ class _OnlylookDoorareaPersonState extends State<OnlylookDoorareaPerson> {
SizedBox(width: 24), SizedBox(width: 24),
Expanded( Expanded(
child: Text( child: Text(
'部门: ${person['personDepartmentName']}', '部门: ${person['personCorpName']??''}',
style: TextStyle( style: TextStyle(
fontSize: 14, fontSize: 14,
color: Colors.grey[700], color: Colors.grey[700],
@ -362,7 +362,13 @@ class _OnlylookDoorareaPersonState extends State<OnlylookDoorareaPerson> {
setState(() async { setState(() async {
applicationInfo=result['data']; applicationInfo=result['data'];
personnelList=applicationInfo['personApplyList']??[]; // personnelList=applicationInfo['personApplyList']??[];
dynamic entourageData = jsonDecode(applicationInfo['entourage'] ?? '[]');
if (entourageData is List) {
personnelList = entourageData.cast<Map<String, dynamic>>();
} else {
personnelList = [];
}
final imageResults = await Future.wait([ final imageResults = await Future.wait([
FileApi.getImagePath(applicationInfo['informSignId'], UploadFileType.enclosedAreaPersonnelApplicantSignature), FileApi.getImagePath(applicationInfo['informSignId'], UploadFileType.enclosedAreaPersonnelApplicantSignature),