Change templateUrl to absolute path

Having templateUrl be a relative path causes problems if the
dashboard is deployed underneath a different root.

Change-Id: Iba12be83224df9b2d9fe568cc3830096fdfd82d5
This commit is contained in:
Tzu-Mainn Chen 2014-04-03 04:35:11 +02:00
parent d412e4dabe
commit 7dadd34997

View File

@ -1,9 +1,9 @@
angular.module('hz').directive('hrNumberPicker', function() {
angular.module('hz').directive('hrNumberPicker', ['hzConfig', function(hzConfig) {
return {
restrict: 'A',
replace: true,
scope: { initial_value: '=value' },
templateUrl: '../../static/infrastructure/angular_templates/numberpicker.html',
templateUrl: hzConfig.static_url + 'infrastructure/angular_templates/numberpicker.html',
link: function(scope, element, attrs) {
input = element.find('input').first();
angular.forEach(element[0].attributes, function(attribute) {
@ -33,4 +33,4 @@ angular.module('hz').directive('hrNumberPicker', function() {
};
}
};
});
}]);