Bug fixes

This commit is contained in:
Hillel Coren 2015-10-15 09:19:41 +03:00
parent 8da5517206
commit a4960245c2
9 changed files with 23 additions and 16 deletions

View File

@ -443,8 +443,8 @@ class InvoiceController extends BaseController
// check if we created a new client with the invoice // check if we created a new client with the invoice
if ($input->invoice->client->public_id == '-1') { if ($input->invoice->client->public_id == '-1') {
$message = $message.' '.trans('texts.and_created_client'); $message = $message.' '.trans('texts.and_created_client');
$url = URL::to('clients/'.$input->invoice->client->public_id); $trackUrl = URL::to('clients/'.$invoice->client->public_id);
Utils::trackViewed($client->getDisplayName(), ENTITY_CLIENT, $url); Utils::trackViewed($invoice->client->getDisplayName(), ENTITY_CLIENT, $trackUrl);
} }
if ($action == 'clone') { if ($action == 'clone') {

View File

@ -72,13 +72,6 @@ Route::post('hook/email_opened', 'AppController@emailOpened');
// Laravel auth routes // Laravel auth routes
/*
Route::controllers([
'auth' => 'Auth\AuthController',
'password' => 'Auth\PasswordController',
]);
*/
get('/signup', array('as' => 'signup', 'uses' => 'Auth\AuthController@getRegister')); get('/signup', array('as' => 'signup', 'uses' => 'Auth\AuthController@getRegister'));
post('/signup', array('as' => 'signup', 'uses' => 'Auth\AuthController@postRegister')); post('/signup', array('as' => 'signup', 'uses' => 'Auth\AuthController@postRegister'));
get('/login', array('as' => 'login', 'uses' => 'Auth\AuthController@getLoginWrapper')); get('/login', array('as' => 'login', 'uses' => 'Auth\AuthController@getLoginWrapper'));

View File

@ -259,6 +259,10 @@ class Utils
public static function dateToString($date) public static function dateToString($date)
{ {
if (!$date) {
return false;
}
$dateTime = new DateTime($date); $dateTime = new DateTime($date);
$timestamp = $dateTime->getTimestamp(); $timestamp = $dateTime->getTimestamp();
$format = Session::get(SESSION_DATE_FORMAT, DEFAULT_DATE_FORMAT); $format = Session::get(SESSION_DATE_FORMAT, DEFAULT_DATE_FORMAT);

View File

@ -2352,6 +2352,9 @@ body { background: #f8f8f8 !important;
font-family: 'Roboto', sans-serif; font-family: 'Roboto', sans-serif;
font-size: 15px; font-size: 15px;
} }
html {
overflow-y: scroll;
}
.bold { font-weight: 700; } .bold { font-weight: 700; }
a {color:#0b4d78;} a {color:#0b4d78;}
/*a:hover { text-decoration: none; color: #0a3857;}*/ /*a:hover { text-decoration: none; color: #0a3857;}*/

View File

@ -785,7 +785,9 @@ body {
font-size: 14px; font-size: 14px;
background-color: #f8f8f8; background-color: #f8f8f8;
} }
html {
overflow-y: scroll;
}
@media screen and (min-width: 700px) { @media screen and (min-width: 700px) {
.navbar-header { .navbar-header {

View File

@ -3,7 +3,9 @@ body {
font-size: 14px; font-size: 14px;
background-color: #f8f8f8; background-color: #f8f8f8;
} }
html {
overflow-y: scroll;
}
@media screen and (min-width: 700px) { @media screen and (min-width: 700px) {
.navbar-header { .navbar-header {

View File

@ -2,6 +2,9 @@ body { background: #f8f8f8 !important;
font-family: 'Roboto', sans-serif; font-family: 'Roboto', sans-serif;
font-size: 15px; font-size: 15px;
} }
html {
overflow-y: scroll;
}
.bold { font-weight: 700; } .bold { font-weight: 700; }
a {color:#0b4d78;} a {color:#0b4d78;}
/*a:hover { text-decoration: none; color: #0a3857;}*/ /*a:hover { text-decoration: none; color: #0a3857;}*/

View File

@ -95,12 +95,12 @@
@if (!Utils::isPro() || \App\Models\InvoiceDesign::count() == COUNT_FREE_DESIGNS_SELF_HOST) @if (!Utils::isPro() || \App\Models\InvoiceDesign::count() == COUNT_FREE_DESIGNS_SELF_HOST)
{!! Former::select('invoice_design_id')->style('display:inline;width:120px')->fromQuery($invoiceDesigns, 'name', 'id')->addOption(trans('texts.more_designs') . '...', '-1') !!} {!! Former::select('invoice_design_id')->style('display:inline')->fromQuery($invoiceDesigns, 'name', 'id')->addOption(trans('texts.more_designs') . '...', '-1') !!}
@else @else
{!! Former::select('invoice_design_id')->style('display:inline;width:120px')->fromQuery($invoiceDesigns, 'name', 'id') !!} {!! Former::select('invoice_design_id')->style('display:inline')->fromQuery($invoiceDesigns, 'name', 'id') !!}
@endif @endif
{!! Former::text('font_size')->type('number')->min('0')->step('1')->style('width:120px') !!} {!! Former::text('font_size')->type('number')->min('0')->step('1') !!}
{!! Former::text('primary_color') !!} {!! Former::text('primary_color') !!}
{!! Former::text('secondary_color') !!} {!! Former::text('secondary_color') !!}

View File

@ -18,7 +18,7 @@
<li>{!! link_to('invoices', trans('texts.recurring_invoice')) !!}</li> <li>{!! link_to('invoices', trans('texts.recurring_invoice')) !!}</li>
@else @else
<li>{!! link_to(($entityType == ENTITY_QUOTE ? 'quotes' : 'invoices'), trans('texts.' . ($entityType == ENTITY_QUOTE ? 'quotes' : 'invoices'))) !!}</li> <li>{!! link_to(($entityType == ENTITY_QUOTE ? 'quotes' : 'invoices'), trans('texts.' . ($entityType == ENTITY_QUOTE ? 'quotes' : 'invoices'))) !!}</li>
<li class='active'>{{ $invoice->invoice_number }}</li> <li class="active">{{ $invoice->invoice_number }}</li>
@endif @endif
</ol> </ol>
@endif @endif
@ -115,7 +115,7 @@
</div> </div>
@elseif ($invoice && isset($lastSent) && $lastSent) @elseif ($invoice && isset($lastSent) && $lastSent)
<div class="pull-right" style="padding-top: 6px"> <div class="pull-right" style="padding-top: 6px">
{!! trans('texts.last_sent_on', ['date' => link_to('/invoices/'.$lastSent->public_id, Utils::dateToString($invoice->last_sent_date), ['id' => 'lastSent'])]) !!} {!! trans('texts.last_sent_on', ['date' => link_to('/invoices/'.$lastSent->public_id, $invoice->last_sent_date, ['id' => 'lastSent'])]) !!}
</div> </div>
@endif @endif
@endif @endif