add default account to frontend

This commit is contained in:
2015-10-26 07:49:10 +01:00
parent 0c92fdf167
commit 01da3c470c
45 changed files with 948 additions and 220 deletions

View File

@@ -27,6 +27,7 @@ function ProductSell(o){
user_cart: [],
discounts: [],
customer_cart: [],
id_account: null,
};
@@ -275,7 +276,7 @@ function ProductSell(o){
table.find('.product-price').html('-');
table.find('.product-sale-price').html('-');
$('#productsaleform-id_product').val('');
$('#productsaleform-id_account').val('');
$('#productsaleform-id_account').val( app.defaults.id_account ? app.defaults.id_account : '');
$("#productsaleform-count").val(1);
}

View File

@@ -162,7 +162,7 @@ function TicketSell(o){
app.defaults.price = app.defaults.ticket_type.price_brutto;
}
function validateAccount(){
app.defaults.id_account = app.defaults.ticket_type.id_account;
app.defaults.id_account = $('#ticketcreate-id_account').val();
}
function refresh(){