Songkick is now optional

This commit is contained in:
gotson
2014-03-28 18:06:32 +08:00
parent 44acaf7599
commit 96bc2b835c
4 changed files with 43 additions and 11 deletions
+33 -8
View File
@@ -970,17 +970,22 @@
<fieldset>
<legend>Songkick</legend>
<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>
<input type="checkbox" name="songkick_enabled" id="songkick" value="1" ${config['songkick_enabled']} /><label>Display concerts by Songkick</label>
</div>
<div id="songkick_filteroptions">
<div id="songkickoptions">
<div class="row">
<label>Location:</label>
<input type="text" name="songkick_location" value="${config['songkick_location']}" size="50">
<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>
@@ -1337,6 +1342,26 @@
}
});
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();