Add special characters to Sosso infoscreen

This commit is contained in:
Aarni Halinen
2018-09-10 11:40:57 +03:00
parent 02cc305abf
commit b3b1bec12c
2 changed files with 11 additions and 3 deletions
+4 -3
View File
@@ -1,7 +1,8 @@
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/css/bootstrap.min.css" integrity="sha384-rwoIResjU2yc3z8GV/NPeZWAv56rSmLldC3R/AZzGRnGxQQKnKkoFVhFQhNUwEyJ" crossorigin="anonymous">
<link rel="stylesheet" href="/static/infoscreen/css/sosso.css">
<div ng-controller="SossoController">
<div id="header">
<img id="header-image" src="/static/img/sossoheader.png" >
<img id="header-image" src="/static/infoscreen/img/sossoheader.png" >
</div>
<div id="container">
<div class="article-row row" ng-repeat="post in data.posts">
@@ -10,8 +11,8 @@
</div>
<div>
<h1 class="col-md-6">
<div class="article-title-col">
{{ post.title }}
<div class="article-title-col"
ng-bind-html="post.title | unsafe">
</div>
</h1>
</div>
@@ -46,6 +46,13 @@ app.filter('trusted_url', ['$sce', function ($sce) {
};
}]);
//Used for special characters in Sosso. This may open up XSS, so we need to trust that sosso.fi doesn't get compromised...
app.filter('unsafe', function($sce) {
return function(val) {
return $sce.trustAsHtml(val);
};
});
app.controller('ABBController', function($scope, $http){
$scope.jobs = [];
var min_date = moment().subtract(30,'days').format("YYYY-MM-DD%20HH:mm:ss");