Fixed merge conflicts from gotson songkick pull request

This commit is contained in:
rembo10
2014-03-28 10:35:02 -07:00
4 changed files with 94 additions and 9 deletions

View File

@@ -178,7 +178,14 @@
$.getJSON("http://api.songkick.com/api/3.0/artists/mbid:${artist['ArtistID']}/calendar.json?apikey=${headphones.SONGKICK_APIKEY}&jsoncallback=?",
function(data){
if (data['resultsPage'].totalEntries >= 1) {
if (data['resultsPage'].totalEntries >= 1) {
if( ${headphones.SONGKICK_FILTER_ENABLED} ) {
data.resultsPage.results.event = $.grep(data.resultsPage.results.event, function(element,index){
return element.venue.metroArea.id == ${headphones.SONGKICK_LOCATION};
});
}
var tourDate;
calendarDomNode.show();
@@ -262,7 +269,9 @@
initActions();
initThisPage();
getArtistBio();
getArtistsCalendar();
if( ${headphones.SONGKICK_ENABLED} ){
getArtistsCalendar();
}
});
</script>

View File

@@ -965,9 +965,23 @@
<fieldset>
<legend>Songkick</legend>
<div class="row">
<label>API Key:</label>
<input type="text" name="songkick_apikey" value="${config['songkick_apikey']}" size="50">
<div class="row checkbox">
<input type="checkbox" name="songkick_enabled" id="songkick" value="1" ${config['songkick_enabled']} /><label>Display concerts by Songkick</label>
</div>
<div id="songkickoptions">
<div class="row">
<label>API Key:</label>
<input type="text" name="songkick_apikey" value="${config['songkick_apikey']}" size="50">
</div>
<div class="row checkbox">
<input type="checkbox" name="songkick_filter_enabled" id="songkick_filter" value="1" ${config['songkick_filter_enabled']} /><label>Enable Songkick filter per area</label>
</div>
<div id="songkick_filteroptions">
<div class="row">
<label>Location:</label>
<input type="text" name="songkick_location" value="${config['songkick_location']}" size="50">
</div>
</div>
</div>
</fieldset>
@@ -1322,6 +1336,46 @@
$("#twitteroptions").slideUp();
}
});
if ($("#songkick").is(":checked"))
{
$("#songkickoptions").show();
}
else
{
$("#songkickoptions").hide();
}
$("#songkick").click(function(){
if ($("#songkick").is(":checked"))
{
$("#songkickoptions").slideDown();
}
else
{
$("#songkickoptions").slideUp();
}
});
if ($("#songkick_filter").is(":checked"))
{
$("#songkick_filteroptions").show();
}
else
{
$("#songkick_filteroptions").hide();
}
$("#songkick_filter").click(function(){
if ($("#songkick_filter").is(":checked"))
{
$("#songkick_filteroptions").slideDown();
}
else
{
$("#songkick_filteroptions").slideUp();
}
});
if ($("#preferred_bitrate").is(":checked"))
{