change cart to plain post from ajax
This commit is contained in:
@@ -3,6 +3,9 @@ $.widget( "fitness.transferList", {
|
||||
transfers: [],
|
||||
url_delete : '',
|
||||
url_pay : '',
|
||||
url_pay_all_visible: '',
|
||||
name_transfers: '',//name to use for transfer id in form
|
||||
id_form: '',
|
||||
columns: [
|
||||
|
||||
{ 'label' : 'Idő' },
|
||||
@@ -42,6 +45,7 @@ $.widget( "fitness.transferList", {
|
||||
_refresh: function(){
|
||||
var s;
|
||||
s = this._render('table',{ 'columns' : this.options.columns, 'transfers' : this.options.transfers,'footer': this.options.footers });
|
||||
s += this.makeForm();
|
||||
this.element.html(s);
|
||||
},
|
||||
|
||||
@@ -159,7 +163,19 @@ $.widget( "fitness.transferList", {
|
||||
// Fire event
|
||||
// this._triggerOptionChanged(key, prev, value);
|
||||
}
|
||||
}, makeForm: function(){
|
||||
var s;
|
||||
s = "";
|
||||
s += "<form method='post' action='"+ this.options.url_pay_all_visible + "' id='"+this.options.id_form+"'>";
|
||||
// s += "<input type='hidden' name='"+this.options.name_number+"' value='"+this.options.value_number+"'>";
|
||||
for( var i = 0; i < this.options.transfers.length; i++){
|
||||
s += "<input type='hidden' name='"+this.options.name_transfers+"' value='"+this.options.transfers[i].id_transfer+"'>";
|
||||
}
|
||||
s += "</form>";
|
||||
return s;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
});
|
||||
Reference in New Issue
Block a user