CC-2184: Hardcoded CSS path should be relative path instead

This commit is contained in:
denise 2012-10-19 11:09:34 -04:00
parent 7165d1fa2e
commit d32495d100
47 changed files with 366 additions and 340 deletions

View file

@ -13,8 +13,8 @@ function setWatchedDirEvents() {
//knownPaths: [{text:'Desktop', image:'desktop.png', path:'/home'}],
knownPaths: [],
imageUrl: 'img/icons/',
systemImageUrl: '/css/img/',
handlerUrl: '/Preference/server-browse/format/json',
systemImageUrl: baseUrl+'/css/img/',
handlerUrl: baseUrl+'/Preference/server-browse/format/json',
title: 'Choose Storage Folder',
basePath: '',
requestMethod: 'POST',
@ -33,8 +33,8 @@ function setWatchedDirEvents() {
//knownPaths: [{text:'Desktop', image:'desktop.png', path:'/home'}],
knownPaths: [],
imageUrl: 'img/icons/',
systemImageUrl: '/css/img/',
handlerUrl: '/Preference/server-browse/format/json',
systemImageUrl: baseUrl+'/css/img/',
handlerUrl: baseUrl+'/Preference/server-browse/format/json',
title: 'Choose Folder to Watch',
basePath: '',
requestMethod: 'POST',
@ -44,7 +44,7 @@ function setWatchedDirEvents() {
var url, chosen;
if(confirm("Are you sure you want to change the storage folder?\nThis will remove the files from your Airtime library!")){
url = "/Preference/change-stor-directory";
url = baseUrl+"/Preference/change-stor-directory";
chosen = $('#storageFolder').val();
$.post(url,
@ -64,7 +64,7 @@ function setWatchedDirEvents() {
$('#watchedFolder-ok').click(function(){
var url, chosen;
url = "/Preference/reload-watch-directory";
url = baseUrl+"/Preference/reload-watch-directory";
chosen = $('#watchedFolder').val();
$.post(url,
@ -80,7 +80,7 @@ function setWatchedDirEvents() {
$('.selected-item').find('.ui-icon-refresh').click(function(){
var folder = $(this).prev().text();
$.get("/Preference/rescan-watch-directory", {format: "json", dir: folder});
$.get(baseUrl+"/Preference/rescan-watch-directory", {format: "json", dir: folder});
});
$('.selected-item').find('.ui-icon-close').click(function(){
@ -88,7 +88,7 @@ function setWatchedDirEvents() {
var row = $(this).parent();
var folder = row.find('#folderPath').text();
url = "/Preference/remove-watch-directory";
url = baseUrl+"/Preference/remove-watch-directory";
$.post(url,
{format: "json", dir: folder},

View file

@ -75,7 +75,7 @@ function showForIcecast(ele){
}
function checkLiquidsoapStatus(){
var url = '/Preference/get-liquidsoap-status/format/json';
var url = baseUrl+'/Preference/get-liquidsoap-status/format/json';
var id = $(this).attr("id");
$.post(url, function(json){
var json_obj = jQuery.parseJSON(json);
@ -127,7 +127,7 @@ function setLiveSourceConnectionOverrideListener(){
live_dj_input.val(url)
live_dj_input.attr("readonly", "readonly")
live_dj_actions.hide()
$.get("/Preference/set-source-connection-url/", {format: "json", type: "livedj", url:encodeURIComponent(url), override: 1});
$.get(baseUrl+"/Preference/set-source-connection-url/", {format: "json", type: "livedj", url:encodeURIComponent(url), override: 1});
event.preventDefault()
})
@ -142,7 +142,7 @@ function setLiveSourceConnectionOverrideListener(){
live_dj_input.val(url)
live_dj_input.attr("readonly", "readonly")
live_dj_actions.hide()
$.get("/Preference/set-source-connection-url", {format: "json", type: "livedj", url:encodeURIComponent(url), override: 0});
$.get(baseUrl+"/Preference/set-source-connection-url", {format: "json", type: "livedj", url:encodeURIComponent(url), override: 0});
event.preventDefault()
})
@ -151,7 +151,7 @@ function setLiveSourceConnectionOverrideListener(){
master_dj_input.val(url)
master_dj_input.attr("readonly", "readonly")
master_dj_actions.hide()
$.get("/Preference/set-source-connection-url", {format: "json", type: "masterdj", url:encodeURIComponent(url), override: 1})
$.get(baseUrl+"/Preference/set-source-connection-url", {format: "json", type: "masterdj", url:encodeURIComponent(url), override: 1})
event.preventDefault()
})
@ -165,7 +165,7 @@ function setLiveSourceConnectionOverrideListener(){
master_dj_input.val(url)
master_dj_input.attr("readonly", "readonly")
master_dj_actions.hide()
$.get("/Preference/set-source-connection-url", {format: "json", type: "masterdj", url:encodeURIComponent(url), override: 0})
$.get(baseUrl+"/Preference/set-source-connection-url", {format: "json", type: "masterdj", url:encodeURIComponent(url), override: 0})
event.preventDefault()
})
}