OpenProject is the leading open source project management software.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
openproject/app/assets/javascripts/angular/helpers/components/path-helper.js

27 lines
744 B

// TODO forward rails routes
angular.module('openproject.uiComponents')
.service('PathHelper', [function() {
PathHelper = {
projectPath: function(projectIdentifier) {
return '/projects/' + projectIdentifier;
},
workPackagesPath: function() {
return '/work_packages';
},
workPackagePath: function(id) {
return '/work_packages/' + id;
},
projectWorkPackagesPath: function(projectIdentifier) {
return PathHelper.projectPath(projectIdentifier) + PathHelper.workPackagesPath();
},
userPath: function(id) {
return '/users/' + id;
},
workPackagesColumnDataPath: function() {
return PathHelper.workPackagesPath() + '/column_data';
}
};
return PathHelper;
}]);