mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-22 17:31:35 +02:00
42 lines
850 B
PHP
42 lines
850 B
PHP
|
<?php
|
||
|
/**
|
||
|
* Invoice Ninja (https://invoiceninja.com).
|
||
|
*
|
||
|
* @link https://github.com/invoiceninja/invoiceninja source repository
|
||
|
*
|
||
|
* @copyright Copyright (c) 2023. Invoice Ninja LLC (https://invoiceninja.com)
|
||
|
*
|
||
|
* @license https://www.elastic.co/licensing/elastic-license
|
||
|
*/
|
||
|
|
||
|
|
||
|
namespace App\Exceptions;
|
||
|
|
||
|
use Exception;
|
||
|
use Illuminate\Http\Request;
|
||
|
use Illuminate\Http\Response;
|
||
|
|
||
|
class QuoteConversion extends Exception
|
||
|
{
|
||
|
/**
|
||
|
* Report the exception.
|
||
|
*
|
||
|
* @return void
|
||
|
*/
|
||
|
public function report()
|
||
|
{
|
||
|
//
|
||
|
}
|
||
|
|
||
|
/**
|
||
|
* Render the exception into an HTTP response.
|
||
|
*
|
||
|
* @param Request $request
|
||
|
* @return Response
|
||
|
*/
|
||
|
public function render($request)
|
||
|
{
|
||
|
return response()->json(['message' => 'This quote has already been converted. Cannot convert again.'], 400);
|
||
|
}
|
||
|
}
|