mirror of
https://github.com/apache/struts.git
synced 2026-08-06 15:17:00 +00:00
WW-4399 struts2-archetype-angularjs uses absolute paths
This commit is contained in:
+2
-2
@@ -24,10 +24,10 @@ var angularStrutsApp = angular.module('angularStrutsApp', ['ngRoute']);
|
||||
angularStrutsApp.config(['$routeProvider',
|
||||
function($routeProvider) {
|
||||
$routeProvider.when('/projects', {
|
||||
templateUrl: '/partials/projects.html',
|
||||
templateUrl: 'partials/projects.html',
|
||||
controller: 'ApacheProjectsController'
|
||||
}).when('/home', {
|
||||
templateUrl: '/partials/home.html',
|
||||
templateUrl: 'partials/home.html',
|
||||
controller: 'HomeController'
|
||||
}).otherwise({ redirectTo: '/home' });
|
||||
}
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@ angularStrutsApp.controller('HomeController', function ($scope) {
|
||||
|
||||
angularStrutsApp.controller('ApacheProjectsController', function ($scope, $http) {
|
||||
this.init = function() {
|
||||
$http({method: 'GET', url: '/projects'}).
|
||||
$http({method: 'GET', url: 'projects'}).
|
||||
success(function(data) {
|
||||
$scope.projects = data.projectNames;
|
||||
}).
|
||||
|
||||
Reference in New Issue
Block a user