Merge branch 'match_position' into 'master'
Add match position to matches See merge request turniere/turniere-frontend!32
This commit is contained in:
commit
c032228519
|
|
@ -119,9 +119,12 @@ export class Match extends React.Component {
|
|||
}
|
||||
return (<div className='mb-3'>
|
||||
<Card className={'shadow-sm match '} onClick={this.toggleModal}>
|
||||
<CardBody className={borderClass + ' border py-2 ' + cardClass + ' ' + styles.match_bg}>
|
||||
<MatchTable match={this.state.match} borderColor={borderClass}/>
|
||||
</CardBody>
|
||||
<div className="d-flex flex-row">
|
||||
<CardBody className={borderClass + ' border py-2 ' + cardClass + ' ' + styles.match_bg}>
|
||||
<MatchTable match={this.state.match} borderColor={borderClass}/>
|
||||
</CardBody>
|
||||
<span className="badge bg-secondary align-items-center">{this.state.match.position}</span>
|
||||
</div>
|
||||
</Card>
|
||||
<small className='text-muted'>{smallMessage}</small>
|
||||
<MatchModal title='Match' isOpen={this.state.modal} toggle={this.toggleModal} match={this.state.match}
|
||||
|
|
|
|||
|
|
@ -88,7 +88,8 @@ function convertGroup(apiGroup) {
|
|||
function convertMatch(apiMatch, allowUndecided) {
|
||||
const result = {
|
||||
id: apiMatch.id, state: apiMatch.state, allowUndecided: allowUndecided,
|
||||
winnerTeamId: apiMatch.winner === null ? null : apiMatch.winner.id
|
||||
winnerTeamId: apiMatch.winner === null ? null : apiMatch.winner.id,
|
||||
position: apiMatch.position + 1
|
||||
};
|
||||
|
||||
if (apiMatch.match_scores.length === 2) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue