diff --git a/public/js/controllers/NinfoCtrl.js b/public/js/controllers/NinfoCtrl.js index 013b0e1..1a13535 100644 --- a/public/js/controllers/NinfoCtrl.js +++ b/public/js/controllers/NinfoCtrl.js @@ -1,4 +1,4 @@ -angular.module('NinfoCtrl', ['SessionsServ', 'ApiServ', 'NotifyServ']) +angular.module('NinfoCtrl', ['nl2br', 'SessionsServ', 'ApiServ', 'NotifyServ']) .controller('NinfoCtrl', function ($scope, SessionServ, ApiServ, NotifyServ) { $scope.ninfo = {} $scope.saving = false; diff --git a/public/js/filters/nl2brFltr.js b/public/js/filters/nl2brFltr.js new file mode 100644 index 0000000..da4916a --- /dev/null +++ b/public/js/filters/nl2brFltr.js @@ -0,0 +1,7 @@ +angular.module('nl2br', []) + .filter('nl2br', function ($sce) { // From http://stackoverflow.com/questions/15449325/how-can-i-preserve-new-lines-in-an-angular-partial#15449549 + return function(text) { + text = text.replace(/\n/g, '
'); + return $sce.trustAsHtml(text); + } +}); diff --git a/public/views/index.html b/public/views/index.html index d4c9c77..3fdf42e 100644 --- a/public/views/index.html +++ b/public/views/index.html @@ -23,6 +23,7 @@ + diff --git a/public/views/ninfo.html b/public/views/ninfo.html index d4c074a..7459112 100644 --- a/public/views/ninfo.html +++ b/public/views/ninfo.html @@ -61,22 +61,22 @@

Équipe Informatiquement Vôtre {{ equipes.ci.length }}

{{ membre.nom }} ({{ membre.section }})
-
{{ membre.comment }}
+

Équipe 404 Brain Not Found {{ equipes.imagis.length }}

{{ membre.nom }} ({{ membre.section }})
-
{{ membre.comment }}
+

Équipe GIS {{ equipes.gis.length }}

{{ membre.nom }} ({{ membre.section }})
-
{{ membre.comment }}
+

Équipe IMA5 (fermée) {{ equipes.ima5.length }}

{{ membre.nom }} ({{ membre.section }})
-
{{ membre.comment }}
+

-- libgit2 0.21.2