Skip to content

Commit

Permalink
Add sg main files and use them in the app
Browse files Browse the repository at this point in the history
  • Loading branch information
LFDM committed Jun 6, 2014
1 parent 490d144 commit 3339057
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 4 deletions.
5 changes: 3 additions & 2 deletions app/js/arethusa.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ angular.module('arethusa', [
'arethusa.review',
'arethusa.search',
'arethusa.exercise',
'arethusa.relation'
], ['$routeProvider', 'MAIN_ROUTE', 'CONF_ROUTE',
'arethusa.relation',
'arethusa.sg'
], ['$routeProvider', 'MAIN_ROUTE', 'CONF_ROUTE',
function ($routeProvider, MAIN_ROUTE, CONF_ROUTE) {
$routeProvider.when('/', MAIN_ROUTE);
$routeProvider.when('/conf_editor', CONF_ROUTE);
Expand Down
3 changes: 3 additions & 0 deletions app/js/arethusa.sg.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"use strict";

angular.module('arethusa.sg', []);
19 changes: 19 additions & 0 deletions app/js/arethusa.sg/sg.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
"use strict";

angular.module('arethusa.sg').service('sg', [
'state',
'configurator',
function(state, configurator) {
var self = this;

function configure() {
configurator.getConfAndDelegate('sg', self);
}

configure();

this.init = function() {
configure();
};
}
]);
3 changes: 1 addition & 2 deletions app/static/configs/sg.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@

"sg" : {
"name" : "SG",
"template" : "templates/sg.html",
"labels" : "./static/configs/arethusa.sg/sg_labels.json"
"template" : "templates/sg.html"
},

"relation" : {
Expand Down
4 changes: 4 additions & 0 deletions app/templates/sg.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

{{ plugin.name }}

{{ plugin.template }}

0 comments on commit 3339057

Please sign in to comment.