Skip to content

Commit

Permalink
Revert "modification formulaire edition du Taxon - fix : #61"
Browse files Browse the repository at this point in the history
This reverts commit d68c112.
  • Loading branch information
amandine-sahl committed May 12, 2016
1 parent d68c112 commit 6da06bb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
9 changes: 6 additions & 3 deletions web/app/bib_taxon/edit/taxons-form.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,22 @@
<div class="form-group form-group-sm">
<label class="col-sm-2 control-label" for="sm">Nom latin</label>
<div class="col-sm-10">
<input class="form-control" type="text" id="sm" ng-model="ctrl.bibTaxon.nom_latin" placeholder="Nom latin" ng-disabled="true">
<input class="form-control" type="text" id="sm" ng-model="ctrl.bibTaxon.nom_latin" placeholder="Nom latin">
</div>
</div>
<div class="form-group form-group-sm">
<label class="col-sm-2 control-label" for="sm">Auteur</label>
<div class="col-sm-10">
<input class="form-control" type="text" id="sm" ng-model="ctrl.bibTaxon.auteur" placeholder="Auteur" ng-disabled="true">
<input class="form-control" type="text" id="sm" ng-model="ctrl.bibTaxon.auteur" placeholder="Auteur">
</div>
</div>
<div class="form-group form-group-sm">
<label class="col-sm-2 control-label" for="sm">cd_nom</label>
<div class="col-sm-6">
<input class="form-control" type="text" id="sm" ng-model="ctrl.bibTaxon.cd_nom" placeholder="cd_nom (taxref)" required ng-disabled="true">
<input class="form-control" type="text" id="sm" ng-model="ctrl.bibTaxon.cd_nom" placeholder="cd_nom (taxref)" required>
</div>
<div class="col-sm-4">
<button class="btn btn-success glyphicon glyphicon-refresh" ng-click="ctrl.refreshTaxrefData()">Rafraichir</button>
</div>
</div>
<uib-tabset active="activeForm">
Expand Down
5 changes: 5 additions & 0 deletions web/app/bib_taxon/edit/taxonsFormControler.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ function($scope, $routeParams, $http, locationHistoryService, $location, toaster
'saveError':{"title":"Erreur d'enregistrement"},
}


var action = $routeParams.action;
var self = this;
if ($routeParams.id) {
Expand Down Expand Up @@ -48,6 +49,10 @@ function($scope, $routeParams, $http, locationHistoryService, $location, toaster
}
});

self.refreshTaxrefData = function() {
self.cd_nom = self.bibTaxon.cd_nom;
}

//------------------------------ Chargement de la listes des attributs ----------------------/
///bibattributs/Animalia/Autre
$scope.$watch(function () {
Expand Down

0 comments on commit 6da06bb

Please sign in to comment.