mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Bug fixes
This commit is contained in:
parent
8049a27beb
commit
380d7e0a4a
@ -200,7 +200,7 @@ class AccountController extends \BaseController {
|
||||
}
|
||||
}
|
||||
|
||||
public function doSection($section = ACCOUNT_DETAILS)
|
||||
public function doSection($section = ACCOUNT_DETAILS, $subSection = false)
|
||||
{
|
||||
if ($section == ACCOUNT_DETAILS)
|
||||
{
|
||||
@ -257,7 +257,7 @@ class AccountController extends \BaseController {
|
||||
|
||||
private function saveCustomFields()
|
||||
{
|
||||
if (!Auth::user()->account->isPro())
|
||||
if (Auth::user()->account->isPro())
|
||||
{
|
||||
$account = Auth::user()->account;
|
||||
$account->custom_label1 = Input::get('custom_label1');
|
||||
@ -271,12 +271,12 @@ class AccountController extends \BaseController {
|
||||
Session::flash('message', trans('texts.updated_settings'));
|
||||
}
|
||||
|
||||
return Redirect::to('company/advanced_settings');
|
||||
return Redirect::to('company/advanced_settings/custom_fields');
|
||||
}
|
||||
|
||||
private function saveInvoiceDesign()
|
||||
{
|
||||
if (!Auth::user()->account->isPro())
|
||||
if (Auth::user()->account->isPro())
|
||||
{
|
||||
$account = Auth::user()->account;
|
||||
$account->primary_color = Input::get('primary_color');// ? Input::get('primary_color') : null;
|
||||
@ -286,7 +286,7 @@ class AccountController extends \BaseController {
|
||||
Session::flash('message', trans('texts.updated_settings'));
|
||||
}
|
||||
|
||||
return Redirect::to('company/advanced_settings');
|
||||
return Redirect::to('company/advanced_settings/invoice_design');
|
||||
}
|
||||
|
||||
private function export()
|
||||
@ -679,7 +679,9 @@ class AccountController extends \BaseController {
|
||||
{
|
||||
$path = Input::file('logo')->getRealPath();
|
||||
File::delete('logo/' . $account->account_key . '.jpg');
|
||||
Image::make($path)->resize(200, 120, true, false)->save('logo/' . $account->account_key . '.jpg');
|
||||
|
||||
$image = Image::make($path)->resize(200, 120, true, false);
|
||||
Image::canvas($image->width, $image->height, '#FFFFFF')->insert($image)->save($account->getLogoPath());
|
||||
}
|
||||
|
||||
Event::fire('user.refresh');
|
||||
|
@ -342,7 +342,7 @@ class InvoiceController extends \BaseController {
|
||||
}
|
||||
else if ($action == 'convert')
|
||||
{
|
||||
return $this->convertQuote($publicId);
|
||||
return $this->convertQuote($publicId);
|
||||
}
|
||||
else if ($action == 'email')
|
||||
{
|
||||
|
@ -14,11 +14,10 @@ class AddQuotes extends Migration {
|
||||
{
|
||||
Schema::table('invoices', function($table)
|
||||
{
|
||||
$table->boolean('is_quote');
|
||||
|
||||
$table->boolean('is_quote');
|
||||
$table->unsignedInteger('quote_id')->nullable();
|
||||
$table->unsignedInteger('quote_invoice_id')->nullable();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
@ -30,8 +29,7 @@ class AddQuotes extends Migration {
|
||||
{
|
||||
Schema::table('invoices', function($table)
|
||||
{
|
||||
$table->dropColumn('is_quote');
|
||||
|
||||
$table->dropColumn('is_quote');
|
||||
$table->dropColumn('quote_id');
|
||||
$table->dropColumn('quote_invoice_id');
|
||||
});
|
||||
|
@ -124,7 +124,7 @@ class ConstantsSeeder extends Seeder
|
||||
Currency::create(array('name' => 'Pound Sterling', 'code' => 'GBP', 'symbol' => '£', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'));
|
||||
Currency::create(array('name' => 'Euro', 'code' => 'EUR', 'symbol' => '€', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'));
|
||||
Currency::create(array('name' => 'Rand', 'code' => 'ZAR', 'symbol' => 'R', 'precision' => '2', 'thousand_separator' => ' ', 'decimal_separator' => '.'));
|
||||
|
||||
Currency::create(array('name' => 'Danish Krone', 'code' => 'DKK', 'symbol' => 'kr ', 'precision' => '2', 'thousand_separator' => '.', 'decimal_separator' => ','));
|
||||
|
||||
DatetimeFormat::create(array('format' => 'd/M/Y g:i a', 'label' => '10/Mar/2013'));
|
||||
DatetimeFormat::create(array('format' => 'd-M-Yk g:i a', 'label' => '10-Mar-2013'));
|
||||
|
@ -62,6 +62,7 @@ class Invoice extends EntityModel
|
||||
$this->setVisible([
|
||||
'invoice_number',
|
||||
'discount',
|
||||
'shipping',
|
||||
'po_number',
|
||||
'invoice_date',
|
||||
'due_date',
|
||||
|
@ -119,11 +119,12 @@ class InvoiceRepository
|
||||
</button>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li><a href="' . \URL::to("{$entityType}s/".$model->public_id.'/edit') . '">'.trans("texts.edit_{$entityType}").'</a></li>
|
||||
<li><a href="' . \URL::to("{$entityType}s/".$model->public_id.'/clone') . '">'.trans("texts.clone_{$entityType}").'</a></li>';
|
||||
<li><a href="' . \URL::to("{$entityType}s/".$model->public_id.'/clone') . '">'.trans("texts.clone_{$entityType}").'</a></li>
|
||||
<li class="divider"></li><li>';
|
||||
|
||||
if ($entityType == ENTITY_INVOICE)
|
||||
{
|
||||
$str .= '<li class="divider"></li><li><a href="' . \URL::to('payments/create/' . $model->client_public_id . '/' . $model->public_id ) . '">'.trans('texts.enter_payment').'</a></li>';
|
||||
$str .= '<a href="' . \URL::to('payments/create/' . $model->client_public_id . '/' . $model->public_id ) . '">'.trans('texts.enter_payment').'</a></li>';
|
||||
|
||||
if ($model->quote_id)
|
||||
{
|
||||
@ -134,7 +135,7 @@ class InvoiceRepository
|
||||
{
|
||||
if ($model->quote_invoice_id)
|
||||
{
|
||||
$str .= '<li class="divider"></li><li><a href="' . \URL::to("invoices/{$model->quote_invoice_id}/edit") . '">' . trans("texts.view_invoice") . '</a></li>';
|
||||
$str .= '<li><a href="' . \URL::to("invoices/{$model->quote_invoice_id}/edit") . '">' . trans("texts.view_invoice") . '</a></li>';
|
||||
}
|
||||
}
|
||||
|
||||
@ -324,8 +325,9 @@ class InvoiceRepository
|
||||
$clone->invoice_number = $invoice->account->getNextInvoiceNumber();
|
||||
|
||||
foreach ([
|
||||
'client_id',
|
||||
'client_id',
|
||||
'discount',
|
||||
'shipping',
|
||||
'invoice_date',
|
||||
'po_number',
|
||||
'due_date',
|
||||
|
@ -18,7 +18,7 @@
|
||||
@endif
|
||||
|
||||
<p/>
|
||||
{{ trans('texts.ninja_email_footer', ['site' => '<a href="'.SITE_URL.'">Invoice Ninja</a>']) }}
|
||||
{{ trans('texts.ninja_email_footer', ['site' => '<a href="https://www.invoiceninja.com">Invoice Ninja</a>']) }}
|
||||
|
||||
</body>
|
||||
</html>
|
@ -11,4 +11,4 @@
|
||||
@endif
|
||||
|
||||
{{ trans('texts.ninja_email_footer', ['site' => 'Invoice Ninja']) }}
|
||||
{{ SITE_URL }}
|
||||
https://www.invoiceninja.com
|
@ -17,7 +17,7 @@
|
||||
@endif
|
||||
|
||||
<p/>
|
||||
{{ trans('texts.ninja_email_footer', ['site' => '<a href="'.SITE_URL.'">Invoice Ninja</a>']) }}
|
||||
{{ trans('texts.ninja_email_footer', ['site' => '<a href="https://www.invoiceninja.com">Invoice Ninja</a>']) }}
|
||||
|
||||
</body>
|
||||
</html>
|
@ -10,4 +10,4 @@
|
||||
@endif
|
||||
|
||||
{{ trans('texts.ninja_email_footer', ['site' => 'Invoice Ninja']) }}
|
||||
{{ SITE_URL }}
|
||||
https://www.invoiceninja.com
|
@ -112,91 +112,91 @@
|
||||
{{ Former::hidden('data')->data_bind("value: ko.mapping.toJSON(model)") }}
|
||||
|
||||
<table class="table invoice-table" style="margin-bottom: 0px !important">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="min-width:32px;" class="hide-border"></th>
|
||||
<th style="min-width:160px">{{ trans('texts.item') }}</th>
|
||||
<th style="width:100%">{{ trans('texts.description') }}</th>
|
||||
<th style="min-width:120px">{{ trans('texts.unit_cost') }}</th>
|
||||
<th style="min-width:120px">{{ trans('texts.quantity') }}</th>
|
||||
<th style="min-width:120px;display:none;" data-bind="visible: $root.invoice_item_taxes.show">{{ trans('texts.tax') }}</th>
|
||||
<th style="min-width:120px;">{{ trans('texts.line_total') }}</th>
|
||||
<th style="min-width:32px;" class="hide-border"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody data-bind="sortable: { data: invoice_items, afterMove: onDragged }">
|
||||
<tr data-bind="event: { mouseover: showActions, mouseout: hideActions }" class="sortable-row">
|
||||
<td class="hide-border td-icon">
|
||||
<i style="display:none" data-bind="visible: actionsVisible() && $parent.invoice_items().length > 1" class="fa fa-sort"></i>
|
||||
</td>
|
||||
<td>
|
||||
{{ Former::text('product_key')->useDatalist($products, 'product_key')->onkeyup('onItemChange()')
|
||||
->raw()->data_bind("value: product_key, valueUpdate: 'afterkeydown'")->addClass('datalist') }}
|
||||
</td>
|
||||
<td>
|
||||
<textarea data-bind="value: wrapped_notes, valueUpdate: 'afterkeydown'" rows="1" cols="60" style="resize: none;" class="form-control word-wrap"></textarea>
|
||||
</td>
|
||||
<td>
|
||||
<input onkeyup="onItemChange()" data-bind="value: prettyCost, valueUpdate: 'afterkeydown'" style="text-align: right" class="form-control"//>
|
||||
</td>
|
||||
<td>
|
||||
<input onkeyup="onItemChange()" data-bind="value: prettyQty, valueUpdate: 'afterkeydown'" style="text-align: right" class="form-control"//>
|
||||
</td>
|
||||
<td style="display:none;" data-bind="visible: $root.invoice_item_taxes.show">
|
||||
<select class="form-control" style="width:100%" data-bind="value: tax, options: $root.tax_rates, optionsText: 'displayName'"></select>
|
||||
</td>
|
||||
<td style="text-align:right;padding-top:9px !important">
|
||||
<div class="line-total" data-bind="text: totals.total"></div>
|
||||
</td>
|
||||
<td style="cursor:pointer" class="hide-border td-icon">
|
||||
<i style="display:none" data-bind="click: $parent.removeItem, visible: actionsVisible() && $parent.invoice_items().length > 1" class="fa fa-minus-circle redlink" title="Remove item"/>
|
||||
</td>
|
||||
</tr>
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="min-width:32px;" class="hide-border"></th>
|
||||
<th style="min-width:160px">{{ trans('texts.item') }}</th>
|
||||
<th style="width:100%">{{ trans('texts.description') }}</th>
|
||||
<th style="min-width:120px">{{ trans('texts.unit_cost') }}</th>
|
||||
<th style="min-width:120px">{{ trans('texts.quantity') }}</th>
|
||||
<th style="min-width:120px;display:none;" data-bind="visible: $root.invoice_item_taxes.show">{{ trans('texts.tax') }}</th>
|
||||
<th style="min-width:120px;">{{ trans('texts.line_total') }}</th>
|
||||
<th style="min-width:32px;" class="hide-border"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody data-bind="sortable: { data: invoice_items, afterMove: onDragged }">
|
||||
<tr data-bind="event: { mouseover: showActions, mouseout: hideActions }" class="sortable-row">
|
||||
<td class="hide-border td-icon">
|
||||
<i style="display:none" data-bind="visible: actionsVisible() && $parent.invoice_items().length > 1" class="fa fa-sort"></i>
|
||||
</td>
|
||||
<td>
|
||||
{{ Former::text('product_key')->useDatalist($products, 'product_key')->onkeyup('onItemChange()')
|
||||
->raw()->data_bind("value: product_key, valueUpdate: 'afterkeydown'")->addClass('datalist') }}
|
||||
</td>
|
||||
<td>
|
||||
<textarea data-bind="value: wrapped_notes, valueUpdate: 'afterkeydown'" rows="1" cols="60" style="resize: none;" class="form-control word-wrap"></textarea>
|
||||
</td>
|
||||
<td>
|
||||
<input onkeyup="onItemChange()" data-bind="value: prettyCost, valueUpdate: 'afterkeydown'" style="text-align: right" class="form-control"//>
|
||||
</td>
|
||||
<td>
|
||||
<input onkeyup="onItemChange()" data-bind="value: prettyQty, valueUpdate: 'afterkeydown'" style="text-align: right" class="form-control"//>
|
||||
</td>
|
||||
<td style="display:none;" data-bind="visible: $root.invoice_item_taxes.show">
|
||||
<select class="form-control" style="width:100%" data-bind="value: tax, options: $root.tax_rates, optionsText: 'displayName'"></select>
|
||||
</td>
|
||||
<td style="text-align:right;padding-top:9px !important">
|
||||
<div class="line-total" data-bind="text: totals.total"></div>
|
||||
</td>
|
||||
<td style="cursor:pointer" class="hide-border td-icon">
|
||||
<i style="display:none" data-bind="click: $parent.removeItem, visible: actionsVisible() && $parent.invoice_items().length > 1" class="fa fa-minus-circle redlink" title="Remove item"/>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td class="hide-border"/>
|
||||
<td colspan="2" rowspan="5">
|
||||
<br/>
|
||||
<td class="hide-border"/>
|
||||
<td colspan="2" rowspan="5">
|
||||
<br/>
|
||||
{{ Former::textarea('public_notes')->data_bind("value: wrapped_notes, valueUpdate: 'afterkeydown'")
|
||||
->label(false)->placeholder(trans('texts.note_to_client'))->style('width: 520px; resize: none') }}
|
||||
->label(false)->placeholder(trans('texts.note_to_client'))->style('width: 520px; resize: none') }}
|
||||
{{ Former::textarea('terms')->data_bind("value: wrapped_terms, valueUpdate: 'afterkeydown'")
|
||||
->label(false)->placeholder(trans('texts.invoice_terms'))->style('width: 520px; resize: none')
|
||||
->addGroupClass('less-space-bottom') }}
|
||||
->label(false)->placeholder(trans('texts.invoice_terms'))->style('width: 520px; resize: none')
|
||||
->addGroupClass('less-space-bottom') }}
|
||||
<label class="checkbox" style="width: 200px">
|
||||
<input type="checkbox" style="width: 24px" data-bind="checked: set_default_terms"/>{{ trans('texts.save_as_default_terms') }}
|
||||
</label>
|
||||
</td>
|
||||
<td style="display:none" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
</td>
|
||||
<td style="display:none" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
<td colspan="2">{{ trans('texts.subtotal') }}</td>
|
||||
<td style="text-align: right"><span data-bind="text: totals.subtotal"/></td>
|
||||
</tr>
|
||||
<tr style="display:none" data-bind="visible: discount() > 0">
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
</tr>
|
||||
<tr style="display:none" data-bind="visible: discount() > 0">
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
<td colspan="2">{{ trans('texts.discount') }}</td>
|
||||
<td style="text-align: right"><span data-bind="text: totals.discounted"/></td>
|
||||
</tr>
|
||||
<tr style="display:none" data-bind="visible: $root.invoice_taxes.show">
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
</tr>
|
||||
<tr style="display:none" data-bind="visible: $root.invoice_taxes.show">
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
<td>{{ trans('texts.tax') }}</td>
|
||||
<td style="min-width:120px"><select class="form-control" style="width:100%" data-bind="value: tax, options: $root.tax_rates, optionsText: 'displayName'"></select></td>
|
||||
<td style="text-align: right"><span data-bind="text: totals.taxAmount"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
<td colspan="2">{{ trans('texts.paid_to_date') }}</td>
|
||||
<td style="text-align: right" data-bind="text: totals.paidToDate"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="hide-border" colspan="3"/>
|
||||
<td style="display:none" class="hide-border" data-bind="visible: $root.invoice_item_taxes.show"/>
|
||||
<td colspan="2"><b>{{ trans($entityType == ENTITY_INVOICE ? 'texts.balance_due' : 'texts.total') }}</b></td>
|
||||
<td style="text-align: right"><span data-bind="text: totals.total"/></td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
|
||||
<p> </p>
|
||||
|
@ -9,7 +9,7 @@
|
||||
<div class="cell">Live .PDF invoice creation </div>
|
||||
<div class="cell">4 beatiful invoice templates</div>
|
||||
<div class="cell">Accept credit card payments</div>
|
||||
<div class="cell">Quotes/Pro-Forma Invoices</div>
|
||||
<div class="cell">Quotes/pro-forma invoices</div>
|
||||
<div class="cell">Custom invoice fields and colors</div>
|
||||
<div class="cell">Dynamic chart builder</div>
|
||||
<div class="cell">Priority email support</div>
|
||||
@ -26,7 +26,7 @@
|
||||
<div class="cell"><div class="hide-desktop">Live .PDF invoice creation</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">4 beatiful invoice templates</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Accept credit card payments</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Quotes/Pro-Forma Invoices</div><span class="glyphicon glyphicon-remove"></div>
|
||||
<div class="cell"><div class="hide-desktop">Quotes/pro-forma invoices</div><span class="glyphicon glyphicon-remove"></div>
|
||||
<div class="cell"><div class="hide-desktop">Custom fields and invoice colors</div><span class="glyphicon glyphicon-remove"></div>
|
||||
<div class="cell"><div class="hide-desktop">Dynamic chart builder</div><span class="glyphicon glyphicon-remove"></div>
|
||||
<div class="cell"><div class="hide-desktop">Priority email support</div><span class="glyphicon glyphicon-remove"></div>
|
||||
@ -43,7 +43,7 @@
|
||||
<div class="cell"><div class="hide-desktop">Live .PDF invoice creation</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">4 beatiful invoice templates</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Accept credit card payments</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Quotes/Pro-Forma Invoices</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Quotes/pro-forma invoices</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Custom invoice fields and colors</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Dynamic chart builder</div><span class="glyphicon glyphicon-ok"></div>
|
||||
<div class="cell"><div class="hide-desktop">Priority email support</div><span class="glyphicon glyphicon-ok"></div>
|
||||
|
@ -108,6 +108,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="background-color:#211f1f; width:100%">
|
||||
<div class="container">
|
||||
@if (Session::has('warning'))
|
||||
<div class="alert alert-warning">{{ Session::get('warning') }}</div>
|
||||
@ -121,6 +122,7 @@
|
||||
<div class="alert alert-danger">{{ Session::get('error') }}</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@yield('content')
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user