issue #269 fixed

parent 5474d8ff
...@@ -514,7 +514,7 @@ dashboardControllers.controller('StudentCollectionsCtrl', function StudentCollec ...@@ -514,7 +514,7 @@ dashboardControllers.controller('StudentCollectionsCtrl', function StudentCollec
// //
// Adds a new pictogram // Adds a new pictogram
// //
$scope.open_add = function (col, row) { $scope.open_add = function (col, row, mainCatGrid) {
var modalInstance = $modal.open({ var modalInstance = $modal.open({
animation: true, animation: true,
templateUrl: 'modules/student/views/addpicto.html', templateUrl: 'modules/student/views/addpicto.html',
...@@ -542,7 +542,7 @@ dashboardControllers.controller('StudentCollectionsCtrl', function StudentCollec ...@@ -542,7 +542,7 @@ dashboardControllers.controller('StudentCollectionsCtrl', function StudentCollec
// Send the picto to the server // Send the picto to the server
$http.post(config.backend + '/stu/' + $scope.studentData.id + '/picto/' + pictoId, { $http.post(config.backend + '/stu/' + $scope.studentData.id + '/picto/' + pictoId, {
attributes: { attributes: {
id_cat: $scope.showFreeCategory ? null : $scope.getCategoryId($scope.selectedCategory), id_cat: ($scope.showFreeCategory || mainCatGrid) ? null : $scope.getCategoryId($scope.selectedCategory),
coord_x: $scope.showFreeCategory ? null : col, coord_x: $scope.showFreeCategory ? null : col,
coord_y: $scope.showFreeCategory ? null : row, coord_y: $scope.showFreeCategory ? null : row,
status: 'enabled', status: 'enabled',
......
...@@ -67,7 +67,7 @@ ...@@ -67,7 +67,7 @@
class="picto_options" class="picto_options"
ng-if="studentPicto == emptyStudentPicto"> ng-if="studentPicto == emptyStudentPicto">
<a <a
ng-click="open_add(rowIndex, colIndex)" ng-click="open_add(rowIndex, colIndex, true)"
class="picto_add" class="picto_add"
title="{{ 'add_picto' | translate}}"> title="{{ 'add_picto' | translate}}">
<i class="color_green glyphicon glyphicon-plus-sign" aria-hidden="true"></i> <i class="color_green glyphicon glyphicon-plus-sign" aria-hidden="true"></i>
...@@ -154,7 +154,7 @@ ...@@ -154,7 +154,7 @@
class="picto_options" class="picto_options"
ng-if="studentPicto == emptyStudentPicto"> ng-if="studentPicto == emptyStudentPicto">
<a <a
ng-click="open_add(rowIndex, colIndex)" ng-click="open_add(rowIndex, colIndex, true)"
class="picto_add" class="picto_add"
title="{{ 'add_picto' | translate}}"> title="{{ 'add_picto' | translate}}">
<i class="color_green glyphicon glyphicon-plus-sign" aria-hidden="true"></i> <i class="color_green glyphicon glyphicon-plus-sign" aria-hidden="true"></i>
...@@ -275,7 +275,7 @@ ...@@ -275,7 +275,7 @@
class="picto_options" class="picto_options"
ng-if="studentPicto == emptyStudentPicto"> ng-if="studentPicto == emptyStudentPicto">
<a <a
ng-click="open_add(rowIndex, colIndex)" ng-click="open_add(rowIndex, colIndex, false)"
class="picto_add" class="picto_add"
title="{{ 'add_picto' | translate}}"> title="{{ 'add_picto' | translate}}">
<i class="color_green glyphicon glyphicon-plus-sign" aria-hidden="true"></i> <i class="color_green glyphicon glyphicon-plus-sign" aria-hidden="true"></i>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment