Skip to content

Commit

Permalink
Remove IPK upload if disabled #619
Browse files Browse the repository at this point in the history
  • Loading branch information
jbleyel committed Aug 5, 2017
1 parent 2c98da6 commit 651b189
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions plugin/controllers/views/ajax/settings.tmpl
Expand Up @@ -97,6 +97,7 @@
<br><br>
<button id="upgrade">Upgrade all Packages</button>
<br><br>
<div id="pkgupload">
<button id="selectfile">Select IPK File for Upload</button>
<br><br>
Uploaded Files:<br>
Expand All @@ -106,6 +107,7 @@
<input type="file" name="rfile" id="rfile" maxlength="100000">
<input type="hidden" name="filename" id="filename">
</form>
</div>
<textarea id="resulttext" style='height:300px;width:100%'>
</textarea>
</div>
Expand Down Expand Up @@ -277,6 +279,8 @@ function ShowPackages(mode)
$("#tblpackages").hide();
if (mode == 'pkgbtn4') {
$("#pkgmore").show();
if(noupload)
return;
$('#tmpfiles').empty();
$.ajax({
url: '/ipkg?command=tmp',
Expand Down Expand Up @@ -410,7 +414,14 @@ $(function() {
}
});
*/

});
</script>
#end raw
#if $allowipkupload
var noupload=true;
#else
\$(function() {
\$("#pkgupload").remove();
});
var noupload=false;
#end if
</script>

0 comments on commit 651b189

Please sign in to comment.