mirror of
https://github.com/Karaka-Management/oms-Billing.git
synced 2026-01-24 05:18:40 +00:00
september update 1
This commit is contained in:
parent
f0836a6c09
commit
b6bcc5ce00
|
|
@ -45,6 +45,6 @@ class Media
|
|||
$defaultTemplate = \reset($media['upload'][0]);
|
||||
|
||||
$setting = new Setting();
|
||||
SettingMapper::create($setting->with(0, 'default_template', (string) $defaultTemplate->getId(), 'Billing'));
|
||||
SettingMapper::create($setting->with(0, 'default_template', (string) $defaultTemplate->getId(), '\\d+', 'Billing'));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,16 @@
|
|||
<?php declare(strict_types=1);
|
||||
<?php
|
||||
/**
|
||||
* Orange Management
|
||||
*
|
||||
* PHP Version 8.0
|
||||
*
|
||||
* @package Modules
|
||||
* @copyright Dennis Eichhorn
|
||||
* @license OMS License 1.0
|
||||
* @version 1.0.0
|
||||
* @link https://orange-management.org
|
||||
*/
|
||||
declare(strict_types=1);
|
||||
|
||||
use Modules\Billing\Controller\BackendController;
|
||||
use Modules\Billing\Models\PermissionState;
|
||||
|
|
|
|||
|
|
@ -42,7 +42,6 @@ final class PurchaseBillMapper extends BillMapper
|
|||
mixed $pivot,
|
||||
string $column = null,
|
||||
int $limit = 50,
|
||||
string $order = 'ASC',
|
||||
int $relations = RelationType::ALL,
|
||||
int $depth = 3,
|
||||
Builder $query = null
|
||||
|
|
@ -51,14 +50,13 @@ final class PurchaseBillMapper extends BillMapper
|
|||
$query = self::getQuery(null, [], $relations, $depth);
|
||||
$query->where(BillTypeMapper::getTable() . '_d' . ($depth - 1) . '.billing_type_transfer_type', '=', BillTransferType::PURCHASE);
|
||||
|
||||
return self::getBeforePivot($pivot, $column, $limit, $order, $relations, $depth, $query);
|
||||
return self::getBeforePivot($pivot, $column, $limit, $relations, $depth, $query);
|
||||
}
|
||||
|
||||
public static function getPurchaseAfterPivot(
|
||||
mixed $pivot,
|
||||
string $column = null,
|
||||
int $limit = 50,
|
||||
string $order = 'ASC',
|
||||
int $relations = RelationType::ALL,
|
||||
int $depth = 3,
|
||||
Builder $query = null
|
||||
|
|
@ -67,7 +65,7 @@ final class PurchaseBillMapper extends BillMapper
|
|||
$query = self::getQuery(null, [], $relations, $depth);
|
||||
$query->where(BillTypeMapper::getTable() . '_d' . ($depth - 1) . '.billing_type_transfer_type', '=', BillTransferType::PURCHASE);
|
||||
|
||||
return self::getAfterPivot($pivot, $column, $limit, $order, $relations, $depth, $query);
|
||||
return self::getAfterPivot($pivot, $column, $limit, $relations, $depth, $query);
|
||||
}
|
||||
|
||||
public static function getPurchaseByItemId(int $id, \DateTime $start, \DateTime $end) : Money
|
||||
|
|
|
|||
|
|
@ -42,7 +42,6 @@ final class SalesBillMapper extends BillMapper
|
|||
mixed $pivot,
|
||||
string $column = null,
|
||||
int $limit = 50,
|
||||
string $order = 'ASC',
|
||||
int $relations = RelationType::ALL,
|
||||
int $depth = 3,
|
||||
Builder $query = null
|
||||
|
|
@ -51,14 +50,13 @@ final class SalesBillMapper extends BillMapper
|
|||
$query = self::getQuery(null, [], $relations, $depth);
|
||||
$query->where(BillTypeMapper::getTable() . '_d' . ($depth - 1) . '.billing_type_transfer_type', '=', BillTransferType::SALES);
|
||||
|
||||
return self::getBeforePivot($pivot, $column, $limit, $order, $relations, $depth, $query);
|
||||
return self::getBeforePivot($pivot, $column, $limit, $relations, $depth, $query);
|
||||
}
|
||||
|
||||
public static function getSalesAfterPivot(
|
||||
mixed $pivot,
|
||||
string $column = null,
|
||||
int $limit = 50,
|
||||
string $order = 'ASC',
|
||||
int $relations = RelationType::ALL,
|
||||
int $depth = 3,
|
||||
Builder $query = null
|
||||
|
|
@ -67,7 +65,7 @@ final class SalesBillMapper extends BillMapper
|
|||
$query = self::getQuery(null, [], $relations, $depth);
|
||||
$query->where(BillTypeMapper::getTable() . '_d' . ($depth - 1) . '.billing_type_transfer_type', '=', BillTransferType::SALES);
|
||||
|
||||
return self::getAfterPivot($pivot, $column, $limit, $order, $relations, $depth, $query);
|
||||
return self::getAfterPivot($pivot, $column, $limit, $relations, $depth, $query);
|
||||
}
|
||||
|
||||
public static function getSalesByItemId(int $id, \DateTime $start, \DateTime $end) : Money
|
||||
|
|
|
|||
|
|
@ -39,7 +39,6 @@ final class StockBillMapper extends BillMapper
|
|||
mixed $pivot,
|
||||
string $column = null,
|
||||
int $limit = 50,
|
||||
string $order = 'ASC',
|
||||
int $relations = RelationType::ALL,
|
||||
int $depth = 3,
|
||||
Builder $query = null
|
||||
|
|
@ -48,14 +47,13 @@ final class StockBillMapper extends BillMapper
|
|||
$query = self::getQuery(null, [], $relations, $depth);
|
||||
$query->where(BillTypeMapper::getTable() . '_d' . ($depth - 1) . '.billing_type_transfer_type', '=', BillTransferType::STOCK);
|
||||
|
||||
return self::getBeforePivot($pivot, $column, $limit, $order, $relations, $depth, $query);
|
||||
return self::getBeforePivot($pivot, $column, $limit, $relations, $depth, $query);
|
||||
}
|
||||
|
||||
public static function getStockAfterPivot(
|
||||
mixed $pivot,
|
||||
string $column = null,
|
||||
int $limit = 50,
|
||||
string $order = 'ASC',
|
||||
int $relations = RelationType::ALL,
|
||||
int $depth = 3,
|
||||
Builder $query = null
|
||||
|
|
@ -64,6 +62,6 @@ final class StockBillMapper extends BillMapper
|
|||
$query = self::getQuery(null, [], $relations, $depth);
|
||||
$query->where(BillTypeMapper::getTable() . '_d' . ($depth - 1) . '.billing_type_transfer_type', '=', BillTransferType::STOCK);
|
||||
|
||||
return self::getAfterPivot($pivot, $column, $limit, $order, $relations, $depth, $query);
|
||||
return self::getAfterPivot($pivot, $column, $limit, $relations, $depth, $query);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user