| 123456789101112131415161718192021222324252627282930313233343536 |
- <?php /** @noinspection PhpUnhandledExceptionInspection */
- namespace App;
- use App\Enums\DocumentTypes;
- $core = Core::getInstance();
- $user = $core->getUser();
- $user->requireAdmin();
- $core->addBreadcrumb("/goods-in", __("Goods-In"));
- $nvp = [
- "type" => DocumentTypes::GOODS_IN,
- "dts_deleted" => null
- ];
- $count = Document::count($nvp);
- $pagination = new Pagination($count);
- $pagination->setTerms(__("%s Goods-In"), __("%s Goods-In"));
- $documents = Document::query($nvp, [
- "sort" => "id",
- "order" => "desc",
- "offset" => $pagination->getOffset(),
- "limit" => $pagination->getPageSize()
- ]);
- $core->addScript("/js/new-document-modal.js");
- View::include("header");
- View::include("goods_in", compact("documents", "pagination"));
- View::include("modals/new_document");
- View::include("footer");
|