Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions acute/acute.select/acute.select.js
Original file line number Diff line number Diff line change
Expand Up @@ -1040,8 +1040,12 @@ angular.module("acute.select", [])
// Service to allow host pages to change settings for all instances (in their module.run function)
.factory('acuteSelectService', function() {

// Get directory of script
var fileName = "acute.select.js";
var directory = document.querySelector('script[src$="' + fileName + '"]').getAttribute('src').replace(fileName,"");

var defaultSettings = {
"templatePath": "/acute.select/template",
"templatePath": directory + "template",
"noItemsText": "No items found.",
"placeholderText": "Please select...",
"itemHeight": 24,
Expand Down Expand Up @@ -1089,4 +1093,4 @@ angular.module("acute.select", [])
defaultSettings[settingName] = value;
}
}
});
});