formatting fixes, bug fixes and support impl.

This commit is contained in:
Dennis Eichhorn 2021-07-04 18:27:20 +02:00
parent 645582aaa6
commit 3bcb5f7f02
10 changed files with 53 additions and 10 deletions

View File

@ -277,8 +277,12 @@ final class ApiController extends Controller
. $bill->createdAt->format('m') . '/'
. $bill->createdAt->format('d') . '/';
if (!\is_dir($pdfDir)) {
\mkdir($pdfDir, 0755, true);
$status = !\is_dir($pdfDir) ? \mkdir($pdfDir, 0755, true) : true;
if ($status === false) {
$response->set($request->uri->__toString(), new FormValidation($status));
$response->header->status = RequestStatusCode::R_400;
return;
}
$view = new View($this->app->l11nManager, $request, $response);

View File

@ -17,7 +17,7 @@ namespace Modules\Billing\Models;
use phpOMS\Stdlib\Base\Enum;
/**
* Task type enum.
* Bill status enum.
*
* @package Modules\Billing\Models
* @license OMS License 1.0

View File

@ -17,7 +17,7 @@ namespace Modules\Billing\Models;
use phpOMS\Stdlib\Base\Enum;
/**
* Task type enum.
* Bill transfer type enum.
*
* @package Modules\Billing\Models
* @license OMS License 1.0

View File

@ -17,7 +17,7 @@ namespace Modules\Billing\Models;
use phpOMS\Localization\ISO639x1Enum;
/**
* Task type enum.
* Bill type enum.
*
* @package Modules\Billing\Models
* @license OMS License 1.0
@ -85,7 +85,7 @@ BillTypeL11n $l11n;
{
if ($l11n instanceof BillTypeL11n) {
$this->l11n = $l11n;
} elseif ($this->l11n instanceof BillTypeL11n) {
} elseif (isset($this->l11n) && $this->l11n instanceof BillTypeL11n) {
$this->l11n->name = $l11n;
} else {
$this->l11n = new BillTypeL11n();

View File

@ -4,7 +4,7 @@
*
* PHP Version 8.0
*
* @package phpOMS\Account
* @package Modules\Billing\Models
* @copyright Dennis Eichhorn
* @license OMS License 1.0
* @version 1.0.0
@ -15,9 +15,9 @@ declare(strict_types=1);
namespace Modules\Billing\Models;
/**
* Null account class.
* Null bill class.
*
* @package phpOMS\Account
* @package Modules\Billing\Models
* @license OMS License 1.0
* @link https://orange-management.org
* @since 1.0.0

View File

@ -0,0 +1,39 @@
<?php
/**
* Orange Management
*
* PHP Version 8.0
*
* @package Modules\Billing\Models
* @copyright Dennis Eichhorn
* @license OMS License 1.0
* @version 1.0.0
* @link https://orange-management.org
*/
declare(strict_types=1);
namespace Modules\Billing\Models;
/**
* Null bill element class.
*
* @package Modules\Billing\Models
* @license OMS License 1.0
* @link https://orange-management.org
* @since 1.0.0
*/
final class NullBillElement extends BillElement
{
/**
* Constructor
*
* @param int $id Model id
*
* @since 1.0.0
*/
public function __construct(int $id = 0)
{
$this->id = $id;
parent::__construct();
}
}

View File

@ -15,7 +15,7 @@ declare(strict_types=1);
namespace Modules\Billing\Models;
/**
* Null account class.
* Null bill type class.
*
* @package Modules\Billing\Models
* @license OMS License 1.0

0
Theme/Backend/bill-analysis.tpl.php Normal file → Executable file
View File

0
Theme/Backend/region-analysis.tpl.php Normal file → Executable file
View File

0
Theme/Backend/rep-analysis.tpl.php Normal file → Executable file
View File