Call calculate_group_points on Match_score Update
This commit is contained in:
parent
08eabcd0f9
commit
f51936f8e7
|
|
@ -13,6 +13,7 @@ class MatchScoresController < ApplicationController
|
||||||
# PATCH/PUT /scores/1
|
# PATCH/PUT /scores/1
|
||||||
def update
|
def update
|
||||||
if @match_score.update(match_score_params)
|
if @match_score.update(match_score_params)
|
||||||
|
GroupStageService.calculate_group_points(@match_score)
|
||||||
render json: @match_score
|
render json: @match_score
|
||||||
else
|
else
|
||||||
render json: @match_score.errors, status: :unprocessable_entity
|
render json: @match_score.errors, status: :unprocessable_entity
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue