mirror of
https://github.com/Karaka-Management/oms-SupplierManagement.git
synced 2026-02-04 11:38:40 +00:00
Went through todos
This commit is contained in:
parent
7109168e4d
commit
c61518fa61
|
|
@ -31,7 +31,31 @@ return [
|
|||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/attribute$' => [
|
||||
'^.*/supplier(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiController:apiSupplierCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
'csrf' => true,
|
||||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiController:apiSupplierUpdate',
|
||||
'verb' => RouteVerb::SET,
|
||||
'csrf' => true,
|
||||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/attribute(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiAttributeController:apiSupplierAttributeCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -39,7 +63,7 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
|
|
@ -50,12 +74,12 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/attribute/type$' => [
|
||||
'^.*/supplier/attribute/type(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiAttributeController:apiSupplierAttributeTypeCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -64,7 +88,7 @@ return [
|
|||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
'state' => PermissionCategory::ATTRIBUTE,
|
||||
],
|
||||
],
|
||||
[
|
||||
|
|
@ -75,11 +99,11 @@ return [
|
|||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
'state' => PermissionCategory::ATTRIBUTE,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/attribute/type/l11n$' => [
|
||||
'^.*/supplier/attribute/type/l11n(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiAttributeController:apiSupplierAttributeTypeL11nCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -87,8 +111,8 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::ATTRIBUTE,
|
||||
],
|
||||
],
|
||||
[
|
||||
|
|
@ -98,12 +122,12 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::ATTRIBUTE,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/attribute/value$' => [
|
||||
'^.*/supplier/attribute/value(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiAttributeController:apiSupplierAttributeValueCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -111,7 +135,7 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
|
|
@ -122,12 +146,12 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/attribute/value/l11n$' => [
|
||||
'^.*/supplier/attribute/value/l11n(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiAttributeController:apiSupplierAttributeValueL11nCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -135,7 +159,7 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
|
|
@ -146,12 +170,12 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/l11n$' => [
|
||||
'^.*/supplier/l11n(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiController:apiSupplierL11nCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -159,7 +183,7 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
|
|
@ -170,12 +194,12 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
],
|
||||
'^.*/supplier/l11n/type$' => [
|
||||
'^.*/supplier/l11n/type(\?.*|$)$' => [
|
||||
[
|
||||
'dest' => '\Modules\SupplierManagement\Controller\ApiController:apiSupplierL11nTypeCreate',
|
||||
'verb' => RouteVerb::PUT,
|
||||
|
|
@ -183,7 +207,7 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::CREATE,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
|
|
@ -194,7 +218,7 @@ return [
|
|||
'active' => true,
|
||||
'permission' => [
|
||||
'module' => ApiController::NAME,
|
||||
'type' => PermissionType::READ,
|
||||
'type' => PermissionType::MODIFY,
|
||||
'state' => PermissionCategory::SUPPLIER,
|
||||
],
|
||||
],
|
||||
|
|
|
|||
|
|
@ -208,6 +208,13 @@ final class BackendController extends Controller
|
|||
*
|
||||
* @return RenderableInterface
|
||||
*
|
||||
* @feature In the supplier and client view you should be able to select multiple bills and click print for printing
|
||||
* https://github.com/Karaka-Management/oms-Billing/issues/35
|
||||
*
|
||||
* @feature The send bill as email should have a global settings where you can either define a global email or
|
||||
* empty = user specific email
|
||||
* https://github.com/Karaka-Management/oms-Billing/issues/33
|
||||
*
|
||||
* @since 1.0.0
|
||||
* @codeCoverageIgnore
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -16,4 +16,5 @@ return ['Navigation' => [
|
|||
'Create' => 'Erstellen',
|
||||
'List' => 'Liste',
|
||||
'Suppliers' => 'Lieferanten',
|
||||
'Attributes' => 'Attribute',
|
||||
]];
|
||||
|
|
|
|||
|
|
@ -16,4 +16,5 @@ return ['Navigation' => [
|
|||
'Create' => 'Create',
|
||||
'List' => 'List',
|
||||
'Suppliers' => 'Suppliers',
|
||||
'Attributes' => 'Attributes',
|
||||
]];
|
||||
|
|
|
|||
|
|
@ -28,6 +28,8 @@ use phpOMS\Localization\RegionEnum;
|
|||
use phpOMS\Message\Http\HttpHeader;
|
||||
use phpOMS\Stdlib\Base\FloatInt;
|
||||
use phpOMS\Stdlib\Base\SmartDateTime;
|
||||
use phpOMS\System\File\ExtensionType;
|
||||
use phpOMS\System\File\FileUtils;
|
||||
use phpOMS\Uri\UriFactory;
|
||||
|
||||
$countryCodes = ISO3166TwoEnum::getConstants();
|
||||
|
|
@ -48,6 +50,10 @@ $supplierStatus = SupplierStatus::getConstants();
|
|||
|
||||
$monthlySalesCosts = $this->data['monthlySalesCosts'] ?? [];
|
||||
|
||||
// @performance The client, supplier and item views should not use actual tabs but individual pages for better performance
|
||||
// Tabs require too many models to be loaded. Implement and then use a tab navigation if it doesn't already exist.
|
||||
// https://github.com/Karaka-Management/oms-ItemManagement/issues/13
|
||||
|
||||
/**
|
||||
* @var \phpOMS\Views\View $this
|
||||
*/
|
||||
|
|
@ -88,7 +94,10 @@ echo $this->data['nav']->render();
|
|||
<?php endif; ?>
|
||||
|
||||
<section class="portlet">
|
||||
<form id="supplierForm" method="<?= $isNew ? 'PUT' : 'POST'; ?>" action="<?= UriFactory::build('{/api}purchase/supplier?csrf={$CSRF}'); ?>">
|
||||
<form id="supplierForm"
|
||||
method="<?= $isNew ? 'PUT' : 'POST'; ?>"
|
||||
action="<?= UriFactory::build('{/api}supplier?csrf={$CSRF}'); ?>"
|
||||
<?= $isNew ? 'data-redirect="' . UriFactory::build('{/base}/purchase/supplier/view') . '?id={/0/response/id}"' : ''; ?>>
|
||||
<div class="portlet-body">
|
||||
<div class="form-group">
|
||||
<label for="iId"><?= $this->getHtml('ID', '0', '0'); ?></label>
|
||||
|
|
@ -350,8 +359,10 @@ echo $this->data['nav']->render();
|
|||
foreach ($supplier->files as $file) :
|
||||
++$count;
|
||||
$url = UriFactory::build('{/base}/media/view?{?}&id=' . $file->id);
|
||||
$extensionType = FileUtils::getExtensionType($value->extension);
|
||||
?>
|
||||
<tr data-href="<?= $url; ?>">
|
||||
<tr data-href="<?= $url; ?>"
|
||||
<?= \in_array($extensionType, [ExtensionType::IMAGE, ExtensionType::PDF]) ? 'data-preview="' . UriFactory::build('{/api}media/export?id=' . $file->id . '&type=html&csrf={$CSRF}') . '"' : ''; ?>>
|
||||
<td><a href="<?= $url; ?>"><?= $file->name; ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= $file->extension; ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= $file->createdAt->format('Y-m-d'); ?></a>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user