Removed default US dollar client currency to enable company setting to be used

This commit is contained in:
Hillel Coren 2014-11-04 22:27:09 +02:00
parent cb185531da
commit be2b7d28fc
3 changed files with 7 additions and 7 deletions

View File

@ -212,7 +212,7 @@ class ClientController extends \BaseController {
$client->private_notes = trim(Input::get('private_notes'));
$client->size_id = Input::get('size_id') ? : null;
$client->industry_id = Input::get('industry_id') ? : null;
$client->currency_id = Input::get('currency_id') ? : 1;
$client->currency_id = Input::get('currency_id') ? : null;
$client->payment_terms = Input::get('payment_terms') ? : 0;
$client->website = trim(Input::get('website'));

View File

@ -31533,8 +31533,8 @@ function populateInvoiceComboboxes(clientId, invoiceId) {
var client = clientMap[invoice.client.public_id];
if (!client) continue; // client is deleted/archived
$invoiceCombobox.append(new Option(invoice.invoice_number + ' - ' + invoice.invoice_status.name + ' - ' +
getClientDisplayName(client) + ' - ' + formatMoney(invoice.amount, invoice.currency_id) + ' | ' +
formatMoney(invoice.balance, invoice.currency_id), invoice.public_id));
getClientDisplayName(client) + ' - ' + formatMoney(invoice.amount, client.currency_id) + ' | ' +
formatMoney(invoice.balance, client.currency_id), invoice.public_id));
}
$('select#invoice').combobox('refresh');
});
@ -31559,7 +31559,7 @@ function populateInvoiceComboboxes(clientId, invoiceId) {
var client = clientMap[invoice.client.public_id];
setComboboxValue($('.invoice-select'), invoice.public_id, (invoice.invoice_number + ' - ' +
invoice.invoice_status.name + ' - ' + getClientDisplayName(client) + ' - ' +
formatMoney(invoice.amount, invoice.currency_id) + ' | ' + formatMoney(invoice.balance, invoice.currency_id)));
formatMoney(invoice.amount, client.currency_id) + ' | ' + formatMoney(invoice.balance, client.currency_id)));
$invoiceSelect.trigger('change');
} else if (clientId) {
var client = clientMap[clientId];

View File

@ -576,8 +576,8 @@ function populateInvoiceComboboxes(clientId, invoiceId) {
var client = clientMap[invoice.client.public_id];
if (!client) continue; // client is deleted/archived
$invoiceCombobox.append(new Option(invoice.invoice_number + ' - ' + invoice.invoice_status.name + ' - ' +
getClientDisplayName(client) + ' - ' + formatMoney(invoice.amount, invoice.currency_id) + ' | ' +
formatMoney(invoice.balance, invoice.currency_id), invoice.public_id));
getClientDisplayName(client) + ' - ' + formatMoney(invoice.amount, client.currency_id) + ' | ' +
formatMoney(invoice.balance, client.currency_id), invoice.public_id));
}
$('select#invoice').combobox('refresh');
});
@ -602,7 +602,7 @@ function populateInvoiceComboboxes(clientId, invoiceId) {
var client = clientMap[invoice.client.public_id];
setComboboxValue($('.invoice-select'), invoice.public_id, (invoice.invoice_number + ' - ' +
invoice.invoice_status.name + ' - ' + getClientDisplayName(client) + ' - ' +
formatMoney(invoice.amount, invoice.currency_id) + ' | ' + formatMoney(invoice.balance, invoice.currency_id)));
formatMoney(invoice.amount, client.currency_id) + ' | ' + formatMoney(invoice.balance, client.currency_id)));
$invoiceSelect.trigger('change');
} else if (clientId) {
var client = clientMap[clientId];