Coefficients transit and display on UI
This commit is contained in:
parent
974d474097
commit
a25e2edfd7
7 changed files with 64 additions and 20 deletions
|
@ -379,7 +379,7 @@ angular.module("FICApp")
|
|||
$scope.my.$promise.then(function(res){
|
||||
$scope.solved_exercices = 0;
|
||||
angular.forEach(res.exercices, function(exercice, eid) {
|
||||
if (exercice.solved) {
|
||||
if (exercice.solved_rank) {
|
||||
$scope.solved_exercices += 1;
|
||||
}
|
||||
}, 0);
|
||||
|
|
|
@ -4,8 +4,9 @@
|
|||
<div class="form-group" ng-repeat="field in fields">
|
||||
<label for="{{ field }}" class="col-xs-1 control-label">{{ field | capitalize }}</label>
|
||||
<div class="col-xs-11">
|
||||
<input type="text" class="form-control" id="{{ field }}" ng-model="exercice[field]" ng-show="field != 'statement' && field != 'depend' && field != 'gain'">
|
||||
<input type="text" class="form-control" id="{{ field }}" ng-model="exercice[field]" ng-show="field != 'statement' && field != 'depend' && field != 'gain' && field != 'coefficient'">
|
||||
<input type="text" class="form-control" id="{{ field }}" ng-model="exercice[field]" ng-show="field == 'gain'" integer>
|
||||
<input type="text" class="form-control" id="{{ field }}" ng-model="exercice[field]" ng-show="field == 'coefficient'" float>
|
||||
<textarea class="form-control" id="{{field}}" ng-model="exercice[field]" ng-show="field == 'statement'"></textarea>
|
||||
<select class="form-control" id="{{field}}" ng-model="exercice[field]" ng-options="ex.id as ex.title for ex in exercices" ng-show="field == 'depend'">
|
||||
<option value="">Aucune</option>
|
||||
|
|
Reference in a new issue