Bug fixes

This commit is contained in:
Hillel Coren 2015-02-26 21:24:49 +02:00
parent bf24e8c40f
commit 854f6777ab
6 changed files with 634 additions and 623 deletions

View File

@ -26,15 +26,20 @@ class InvoiceApiController extends Controller
return Response::make($response, 200, $headers);
}
/*
public function store()
{
$data = Input::all();
$invoice = $this->invoiceRepo->save(false, $data, false);
/*
public function store()
{
if (!Utils::isPro()) {
return Redirect::to('/');
}
$response = json_encode($invoice, JSON_PRETTY_PRINT);
$headers = Utils::getApiHeaders();
return Response::make($response, 200, $headers);
}
*/
$data = Input::all();
$invoice = $this->invoiceRepo->save(false, $data, false);
$response = json_encode($invoice, JSON_PRETTY_PRINT);
$headers = Utils::getApiHeaders();
return Response::make($response, 200, $headers);
}
*/
}

File diff suppressed because it is too large Load Diff

View File

@ -220,7 +220,7 @@ class InvoiceRepository
$invoice->is_quote = true;
}
}
$invoice->client_id = $data['client_id'];
$invoice->discount = round(Utils::parseFloat($data['discount']), 2);
$invoice->is_amount_discount = $data['is_amount_discount'] ? true : false;

View File

@ -58,13 +58,11 @@ $monolog->pushHandler(new Monolog\Handler\SyslogHandler('intranet', 'user', Logg
App::error(function(Exception $exception, $code)
{
if (Utils::isNinjaProd())
{
Utils::logError($code . ' ' . Utils::getErrorString($exception));
return Response::view('error', ['hideHeader' => true, 'error' => "A {$code} error occurred."], $code);
}
else
{
Utils::logError($code . ' ' . Utils::getErrorString($exception));
if (Utils::isNinjaProd()) {
return Response::view('error', ['hideHeader' => true, 'error' => "A {$code} error occurred."], $code);
} else {
return null;
}
});

View File

@ -20,7 +20,7 @@
<h1>{{ trans('texts.confirmation_header') }}</h1>
<p>
{{ $invitationMessage . trans('texts.confirmation_message') }}
{{ $invitationMessage . trans('texts.confirmation_message') }}<br/>
<a href='{{{ URL::to("user/confirm/{$user->confirmation_code}") }}}'>
{{{ URL::to("user/confirm/{$user->confirmation_code}") }}}
</a>

View File

@ -2,6 +2,28 @@
@section('content')
<style type="text/css">
body {
background-color: #f8f8f8;
color: #1b1a1a;
}
.panel-body {
padding-bottom: 100px;
}
</style>
<div class="container">
<p>&nbsp;</p>
<div class="panel panel-default">
<div class="panel-body">
<section data-type="background">
<div class="container">
<div class="row">
@ -148,4 +170,8 @@
<p>&nbsp;</p>
<p>&nbsp;</p>
</div>
</div>
</div>
@stop