Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
17799af2e7 | ||
|
|
7d65be0514 |
@@ -134,6 +134,7 @@ class EventRegistrationItem {
|
|||||||
required this.itemName,
|
required this.itemName,
|
||||||
required this.groupName,
|
required this.groupName,
|
||||||
required this.matchPlace,
|
required this.matchPlace,
|
||||||
|
|
||||||
this.matchStartTime = '',
|
this.matchStartTime = '',
|
||||||
this.matchEndTime = '',
|
this.matchEndTime = '',
|
||||||
this.completed = false,
|
this.completed = false,
|
||||||
@@ -143,6 +144,7 @@ class EventRegistrationItem {
|
|||||||
this.userId = '',
|
this.userId = '',
|
||||||
this.playerName = '',
|
this.playerName = '',
|
||||||
this.playerPhone = '',
|
this.playerPhone = '',
|
||||||
|
this.playerNo = '',
|
||||||
});
|
});
|
||||||
|
|
||||||
final String eventId;
|
final String eventId;
|
||||||
@@ -158,6 +160,7 @@ class EventRegistrationItem {
|
|||||||
final String opponentId;
|
final String opponentId;
|
||||||
final String opponentName;
|
final String opponentName;
|
||||||
final List<EventTeamMember> teamMembers;
|
final List<EventTeamMember> teamMembers;
|
||||||
|
final String playerNo;
|
||||||
|
|
||||||
/// 来自报名列表父级,不在 item JSON 内
|
/// 来自报名列表父级,不在 item JSON 内
|
||||||
final String userId;
|
final String userId;
|
||||||
@@ -205,6 +208,7 @@ class EventRegistrationItem {
|
|||||||
: const [],
|
: const [],
|
||||||
userId: userId,
|
userId: userId,
|
||||||
playerName: playerName,
|
playerName: playerName,
|
||||||
|
playerNo: _readString(map, const ['playerNo']),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -526,9 +526,10 @@ String _formatOpponentLine(EventRegistrationItem item) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
String _formatNumberBadge(EventRegistrationItem item) {
|
String _formatNumberBadge(EventRegistrationItem item) {
|
||||||
final place = item.matchPlace.trim();
|
return item.playerNo.trim().isEmpty ? '' : '${item.playerNo.trim()}号';
|
||||||
if (place.isEmpty) return '';
|
// final place = item.matchPlace.trim();
|
||||||
final match = RegExp(r'\d+').firstMatch(place);
|
// if (place.isEmpty) return '';
|
||||||
if (match != null) return '${match.group(0)}号';
|
// final match = RegExp(r'\d+').firstMatch(place);
|
||||||
return place;
|
// if (match != null) return '${match.group(0)}号';
|
||||||
|
// return place;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user