Added missing dao functions
This commit is contained in:
@@ -306,10 +306,7 @@ class _MatchResultViewState extends State<MatchResultView> {
|
||||
Future<bool> _handleWinner() async {
|
||||
if (isTeamMatch) {
|
||||
if (_selectedTeam == null) {
|
||||
return await db.teamDao.removeWinnerTeam(
|
||||
matchId: widget.match.id,
|
||||
teamId: _selectedTeam!.id,
|
||||
);
|
||||
return await db.teamDao.removeWinnerTeam(matchId: widget.match.id);
|
||||
} else {
|
||||
return await db.teamDao.setWinnerTeam(
|
||||
matchId: widget.match.id,
|
||||
@@ -332,7 +329,7 @@ class _MatchResultViewState extends State<MatchResultView> {
|
||||
Future<bool> _handleWinners() async {
|
||||
if (isTeamMatch) {
|
||||
if (_selectedTeams.isEmpty) {
|
||||
return await db.scoreEntryDao.removeWinner(matchId: widget.match.id);
|
||||
return await db.teamDao.removeWinnerTeam(matchId: widget.match.id);
|
||||
} else {
|
||||
return await db.teamDao.setWinnerTeams(
|
||||
matchId: widget.match.id,
|
||||
|
||||
@@ -235,7 +235,7 @@ class _MatchTileState extends State<MatchTile> {
|
||||
LayoutBuilder(
|
||||
builder: (context, constraints) {
|
||||
final useSingleColumn = match.teams!.any(
|
||||
(team) => team.name.length > 14,
|
||||
(team) => team.name.length > 10,
|
||||
);
|
||||
|
||||
const spacing = 8.0;
|
||||
|
||||
Reference in New Issue
Block a user