1
0
mirror of https://github.com/misterunknown/ifm.git synced 2025-08-09 17:46:31 +02:00

Fix download function when a specific api url is given.

This commit is contained in:
Marco Dickert
2018-03-28 10:16:28 +02:00
parent 70b47fcfcd
commit 9863e4c1ad
4 changed files with 6 additions and 6 deletions

View File

@@ -278,7 +278,7 @@ f00bar;
</td>
{{#config.download}}
<td>
<form id="d_{{guid}}">
<form id="d_{{guid}}" action="{{api}}" method="post">
<input type="hidden" name="dir" value="{{download.currentDir}}">
<input type="hidden" name="filename" value="{{download.name}}">
<input type="hidden" name="api" value="{{download.action}}">
@@ -1631,7 +1631,7 @@ function IFM( params ) {
// build new tbody and replace the old one with the new
var newTBody = Mustache.render( self.templates.filetable, { items: data, config: self.config, i18n: self.i18n } );
var newTBody = Mustache.render( self.templates.filetable, { items: data, config: self.config, i18n: self.i18n, api: self.api } );
var filetable = document.getElementById( 'filetable' );
filetable.tBodies[0].remove();
filetable.append( document.createElement( 'tbody' ) );

View File

@@ -278,7 +278,7 @@ f00bar;
</td>
{{#config.download}}
<td>
<form id="d_{{guid}}">
<form id="d_{{guid}}" action="{{api}}" method="post">
<input type="hidden" name="dir" value="{{download.currentDir}}">
<input type="hidden" name="filename" value="{{download.name}}">
<input type="hidden" name="api" value="{{download.action}}">
@@ -1631,7 +1631,7 @@ function IFM( params ) {
// build new tbody and replace the old one with the new
var newTBody = Mustache.render( self.templates.filetable, { items: data, config: self.config, i18n: self.i18n } );
var newTBody = Mustache.render( self.templates.filetable, { items: data, config: self.config, i18n: self.i18n, api: self.api } );
var filetable = document.getElementById( 'filetable' );
filetable.tBodies[0].remove();
filetable.append( document.createElement( 'tbody' ) );

View File

@@ -192,7 +192,7 @@ function IFM( params ) {
// build new tbody and replace the old one with the new
var newTBody = Mustache.render( self.templates.filetable, { items: data, config: self.config, i18n: self.i18n } );
var newTBody = Mustache.render( self.templates.filetable, { items: data, config: self.config, i18n: self.i18n, api: self.api } );
var filetable = document.getElementById( 'filetable' );
filetable.tBodies[0].remove();
filetable.append( document.createElement( 'tbody' ) );

View File

@@ -14,7 +14,7 @@
</td>
{{#config.download}}
<td>
<form id="d_{{guid}}">
<form id="d_{{guid}}" action="{{api}}" method="post">
<input type="hidden" name="dir" value="{{download.currentDir}}">
<input type="hidden" name="filename" value="{{download.name}}">
<input type="hidden" name="api" value="{{download.action}}">