1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-14 07:02:34 +01:00
invoiceninja/app/Http/Controllers/ClientPortal/CreditController.php
2021-05-18 12:03:06 +02:00

37 lines
791 B
PHP

<?php
namespace App\Http\Controllers\ClientPortal;
use App\Http\Controllers\Controller;
use App\Http\Requests\ClientPortal\ShowCreditRequest;
use App\Models\Credit;
use Illuminate\Contracts\View\Factory;
use Illuminate\View\View;
class CreditController extends Controller
{
/**
* Display listing of client credits.
*
* @return Factory|View
*/
public function index()
{
return $this->render('credits.index');
}
public function show(ShowCreditRequest $request, Credit $credit)
{
set_time_limit(0);
$data = ['credit' => $credit];
if ($request->query('mode') === 'fullscreen') {
return render('credits.show-fullscreen', $data);
}
return $this->render('credits.show', $data);
}
}