From 30f26f7fbe8a31b570c435c919b09b1051b76b5c Mon Sep 17 00:00:00 2001 From: ahmad afandi Date: Tue, 26 Aug 2025 15:44:12 +0700 Subject: [PATCH 1/8] Replace akaunting/money with akaunting/laravel-money - Remove akaunting/money ^5.2 (deprecated package) - Add akaunting/laravel-money ^6.0 (recommended replacement) - Package provides better Laravel integration and modern features - Tested: Application runs successfully after package replacement - No breaking changes detected in current codebase Benefits: - Better Laravel 10+ compatibility - Improved performance and features - Active maintenance and support - Follows Laravel best practices --- composer.json | 2 +- composer.lock | 34 ++++++++++++++++------------------ 2 files changed, 17 insertions(+), 19 deletions(-) diff --git a/composer.json b/composer.json index 4ee1d7fe..97115d36 100644 --- a/composer.json +++ b/composer.json @@ -10,7 +10,7 @@ "require": { "php": "^8.1", "akaunting/laravel-apexcharts": "^3.0", - "akaunting/money": "^5.2", + "akaunting/laravel-money": "^6.0", "alexusmai/laravel-file-manager": "^3.0", "bensampo/laravel-enum": "^6.3", "cviebrock/eloquent-sluggable": "^10.0", diff --git a/composer.lock b/composer.lock index e5f9ef57..630df782 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "4e7ee1edfe6896b0c775d0fe454a198b", + "content-hash": "1abfda25a95b394bab4d0e465baf0de2", "packages": [ { "name": "akaunting/laravel-apexcharts", @@ -76,31 +76,31 @@ "time": "2025-04-04T21:02:33+00:00" }, { - "name": "akaunting/money", - "version": "5.2.2", + "name": "akaunting/laravel-money", + "version": "6.0.2", "source": { "type": "git", "url": "https://github.com/akaunting/laravel-money.git", - "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9" + "reference": "5dca81f4297b99f8dbf0f4a6bb4d45c56acbd76a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/akaunting/laravel-money/zipball/d99a9e8e576cac40668d0a5afaf7ea153590aff9", - "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9", + "url": "https://api.github.com/repos/akaunting/laravel-money/zipball/5dca81f4297b99f8dbf0f4a6bb4d45c56acbd76a", + "reference": "5dca81f4297b99f8dbf0f4a6bb4d45c56acbd76a", "shasum": "" }, "require": { - "illuminate/contracts": "^9.0|^10.0|^11.0", - "illuminate/support": "^9.0|^10.0|^11.0", - "illuminate/validation": "^9.0|^10.0|^11.0", - "illuminate/view": "^9.0|^10.0|^11.0", - "php": "^8.0", + "illuminate/contracts": "^10.0|^11.0|^12", + "illuminate/support": "^10.0|^11.0|^12", + "illuminate/validation": "^10.0|^11.0|^12", + "illuminate/view": "^10.0|^11.0|^12", + "php": "^8.2", "vlucas/phpdotenv": "^5.4.1" }, "require-dev": { - "orchestra/testbench": "^7.4|^8.0|^9.0", - "phpunit/phpunit": "^9.5|^10.0|^11.0", - "vimeo/psalm": "^4.23|^5.1" + "orchestra/testbench": "^8.0|^9.0|^10", + "phpunit/phpunit": "^10.5|^11.0", + "vimeo/psalm": "^6.0" }, "type": "library", "extra": { @@ -139,11 +139,9 @@ "money" ], "support": { - "issues": "https://github.com/akaunting/laravel-money/issues", - "source": "https://github.com/akaunting/laravel-money/tree/5.2.2" + "source": "https://github.com/akaunting/laravel-money/tree/6.0.2" }, - "abandoned": "akaunting/laravel-money", - "time": "2024-09-25T10:06:11+00:00" + "time": "2025-02-22T11:28:38+00:00" }, { "name": "alexusmai/laravel-file-manager", From beb682da5d4a7593b9c1aa9d9cb76faf51b1a4e5 Mon Sep 17 00:00:00 2001 From: ahmad afandi Date: Tue, 26 Aug 2025 16:45:12 +0700 Subject: [PATCH 2/8] ganti package --- app/Providers/AppServiceProvider.php | 2 - composer.json | 3 +- composer.lock | 221 +++++--------- config/app.php | 4 +- config/laravel_generator.php | 215 -------------- resources/views/articles/create.blade.php | 24 +- resources/views/articles/edit.blade.php | 22 +- resources/views/articles/fields.blade.php | 24 +- resources/views/articles/index.blade.php | 2 +- .../views/articles/show_fields.blade.php | 13 +- resources/views/categories/create.blade.php | 32 +-- resources/views/categories/edit.blade.php | 30 +- resources/views/categories/fields.blade.php | 10 +- resources/views/categories/index.blade.php | 2 +- .../views/categories/show_fields.blade.php | 6 +- resources/views/common/alerts.blade.php | 35 +++ resources/views/common/errors.blade.php | 9 + resources/views/departments/create.blade.php | 12 +- resources/views/departments/edit.blade.php | 13 +- resources/views/departments/fields.blade.php | 12 +- resources/views/departments/index.blade.php | 2 +- .../views/departments/show_fields.blade.php | 7 +- resources/views/downloads/create.blade.php | 32 +-- resources/views/downloads/edit.blade.php | 30 +- resources/views/downloads/fields.blade.php | 40 +-- resources/views/downloads/index.blade.php | 2 +- resources/views/employees/create.blade.php | 12 +- resources/views/employees/edit.blade.php | 13 +- resources/views/employees/fields.blade.php | 74 +++-- resources/views/employees/index.blade.php | 2 +- .../views/employees/show_fields.blade.php | 19 +- resources/views/group/fields.blade.php | 23 +- resources/views/group/menu.blade.php | 270 +++++++++--------- resources/views/menus/fields.blade.php | 51 +--- resources/views/menus/index.blade.php | 160 +++++------ resources/views/pages/create.blade.php | 24 +- resources/views/pages/edit.blade.php | 22 +- resources/views/pages/fields.blade.php | 20 +- resources/views/pages/index.blade.php | 2 +- resources/views/positions/create.blade.php | 12 +- resources/views/positions/edit.blade.php | 12 +- resources/views/positions/fields.blade.php | 26 +- resources/views/positions/index.blade.php | 2 +- .../views/positions/show_fields.blade.php | 7 +- .../views/riwayat_pengguna/filter.blade.php | 6 +- resources/views/settings/create.blade.php | 32 +-- resources/views/settings/edit.blade.php | 30 +- resources/views/settings/fields.blade.php | 23 +- resources/views/settings/index.blade.php | 2 +- .../views/settings/show_fields.blade.php | 12 +- resources/views/slides/create.blade.php | 32 +-- resources/views/slides/edit.blade.php | 30 +- resources/views/slides/fields.blade.php | 21 +- resources/views/slides/index.blade.php | 2 +- .../templates/fields/boolean.blade.php | 12 - .../templates/fields/checkbox.blade.php | 8 - .../templates/fields/checkbox_group.blade.php | 14 - .../templates/fields/date.blade.php | 15 - .../templates/fields/email.blade.php | 9 - .../templates/fields/file.blade.php | 15 - .../templates/fields/number.blade.php | 9 - .../templates/fields/password.blade.php | 9 - .../templates/fields/radio.blade.php | 3 - .../templates/fields/radio_group.blade.php | 9 - .../templates/fields/select.blade.php | 9 - .../templates/fields/text.blade.php | 9 - .../templates/fields/textarea.blade.php | 9 - .../templates/fields/toggle-switch.blade.php | 11 - .../templates/layouts/menu_template.blade.php | 10 - .../templates/scaffold/create.blade.php | 37 --- .../templates/scaffold/edit.blade.php | 36 --- .../templates/scaffold/index-asli.blade.php | 39 --- .../templates/scaffold/index.blade.php | 174 ----------- .../scaffold/paginate-asli.blade.php | 1 - .../templates/scaffold/paginate.blade.php | 1 - .../templates/scaffold/show.blade.php | 39 --- .../templates/scaffold/show_field.blade.php | 9 - .../scaffold/table/blade/body-asli.blade.php | 44 --- .../scaffold/table/blade/body.blade.php | 19 -- .../scaffold/table/blade/cell.blade.php | 1 - .../scaffold/table/blade/header.blade.php | 1 - .../table/datatable/actions.blade.php | 20 -- .../scaffold/table/datatable/body.blade.php | 12 - .../scaffold/table/datatable/column.blade.php | 5 - .../scaffold/table/livewire/actions.blade.php | 12 - .../scaffold/table/livewire/body.blade.php | 3 - .../templates/users/create.blade.php | 37 --- .../templates/users/edit.blade.php | 37 --- .../templates/users/fields.blade.php | 23 -- .../templates/users/index.blade.php | 38 --- .../templates/users/menu.blade.php | 6 - .../templates/users/show.blade.php | 29 -- .../templates/users/show_fields.blade.php | 11 - .../templates/users/table.blade.php | 32 --- .../api/controller/model/controller.blade.php | 141 --------- .../model/controller_resource.blade.php | 142 --------- .../repository/controller.blade.php | 144 ---------- .../repository/controller_resource.blade.php | 146 ---------- .../api/docs/controller/controller.blade.php | 3 - .../api/docs/controller/destroy.blade.php | 6 - .../api/docs/controller/index.blade.php | 4 - .../api/docs/controller/show.blade.php | 4 - .../api/docs/controller/store.blade.php | 4 - .../api/docs/controller/update.blade.php | 4 - .../api/request/create.blade.php | 31 -- .../api/request/update.blade.php | 33 --- .../api/resource/resource.blade.php | 23 -- .../laravel-generator/api/routes.blade.php | 2 - .../api/test/api_test.blade.php | 84 ------ .../api/test/api_test_trait.blade.php | 36 --- .../laravel-generator/migration.blade.php | 32 --- .../laravel-generator/model/factory.blade.php | 32 --- .../laravel-generator/model/model.blade.php | 37 --- .../model/relationship.blade.php | 4 - .../laravel-generator/model/seeder.blade.php | 20 -- .../repository/repository.blade-asli.php | 25 -- .../repository/repository.blade.php | 44 --- .../repository/repository_test.blade.php | 81 ------ .../scaffold/controller/controller.blade.php | 109 ------- .../controller_repository.blade.php | 119 -------- .../controller/index_method.blade.php | 8 - .../index_method_datatable.blade.php | 4 - .../index_method_livewire.blade.php | 4 - .../index_method_repository-asli.blade.php | 6 - .../index_method_repository.blade.php | 9 - .../messages/delete_success.blade.php | 5 - .../controller/messages/not_found.blade.php | 9 - .../messages/save_success.blade.php | 5 - .../messages/update_success.blade.php | 5 - .../controller/model_not_found.blade.php | 9 - .../scaffold/layouts/datatables_css.blade.php | 3 - .../scaffold/layouts/datatables_js.blade.php | 7 - .../scaffold/request/create.blade.php | 31 -- .../scaffold/request/update.blade.php | 33 --- .../scaffold/routes.blade.php | 2 - .../scaffold/table/datatable.blade.php | 92 ------ .../scaffold/table/livewire.blade.php | 48 ---- .../user/create_user_request.blade.php | 37 --- .../user/update_user_request.blade.php | 38 --- .../scaffold/user/user_controller.blade.php | 148 ---------- ...er_controller_without_repository.blade.php | 148 ---------- .../scaffold/user/user_repository.blade.php | 43 --- .../stubs/app_base_controller.blade.php | 37 --- .../stubs/base_repository.blade.php | 157 ---------- .../transformer/transformer.blade.php | 19 -- resources/views/web/partials/search.blade.php | 12 +- .../views/web/partials/unduhan.blade.php | 13 +- 147 files changed, 759 insertions(+), 4045 deletions(-) delete mode 100644 config/laravel_generator.php create mode 100644 resources/views/common/alerts.blade.php create mode 100644 resources/views/common/errors.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/boolean.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/checkbox.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/checkbox_group.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/date.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/email.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/file.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/number.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/password.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/radio.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/radio_group.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/select.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/text.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/textarea.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/fields/toggle-switch.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/layouts/menu_template.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/create.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/edit.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/index-asli.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/index.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/paginate-asli.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/paginate.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/show.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/show_field.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body-asli.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/cell.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/header.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/actions.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/body.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/column.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/actions.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/body.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/create.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/edit.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/fields.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/index.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/menu.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/show.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/show_fields.blade.php delete mode 100644 resources/views/vendor/adminlte-templates/templates/users/table.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/controller/model/controller.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/controller/model/controller_resource.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/controller/repository/controller.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/controller/repository/controller_resource.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/docs/controller/controller.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/docs/controller/destroy.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/docs/controller/index.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/docs/controller/show.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/docs/controller/store.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/docs/controller/update.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/request/create.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/request/update.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/resource/resource.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/routes.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/test/api_test.blade.php delete mode 100644 resources/views/vendor/laravel-generator/api/test/api_test_trait.blade.php delete mode 100644 resources/views/vendor/laravel-generator/migration.blade.php delete mode 100644 resources/views/vendor/laravel-generator/model/factory.blade.php delete mode 100644 resources/views/vendor/laravel-generator/model/model.blade.php delete mode 100644 resources/views/vendor/laravel-generator/model/relationship.blade.php delete mode 100644 resources/views/vendor/laravel-generator/model/seeder.blade.php delete mode 100644 resources/views/vendor/laravel-generator/repository/repository.blade-asli.php delete mode 100644 resources/views/vendor/laravel-generator/repository/repository.blade.php delete mode 100644 resources/views/vendor/laravel-generator/repository/repository_test.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/controller.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/controller_repository.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/index_method.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/index_method_datatable.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/index_method_livewire.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository-asli.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/messages/delete_success.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/messages/not_found.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/messages/save_success.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/messages/update_success.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/controller/model_not_found.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/layouts/datatables_css.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/layouts/datatables_js.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/request/create.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/request/update.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/routes.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/table/datatable.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/table/livewire.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/user/create_user_request.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/user/update_user_request.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/user/user_controller.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/user/user_controller_without_repository.blade.php delete mode 100644 resources/views/vendor/laravel-generator/scaffold/user/user_repository.blade.php delete mode 100644 resources/views/vendor/laravel-generator/stubs/app_base_controller.blade.php delete mode 100644 resources/views/vendor/laravel-generator/stubs/base_repository.blade.php delete mode 100644 resources/views/vendor/laravel-generator/transformer/transformer.blade.php diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php index 5a60d391..f1a9dc8f 100644 --- a/app/Providers/AppServiceProvider.php +++ b/app/Providers/AppServiceProvider.php @@ -35,8 +35,6 @@ public function boot() { $this->bootHttps(); $this->addValidation(); - // daftarkan manual karena gagal install infyomlabs/adminlte-templates terkendala depedency - View::addNamespace('adminlte-templates', resource_path('views/vendor/adminlte-templates')); $this->addLogQuery(); if (App::runningInConsole()) { diff --git a/composer.json b/composer.json index 97115d36..f86dc06f 100644 --- a/composer.json +++ b/composer.json @@ -10,7 +10,6 @@ "require": { "php": "^8.1", "akaunting/laravel-apexcharts": "^3.0", - "akaunting/laravel-money": "^6.0", "alexusmai/laravel-file-manager": "^3.0", "bensampo/laravel-enum": "^6.3", "cviebrock/eloquent-sluggable": "^10.0", @@ -23,7 +22,6 @@ "laravel/sanctum": "^3.3", "laravel/tinker": "^2.8", "laravel/ui": "^4.2", - "laravelcollective/html": "^6.4", "league/flysystem-ftp": "^3.10", "openspout/openspout": "^4.24", "proengsoft/laravel-jsvalidation": "^4.8", @@ -31,6 +29,7 @@ "spatie/laravel-activitylog": "^4.7", "spatie/laravel-csp": "^2.8", "spatie/laravel-fractal": "^6.0", + "spatie/laravel-html": "^3.12", "spatie/laravel-json-api-paginate": "^1.13", "spatie/laravel-permission": "^6.4", "spatie/laravel-query-builder": "^5.2", diff --git a/composer.lock b/composer.lock index 630df782..9fc711a9 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "1abfda25a95b394bab4d0e465baf0de2", + "content-hash": "ab01ed8927134d0fdba6477b43c6350b", "packages": [ { "name": "akaunting/laravel-apexcharts", @@ -75,74 +75,6 @@ }, "time": "2025-04-04T21:02:33+00:00" }, - { - "name": "akaunting/laravel-money", - "version": "6.0.2", - "source": { - "type": "git", - "url": "https://github.com/akaunting/laravel-money.git", - "reference": "5dca81f4297b99f8dbf0f4a6bb4d45c56acbd76a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/akaunting/laravel-money/zipball/5dca81f4297b99f8dbf0f4a6bb4d45c56acbd76a", - "reference": "5dca81f4297b99f8dbf0f4a6bb4d45c56acbd76a", - "shasum": "" - }, - "require": { - "illuminate/contracts": "^10.0|^11.0|^12", - "illuminate/support": "^10.0|^11.0|^12", - "illuminate/validation": "^10.0|^11.0|^12", - "illuminate/view": "^10.0|^11.0|^12", - "php": "^8.2", - "vlucas/phpdotenv": "^5.4.1" - }, - "require-dev": { - "orchestra/testbench": "^8.0|^9.0|^10", - "phpunit/phpunit": "^10.5|^11.0", - "vimeo/psalm": "^6.0" - }, - "type": "library", - "extra": { - "laravel": { - "providers": [ - "Akaunting\\Money\\Provider" - ] - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Akaunting\\Money\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Denis Duliçi", - "email": "info@akaunting.com", - "homepage": "https://akaunting.com", - "role": "Developer" - } - ], - "description": "Currency formatting and conversion package for Laravel", - "keywords": [ - "convert", - "currency", - "format", - "laravel", - "money" - ], - "support": { - "source": "https://github.com/akaunting/laravel-money/tree/6.0.2" - }, - "time": "2025-02-22T11:28:38+00:00" - }, { "name": "alexusmai/laravel-file-manager", "version": "v3.1.1", @@ -2947,79 +2879,6 @@ }, "time": "2025-01-28T15:15:29+00:00" }, - { - "name": "laravelcollective/html", - "version": "v6.4.1", - "source": { - "type": "git", - "url": "https://github.com/LaravelCollective/html.git", - "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/LaravelCollective/html/zipball/64ddfdcaeeb8d332bd98bef442bef81e39c3910b", - "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b", - "shasum": "" - }, - "require": { - "illuminate/http": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/routing": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/session": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/view": "^6.0|^7.0|^8.0|^9.0|^10.0", - "php": ">=7.2.5" - }, - "require-dev": { - "illuminate/database": "^6.0|^7.0|^8.0|^9.0|^10.0", - "mockery/mockery": "~1.0", - "phpunit/phpunit": "~8.5|^9.5.10" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "6.x-dev" - }, - "laravel": { - "providers": [ - "Collective\\Html\\HtmlServiceProvider" - ], - "aliases": { - "Form": "Collective\\Html\\FormFacade", - "Html": "Collective\\Html\\HtmlFacade" - } - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Collective\\Html\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Adam Engebretson", - "email": "adam@laravelcollective.com" - }, - { - "name": "Taylor Otwell", - "email": "taylorotwell@gmail.com" - } - ], - "description": "HTML and Form Builders for the Laravel Framework", - "homepage": "https://laravelcollective.com", - "support": { - "issues": "https://github.com/LaravelCollective/html/issues", - "source": "https://github.com/LaravelCollective/html" - }, - "abandoned": "spatie/laravel-html", - "time": "2023-04-25T02:46:11+00:00" - }, { "name": "league/commonmark", "version": "2.7.1", @@ -6010,6 +5869,84 @@ ], "time": "2025-02-14T10:43:50+00:00" }, + { + "name": "spatie/laravel-html", + "version": "3.12.0", + "source": { + "type": "git", + "url": "https://github.com/spatie/laravel-html.git", + "reference": "3655f335609d853f51e431698179ddfe05851126" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/laravel-html/zipball/3655f335609d853f51e431698179ddfe05851126", + "reference": "3655f335609d853f51e431698179ddfe05851126", + "shasum": "" + }, + "require": { + "illuminate/http": "^10.0|^11.0|^12.0", + "illuminate/support": "^10.0|^11.0|^12.0", + "php": "^8.2" + }, + "require-dev": { + "mockery/mockery": "^1.3", + "orchestra/testbench": "^8.0|^9.0|^10.0", + "pestphp/pest": "^2.34|^3.7" + }, + "type": "library", + "extra": { + "laravel": { + "aliases": { + "Html": "Spatie\\Html\\Facades\\Html" + }, + "providers": [ + "Spatie\\Html\\HtmlServiceProvider" + ] + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Spatie\\Html\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Sebastian De Deyne", + "email": "sebastian@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + }, + { + "name": "Freek Van der Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "A fluent html builder", + "homepage": "https://github.com/spatie/laravel-html", + "keywords": [ + "html", + "spatie" + ], + "support": { + "source": "https://github.com/spatie/laravel-html/tree/3.12.0" + }, + "funding": [ + { + "url": "https://spatie.be/open-source/support-us", + "type": "custom" + } + ], + "time": "2025-03-21T08:58:06+00:00" + }, { "name": "spatie/laravel-json-api-paginate", "version": "1.16.3", diff --git a/config/app.php b/config/app.php index 026ad258..45c99bd6 100644 --- a/config/app.php +++ b/config/app.php @@ -199,7 +199,6 @@ /* * Package Service Providers... */ - Collective\Html\HtmlServiceProvider::class, /* * Application Service Providers... @@ -227,8 +226,7 @@ 'aliases' => Facade::defaultAliases()->merge([ // 'ExampleClass' => App\Example\ExampleClass::class, 'Image' => Intervention\Image\Facades\Image::class, - 'Form' => Collective\Html\FormFacade::class, - 'Html' => Collective\Html\HtmlFacade::class, + 'Html' => Spatie\Html\Facades\Html::class, ])->toArray(), 'format' => [ diff --git a/config/laravel_generator.php b/config/laravel_generator.php deleted file mode 100644 index 95428d5c..00000000 --- a/config/laravel_generator.php +++ /dev/null @@ -1,215 +0,0 @@ - [ - - 'migration' => database_path('migrations/'), - - 'model' => app_path('Models/'), - - 'datatables' => app_path('DataTables/'), - - 'livewire_tables' => app_path('Http/Livewire/'), - - 'repository' => app_path('Http/Repository/'), - - 'transformer' => app_path('Http/Transformers/'), - - 'routes' => base_path('routes/web.php'), - - 'api_routes' => base_path('routes/api.php'), - - 'request' => app_path('Http/Requests/'), - - 'api_request' => app_path('Http/Requests/API/'), - - 'controller' => app_path('Http/Controllers/'), - - 'api_controller' => app_path('Http/Controllers/API/'), - - 'api_resource' => app_path('Http/Resources/'), - - 'schema_files' => resource_path('model_schemas/'), - - 'seeder' => database_path('seeders/'), - - 'database_seeder' => database_path('seeders/DatabaseSeeder.php'), - - 'factory' => database_path('factories/'), - - 'view_provider' => app_path('Providers/ViewServiceProvider.php'), - - 'tests' => base_path('tests/'), - - 'repository_test' => base_path('tests/Repositories/'), - - 'api_test' => base_path('tests/APIs/'), - - 'views' => resource_path('views/'), - - 'menu_file' => resource_path('views/layouts/menu.blade.php'), - ], - - /* - |-------------------------------------------------------------------------- - | Namespaces - |-------------------------------------------------------------------------- - | - */ - - 'namespace' => [ - - 'model' => 'App\Models', - - 'datatables' => 'App\DataTables', - - 'livewire_tables' => 'App\Http\Livewire', - - 'repository' => 'App\Http\Repository', - - 'transformer' => 'App\Http\Transformers', - - 'controller' => 'App\Http\Controllers', - - 'api_controller' => 'App\Http\Controllers\API', - - 'api_resource' => 'App\Http\Resources', - - 'request' => 'App\Http\Requests', - - 'api_request' => 'App\Http\Requests\API', - - 'seeder' => 'Database\Seeders', - - 'factory' => 'Database\Factories', - - 'tests' => 'Tests', - - 'repository_test' => 'Tests\Repositories', - - 'api_test' => 'Tests\APIs', - ], - - /* - |-------------------------------------------------------------------------- - | Templates - |-------------------------------------------------------------------------- - | - */ - - 'templates' => 'adminlte-templates', - - /* - |-------------------------------------------------------------------------- - | Model extend class - |-------------------------------------------------------------------------- - | - */ - - 'model_extend_class' => 'Illuminate\Database\Eloquent\Model', - - /* - |-------------------------------------------------------------------------- - | API routes prefix & version - |-------------------------------------------------------------------------- - | - */ - - 'api_prefix' => 'api', - - /* - |-------------------------------------------------------------------------- - | Options - |-------------------------------------------------------------------------- - | - */ - - 'options' => [ - - 'soft_delete' => true, - - 'save_schema_file' => false, - - 'localized' => false, - - 'repository_pattern' => true, - - 'resources' => false, - - 'factory' => false, - - 'seeder' => false, - - 'swagger' => false, // generate swagger for your APIs - - 'tests' => false, // generate test cases for your APIs - - 'excluded_fields' => ['id'], // Array of columns that doesn't required while creating module - ], - - /* - |-------------------------------------------------------------------------- - | Prefixes - |-------------------------------------------------------------------------- - | - */ - - 'prefixes' => [ - - 'route' => '', // e.g. admin or admin.shipping or admin.shipping.logistics - - 'namespace' => '', // e.g. Admin or Admin\Shipping or Admin\Shipping\Logistics - - 'view' => '', // e.g. admin or admin/shipping or admin/shipping/logistics - ], - - /* - |-------------------------------------------------------------------------- - | Table Types - | - | Possible Options: blade, datatables, livewire - |-------------------------------------------------------------------------- - | - */ - - 'tables' => 'blade', - - /* - |-------------------------------------------------------------------------- - | Timestamp Fields - |-------------------------------------------------------------------------- - | - */ - - 'timestamps' => [ - - 'enabled' => true, - - 'created_at' => 'created_at', - - 'updated_at' => 'updated_at', - - 'deleted_at' => 'deleted_at', - ], - - /* - |-------------------------------------------------------------------------- - | Specify custom doctrine mappings as per your need - |-------------------------------------------------------------------------- - | - */ - - 'from_table' => [ - - 'doctrine_mappings' => [], - ], - -]; diff --git a/resources/views/articles/create.blade.php b/resources/views/articles/create.blade.php index 02eb13e4..532d495b 100644 --- a/resources/views/articles/create.blade.php +++ b/resources/views/articles/create.blade.php @@ -8,25 +8,25 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::open(['route' => 'articles.store', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Artikel +
+ {!! Html::form('POST', route('articles.store'))->attribute('enctype', 'multipart/form-data')->open() !!} -
+
-
- @include('articles.fields') -
+
+ @include('articles.fields') +
-
+
- {!! Form::close() !!} + {!! Html::form()->close() !!} +
- @endsection diff --git a/resources/views/articles/edit.blade.php b/resources/views/articles/edit.blade.php index 577894bf..9badd084 100644 --- a/resources/views/articles/edit.blade.php +++ b/resources/views/articles/edit.blade.php @@ -9,23 +9,23 @@
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::model($article, ['route' => ['articles.update', $article->id], 'method' => 'patch', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Artikel +
+ {!! Html::form('PUT', route('articles.update', $article->id))->attribute('enctype', 'multipart/form-data')->bind($article)->open() !!} -
-
- @include('articles.fields') +
+
+ @include('articles.fields') +
-
- {!! Form::close() !!} + {!! Html::form()->close() !!} +
- @endsection diff --git a/resources/views/articles/fields.blade.php b/resources/views/articles/fields.blade.php index 543be995..bbcd2205 100644 --- a/resources/views/articles/fields.blade.php +++ b/resources/views/articles/fields.blade.php @@ -3,14 +3,14 @@
- {!! Form::label('title', 'Judul Artikel') !!} - {!! Form::text('title', null, ['class' => 'form-control', 'required', 'maxlength' => 255]) !!} + {!! Html::label('title', 'Judul Artikel') !!} + {!! Html::text('title')->class('form-control')->required()->maxlength(255)->value(old('title', $article->title ?? null)) !!}
- {!! Form::label('content', 'Isi Artikel') !!} - {!! Form::textarea('content', null, ['class' => 'form-control editor', 'required', 'maxlength' => 65535]) !!} + {!! Html::label('content', 'Isi Artikel') !!} + {!! Html::textarea('content')->class('form-control editor')->required()->maxlength(65535)->value(old('content', $article->content ?? null)) !!}
@@ -21,25 +21,25 @@
- {!! Form::label('category_id', 'Kategori') !!} - {!! Form::select('category_id', $categories, null, ['class' => 'form-control select2', 'required']) !!} + {!! Html::label('category_id', 'Kategori') !!} + {!! Html::select('category_id', $categories)->class('form-control select2')->required()->value(old('category_id', $article->category_id ?? null)) !!}
- {!! Form::label('state', 'Status') !!} - {!! Form::select('state', $stateItem, null, ['class' => 'form-control select2', 'required']) !!} + {!! Html::label('state', 'Status') !!} + {!! Html::select('state', $stateItem)->class('form-control select2')->required()->value(old('state', $article->state ?? null)) !!}
- {!! Form::label('published_at', 'Tanggal Terbit') !!} - {!! Form::text('published_at', $article?->local_published_at , ['class' => 'form-control datepicker','id'=>'published_at']) !!} + {!! Html::label('published_at', 'Tanggal Terbit') !!} + {!! Html::text('published_at')->class('form-control datepicker')->id('published_at')->value(old('published_at', $article?->local_published_at)) !!}
- {!! Form::button(' Batal', ['type' => 'reset', 'class' => 'btn btn-danger btn-sm'] ) !!} - {!! Form::button(' Simpan', ['type' => 'submit', 'class' => 'btn btn-primary btn-sm'] ) !!} + {!! Html::button(' Batal')->type('reset')->class('btn btn-danger btn-sm') !!} + {!! Html::submit(' Simpan')->class('btn btn-primary btn-sm') !!}
diff --git a/resources/views/articles/index.blade.php b/resources/views/articles/index.blade.php index 443a69f6..30763194 100644 --- a/resources/views/articles/index.blade.php +++ b/resources/views/articles/index.blade.php @@ -11,7 +11,7 @@
- @include('adminlte-templates::common.alerts') + @include('common.alerts')
@if($canwrite) diff --git a/resources/views/articles/show_fields.blade.php b/resources/views/articles/show_fields.blade.php index c5193b1e..f628450e 100644 --- a/resources/views/articles/show_fields.blade.php +++ b/resources/views/articles/show_fields.blade.php @@ -1,36 +1,35 @@
- {!! Form::label('category_id', 'Category Id:') !!} + {!! Html::label('category_id', 'Category Id:') !!}

{{ $article->category_id }}

- {!! Form::label('published_at', 'Published At:') !!} + {!! Html::label('published_at', 'Published At:') !!}

{{ $article->published_at }}

- {!! Form::label('slug', 'Slug:') !!} + {!! Html::label('slug', 'Slug:') !!}

{{ $article->slug }}

- {!! Form::label('title', 'Title:') !!} + {!! Html::label('title', 'Title:') !!}

{{ $article->title }}

- {!! Form::label('description', 'Description:') !!} + {!! Html::label('description', 'Description:') !!}

{{ $article->description }}

- {!! Form::label('content', 'Content:') !!} + {!! Html::label('content', 'Content:') !!}

{{ $article->content }}

- diff --git a/resources/views/categories/create.blade.php b/resources/views/categories/create.blade.php index 0fd9d0c4..e4787cda 100644 --- a/resources/views/categories/create.blade.php +++ b/resources/views/categories/create.blade.php @@ -8,30 +8,30 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::open(['route' => 'categories.store']) !!} +  Kembali ke Daftar Kategori +
+ {!! Html::form('POST', route('categories.store'))->open() !!} -
+
-
- @include('categories.fields') -
+
+ @include('categories.fields') +
-
+
- + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
-
@endsection diff --git a/resources/views/categories/edit.blade.php b/resources/views/categories/edit.blade.php index 281230b6..ab40f400 100644 --- a/resources/views/categories/edit.blade.php +++ b/resources/views/categories/edit.blade.php @@ -9,28 +9,28 @@
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::model($category, ['route' => ['categories.update', $category->id], 'method' => 'patch']) !!} +  Kembali ke Daftar Kategori +
+ {!! Html::form('PUT', route('categories.update', $category->id))->bind($category)->open() !!} -
-
- @include('categories.fields') +
+
+ @include('categories.fields') +
-
- + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
-
@endsection diff --git a/resources/views/categories/fields.blade.php b/resources/views/categories/fields.blade.php index 5cb22695..886fc7df 100644 --- a/resources/views/categories/fields.blade.php +++ b/resources/views/categories/fields.blade.php @@ -1,21 +1,21 @@
- {!! Form::label('name', 'Nama Kategori', ['class' => 'col-3']) !!} + {!! Html::label('name', 'Nama Kategori')->class('col-3') !!}
- {!! Form::text('name', null, ['class' => 'form-control col-9', 'required', 'maxlength' => 255]) !!} + {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
- {!! Form::label('status', 'Tampilkan', ['class' => 'col-3']) !!} + {!! Html::label('status', 'Tampilkan')->class('col-3') !!}
diff --git a/resources/views/categories/index.blade.php b/resources/views/categories/index.blade.php index d041570e..2183870c 100644 --- a/resources/views/categories/index.blade.php +++ b/resources/views/categories/index.blade.php @@ -11,7 +11,7 @@
- @include('adminlte-templates::common.alerts') + @include('common.alerts')
@if($canwrite) diff --git a/resources/views/categories/show_fields.blade.php b/resources/views/categories/show_fields.blade.php index ee43c6af..b8f1f676 100644 --- a/resources/views/categories/show_fields.blade.php +++ b/resources/views/categories/show_fields.blade.php @@ -1,18 +1,18 @@
- {!! Form::label('slug', 'Slug:') !!} + {!! Html::label('slug', 'Slug:') !!}

{{ $category->slug }}

- {!! Form::label('title', 'Title:') !!} + {!! Html::label('title', 'Title:') !!}

{{ $category->title }}

- {!! Form::label('description', 'Description:') !!} + {!! Html::label('description', 'Description:') !!}

{{ $category->description }}

diff --git a/resources/views/common/alerts.blade.php b/resources/views/common/alerts.blade.php new file mode 100644 index 00000000..42350d9d --- /dev/null +++ b/resources/views/common/alerts.blade.php @@ -0,0 +1,35 @@ +@if ($message = Session::get('success')) +
+ + {{ $message }} +
+@endif + +@if ($message = Session::get('error')) +
+ + {{ $message }} +
+@endif + +@if ($message = Session::get('warning')) +
+ + {{ $message }} +
+@endif + +@if ($message = Session::get('info')) +
+ + {{ $message }} +
+@endif + +@if ($message = Session::get('alert')) +
+ +

Pemberitahuan

+

{{ $message }}

+
+@endif diff --git a/resources/views/common/errors.blade.php b/resources/views/common/errors.blade.php new file mode 100644 index 00000000..4a1805c8 --- /dev/null +++ b/resources/views/common/errors.blade.php @@ -0,0 +1,9 @@ +@if (!empty($errors)) + @if ($errors->any()) +
    + @foreach ($errors->all() as $error) +
  • {!! $error !!}
  • + @endforeach +
+ @endif +@endif diff --git a/resources/views/departments/create.blade.php b/resources/views/departments/create.blade.php index 00b6700d..b3d3c186 100644 --- a/resources/views/departments/create.blade.php +++ b/resources/views/departments/create.blade.php @@ -4,13 +4,13 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::open(['route' => 'departments.store']) !!} + {!! Html::form('POST', route('departments.store'))->open() !!}
@@ -21,13 +21,11 @@ class="fas fa-arrow-circle-left"> Kembali ke Daftar Department
- {!! Form::close() !!} + {!! Html::form()->close() !!}
diff --git a/resources/views/departments/edit.blade.php b/resources/views/departments/edit.blade.php index 2215619c..e27fcb15 100644 --- a/resources/views/departments/edit.blade.php +++ b/resources/views/departments/edit.blade.php @@ -4,14 +4,13 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::model($department, ['route' => ['departments.update', $department->id], 'method' => 'patch']) - !!} + {!! Html::form('PUT', route('departments.update', $department->id))->bind($department)->open() !!}
@@ -20,13 +19,11 @@ class="fas fa-arrow-circle-left"> Kembali ke Daftar Department
- {!! Form::close() !!} + {!! Html::form()->close() !!}
diff --git a/resources/views/departments/fields.blade.php b/resources/views/departments/fields.blade.php index 9db283e0..fbc56def 100644 --- a/resources/views/departments/fields.blade.php +++ b/resources/views/departments/fields.blade.php @@ -1,19 +1,19 @@
- {!! Form::label('name', 'Nama:') !!} - {!! Form::text('name', null, ['class' => 'form-control', 'required', 'maxlength' => 50, 'maxlength' => 50]) !!} + {!! Html::label('name', 'Nama:') !!} + {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
- {!! Form::label('description', 'Deskripsi:') !!} - {!! Form::text('description', null, ['class' => 'form-control', 'required', 'maxlength' => 255, 'maxlength' => 255]) !!} + {!! Html::label('description', 'Deskripsi:') !!} + {!! Html::text('description')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
- {!! Form::label('parent_id', 'Dibawah Departemen:') !!} - {!! Form::select('parent_id', $parents, null, ['class' => 'form-control select2']) !!} + {!! Html::label('parent_id', 'Dibawah Departemen:') !!} + {!! Html::select('parent_id', $parents)->class('form-control select2') !!}
diff --git a/resources/views/departments/index.blade.php b/resources/views/departments/index.blade.php index 3ac517d3..34834ddf 100644 --- a/resources/views/departments/index.blade.php +++ b/resources/views/departments/index.blade.php @@ -6,7 +6,7 @@
- @include('adminlte-templates::common.alerts') + @include('common.alerts')
@if($canwrite) diff --git a/resources/views/departments/show_fields.blade.php b/resources/views/departments/show_fields.blade.php index b92b921e..05475b65 100644 --- a/resources/views/departments/show_fields.blade.php +++ b/resources/views/departments/show_fields.blade.php @@ -1,18 +1,17 @@
- {!! Form::label('name', 'Name:') !!} + {!! Html::label('name', 'Name:') !!}

{{ $department->name }}

- {!! Form::label('description', 'Description:') !!} + {!! Html::label('description', 'Description:') !!}

{{ $department->description }}

- {!! Form::label('parent_id', 'Parent Id:') !!} + {!! Html::label('parent_id', 'Parent Id:') !!}

{{ $department->parent_id }}

- diff --git a/resources/views/downloads/create.blade.php b/resources/views/downloads/create.blade.php index 56e55e89..d7e4ecf3 100644 --- a/resources/views/downloads/create.blade.php +++ b/resources/views/downloads/create.blade.php @@ -8,32 +8,32 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::open(['route' => 'downloads.store', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Unduhan +
+ {!! Html::form('POST', route('downloads.store'))->attribute('enctype', 'multipart/form-data')->open() !!} -
+
-
- @include('downloads.fields') -
+
+ @include('downloads.fields') +
-
+
- + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
-
@endsection @section('js') {!! JsValidator::formRequest('App\Http\Requests\CreateDownloadRequest') !!} diff --git a/resources/views/downloads/edit.blade.php b/resources/views/downloads/edit.blade.php index 1eb31d0a..39fdf42c 100644 --- a/resources/views/downloads/edit.blade.php +++ b/resources/views/downloads/edit.blade.php @@ -9,30 +9,30 @@
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::model($download, ['route' => ['downloads.update', $download->id, 'enctype' => 'multipart/form-data'], 'method' => 'patch']) !!} +  Kembali ke Daftar Unduhan +
+ {!! Html::form('PUT', route('downloads.update', $download->id))->attribute('enctype', 'multipart/form-data')->bind($download)->open() !!} -
-
- @include('downloads.fields') +
+
+ @include('downloads.fields') +
-
- + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
-
@endsection @section('js') {!! JsValidator::formRequest('App\Http\Requests\UpdateDownloadRequest') !!} diff --git a/resources/views/downloads/fields.blade.php b/resources/views/downloads/fields.blade.php index b0da4df1..9c537faa 100644 --- a/resources/views/downloads/fields.blade.php +++ b/resources/views/downloads/fields.blade.php @@ -1,19 +1,20 @@
- {!! Form::label('title', 'Judul', ['class' => 'col-3']) !!} + {!! Html::label('title', 'Judul')->class('col-3') !!}
- {!! Form::text('title', null, ['class' => 'form-control', 'required', 'maxlength' => 255]) !!} + {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
- {!! Form::label('url', 'Berkas', ['class' => 'col-3']) !!} + {!! Html::label('url', 'Berkas')->class('col-3') !!}
- +
@if (isset($download)) @@ -26,32 +27,31 @@
- {!! Form::label('description', 'Keterangan', ['class' => 'col-3']) !!} + {!! Html::label('description', 'Keterangan')->class('col-3') !!}
- {!! Form::textarea('description', null, ['class' => 'form-control', 'rows' =>3 , 'maxlength' => 65535]) !!} + {!! Html::textarea('description')->class('form-control')->attribute('rows', 3)->attribute('maxlength', 65535) !!}
- {!! Form::label('state', 'Status', ['class' => 'col-3']) !!} + {!! Html::label('state', 'Status')->class('col-3') !!}
- {!! Form::select('state', $stateItem, null, ['class' => 'form-control select2', 'required']) !!} + {!! Html::select('state', $stateItem)->class('form-control select2')->attribute('required') !!}
@push('js') @endpush diff --git a/resources/views/downloads/index.blade.php b/resources/views/downloads/index.blade.php index ccfedc44..b537cca6 100644 --- a/resources/views/downloads/index.blade.php +++ b/resources/views/downloads/index.blade.php @@ -11,7 +11,7 @@
- @include('adminlte-templates::common.alerts') + @include('common.alerts')
@if($canwrite) diff --git a/resources/views/employees/create.blade.php b/resources/views/employees/create.blade.php index 682857b7..f18f08cd 100644 --- a/resources/views/employees/create.blade.php +++ b/resources/views/employees/create.blade.php @@ -4,13 +4,13 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::open(['route' => 'employees.store', 'enctype' => 'multipart/form-data']) !!} + {!! Html::form('POST', route('employees.store'))->attribute('enctype', 'multipart/form-data')->open() !!}
@@ -26,13 +26,11 @@ class="fas fa-arrow-circle-left"> Kembali ke Daftar Employee
- {!! Form::close() !!} + {!! Html::form()->close() !!}
diff --git a/resources/views/employees/edit.blade.php b/resources/views/employees/edit.blade.php index 1e5420d4..a1a1ef4b 100644 --- a/resources/views/employees/edit.blade.php +++ b/resources/views/employees/edit.blade.php @@ -4,14 +4,13 @@ @include('partials.breadcrumbs')
- @include('adminlte-templates::common.errors') + @include('common.errors')
- {!! Form::model($employee, ['route' => ['employees.update', $employee->id], 'method' => 'patch', - 'enctype' => 'multipart/form-data']) !!} + {!! Html::form('PUT', route('employees.update', $employee->id))->attribute('enctype', 'multipart/form-data')->bind($employee)->open() !!}
@@ -25,13 +24,11 @@ class="fas fa-arrow-circle-left"> Kembali ke Daftar Employee
- {!! Form::close() !!} + {!! Html::form()->close() !!}
diff --git a/resources/views/employees/fields.blade.php b/resources/views/employees/fields.blade.php index 8887b68f..85e68132 100644 --- a/resources/views/employees/fields.blade.php +++ b/resources/views/employees/fields.blade.php @@ -1,46 +1,88 @@ - -
- {!! Form::label('name', 'Nama:') !!} - {!! Form::text('name', null, ['class' => 'form-control', 'required', 'maxlength' => 50, 'maxlength' => 50]) !!} + +
+ {!! Html::label('name', 'Nama:') !!} + {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} +
+ +@push('page_scripts') + +@endpush + + +
+ {!! Html::label('identity_number', 'NIP:') !!} + {!! Html::text('identity_number')->class('form-control')->attribute('maxlength', 20) !!} +
+ + +
+ {!! Html::label('email', 'Email:') !!} + {!! Html::email('email')->class('form-control')->attribute('maxlength', 255) !!} +
+ + +
+ {!! Html::label('description', 'Deskripsi:') !!} + {!! Html::text('description')->class('form-control')->attribute('maxlength', 255) !!} +
+ + +
+ {!! Html::label('phone', 'Telepon:') !!} + {!! Html::text('phone')->class('form-control')->attribute('maxlength', 20) !!} +
+ + +
+ {!! Html::label('position_id', 'Jabatan:') !!} + {!! Html::select('position_id', $positions)->class('form-control select2') !!} +
+ + +
+ {!! Html::label('department_id', 'Departemen:') !!} + {!! Html::select('department_id', $departments)->class('form-control select2') !!}
- {!! Form::label('identity_number', 'NIP:') !!} - {!! Form::text('identity_number', null, ['class' => 'form-control', 'maxlength' => 20, 'maxlength' => 20]) !!} + {!! Html::label('identity_number', 'NIP:') !!} + {!! Html::text('identity_number')->class('form-control')->attribute('maxlength', 20) !!}
- {!! Form::label('email', 'Email:') !!} - {!! Form::email('email', null, ['class' => 'form-control', 'maxlength' => 255, 'maxlength' => 255]) !!} + {!! Html::label('email', 'Email:') !!} + {!! Html::email('email')->class('form-control')->attribute('maxlength', 255) !!}
- {!! Form::label('description', 'Deskripsi:') !!} - {!! Form::text('description', null, ['class' => 'form-control', 'maxlength' => 255, 'maxlength' => 255]) !!} + {!! Html::label('description', 'Deskripsi:') !!} + {!! Html::text('description')->class('form-control')->attribute('maxlength', 255) !!}
- {!! Form::label('phone', 'Telepon:') !!} - {!! Form::text('phone', null, ['class' => 'form-control', 'maxlength' => 20, 'maxlength' => 20]) !!} + {!! Html::label('phone', 'Telepon:') !!} + {!! Html::text('phone')->class('form-control')->attribute('maxlength', 20) !!}
- {!! Form::label('position_id', 'Jabatan:') !!} - {!! Form::select('position_id', $positions, null, ['class' => 'form-control select2']) !!} + {!! Html::label('position_id', 'Jabatan:') !!} + {!! Html::select('position_id', $positions)->class('form-control select2') !!}
- {!! Form::label('department_id', 'Departemen:') !!} - {!! Form::select('department_id', $departments, null, ['class' => 'form-control select2']) !!} + {!! Html::label('department_id', 'Departemen:') !!} + {!! Html::select('department_id', $departments)->class('form-control select2') !!}
diff --git a/resources/views/employees/index.blade.php b/resources/views/employees/index.blade.php index b1fd352b..beb872ed 100644 --- a/resources/views/employees/index.blade.php +++ b/resources/views/employees/index.blade.php @@ -6,7 +6,7 @@
- @include('adminlte-templates::common.alerts') + @include('common.alerts')
@if ($canwrite) diff --git a/resources/views/employees/show_fields.blade.php b/resources/views/employees/show_fields.blade.php index 79243050..65dc635c 100644 --- a/resources/views/employees/show_fields.blade.php +++ b/resources/views/employees/show_fields.blade.php @@ -1,54 +1,53 @@
- {!! Form::label('name', 'Name:') !!} + {!! Html::label('name', 'Name:') !!}

{{ $employee->name }}

- {!! Form::label('identity_number', 'Identity Number:') !!} + {!! Html::label('identity_number', 'Identity Number:') !!}

{{ $employee->identity_number }}

- {!! Form::label('email', 'Email:') !!} + {!! Html::label('email', 'Email:') !!}

{{ $employee->email }}

- {!! Form::label('description', 'Description:') !!} + {!! Html::label('description', 'Description:') !!}

{{ $employee->description }}

- {!! Form::label('phone', 'Phone:') !!} + {!! Html::label('phone', 'Phone:') !!}

{{ $employee->phone }}

- {!! Form::label('foto', 'Foto:') !!} + {!! Html::label('foto', 'Foto:') !!}

{{ $employee->foto }}

- {!! Form::label('position_id', 'Position Id:') !!} + {!! Html::label('position_id', 'Position Id:') !!}

{{ $employee->position_id }}

- {!! Form::label('department_id', 'Department Id:') !!} + {!! Html::label('department_id', 'Department Id:') !!}

{{ $employee->department_id }}

- {!! Form::label('user_id', 'User Id:') !!} + {!! Html::label('user_id', 'User Id:') !!}

{{ $employee->user_id }}

- diff --git a/resources/views/group/fields.blade.php b/resources/views/group/fields.blade.php index 879e3eb9..2469ebac 100644 --- a/resources/views/group/fields.blade.php +++ b/resources/views/group/fields.blade.php @@ -1,17 +1,13 @@
- {!! Form::text('text', null, [ - 'class' => 'form-control item-menu', - 'maxlength' => 255, - 'placeholder' => 'Nama Menu', - ]) !!}
+ {!! Html::text('text')->class('form-control item-menu')->attribute('maxlength', 255)->attribute('placeholder', 'Nama Menu') !!}
- {!! Form::select( + {!! Html::select( 'icon', [ '' => 'Select Icon', // Pilihan kosong di awal @@ -57,18 +53,17 @@ 'fas fa-shopping-cart' => 'Shopping Cart', ], '', - ['class' => 'form-control item-menu'], - ) !!} + )->class('form-control item-menu') !!}
@@ -76,12 +71,8 @@
- {!! Form::select('sourcelist', [], null, ['class' => 'form-control']) !!} - {!! Form::text('href', null, [ - 'class' => 'form-control item-menu', - 'maxlength' => 255, - 'placeholder' => 'http://contoh.com', - ]) !!} + {!! Html::select('sourcelist', [])->class('form-control') !!} + {!! Html::text('href')->class('form-control item-menu')->attribute('maxlength', 255)->attribute('placeholder', 'http://contoh.com') !!}
diff --git a/resources/views/group/menu.blade.php b/resources/views/group/menu.blade.php index 3e4c91a3..d02a4a0c 100644 --- a/resources/views/group/menu.blade.php +++ b/resources/views/group/menu.blade.php @@ -1,9 +1,9 @@
-
-
-
- {!! Form::open(['id' => 'frmEdit']) !!} +
+
+
+ {!! Html::form()->id('frmEdit')->open() !!}
@@ -12,12 +12,10 @@ @include('group.fields')
@if ($canwrite) - + @endif
@@ -27,21 +25,19 @@
    - {!! Form::textarea('json_menu', null, ['hidden', 'rows' => 1]) !!} + {!! Html::textarea('json_menu')->attribute('hidden')->attribute('rows', 1) !!}
    @if ($canwrite) - + @endif
    -
    - {!! Form::close() !!} +
    + {!! Html::form()->close() !!}
    @@ -49,138 +45,138 @@
    @push('js') - - - + + + $('button.reload').click(function() { + window.location.reload() + }) + } + return { + retrieveData, + buildEditor + } + } + @endpush diff --git a/resources/views/menus/fields.blade.php b/resources/views/menus/fields.blade.php index f52934eb..43514930 100644 --- a/resources/views/menus/fields.blade.php +++ b/resources/views/menus/fields.blade.php @@ -1,15 +1,11 @@
    - {!! Form::select('menu_type', ['1' => 'Default', '2' => 'Presisi'], '1', ['class' => 'form-control']) !!}
    - {!! Form::text('text', null, [ - 'class' => 'form-control item-menu', - 'maxlength' => 255, - 'placeholder' => 'Nama Menu', - ]) !!}
    + {!! Html::select('menu_type', ['1' => 'Default', '2' => 'Presisi'], '1')->class('form-control') !!}
    + {!! Html::text('text')->class('form-control item-menu')->attribute('maxlength', 255)->attribute('placeholder', 'Nama Menu') !!}
    - {!! Form::select( + {!! Html::select( 'icon', [ '' => 'Select Icon', // Pilihan kosong di awal @@ -55,8 +51,7 @@ 'fas fa-shopping-cart' => 'Shopping Cart', ], '', - ['class' => 'form-control item-menu'], - ) !!} + )->class('form-control item-menu') !!}
    @@ -64,16 +59,16 @@
    @@ -81,34 +76,18 @@
    - {!! Form::select('sourcelist', $sourceItem, null, ['class' => 'form-control']) !!} - {!! Form::text('href', null, [ - 'class' => 'form-control item-menu', - 'maxlength' => 255, - 'placeholder' => 'http://contoh.com', - ]) !!} + {!! Html::select('sourcelist', $sourceItem)->class('form-control') !!} + {!! Html::text('href')->class('form-control item-menu')->attribute('maxlength', 255)->attribute('placeholder', 'http://contoh.com') !!}
    - {!! Form::select('penduduk', $sourceItem['penduduk'], null, [ - 'class' => 'form-control', - 'style' => 'display:none;', - ]) !!} - {!! Form::select('keluarga', $sourceItem['keluarga'], null, [ - 'class' => 'form-control', - 'style' => 'display:none;', - ]) !!} - {!! Form::select('bantuan', $sourceItem['bantuan'], null, [ - 'class' => 'form-control', - 'style' => 'display:none;', - ]) !!} - {!! Form::select('rtm', $sourceItem['rtm'], null, ['class' => 'form-control', 'style' => 'display:none;']) !!} - {!! Form::select('kesehatan', $sourceItem['kesehatan'], null, [ - 'class' => 'form-control', - 'style' => 'display:none;', - ]) !!} + {!! Html::select('penduduk', $sourceItem['penduduk'])->class('form-control')->style('display:none;') !!} + {!! Html::select('keluarga', $sourceItem['keluarga'])->class('form-control')->style('display:none;') !!} + {!! Html::select('bantuan', $sourceItem['bantuan'])->class('form-control')->style('display:none;') !!} + {!! Html::select('rtm', $sourceItem['rtm'])->class('form-control')->style('display:none;') !!} + {!! Html::select('kesehatan', $sourceItem['kesehatan'])->class('form-control')->style('display:none;') !!}
    diff --git a/resources/views/menus/index.blade.php b/resources/views/menus/index.blade.php index 173addbc..c70c0589 100644 --- a/resources/views/menus/index.blade.php +++ b/resources/views/menus/index.blade.php @@ -11,10 +11,10 @@
    - @include('adminlte-templates::common.alerts') + @include('common.alerts')
    - {!! Form::open(['route' => 'menus.store', 'id' => 'frmEdit']) !!} + {!! Html::form('POST', route('menus.store'))->id('frmEdit')->open() !!}
    @@ -23,10 +23,10 @@ @include('menus.fields')
    @if ($canwrite) - + @endif
    @@ -36,19 +36,19 @@
      - {!! Form::textarea('json_menu', null, ['hidden', 'rows' => 1]) !!} + {!! Html::textarea('json_menu')->attribute('hidden')->attribute('rows', 1) !!}
      @if ($canwrite) - + @endif
      - {!! Form::close() !!} + {!! Html::form()->close() !!}
      @@ -57,79 +57,79 @@ @endsection @section('js') - - - + + @endsection diff --git a/resources/views/pages/create.blade.php b/resources/views/pages/create.blade.php index e81d2746..51070af2 100644 --- a/resources/views/pages/create.blade.php +++ b/resources/views/pages/create.blade.php @@ -8,25 +8,25 @@ @include('partials.breadcrumbs')
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::open(['route' => 'pages.store', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Halaman +
      + {!! Html::form('POST', route('pages.store'))->attribute('enctype', 'multipart/form-data')->open() !!} -
      +
      -
      - @include('pages.fields') -
      +
      + @include('pages.fields') +
      -
      +
      - {!! Form::close() !!} + {!! Html::form()->close() !!} +
      -
      @endsection diff --git a/resources/views/pages/edit.blade.php b/resources/views/pages/edit.blade.php index 7b430f11..77057e2a 100644 --- a/resources/views/pages/edit.blade.php +++ b/resources/views/pages/edit.blade.php @@ -9,23 +9,23 @@
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::model($page, ['route' => ['pages.update', $page->id], 'method' => 'patch', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Halaman +
      + {!! Html::form('PUT', route('pages.update', $page->id))->attribute('enctype', 'multipart/form-data')->bind($page)->open() !!} -
      -
      - @include('pages.fields') +
      +
      + @include('pages.fields') +
      -
      - {!! Form::close() !!} + {!! Html::form()->close() !!} +
      -
      @endsection diff --git a/resources/views/pages/fields.blade.php b/resources/views/pages/fields.blade.php index ec951bdf..40d70596 100644 --- a/resources/views/pages/fields.blade.php +++ b/resources/views/pages/fields.blade.php @@ -2,14 +2,14 @@
      - {!! Form::label('title', 'Judul') !!} - {!! Form::text('title', null, ['class' => 'form-control', 'required', 'maxlength' => 200]) !!} + {!! Html::label('title', 'Judul') !!} + {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 200) !!}
      - {!! Form::label('content', 'Isi') !!} - {!! Form::textarea('content', null, ['class' => 'form-control editor', 'required', 'maxlength' => 65535]) !!} + {!! Html::label('content', 'Isi') !!} + {!! Html::textarea('content')->class('form-control editor')->attribute('required')->attribute('maxlength', 65535) !!}
      @@ -20,19 +20,19 @@
      - {!! Form::label('published_at', 'Tanggal Posting') !!} - {!! Form::text('published_at', $page?->local_published_at ?? null, ['class' => 'form-control datepicker','id'=>'published_at', 'required']) !!} + {!! Html::label('published_at', 'Tanggal Posting') !!} + {!! Html::text('published_at', $page?->local_published_at ?? null)->class('form-control datepicker')->id('published_at')->attribute('required') !!}
      - {!! Form::label('state', 'Status') !!} - {!! Form::select('state', $stateItem, null, ['class' => 'form-control select2', 'required']) !!} + {!! Html::label('state', 'Status') !!} + {!! Html::select('state', $stateItem)->class('form-control select2')->attribute('required') !!}
      - {!! Form::button(' Batal', ['type' => 'reset', 'class' => 'btn btn-danger btn-sm'] ) !!} - {!! Form::button(' Simpan', ['type' => 'submit', 'class' => 'btn btn-primary btn-sm'] ) !!} + {!! Html::button(' Batal')->type('reset')->class('btn btn-danger btn-sm') !!} + {!! Html::button(' Simpan')->type('submit')->class('btn btn-primary btn-sm') !!}
      diff --git a/resources/views/pages/index.blade.php b/resources/views/pages/index.blade.php index b600b4ad..242e42b4 100644 --- a/resources/views/pages/index.blade.php +++ b/resources/views/pages/index.blade.php @@ -11,7 +11,7 @@
      - @include('adminlte-templates::common.alerts') + @include('common.alerts')
      @if($canwrite) diff --git a/resources/views/positions/create.blade.php b/resources/views/positions/create.blade.php index 3ec09291..0ea19e04 100644 --- a/resources/views/positions/create.blade.php +++ b/resources/views/positions/create.blade.php @@ -4,13 +4,13 @@ @include('partials.breadcrumbs')
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::open(['route' => 'positions.store']) !!} + {!! Html::form('POST', route('positions.store'))->open() !!}
      @@ -21,13 +21,11 @@ class="fas fa-arrow-circle-left"> Kembali ke Daftar Position
      - {!! Form::close() !!} + {!! Html::form()->close() !!}
      diff --git a/resources/views/positions/edit.blade.php b/resources/views/positions/edit.blade.php index 7a523e6a..286cf420 100644 --- a/resources/views/positions/edit.blade.php +++ b/resources/views/positions/edit.blade.php @@ -4,13 +4,13 @@ @include('partials.breadcrumbs')
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::model($position, ['route' => ['positions.update', $position->id], 'method' => 'patch']) !!} + {!! Html::form('PUT', route('positions.update', $position->id))->bind($position)->open() !!}
      @@ -19,13 +19,11 @@ class="fas fa-arrow-circle-left"> Kembali ke Daftar Position
      - {!! Form::close() !!} + {!! Html::form()->close() !!}
      diff --git a/resources/views/positions/fields.blade.php b/resources/views/positions/fields.blade.php index ceb0dbae..2d7580c7 100644 --- a/resources/views/positions/fields.blade.php +++ b/resources/views/positions/fields.blade.php @@ -1,19 +1,23 @@ - -
      - {!! Form::label('name', 'Nama:') !!} - {!! Form::text('name', null, ['class' => 'form-control', 'required', 'maxlength' => 50, 'maxlength' => 50]) !!} + +
      + {!! Html::label('name', 'Nama:') !!} + {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      +@push('page_scripts') + +@endpush -
      - {!! Form::label('description', 'Deskripsi:') !!} - {!! Form::text('description', null, ['class' => 'form-control', 'required', 'maxlength' => 255, 'maxlength' => 255]) !!} +
      + {!! Html::label('description', 'Deskripsi:') !!} + {!! Html::text('description')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      - -
      - {!! Form::label('parent_id', 'Jabatan Atasan:') !!} - {!! Form::select('parent_id', $parents, null, ['class' => 'form-control select2']) !!} +
      + {!! Html::label('parent_id', 'Jabatan Atasan:') !!} + {!! Html::select('parent_id', $parents)->class('form-control select2') !!}
      diff --git a/resources/views/positions/index.blade.php b/resources/views/positions/index.blade.php index 2c1b86ba..5747574f 100644 --- a/resources/views/positions/index.blade.php +++ b/resources/views/positions/index.blade.php @@ -6,7 +6,7 @@
      - @include('adminlte-templates::common.alerts') + @include('common.alerts')
      @if ($canwrite) diff --git a/resources/views/positions/show_fields.blade.php b/resources/views/positions/show_fields.blade.php index 8f228094..cfbccacb 100644 --- a/resources/views/positions/show_fields.blade.php +++ b/resources/views/positions/show_fields.blade.php @@ -1,18 +1,17 @@
      - {!! Form::label('name', 'Name:') !!} + {!! Html::label('name', 'Name:') !!}

      {{ $position->name }}

      - {!! Form::label('description', 'Description:') !!} + {!! Html::label('description', 'Description:') !!}

      {{ $position->description }}

      - {!! Form::label('parent_id', 'Parent Id:') !!} + {!! Html::label('parent_id', 'Parent Id:') !!}

      {{ $position->parent_id }}

      - diff --git a/resources/views/riwayat_pengguna/filter.blade.php b/resources/views/riwayat_pengguna/filter.blade.php index 6a669d10..a249a682 100644 --- a/resources/views/riwayat_pengguna/filter.blade.php +++ b/resources/views/riwayat_pengguna/filter.blade.php @@ -6,7 +6,9 @@
      - +
      @@ -15,7 +17,7 @@
      - {{ Form::select('causer_id', $pengguna, null, ['class' => 'select2 form-control width-100']) }} + {{ Html::select('causer_id', $pengguna)->class('select2 form-control width-100') }}
      diff --git a/resources/views/settings/create.blade.php b/resources/views/settings/create.blade.php index e4e01795..cc333ffa 100644 --- a/resources/views/settings/create.blade.php +++ b/resources/views/settings/create.blade.php @@ -8,30 +8,30 @@ @include('partials.breadcrumbs')
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::open(['route' => 'settings.store']) !!} +  Kembali ke Daftar Setting +
      + {!! Html::form('POST', route('settings.store'))->open() !!} -
      +
      -
      - @include('settings.fields') -
      +
      + @include('settings.fields') +
      -
      +
      - + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
      -
      @endsection diff --git a/resources/views/settings/edit.blade.php b/resources/views/settings/edit.blade.php index 97b0de5c..b4f5f864 100644 --- a/resources/views/settings/edit.blade.php +++ b/resources/views/settings/edit.blade.php @@ -9,28 +9,28 @@
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::model($setting, ['route' => ['settings.update', $setting->id], 'method' => 'patch']) !!} +  Kembali ke Daftar Setting +
      + {!! Html::form('PUT', route('settings.update', $setting->id))->bind($setting)->open() !!} -
      -
      - @include('settings.fields') +
      +
      + @include('settings.fields') +
      -
      - + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
      -
      @endsection diff --git a/resources/views/settings/fields.blade.php b/resources/views/settings/fields.blade.php index c5a19f09..6fc86969 100644 --- a/resources/views/settings/fields.blade.php +++ b/resources/views/settings/fields.blade.php @@ -1,32 +1,33 @@
      - {!! Form::label('key', 'Kode Kunci:') !!} - {!! Form::text('key', null, ['class' => 'form-control', 'required', 'maxlength' => 50, 'disabled' => 'disabled']) !!} + {!! Html::label('key', 'Kode Kunci:') !!} + {!! Html::text('key')->class('form-control')->attribute('required')->attribute('maxlength', 50)->attribute('disabled') !!}
      - {!! Form::label('name', 'Nama:') !!} - {!! Form::text('name', null, ['class' => 'form-control', 'required', 'maxlength' => 255]) !!} + {!! Html::label('name', 'Nama:') !!} + {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @switch($setting->type) @case('dropdown') - {!! Form::label('value', 'Status:') !!} - {!! Form::select('value', collect($setting->attribute)->pluck('text', 'value'), $setting->value, ['class' => 'form-control', 'required']) !!} - @break + {!! Html::label('value', 'Status:') !!} + {!! Html::select('value', collect($setting->attribute)->pluck('text', 'value'), $setting->value)->class('form-control')->attribute('required') !!} + @break + @default - {!! Form::label('value', 'Nilai:') !!} - {!! Form::text('value', null, ['class' => 'form-control', 'required', 'maxlength' => 255]) !!} + {!! Html::label('value', 'Nilai:') !!} + {!! Html::text('value')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} @endswitch
      - {!! Form::label('description', 'Deskripsi:') !!} - {!! Form::textarea('description', null, ['class' => 'form-control', 'rows' => 3 , 'maxlength' => 255]) !!} + {!! Html::label('description', 'Deskripsi:') !!} + {!! Html::textarea('description')->class('form-control')->attribute('rows', 3)->attribute('maxlength', 255) !!}
      diff --git a/resources/views/settings/index.blade.php b/resources/views/settings/index.blade.php index 3bb69e94..162f1e8e 100644 --- a/resources/views/settings/index.blade.php +++ b/resources/views/settings/index.blade.php @@ -10,7 +10,7 @@
      - @include('adminlte-templates::common.alerts') + @include('common.alerts') @include('settings.opensid') diff --git a/resources/views/settings/show_fields.blade.php b/resources/views/settings/show_fields.blade.php index e2230af1..606b0805 100644 --- a/resources/views/settings/show_fields.blade.php +++ b/resources/views/settings/show_fields.blade.php @@ -1,36 +1,36 @@
      - {!! Form::label('key', 'Key:') !!} + {!! Html::label('key', 'Key:') !!}

      {{ $setting->key }}

      - {!! Form::label('name', 'Name:') !!} + {!! Html::label('name', 'Name:') !!}

      {{ $setting->name }}

      - {!! Form::label('value', 'Value:') !!} + {!! Html::label('value', 'Value:') !!}

      {{ $setting->value }}

      - {!! Form::label('type', 'Type:') !!} + {!! Html::label('type', 'Type:') !!}

      {{ $setting->type }}

      - {!! Form::label('attribute', 'Attribute:') !!} + {!! Html::label('attribute', 'Attribute:') !!}

      {{ $setting->attribute }}

      - {!! Form::label('description', 'Description:') !!} + {!! Html::label('description', 'Description:') !!}

      {{ $setting->description }}

      diff --git a/resources/views/slides/create.blade.php b/resources/views/slides/create.blade.php index 5874feaa..947406e3 100644 --- a/resources/views/slides/create.blade.php +++ b/resources/views/slides/create.blade.php @@ -8,30 +8,30 @@ @include('partials.breadcrumbs')
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::open(['route' => 'slides.store', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Slide +
      + {!! Html::form('POST', route('slides.store'))->attribute('enctype', 'multipart/form-data')->open() !!} -
      +
      -
      - @include('slides.fields') -
      +
      + @include('slides.fields') +
      -
      +
      - + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
      -
      @endsection diff --git a/resources/views/slides/edit.blade.php b/resources/views/slides/edit.blade.php index de3b2715..ded9995f 100644 --- a/resources/views/slides/edit.blade.php +++ b/resources/views/slides/edit.blade.php @@ -9,28 +9,28 @@
      - @include('adminlte-templates::common.errors') + @include('common.errors')
      - {!! Form::model($slide, ['route' => ['slides.update', $slide->id], 'method' => 'patch', 'enctype' => 'multipart/form-data']) !!} +  Kembali ke Daftar Slide +
      + {!! Html::form('PUT', route('slides.update', $slide->id))->attribute('enctype', 'multipart/form-data')->bind($slide)->open() !!} -
      -
      - @include('slides.fields') +
      +
      + @include('slides.fields') +
      -
      - + - {!! Form::close() !!} + {!! Html::form()->close() !!} +
      -
      @endsection diff --git a/resources/views/slides/fields.blade.php b/resources/views/slides/fields.blade.php index 11a7d0bc..f3c6ac61 100644 --- a/resources/views/slides/fields.blade.php +++ b/resources/views/slides/fields.blade.php @@ -1,10 +1,10 @@
      - {!! Form::label('title', 'Judul') !!} + {!! Html::label('title', 'Judul') !!}
      - {!! Form::text('title', null, ['class' => 'form-control', 'required', 'maxlength' => 255]) !!} + {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -12,41 +12,40 @@
      - {!! Form::label('url', 'Url') !!} + {!! Html::label('url', 'Url') !!}
      - {!! Form::text('url', null, ['class' => 'form-control', 'maxlength' => 255]) !!} + {!! Html::text('url')->class('form-control')->attribute('maxlength', 255) !!}
      - {!! Form::label('description', 'Keterangan') !!} + {!! Html::label('description', 'Keterangan') !!}
      - {!! Form::textarea('description', null, ['class' => 'form-control', 'rows' => 4, 'maxlength' => 65535]) - !!} + {!! Html::textarea('description')->class('form-control')->attribute('rows', 4)->attribute('maxlength', 65535) !!}
      - {!! Form::label('state', 'Status', ['class' => 'col-3']) !!} + {!! Html::label('state', 'Status')->class('col-3') !!}
      - {!! Form::label('foto', 'Gambar', ['class' => 'col-3']) !!} + {!! Html::label('foto', 'Gambar')->class('col-3') !!}
      @include('slides.foto') diff --git a/resources/views/slides/index.blade.php b/resources/views/slides/index.blade.php index 81a1beef..4ce1c623 100644 --- a/resources/views/slides/index.blade.php +++ b/resources/views/slides/index.blade.php @@ -11,7 +11,7 @@
      - @include('adminlte-templates::common.alerts') + @include('common.alerts')
      @if($canwrite) diff --git a/resources/views/vendor/adminlte-templates/templates/fields/boolean.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/boolean.blade.php deleted file mode 100644 index 2cfa1aea..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/boolean.blade.php +++ /dev/null @@ -1,12 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/checkbox.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/checkbox.blade.php deleted file mode 100644 index f1c29454..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/checkbox.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - -
      -
      - @{!! Form::hidden('{{ $fieldName }}', 0, ['class' => 'form-check-input']) !!} - @{!! Form::checkbox('{{ $fieldName }}', '{{ $checkboxVal }}', null, ['class' => 'form-check-input']) !!} - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}', ['class' => 'form-check-label']) !!} -
      -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/checkbox_group.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/checkbox_group.blade.php deleted file mode 100644 index fb9fbf74..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/checkbox_group.blade.php +++ /dev/null @@ -1,14 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - {!! $checkboxes !!} -
      \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/fields/date.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/date.blade.php deleted file mode 100644 index fb8464b5..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/date.blade.php +++ /dev/null @@ -1,15 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::text('{{ $fieldName }}', null, ['class' => 'form-control','id'=>'{{ $fieldName }}']) !!} -
      - -@@push('page_scripts') - -@@endpush diff --git a/resources/views/vendor/adminlte-templates/templates/fields/email.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/email.blade.php deleted file mode 100644 index 85e13ae2..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/email.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::email('{{ $fieldName }}', null, ['class' => 'form-control'@php if(isset($options)) { echo htmlspecialchars_decode($options); } @endphp]) !!} -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/file.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/file.blade.php deleted file mode 100644 index 7f8e326f..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/file.blade.php +++ /dev/null @@ -1,15 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif -
      -
      - @{!! Form::file('{{ $fieldName }}', ['class' => 'custom-file-input']) !!} - @{!! Form::label('{{ $fieldName }}', 'Choose file', ['class' => 'custom-file-label']) !!} -
      -
      -
      -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/number.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/number.blade.php deleted file mode 100644 index 3aab413b..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/number.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::number('{{ $fieldName }}', null, ['class' => 'form-control'@php if(isset($options)) { echo htmlspecialchars_decode($options); } @endphp]) !!} -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/password.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/password.blade.php deleted file mode 100644 index e808279d..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/password.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::password('{{ $fieldName }}', ['class' => 'form-control'@php if(isset($options)) { echo htmlspecialchars_decode($options); } @endphp]) !!} -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/radio.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/radio.blade.php deleted file mode 100644 index ccda2397..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/radio.blade.php +++ /dev/null @@ -1,3 +0,0 @@ - diff --git a/resources/views/vendor/adminlte-templates/templates/fields/radio_group.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/radio_group.blade.php deleted file mode 100644 index 91e277e8..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/radio_group.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}'), ['class' => 'form-check-label']) !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}', ['class' => 'form-check-label']) !!} -@endif - {!! $radioButtons !!} -
      \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/fields/select.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/select.blade.php deleted file mode 100644 index f4b33860..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/select.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::select('{{ $fieldName }}', @php echo htmlspecialchars_decode($selectValues) @endphp, null, ['class' => 'form-control custom-select']) !!} -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/text.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/text.blade.php deleted file mode 100644 index bfd7dc37..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/text.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::text('{{ $fieldName }}', null, ['class' => 'form-control'@php if(isset($options)) { echo htmlspecialchars_decode($options); } @endphp]) !!} -
      diff --git a/resources/views/vendor/adminlte-templates/templates/fields/textarea.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/textarea.blade.php deleted file mode 100644 index 7b324c02..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/textarea.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif - @{!! Form::textarea('{{ $fieldName }}', null, ['class' => 'form-control'@php if(isset($options)) { echo htmlspecialchars_decode($options); } @endphp]) !!} -
      \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/fields/toggle-switch.blade.php b/resources/views/vendor/adminlte-templates/templates/fields/toggle-switch.blade.php deleted file mode 100644 index 2f30108a..00000000 --- a/resources/views/vendor/adminlte-templates/templates/fields/toggle-switch.blade.php +++ /dev/null @@ -1,11 +0,0 @@ - -
      -
      - @{!! Form::checkbox('{{ $fieldName }}', 1, null, ['class' => 'custom-control-input']) !!} -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':', ['class' => 'custom-control-label']) !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:', ['class' => 'custom-control-label']) !!} -@endif -
      -
      diff --git a/resources/views/vendor/adminlte-templates/templates/layouts/menu_template.blade.php b/resources/views/vendor/adminlte-templates/templates/layouts/menu_template.blade.php deleted file mode 100644 index f55644d0..00000000 --- a/resources/views/vendor/adminlte-templates/templates/layouts/menu_template.blade.php +++ /dev/null @@ -1,10 +0,0 @@ - diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/create.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/create.blade.php deleted file mode 100644 index 29e9f49e..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/create.blade.php +++ /dev/null @@ -1,37 +0,0 @@ -@@extends('layouts.index') - -@@section('content_header') -

      Tambah {{ $config->modelNames->name }}

      -@@stop - -@@section('content') - @@include('partials.breadcrumbs') -
      -
      - @@include('adminlte-templates::common.errors') -
      - - @{!! Form::open(['route' => '{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.store']) !!} - -
      - -
      - @@include('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.fields') -
      - -
      - - - - @{!! Form::close() !!} - -
      -
      -
      -@@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/edit.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/edit.blade.php deleted file mode 100644 index 98e902c0..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/edit.blade.php +++ /dev/null @@ -1,36 +0,0 @@ -@@extends('layouts.index') - -@@section('content_header') -

      Edit {{ $config->modelNames->name }}

      -@@stop - -@@section('content') - @@include('partials.breadcrumbs') - -
      -
      - @@include('adminlte-templates::common.errors') -
      - - @{!! Form::model(${{ $config->modelNames->camel }}, ['route' => ['{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.update', ${{ $config->modelNames->camel }}->{{ $config->primaryName }}], 'method' => 'patch']) !!} - -
      -
      - @@include('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.fields') -
      -
      - - - - @{!! Form::close() !!} - -
      -
      -
      -@@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/index-asli.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/index-asli.blade.php deleted file mode 100644 index f8b0d85e..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/index-asli.blade.php +++ /dev/null @@ -1,39 +0,0 @@ -@@extends('layouts.index') - -@@section('content') -
      -
      -
      -
      -@if($config->options->localized) -

      @@lang('models/{{ $config->modelNames->camelPlural }}.plural')

      -@else -

      {{ $config->modelNames->humanPlural }}

      -@endif -
      - -
      -
      -
      - -
      - - @@include('flash::message') - -
      - -
      - {!! $table !!} -
      -
      - -@@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/index.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/index.blade.php deleted file mode 100644 index cf4ab304..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/index.blade.php +++ /dev/null @@ -1,174 +0,0 @@ -@@extends('layouts.index') - -@@section('content_header') -

      Data {{ $config->modelNames->name }}

      -@@stop - -@@section('content') - @@include('partials.breadcrumbs') - -
      - -
      -
      - @@include('adminlte-templates::common.alerts') - -
      -
      -
      -@@endsection - -@@section('js') - -@@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/paginate-asli.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/paginate-asli.blade.php deleted file mode 100644 index cce85fe9..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/paginate-asli.blade.php +++ /dev/null @@ -1 +0,0 @@ -@@include('adminlte-templates::common.paginate', ['records' => ${!! $config->modelNames->camelPlural !!}]) diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/paginate.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/paginate.blade.php deleted file mode 100644 index c483c14a..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/paginate.blade.php +++ /dev/null @@ -1 +0,0 @@ -@@include('adminlte-templates::common.paginator', ['paginator' => ${!! $config->modelNames->camelPlural !!}]) diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/show.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/show.blade.php deleted file mode 100644 index 3dd18697..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/show.blade.php +++ /dev/null @@ -1,39 +0,0 @@ -@@extends('layouts.app') - -@@section('content') -
      -
      -
      -
      -

      -@if($config->options->localized) -@@lang('models/{!! $config->modelNames->camelPlural !!}.singular') @@lang('crud.detail') -@else -{{ $config->modelNames->human }} Details -@endif -

      -
      - -
      -
      -
      - -
      -
      -
      -
      - @@include('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.show_fields') -
      -
      -
      -
      -@@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/show_field.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/show_field.blade.php deleted file mode 100644 index 43a0a2dc..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/show_field.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - -
      -@if($config->options->localized) - @{!! Form::label('{{ $fieldName }}', __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}').':') !!} -@else - @{!! Form::label('{{ $fieldName }}', '{{ $fieldTitle }}:') !!} -@endif -

      @{{ ${!! $config->modelNames->camel !!}->{!! $fieldName !!} }}

      -
      \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body-asli.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body-asli.blade.php deleted file mode 100644 index e3967a33..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body-asli.blade.php +++ /dev/null @@ -1,44 +0,0 @@ -
      -
      - - - - {!! $fieldHeaders !!} -@if($config->options->localized) - -@else - -@endif - - - - @@foreach(${{ $config->modelNames->camelPlural }} as ${{ $config->modelNames->camel }}) - - {!! $fieldBody !!} - - - @@endforeach - -
      @lang('crud.action')Action
      - @{!! Form::open(['route' => ['{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.destroy', ${{ $config->modelNames->camel }}->{{ $config->primaryName }}], 'method' => 'delete']) !!} -
      - - - - - - - @{!! Form::button('', ['type' => 'submit', 'class' => 'btn btn-danger btn-xs', 'onclick' => "return confirm('Are you sure?')"]) !!} -
      - @{!! Form::close() !!} -
      -
      - - -
      diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body.blade.php deleted file mode 100644 index b35aa581..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/body.blade.php +++ /dev/null @@ -1,19 +0,0 @@ - -
      - - - - - {!! $fieldHeaders !!} -@if($config->options->localized) - -@else - -@endif - - - - -
      No@lang('crud.action')Aksi
      -
      - diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/cell.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/cell.blade.php deleted file mode 100644 index fa8b1e99..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/cell.blade.php +++ /dev/null @@ -1 +0,0 @@ -@{{ ${!! $modelVariable !!}->{!! $fieldName !!} }} \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/header.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/header.blade.php deleted file mode 100644 index 726343f6..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/blade/header.blade.php +++ /dev/null @@ -1 +0,0 @@ -{!! $fieldTitle !!} \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/actions.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/actions.blade.php deleted file mode 100644 index aca44d29..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/actions.blade.php +++ /dev/null @@ -1,20 +0,0 @@ -@{!! Form::open(['route' => ['{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.destroy', ${{ $config->primaryName }}], 'method' => 'delete']) !!} -
      - - - - - - - @{!! Form::button('', [ - 'type' => 'submit', - 'class' => 'btn btn-danger btn-xs', -@if($config->options->localized) - 'onclick' => "return confirm('Are you sure?')" -@else - 'onclick' => 'return confirm("'.__('crud.are_you_sure').'")' -@endif - - ]) !!} -
      -@{!! Form::close() !!} diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/body.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/body.blade.php deleted file mode 100644 index 8575f98e..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/body.blade.php +++ /dev/null @@ -1,12 +0,0 @@ -@@push('third_party_stylesheets') - @@include('layouts.datatables_css') -@@endpush - -
      - @{!! $dataTable->table(['width' => '100%', 'class' => 'table table-striped table-bordered']) !!} -
      - -@@push('third_party_scripts') - @@include('layouts.datatables_js') - @{!! $dataTable->scripts() !!} -@@endpush diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/column.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/column.blade.php deleted file mode 100644 index 4f46c99d..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/datatable/column.blade.php +++ /dev/null @@ -1,5 +0,0 @@ -@if($config->options->localized) - '{{ $fieldName }}' => new Column(['title' => __('models/{{ $config->modelNames->camelPlural }}.fields.{{ $fieldName }}'), 'data' => '{{ $fieldName }}']) -@else - '{{ $fieldName }}' -@endif \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/actions.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/actions.blade.php deleted file mode 100644 index 0c66a35c..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/actions.blade.php +++ /dev/null @@ -1,12 +0,0 @@ - diff --git a/resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/body.blade.php b/resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/body.blade.php deleted file mode 100644 index ff6826a9..00000000 --- a/resources/views/vendor/adminlte-templates/templates/scaffold/table/livewire/body.blade.php +++ /dev/null @@ -1,3 +0,0 @@ -
      - @@livewire('{{ $config->modelNames->dashedPlural }}-table', []) -
      \ No newline at end of file diff --git a/resources/views/vendor/adminlte-templates/templates/users/create.blade.php b/resources/views/vendor/adminlte-templates/templates/users/create.blade.php deleted file mode 100644 index be044f75..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/create.blade.php +++ /dev/null @@ -1,37 +0,0 @@ -@extends('layouts.app') - -@section('content') -
      -
      -
      -
      -

      Create User

      -
      -
      -
      -
      - -
      - - @include('adminlte-templates::common.errors') - -
      - - {!! Form::open(['route' => 'users.store']) !!} - -
      -
      - @include('users.fields') -
      -
      - - - - {!! Form::close() !!} - -
      -
      -@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/users/edit.blade.php b/resources/views/vendor/adminlte-templates/templates/users/edit.blade.php deleted file mode 100644 index d6ff7515..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/edit.blade.php +++ /dev/null @@ -1,37 +0,0 @@ -@extends('layouts.app') - -@section('content') -
      -
      -
      -
      -

      User

      -
      -
      -
      -
      - -
      - - @include('adminlte-templates::common.errors') - -
      - - {!! Form::model($user, ['route' => ['users.update', $user->id], 'method' => 'patch']) !!} - -
      -
      - @include('users.fields') -
      -
      - - - - {!! Form::close() !!} - -
      -
      -@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/users/fields.blade.php b/resources/views/vendor/adminlte-templates/templates/users/fields.blade.php deleted file mode 100644 index de96b296..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/fields.blade.php +++ /dev/null @@ -1,23 +0,0 @@ - -
      - {!! Form::label('name', 'Name') !!} - {!! Form::text('name', null, ['class' => 'form-control']) !!} -
      - - -
      - {!! Form::label('email', 'Email') !!} - {!! Form::email('email', null, ['class' => 'form-control']) !!} -
      - - -
      - {!! Form::label('password', 'Password') !!} - {!! Form::password('password', ['class' => 'form-control']) !!} -
      - - -
      - {!! Form::label('password', 'Password Confirmation') !!} - {!! Form::password('password_confirmation', ['class' => 'form-control']) !!} -
      diff --git a/resources/views/vendor/adminlte-templates/templates/users/index.blade.php b/resources/views/vendor/adminlte-templates/templates/users/index.blade.php deleted file mode 100644 index d1ccda79..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/index.blade.php +++ /dev/null @@ -1,38 +0,0 @@ -@extends('layouts.app') - -@section('content') -
      -
      -
      -
      -

      Users

      -
      - -
      -
      -
      - -
      - - @include('flash::message') - -
      - -
      -
      - @include('users.table') - - -
      -
      -
      -@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/users/menu.blade.php b/resources/views/vendor/adminlte-templates/templates/users/menu.blade.php deleted file mode 100644 index 34b7eb11..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/menu.blade.php +++ /dev/null @@ -1,6 +0,0 @@ - diff --git a/resources/views/vendor/adminlte-templates/templates/users/show.blade.php b/resources/views/vendor/adminlte-templates/templates/users/show.blade.php deleted file mode 100644 index b51a7fbd..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/show.blade.php +++ /dev/null @@ -1,29 +0,0 @@ -@extends('layouts.app') - -@section('content') -
      -
      -
      -
      -

      Users

      -
      - -
      -
      -
      - -
      -
      -
      -
      - @include('users.show_fields') -
      -
      -
      -
      -@endsection diff --git a/resources/views/vendor/adminlte-templates/templates/users/show_fields.blade.php b/resources/views/vendor/adminlte-templates/templates/users/show_fields.blade.php deleted file mode 100644 index df1049e0..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/show_fields.blade.php +++ /dev/null @@ -1,11 +0,0 @@ - -
      - {!! Form::label('name', 'Name:') !!} -

      {!! $user->name !!}

      -
      - - -
      - {!! Form::label('email', 'Email:') !!} -

      {!! $user->email !!}

      -
      diff --git a/resources/views/vendor/adminlte-templates/templates/users/table.blade.php b/resources/views/vendor/adminlte-templates/templates/users/table.blade.php deleted file mode 100644 index 48ba667a..00000000 --- a/resources/views/vendor/adminlte-templates/templates/users/table.blade.php +++ /dev/null @@ -1,32 +0,0 @@ -
      - - - - - - - - - - @foreach($users as $user) - - - - - - @endforeach - -
      NameEmailAction
      {!! $user->name !!}{!! $user->email !!} - {!! Form::open(['route' => ['users.destroy', $user->id], 'method' => 'delete']) !!} -
      - - - - - - - {!! Form::button('', ['type' => 'submit', 'class' => 'btn btn-danger btn-xs', 'onclick' => "return confirm('Are you sure?')"]) !!} -
      - {!! Form::close() !!} -
      -
      diff --git a/resources/views/vendor/laravel-generator/api/controller/model/controller.blade.php b/resources/views/vendor/laravel-generator/api/controller/model/controller.blade.php deleted file mode 100644 index e96f7a5e..00000000 --- a/resources/views/vendor/laravel-generator/api/controller/model/controller.blade.php +++ /dev/null @@ -1,141 +0,0 @@ -@php - echo "namespaces->apiController }}; - -use {{ $config->namespaces->apiRequest }}\Create{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->apiRequest }}\Update{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use Illuminate\Http\JsonResponse; -use Illuminate\Http\Request; -use {{ $config->namespaces->app }}\Http\Controllers\AppBaseController; - -{!! $docController !!} -class {{ $config->modelNames->name }}APIController extends AppBaseController -{ - {!! $docIndex !!} - public function index(Request $request): JsonResponse - { - $query = {{ $config->modelNames->name }}::query(); - - if ($request->get('skip')) { - $query->skip($request->get('skip')); - } - if ($request->get('limit')) { - $query->limit($request->get('limit')); - } - - ${{ $config->modelNames->camelPlural }} = $query->get(); - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camelPlural }}->toArray(), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.plural')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camelPlural }}->toArray(), '{{ $config->modelNames->humanPlural }} retrieved successfully'); -@endif - } - - {!! $docStore !!} - public function store(Create{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - $input = $request->all(); - - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::create($input); - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camel }}->toArray(), - __('messages.saved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camel }}->toArray(), '{{ $config->modelNames->human }} saved successfully'); -@endif - } - - {!! $docShow !!} - public function show($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camel }}->toArray(), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camel }}->toArray(), '{{ $config->modelNames->human }} retrieved successfully'); -@endif - } - - {!! $docUpdate !!} - public function update($id, Update{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }}->fill($request->all()); - ${{ $config->modelNames->camel }}->save(); - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camel }}->toArray(), - __('messages.updated', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camel }}->toArray(), '{{ $config->modelNames->name }} updated successfully'); -@endif - } - - {!! $docDestroy !!} - public function destroy($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }}->delete(); - -@if($config->options->localized) - return $this->sendResponse( - $id, - __('messages.deleted', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendSuccess('{{ $config->modelNames->human }} deleted successfully'); -@endif - } -} diff --git a/resources/views/vendor/laravel-generator/api/controller/model/controller_resource.blade.php b/resources/views/vendor/laravel-generator/api/controller/model/controller_resource.blade.php deleted file mode 100644 index e90f383b..00000000 --- a/resources/views/vendor/laravel-generator/api/controller/model/controller_resource.blade.php +++ /dev/null @@ -1,142 +0,0 @@ -@php - echo "namespaces->apiController }}; - -use {{ $config->namespaces->apiRequest }}\Create{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->apiRequest }}\Update{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use Illuminate\Http\JsonResponse; -use Illuminate\Http\Request; -use {{ $config->namespaces->app }}\Http\Controllers\AppBaseController; -use {{ $config->namespaces->apiResource }}\{{ $config->modelNames->name }}Resource; - -{!! $docController !!} -class {{ $config->modelNames->name }}APIController extends AppBaseController -{ - {!! $docIndex !!} - public function index(Request $request): JsonResponse - { - $query = {{ $config->modelNames->name }}::query(); - - if ($request->get('skip')) { - $query->skip($request->get('skip')); - } - if ($request->get('limit')) { - $query->limit($request->get('limit')); - } - - ${{ $config->modelNames->camelPlural }} = $query->get(); - -@if($config->options->localized) - return $this->sendResponse( - {{ $config->modelNames->name }}Resource::collection(${{ $config->modelNames->camelPlural }}), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.plural')]) - ); -@else - return $this->sendResponse({{ $config->modelNames->name }}Resource::collection(${{ $config->modelNames->camelPlural }}), '{{ $config->modelNames->humanPlural }} retrieved successfully'); -@endif - } - - {!! $docStore !!} - public function store(Create{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - $input = $request->all(); - - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::create($input); - -@if($config->options->localized) - return $this->sendResponse( - new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), - __('messages.saved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), '{{ $config->modelNames->human }} saved successfully'); -@endif - } - - {!! $docShow !!} - public function show($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - -@if($config->options->localized) - return $this->sendResponse( - new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), '{{ $config->modelNames->human }} retrieved successfully'); -@endif - } - - {!! $docUpdate !!} - public function update($id, Update{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }}->fill($request->all()); - ${{ $config->modelNames->camel }}->save(); - -@if($config->options->localized) - return $this->sendResponse( - new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), - __('messages.updated', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), '{{ $config->modelNames->name }} updated successfully'); -@endif - } - - {!! $docDestroy !!} - public function destroy($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }}->delete(); - -@if($config->options->localized) - return $this->sendResponse( - $id, - __('messages.deleted', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendSuccess('{{ $config->modelNames->human }} deleted successfully'); -@endif - } -} diff --git a/resources/views/vendor/laravel-generator/api/controller/repository/controller.blade.php b/resources/views/vendor/laravel-generator/api/controller/repository/controller.blade.php deleted file mode 100644 index 47df106b..00000000 --- a/resources/views/vendor/laravel-generator/api/controller/repository/controller.blade.php +++ /dev/null @@ -1,144 +0,0 @@ -@php - echo "namespaces->apiController }}; - -use {{ $config->namespaces->apiRequest }}\Create{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->apiRequest }}\Update{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use {{ $config->namespaces->repository }}\{{ $config->modelNames->name }}Repository; -use Illuminate\Http\JsonResponse; -use Illuminate\Http\Request; -use {{ $config->namespaces->app }}\Http\Controllers\AppBaseController; - -{!! $docController !!} -class {{ $config->modelNames->name }}APIController extends AppBaseController -{ - private {{ $config->modelNames->name }}Repository ${{ $config->modelNames->camel }}Repository; - - public function __construct({{ $config->modelNames->name }}Repository ${{ $config->modelNames->camel }}Repo) - { - $this->{{ $config->modelNames->camel }}Repository = ${{ $config->modelNames->camel }}Repo; - } - - {!! $docIndex !!} - public function index(Request $request): JsonResponse - { - ${{ $config->modelNames->camelPlural }} = $this->{{ $config->modelNames->camel }}Repository->all( - $request->except(['skip', 'limit']), - $request->get('skip'), - $request->get('limit') - ); - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camelPlural }}->toArray(), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.plural')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camelPlural }}->toArray(), '{{ $config->modelNames->humanPlural }} retrieved successfully'); -@endif - } - - {!! $docStore !!} - public function store(Create{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - $input = $request->all(); - - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->create($input); - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camel }}->toArray(), - __('messages.saved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camel }}->toArray(), '{{ $config->modelNames->human }} saved successfully'); -@endif - } - - {!! $docShow !!} - public function show($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/$MODEL_NAME_PLURAL_CAMEL$.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camel }}->toArray(), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camel }}->toArray(), '{{ $config->modelNames->human }} retrieved successfully'); -@endif - } - - {!! $docUpdate !!} - public function update($id, Update{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - $input = $request->all(); - - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/$MODEL_NAME_PLURAL_CAMEL$.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->update($input, $id); - -@if($config->options->localized) - return $this->sendResponse( - ${{ $config->modelNames->camel }}->toArray(), - __('messages.updated', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(${{ $config->modelNames->camel }}->toArray(), '{{ $config->modelNames->name }} updated successfully'); -@endif - } - - {!! $docDestroy !!} - public function destroy($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/$MODEL_NAME_PLURAL_CAMEL$.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }}->delete(); - -@if($config->options->localized) - return $this->sendError( - $id, - __('messages.deleted', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendSuccess('{{ $config->modelNames->human }} deleted successfully'); -@endif - } -} diff --git a/resources/views/vendor/laravel-generator/api/controller/repository/controller_resource.blade.php b/resources/views/vendor/laravel-generator/api/controller/repository/controller_resource.blade.php deleted file mode 100644 index 5c7bfca7..00000000 --- a/resources/views/vendor/laravel-generator/api/controller/repository/controller_resource.blade.php +++ /dev/null @@ -1,146 +0,0 @@ -@php - echo "namespaces->apiController }}; - -use {{ $config->namespaces->apiRequest }}\Create{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->apiRequest }}\Update{{ $config->modelNames->name }}APIRequest; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use {{ $config->namespaces->repository }}\{{ $config->modelNames->name }}Repository; -use Illuminate\Http\JsonResponse; -use Illuminate\Http\Request; -use {{ $config->namespaces->app }}\Http\Controllers\AppBaseController; -use {{ $config->namespaces->apiResource }}\{{ $config->modelNames->name }}Resource; - -{!! $docController !!} -class {{ $config->modelNames->name }}APIController extends AppBaseController -{ - /** @var {{ $config->modelNames->name }}Repository */ - private ${{ $config->modelNames->camel }}Repository; - - public function __construct({{ $config->modelNames->name }}Repository ${{ $config->modelNames->camel }}Repo) - { - $this->{{ $config->modelNames->camel }}Repository = ${{ $config->modelNames->camel }}Repo; - } - - {!! $docIndex !!} - public function index(Request $request): JsonResponse - { - ${{ $config->modelNames->camelPlural }} = $this->{{ $config->modelNames->camel }}Repository->all( - $request->except(['skip', 'limit']), - $request->get('skip'), - $request->get('limit') - ); - -@if($config->options->localized) - return $this->sendResponse( - {{ $config->modelNames->name }}Resource::collection(${{ $config->modelNames->camelPlural }}), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.plural')]) - ); -@else - return $this->sendResponse({{ $config->modelNames->name }}Resource::collection(${{ $config->modelNames->camelPlural }}), '{{ $config->modelNames->humanPlural }} retrieved successfully'); -@endif - } - - {!! $docStore !!} - public function store(Create{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - $input = $request->all(); - - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->create($input); - -@if($config->options->localized) - return $this->sendResponse( - new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), - __('messages.saved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), '{{ $config->modelNames->human }} saved successfully'); -@endif - } - - {!! $docShow !!} - public function show($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - -@if($config->options->localized) - return $this->sendResponse( - new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), - __('messages.retrieved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), '{{ $config->modelNames->human }} retrieved successfully'); -@endif - } - - {!! $docUpdate !!} - public function update($id, Update{{ $config->modelNames->name }}APIRequest $request): JsonResponse - { - $input = $request->all(); - - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->update($input, $id); - -@if($config->options->localized) - return $this->sendResponse( - new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), - __('messages.updated', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendResponse(new {{ $config->modelNames->name }}Resource(${{ $config->modelNames->camel }}), '{{ $config->modelNames->name }} updated successfully'); -@endif - } - - {!! $docDestroy !!} - public function destroy($id): JsonResponse - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - return $this->sendError( - __('messages.not_found', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendError('{{ $config->modelNames->human }} not found'); -@endif - } - - ${{ $config->modelNames->camel }}->delete(); - -@if($config->options->localized) - return $this->sendResponse( - $id, - __('messages.deleted', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')]) - ); -@else - return $this->sendSuccess('{{ $config->modelNames->human }} deleted successfully'); -@endif - } -} diff --git a/resources/views/vendor/laravel-generator/api/docs/controller/controller.blade.php b/resources/views/vendor/laravel-generator/api/docs/controller/controller.blade.php deleted file mode 100644 index 5316b6ed..00000000 --- a/resources/views/vendor/laravel-generator/api/docs/controller/controller.blade.php +++ /dev/null @@ -1,3 +0,0 @@ -/** - * Class {{ $config->modelNames->name }}APIController - */ \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/docs/controller/destroy.blade.php b/resources/views/vendor/laravel-generator/api/docs/controller/destroy.blade.php deleted file mode 100644 index 880335f7..00000000 --- a/resources/views/vendor/laravel-generator/api/docs/controller/destroy.blade.php +++ /dev/null @@ -1,6 +0,0 @@ -/** - * Remove the specified {{ $config->modelNames->name }} from storage. - * DELETE /{{ $config->modelNames->dashedPlural }}/{id} - * - * @throws \Exception - */ \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/docs/controller/index.blade.php b/resources/views/vendor/laravel-generator/api/docs/controller/index.blade.php deleted file mode 100644 index a6880427..00000000 --- a/resources/views/vendor/laravel-generator/api/docs/controller/index.blade.php +++ /dev/null @@ -1,4 +0,0 @@ -/** - * Display a listing of the {{ $config->modelNames->plural }}. - * GET|HEAD /{{ $config->modelNames->dashedPlural }} - */ \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/docs/controller/show.blade.php b/resources/views/vendor/laravel-generator/api/docs/controller/show.blade.php deleted file mode 100644 index 89ee701c..00000000 --- a/resources/views/vendor/laravel-generator/api/docs/controller/show.blade.php +++ /dev/null @@ -1,4 +0,0 @@ -/** - * Display the specified {{ $config->modelNames->name }}. - * GET|HEAD /{{ $config->modelNames->dashedPlural }}/{id} - */ \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/docs/controller/store.blade.php b/resources/views/vendor/laravel-generator/api/docs/controller/store.blade.php deleted file mode 100644 index 7126f846..00000000 --- a/resources/views/vendor/laravel-generator/api/docs/controller/store.blade.php +++ /dev/null @@ -1,4 +0,0 @@ -/** - * Store a newly created {{ $config->modelNames->name }} in storage. - * POST /{{ $config->modelNames->dashedPlural }} - */ \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/docs/controller/update.blade.php b/resources/views/vendor/laravel-generator/api/docs/controller/update.blade.php deleted file mode 100644 index d3e413c9..00000000 --- a/resources/views/vendor/laravel-generator/api/docs/controller/update.blade.php +++ /dev/null @@ -1,4 +0,0 @@ -/** - * Update the specified {{ $config->modelNames->name }} in storage. - * PUT/PATCH /{{ $config->modelNames->dashedPlural }}/{id} - */ \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/request/create.blade.php b/resources/views/vendor/laravel-generator/api/request/create.blade.php deleted file mode 100644 index 80e55ad2..00000000 --- a/resources/views/vendor/laravel-generator/api/request/create.blade.php +++ /dev/null @@ -1,31 +0,0 @@ -@php - echo "namespaces->apiRequest }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use InfyOm\Generator\Request\APIRequest; - -class Create{{ $config->modelNames->name }}APIRequest extends APIRequest -{ - /** - * Determine if the user is authorized to make this request. - * - * @return bool - */ - public function authorize() - { - return true; - } - - /** - * Get the validation rules that apply to the request. - * - * @return array - */ - public function rules() - { - return {{ $config->modelNames->name }}::$rules; - } -} diff --git a/resources/views/vendor/laravel-generator/api/request/update.blade.php b/resources/views/vendor/laravel-generator/api/request/update.blade.php deleted file mode 100644 index 24a709d7..00000000 --- a/resources/views/vendor/laravel-generator/api/request/update.blade.php +++ /dev/null @@ -1,33 +0,0 @@ -@php - echo "namespaces->apiRequest }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use InfyOm\Generator\Request\APIRequest; - -class Update{{ $config->modelNames->name }}APIRequest extends APIRequest -{ - /** - * Determine if the user is authorized to make this request. - * - * @return bool - */ - public function authorize() - { - return true; - } - - /** - * Get the validation rules that apply to the request. - * - * @return array - */ - public function rules() - { - $rules = {{ $config->modelNames->name }}::$rules; - {!! $uniqueRules !!} - return $rules; - } -} diff --git a/resources/views/vendor/laravel-generator/api/resource/resource.blade.php b/resources/views/vendor/laravel-generator/api/resource/resource.blade.php deleted file mode 100644 index 114fb7b5..00000000 --- a/resources/views/vendor/laravel-generator/api/resource/resource.blade.php +++ /dev/null @@ -1,23 +0,0 @@ -@php - echo "namespaces->apiResource }}; - -use Illuminate\Http\Resources\Json\JsonResource; - -class {{ $config->modelNames->name }}Resource extends JsonResource -{ - /** - * Transform the resource into an array. - * - * @param \Illuminate\Http\Request $request - * @return array - */ - public function toArray($request) - { - return [ - {!! $fields !!} - ]; - } -} diff --git a/resources/views/vendor/laravel-generator/api/routes.blade.php b/resources/views/vendor/laravel-generator/api/routes.blade.php deleted file mode 100644 index f28696f8..00000000 --- a/resources/views/vendor/laravel-generator/api/routes.blade.php +++ /dev/null @@ -1,2 +0,0 @@ -Route::resource('{{ $config->prefixes->getRoutePrefixWith('/') }}{{ $config->modelNames->dashedPlural }}', {{ $config->namespaces->apiController }}\{{ $config->modelNames->name }}APIController::class){!! infy_nl_tab() !!}->except(['create', 'edit'])@if(!$config->prefixes->route);@endif -@if($config->prefixes->route){!! infy_nl_tab().'->names(['.infy_nl_tab(1,2).implode(','.infy_nl_tab(1, 2), create_resource_route_names($config->prefixes->getRoutePrefixWith('.').$config->modelNames->camelPlural)).infy_nl_tab().']);' !!}@endif \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/api/test/api_test.blade.php b/resources/views/vendor/laravel-generator/api/test/api_test.blade.php deleted file mode 100644 index 60126d46..00000000 --- a/resources/views/vendor/laravel-generator/api/test/api_test.blade.php +++ /dev/null @@ -1,84 +0,0 @@ -@php - echo "namespaces->apiTests }}; - -use Illuminate\Foundation\Testing\WithoutMiddleware; -use Illuminate\Foundation\Testing\DatabaseTransactions; -use {{ $config->namespaces->tests }}\TestCase; -use {{ $config->namespaces->tests }}\ApiTestTrait; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; - -class {{ $config->modelNames->name }}ApiTest extends TestCase -{ - use ApiTestTrait, WithoutMiddleware, DatabaseTransactions; - - /** - * @test - */ - public function test_create_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->make()->toArray(); - - $this->response = $this->json( - 'POST', - '/{{ $config->apiPrefix }}/{{ $config->modelNames->dashedPlural }}', ${{ $config->modelNames->camel }} - ); - - $this->assertApiResponse(${{ $config->modelNames->camel }}); - } - - /** - * @test - */ - public function test_read_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->create(); - - $this->response = $this->json( - 'GET', - '/{{ $config->apiPrefix }}/{{ $config->modelNames->dashedPlural }}/'.${{ $config->modelNames->camel }}->{{ $config->primaryName }} - ); - - $this->assertApiResponse(${{ $config->modelNames->camel }}->toArray()); - } - - /** - * @test - */ - public function test_update_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->create(); - $edited{{ $config->modelNames->name }} = {{ $config->modelNames->name }}::factory()->make()->toArray(); - - $this->response = $this->json( - 'PUT', - '/{{ $config->apiPrefix }}/{{ $config->modelNames->dashedPlural }}/'.${{ $config->modelNames->camel }}->{{ $config->primaryName }}, - $edited{{ $config->modelNames->name }} - ); - - $this->assertApiResponse($edited{{ $config->modelNames->name }}); - } - - /** - * @test - */ - public function test_delete_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->create(); - - $this->response = $this->json( - 'DELETE', - '/{{ $config->apiPrefix }}/{{ $config->modelNames->dashedPlural }}/'.${{ $config->modelNames->camel }}->{{ $config->primaryName }} - ); - - $this->assertApiSuccess(); - $this->response = $this->json( - 'GET', - '/{{ $config->apiPrefix }}/{{ $config->modelNames->dashedPlural }}/'.${{ $config->modelNames->camel }}->{{ $config->primaryName }} - ); - - $this->response->assertStatus(404); - } -} diff --git a/resources/views/vendor/laravel-generator/api/test/api_test_trait.blade.php b/resources/views/vendor/laravel-generator/api/test/api_test_trait.blade.php deleted file mode 100644 index 4d1c3f66..00000000 --- a/resources/views/vendor/laravel-generator/api/test/api_test_trait.blade.php +++ /dev/null @@ -1,36 +0,0 @@ -@php - echo "assertApiSuccess(); - - $response = json_decode($this->response->getContent(), true); - $responseData = $response['data']; - - $this->assertNotEmpty($responseData['id']); - $this->assertModelData($actualData, $responseData); - } - - public function assertApiSuccess() - { - $this->response->assertStatus(200); - $this->response->assertJson(['success' => true]); - } - - public function assertModelData(Array $actualData, Array $expectedData) - { - foreach ($actualData as $key => $value) { - if (in_array($key, {!! $timestamps !!})) { - continue; - } - $this->assertEquals($actualData[$key], $expectedData[$key]); - } - } -} diff --git a/resources/views/vendor/laravel-generator/migration.blade.php b/resources/views/vendor/laravel-generator/migration.blade.php deleted file mode 100644 index 4e34a143..00000000 --- a/resources/views/vendor/laravel-generator/migration.blade.php +++ /dev/null @@ -1,32 +0,0 @@ -@php - echo "tableName }}', function (Blueprint $table) { - {!! $fields !!} - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('{{ $config->tableName }}'); - } -}; diff --git a/resources/views/vendor/laravel-generator/model/factory.blade.php b/resources/views/vendor/laravel-generator/model/factory.blade.php deleted file mode 100644 index a7bf955d..00000000 --- a/resources/views/vendor/laravel-generator/model/factory.blade.php +++ /dev/null @@ -1,32 +0,0 @@ -@php - echo "namespaces->factory }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use Illuminate\Database\Eloquent\Factories\Factory; -{!! $usedRelations !!} - -class {{ $config->modelNames->name }}Factory extends Factory -{ - /** - * The name of the factory's corresponding model. - * - * @var string - */ - protected $model = {{ $config->modelNames->name }}::class; - - /** - * Define the model's default state. - * - * @return array - */ - public function definition() - { - {!! $relations !!} - return [ - {!! $fields !!} - ]; - } -} diff --git a/resources/views/vendor/laravel-generator/model/model.blade.php b/resources/views/vendor/laravel-generator/model/model.blade.php deleted file mode 100644 index dab7fef6..00000000 --- a/resources/views/vendor/laravel-generator/model/model.blade.php +++ /dev/null @@ -1,37 +0,0 @@ -@php - echo "namespaces->model }}; - -use Illuminate\Database\Eloquent\Model; -@if($config->options->softDelete) {{ 'use Illuminate\Database\Eloquent\SoftDeletes;' }}@endif -@if($config->options->tests or $config->options->factory) {{ 'use Illuminate\Database\Eloquent\Factories\HasFactory;' }}@endif - -@if(isset($swaggerDocs)){!! $swaggerDocs !!}@endif -class {{ $config->modelNames->name }} extends Model -{ -@if($config->options->softDelete) {{ infy_tab().'use SoftDeletes;' }}@endif -@if($config->options->tests or $config->options->factory){{ infy_tab().'use HasFactory;' }}@endif - public $table = '{{ $config->tableName }}'; - -@if($customPrimaryKey)@tab()protected $primaryKey = '{{ $customPrimaryKey }}';@nls(2)@endif -@if($config->connection)@tab()protected $connection = '{{ $config->connection }}';@nls(2)@endif -@if(!$timestamps)@tab()public $timestamps = false;@nls(2)@endif -@if($customSoftDelete)@tab()protected $dates = ['{{ $customSoftDelete }}'];@nls(2)@endif -@if($customCreatedAt)@tab()const CREATED_AT = '{{ $customCreatedAt }}';@nls(2)@endif -@if($customUpdatedAt)@tab()const UPDATED_AT = '{{ $customUpdatedAt }}';@nls(2)@endif - public $fillable = [ - {!! $fillables !!} - ]; - - protected $casts = [ - {!! $casts !!} - ]; - - public static array $rules = [ - {!! $rules !!} - ]; - - {!! $relations !!} -} diff --git a/resources/views/vendor/laravel-generator/model/relationship.blade.php b/resources/views/vendor/laravel-generator/model/relationship.blade.php deleted file mode 100644 index 66c5fc35..00000000 --- a/resources/views/vendor/laravel-generator/model/relationship.blade.php +++ /dev/null @@ -1,4 +0,0 @@ - public function {{ $functionName }}(): \Illuminate\Database\Eloquent\Relations\{{ $relationClass }} - { - return $this->{{ $relation }}(\{{ $config->namespaces->model }}\{{ $relatedModel }}::class{!! $fields !!}); - } \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/model/seeder.blade.php b/resources/views/vendor/laravel-generator/model/seeder.blade.php deleted file mode 100644 index e9b27016..00000000 --- a/resources/views/vendor/laravel-generator/model/seeder.blade.php +++ /dev/null @@ -1,20 +0,0 @@ -@php - echo "namespaces->seeder }}; - -use Illuminate\Database\Seeder; - -class {{ $config->modelNames->plural }}TableSeeder extends Seeder -{ - /** - * Run the database seeds. - * - * @return void - */ - public function run() - { - - } -} diff --git a/resources/views/vendor/laravel-generator/repository/repository.blade-asli.php b/resources/views/vendor/laravel-generator/repository/repository.blade-asli.php deleted file mode 100644 index 60fe5743..00000000 --- a/resources/views/vendor/laravel-generator/repository/repository.blade-asli.php +++ /dev/null @@ -1,25 +0,0 @@ -@php - echo "namespaces->repository }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use {{ $config->namespaces->app }}\Repositories\BaseRepository; - -class {{ $config->modelNames->name }}Repository extends BaseRepository -{ - protected $fieldSearchable = [ - {!! $fieldSearchable !!} - ]; - - public function getFieldsSearchable(): array - { - return $this->fieldSearchable; - } - - public function model(): string - { - return {{ $config->modelNames->name }}::class; - } -} diff --git a/resources/views/vendor/laravel-generator/repository/repository.blade.php b/resources/views/vendor/laravel-generator/repository/repository.blade.php deleted file mode 100644 index 5f8f26eb..00000000 --- a/resources/views/vendor/laravel-generator/repository/repository.blade.php +++ /dev/null @@ -1,44 +0,0 @@ -@php - echo "namespaces->repository }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use {{ $config->namespaces->repository }}\BaseRepository; -use Spatie\QueryBuilder\AllowedFilter; -use Spatie\QueryBuilder\QueryBuilder; - -class {{ $config->modelNames->name }}Repository extends BaseRepository -{ - protected $fieldSearchable = [ - {!! $fieldSearchable !!} - ]; - - public function getFieldsSearchable(): array - { - return $this->fieldSearchable; - } - - public function model(): string - { - return {{ $config->modelNames->name }}::class; - } - - public function list{{ $config->modelNames->name }}() - { - return QueryBuilder::for($this->model()) - ->allowedFields('*') - ->allowedFilters([ - AllowedFilter::callback('search', function ($query, $value) { - $query->where(function($q) use ($value) { - @foreach ($config->fields as $field) - @if($config->primaryName == $field->name) @continue @endif - $q->orWhere('{{ $field->name }}', 'LIKE', '%'.$value.'%'); - @endforeach - }); - }), - ])->allowedSorts($this->getFieldsSearchable()) - ->jsonPaginate(); - } -} diff --git a/resources/views/vendor/laravel-generator/repository/repository_test.blade.php b/resources/views/vendor/laravel-generator/repository/repository_test.blade.php deleted file mode 100644 index 72b677f2..00000000 --- a/resources/views/vendor/laravel-generator/repository/repository_test.blade.php +++ /dev/null @@ -1,81 +0,0 @@ -@php - echo "namespaces->repositoryTests }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use {{ $config->namespaces->repository }}\{{ $config->modelNames->name }}Repository; -use Illuminate\Foundation\Testing\DatabaseTransactions; -use {{ $config->namespaces->tests }}\TestCase; -use {{ $config->namespaces->tests }}\ApiTestTrait; - -class {{ $config->modelNames->name }}RepositoryTest extends TestCase -{ - use ApiTestTrait, DatabaseTransactions; - - protected {{ $config->modelNames->name }}Repository ${{ $config->modelNames->camel }}Repo; - - public function setUp() : void - { - parent::setUp(); - $this->{{ $config->modelNames->camel }}Repo = app({{ $config->modelNames->name }}Repository::class); - } - - /** - * @test create - */ - public function test_create_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->make()->toArray(); - - $created{{ $config->modelNames->name }} = $this->{{ $config->modelNames->camel }}Repo->create(${{ $config->modelNames->camel }}); - - $created{{ $config->modelNames->name }} = $created{{ $config->modelNames->name }}->toArray(); - $this->assertArrayHasKey('id', $created{{ $config->modelNames->name }}); - $this->assertNotNull($created{{ $config->modelNames->name }}['id'], 'Created {{ $config->modelNames->name }} must have id specified'); - $this->assertNotNull({{ $config->modelNames->name }}::find($created{{ $config->modelNames->name }}['id']), '{{ $config->modelNames->name }} with given id must be in DB'); - $this->assertModelData(${{ $config->modelNames->camel }}, $created{{ $config->modelNames->name }}); - } - - /** - * @test read - */ - public function test_read_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->create(); - - $db{{ $config->modelNames->name }} = $this->{{ $config->modelNames->camel }}Repo->find(${{ $config->modelNames->camel }}->{{ $config->primaryName }}); - - $db{{ $config->modelNames->name }} = $db{{ $config->modelNames->name }}->toArray(); - $this->assertModelData(${{ $config->modelNames->camel }}->toArray(), $db{{ $config->modelNames->name }}); - } - - /** - * @test update - */ - public function test_update_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->create(); - $fake{{ $config->modelNames->name }} = {{ $config->modelNames->name }}::factory()->make()->toArray(); - - $updated{{ $config->modelNames->name }} = $this->{{ $config->modelNames->camel }}Repo->update($fake{{ $config->modelNames->name }}, ${{ $config->modelNames->camel }}->{{ $config->primaryName }}); - - $this->assertModelData($fake{{ $config->modelNames->name }}, $updated{{ $config->modelNames->name }}->toArray()); - $db{{ $config->modelNames->name }} = $this->{{ $config->modelNames->camel }}Repo->find(${{ $config->modelNames->camel }}->{{ $config->primaryName }}); - $this->assertModelData($fake{{ $config->modelNames->name }}, $db{{ $config->modelNames->name }}->toArray()); - } - - /** - * @test delete - */ - public function test_delete_{{ $config->modelNames->snake }}() - { - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::factory()->create(); - - $resp = $this->{{ $config->modelNames->camel }}Repo->delete(${{ $config->modelNames->camel }}->{{ $config->primaryName }}); - - $this->assertTrue($resp); - $this->assertNull({{ $config->modelNames->name }}::find(${{ $config->modelNames->camel }}->{{ $config->primaryName }}), '{{ $config->modelNames->name }} should not exist in DB'); - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/controller.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/controller.blade.php deleted file mode 100644 index 1be8c568..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/controller.blade.php +++ /dev/null @@ -1,109 +0,0 @@ -@php - echo "namespaces->controller }}; - -@if(config('laravel_generator.tables') == 'datatables') -use {{ $config->namespaces->dataTables }}\{{ $config->modelNames->name }}DataTable; -@endif -use {{ $config->namespaces->request }}\Create{{ $config->modelNames->name }}Request; -use {{ $config->namespaces->request }}\Update{{ $config->modelNames->name }}Request; -use {{ $config->namespaces->app }}\Http\Controllers\AppBaseController; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use Illuminate\Http\Request; -use Flash; - -class {{ $config->modelNames->name }}Controller extends AppBaseController -{ - /** - * Display a listing of the {{ $config->modelNames->name }}. - */ - {!! $indexMethod !!} - - /** - * Show the form for creating a new {{ $config->modelNames->name }}. - */ - public function create() - { - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.create'); - } - - /** - * Store a newly created {{ $config->modelNames->name }} in storage. - */ - public function store(Create{{ $config->modelNames->name }}Request $request) - { - $input = $request->all(); - - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::create($input); - - @include('laravel-generator::scaffold.controller.messages.save_success') - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } - - /** - * Display the specified {{ $config->modelNames->name }}. - */ - public function show($id) - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.show')->with('{{ $config->modelNames->camel }}', ${{ $config->modelNames->camel }}); - } - - /** - * Show the form for editing the specified {{ $config->modelNames->name }}. - */ - public function edit($id) - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.edit')->with('{{ $config->modelNames->camel }}', ${{ $config->modelNames->camel }}); - } - - /** - * Update the specified {{ $config->modelNames->name }} in storage. - */ - public function update($id, Update{{ $config->modelNames->name }}Request $request) - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - ${{ $config->modelNames->camel }}->fill($request->all()); - ${{ $config->modelNames->camel }}->save(); - - @include('laravel-generator::scaffold.controller.messages.update_success') - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } - - /** - * Remove the specified {{ $config->modelNames->name }} from storage. - * - * @throws \Exception - */ - public function destroy($id) - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camel }} */ - ${{ $config->modelNames->camel }} = {{ $config->modelNames->name }}::find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - ${{ $config->modelNames->camel }}->delete(); - - @include('laravel-generator::scaffold.controller.messages.delete_success') - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/controller_repository.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/controller_repository.blade.php deleted file mode 100644 index 87188cf1..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/controller_repository.blade.php +++ /dev/null @@ -1,119 +0,0 @@ -@php - echo "namespaces->controller }}; - -@if(config('laravel_generator.tables') === 'datatables') -use {{ $config->namespaces->dataTables }}\{{ $config->modelNames->name }}DataTable; -@endif -use {{ $config->namespaces->request }}\Create{{ $config->modelNames->name }}Request; -use {{ $config->namespaces->request }}\Update{{ $config->modelNames->name }}Request; -use {{ $config->namespaces->app }}\Http\Controllers\AppBaseController; -use {{ $config->namespaces->repository }}\{{ $config->modelNames->name }}Repository; -use {{ config('laravel_generator.namespace.transformer')}}\{{ $config->modelNames->name }}Transformer; -use Illuminate\Http\Request; -use Flash; - -class {{ $config->modelNames->name }}Controller extends AppBaseController -{ - /** @var {{ $config->modelNames->name }}Repository ${{ $config->modelNames->camel }}Repository*/ - private ${{ $config->modelNames->camel }}Repository; - - public function __construct({{ $config->modelNames->name }}Repository ${{ $config->modelNames->camel }}Repo) - { - $this->{{ $config->modelNames->camel }}Repository = ${{ $config->modelNames->camel }}Repo; - } - - /** - * Display a listing of the {{ $config->modelNames->name }}. - */ - {!! $indexMethod !!} - - /** - * Show the form for creating a new {{ $config->modelNames->name }}. - */ - public function create() - { - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.create', $this->getOptionItems()); - } - - /** - * Store a newly created {{ $config->modelNames->name }} in storage. - */ - public function store(Create{{ $config->modelNames->name }}Request $request) - { - $input = $request->all(); - - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->create($input); - - @include('laravel-generator::scaffold.controller.messages.save_success') - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } - - /** - * Display the specified {{ $config->modelNames->name }}. - */ - public function show($id) - { - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.show')->with('{{ $config->modelNames->camel }}', ${{ $config->modelNames->camel }}); - } - - /** - * Show the form for editing the specified {{ $config->modelNames->name }}. - */ - public function edit($id) - { - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.edit', $this->getOptionItems($id))->with('{{ $config->modelNames->camel }}', ${{ $config->modelNames->camel }}); - } - - /** - * Update the specified {{ $config->modelNames->name }} in storage. - */ - public function update($id, Update{{ $config->modelNames->name }}Request $request) - { - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->update($request->all(), $id); - - @include('laravel-generator::scaffold.controller.messages.update_success') - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } - - /** - * Remove the specified {{ $config->modelNames->name }} from storage. - * - * @throws \Exception - */ - public function destroy($id) - { - ${{ $config->modelNames->camel }} = $this->{{ $config->modelNames->camel }}Repository->find($id); - - @include('laravel-generator::scaffold.controller.messages.not_found') - - $this->{{ $config->modelNames->camel }}Repository->delete($id); - if(request()->ajax()){ - return $this->sendSuccess('Role deleted successfully.'); - } - @include('laravel-generator::scaffold.controller.messages.delete_success') - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } - - protected function getOptionItems($id = null) - { - return []; - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/index_method.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/index_method.blade.php deleted file mode 100644 index f1d7bae4..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/index_method.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - public function index(Request $request) - { - /** @var {{ $config->modelNames->name }} ${{ $config->modelNames->camelPlural }} */ - ${{ $config->modelNames->camelPlural }} = {{ $config->modelNames->name }}::{!! $renderType !!}; - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.index') - ->with('{{ $config->modelNames->camelPlural }}', ${{ $config->modelNames->camelPlural }}); - } diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_datatable.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/index_method_datatable.blade.php deleted file mode 100644 index 7d306e3f..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_datatable.blade.php +++ /dev/null @@ -1,4 +0,0 @@ - public function index({{ $config->modelNames->name }}DataTable ${{ $config->modelNames->camel }}DataTable) - { - return ${{ $config->modelNames->camel }}DataTable->render('{{ $config->modelNames->snakePlural }}.index'); - } diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_livewire.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/index_method_livewire.blade.php deleted file mode 100644 index 80c415b3..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_livewire.blade.php +++ /dev/null @@ -1,4 +0,0 @@ - public function index(Request $request) - { - return view('{{ $config->modelNames->snakePlural }}.index'); - } \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository-asli.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository-asli.blade.php deleted file mode 100644 index 708041ba..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository-asli.blade.php +++ /dev/null @@ -1,6 +0,0 @@ - public function index(Request $request) - { - ${{ $config->modelNames->camelPlural }} = $this->{{ $config->modelNames->camel }}Repository->{!! $renderType !!}; - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.index'); - } diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository.blade.php deleted file mode 100644 index 9e1858cb..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/index_method_repository.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - public function index(Request $request) - { - if ($request->ajax()){ - ${{ $config->modelNames->camelPlural }} = $this->{{ $config->modelNames->camel }}Repository->{!! $renderType !!}; - return $this->fractal($this->{{ $config->modelNames->camel }}Repository->list{{ $config->modelNames->name }}(), new {{ $config->modelNames->name }}Transformer, '{{ $config->modelNames->camelPlural }}')->respond(); - } - - return view('{{ $config->prefixes->getViewPrefixForInclude() }}{{ $config->modelNames->snakePlural }}.index'); - } diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/messages/delete_success.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/messages/delete_success.blade.php deleted file mode 100644 index 00dde628..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/messages/delete_success.blade.php +++ /dev/null @@ -1,5 +0,0 @@ -@if($config->options->localized) - Flash::success(__('messages.deleted', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')])); -@else - Flash::success('{{ $config->modelNames->human }} deleted successfully.'); -@endif \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/messages/not_found.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/messages/not_found.blade.php deleted file mode 100644 index b35c4589..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/messages/not_found.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - Flash::error(__('models/{{ $config->modelNames->camelPlural }}.singular').' '.__('messages.not_found')); -@else - Flash::error('{{ $config->modelNames->human }} not found'); -@endif - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/messages/save_success.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/messages/save_success.blade.php deleted file mode 100644 index cc206fd9..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/messages/save_success.blade.php +++ /dev/null @@ -1,5 +0,0 @@ -@if($config->options->localized) - Flash::success(__('messages.saved', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')])); -@else - Flash::success('{{ $config->modelNames->human }} saved successfully.'); -@endif diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/messages/update_success.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/messages/update_success.blade.php deleted file mode 100644 index 3f895353..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/messages/update_success.blade.php +++ /dev/null @@ -1,5 +0,0 @@ -@if($config->options->localized) - Flash::success(__('messages.updated', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')])); -@else - Flash::success('{{ $config->modelNames->human }} updated successfully.'); -@endif \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/scaffold/controller/model_not_found.blade.php b/resources/views/vendor/laravel-generator/scaffold/controller/model_not_found.blade.php deleted file mode 100644 index b35c4589..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/controller/model_not_found.blade.php +++ /dev/null @@ -1,9 +0,0 @@ - if (empty(${{ $config->modelNames->camel }})) { -@if($config->options->localized) - Flash::error(__('models/{{ $config->modelNames->camelPlural }}.singular').' '.__('messages.not_found')); -@else - Flash::error('{{ $config->modelNames->human }} not found'); -@endif - - return redirect(route('{{ $config->prefixes->getRoutePrefixWith('.') }}{{ $config->modelNames->camelPlural }}.index')); - } diff --git a/resources/views/vendor/laravel-generator/scaffold/layouts/datatables_css.blade.php b/resources/views/vendor/laravel-generator/scaffold/layouts/datatables_css.blade.php deleted file mode 100644 index fbc98e32..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/layouts/datatables_css.blade.php +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/scaffold/layouts/datatables_js.blade.php b/resources/views/vendor/laravel-generator/scaffold/layouts/datatables_js.blade.php deleted file mode 100644 index b09a8787..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/layouts/datatables_js.blade.php +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/scaffold/request/create.blade.php b/resources/views/vendor/laravel-generator/scaffold/request/create.blade.php deleted file mode 100644 index 388fb739..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/request/create.blade.php +++ /dev/null @@ -1,31 +0,0 @@ -@php - echo "namespaces->request }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use Illuminate\Foundation\Http\FormRequest; - -class Create{{ $config->modelNames->name }}Request extends FormRequest -{ - /** - * Determine if the user is authorized to make this request. - * - * @return bool - */ - public function authorize() - { - return true; - } - - /** - * Get the validation rules that apply to the request. - * - * @return array - */ - public function rules() - { - return {{ $config->modelNames->name }}::$rules; - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/request/update.blade.php b/resources/views/vendor/laravel-generator/scaffold/request/update.blade.php deleted file mode 100644 index 7404c262..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/request/update.blade.php +++ /dev/null @@ -1,33 +0,0 @@ -@php - echo "namespaces->request }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -use Illuminate\Foundation\Http\FormRequest; - -class Update{{ $config->modelNames->name }}Request extends FormRequest -{ - /** - * Determine if the user is authorized to make this request. - * - * @return bool - */ - public function authorize() - { - return true; - } - - /** - * Get the validation rules that apply to the request. - * - * @return array - */ - public function rules() - { - $rules = {{ $config->modelNames->name }}::$rules; - {!! $uniqueRules !!} - return $rules; - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/routes.blade.php b/resources/views/vendor/laravel-generator/scaffold/routes.blade.php deleted file mode 100644 index 30a5fa0e..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/routes.blade.php +++ /dev/null @@ -1,2 +0,0 @@ -Route::resource('{{ $config->prefixes->getRoutePrefixWith('/') }}{{ $config->modelNames->dashedPlural }}', {{ $config->namespaces->controller }}\{{ $config->modelNames->name }}Controller::class)@if(!$config->prefixes->route);@endif -@if($config->prefixes->route){!! infy_nl_tab().'->names(['.infy_nl_tab(1, 2).implode(','.infy_nl_tab(1, 2), create_resource_route_names($config->prefixes->getRoutePrefixWith('.').$config->modelNames->camelPlural, true)).infy_nl_tab().']);' !!}@endif \ No newline at end of file diff --git a/resources/views/vendor/laravel-generator/scaffold/table/datatable.blade.php b/resources/views/vendor/laravel-generator/scaffold/table/datatable.blade.php deleted file mode 100644 index 2893f510..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/table/datatable.blade.php +++ /dev/null @@ -1,92 +0,0 @@ -@php - echo "namespaces->dataTables }}; - -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; -@if($config->options->localized) -use Yajra\DataTables\Html\Column; -@endif -use Yajra\DataTables\Services\DataTable; -use Yajra\DataTables\EloquentDataTable; - -class {{ $config->modelNames->name }}DataTable extends DataTable -{ - /** - * Build DataTable class. - * - * @param mixed $query Results from query() method. - * @return \Yajra\DataTables\DataTableAbstract - */ - public function dataTable($query) - { - $dataTable = new EloquentDataTable($query); - - return $dataTable->addColumn('action', '{{ $config->modelNames->snakePlural }}.datatables_actions'); - } - - /** - * Get query source of dataTable. - * - * @param \App\Models\{{ $config->modelNames->name }} $model - * @return \Illuminate\Database\Eloquent\Builder - */ - public function query({{ $config->modelNames->name }} $model) - { - return $model->newQuery(); - } - - /** - * Optional method if you want to use html builder. - * - * @return \Yajra\DataTables\Html\Builder - */ - public function html() - { - return $this->builder() - ->columns($this->getColumns()) - ->minifiedAjax() - ->addAction(['width' => '120px', 'printable' => false]) - ->parameters([ - 'dom' => 'Bfrtip', - 'stateSave' => true, - 'order' => [[0, 'desc']], - 'buttons' => [ - // Enable Buttons as per your need -// ['extend' => 'create', 'className' => 'btn btn-default btn-sm no-corner',], -// ['extend' => 'export', 'className' => 'btn btn-default btn-sm no-corner',], -// ['extend' => 'print', 'className' => 'btn btn-default btn-sm no-corner',], -// ['extend' => 'reset', 'className' => 'btn btn-default btn-sm no-corner',], -// ['extend' => 'reload', 'className' => 'btn btn-default btn-sm no-corner',], - ], -@if($config->options->localized) - 'language' => [ - 'url' => url('//cdn.datatables.net/plug-ins/1.10.12/i18n/English.json'), - ], -@endif - ]); - } - - /** - * Get columns. - * - * @return array - */ - protected function getColumns() - { - return [ - {!! $columns !!} - ]; - } - - /** - * Get filename for export. - * - * @return string - */ - protected function filename(): string - { - return '{{ $config->modelNames->snakePlural }}_datatable_' . time(); - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/table/livewire.blade.php b/resources/views/vendor/laravel-generator/scaffold/table/livewire.blade.php deleted file mode 100644 index 71730244..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/table/livewire.blade.php +++ /dev/null @@ -1,48 +0,0 @@ -@php - echo "namespaces->livewireTables }}; - -use Laracasts\Flash\Flash; -use Rappasoft\LaravelLivewireTables\DataTableComponent; -use Rappasoft\LaravelLivewireTables\Views\Column; -use {{ $config->namespaces->model }}\{{ $config->modelNames->name }}; - -class {{ $config->modelNames->plural }}Table extends DataTableComponent -{ - protected $model = {{ $config->modelNames->name }}::class; - - protected $listeners = ['deleteRecord' => 'deleteRecord']; - - public function deleteRecord($id) - { - {{ $config->modelNames->name }}::find($id)->delete(); -@if($config->options->localized) - Flash::success(__('messages.deleted', ['model' => __('models/{{ $config->modelNames->camelPlural }}.singular')])); -@else - Flash::success('{{ $config->modelNames->human }} deleted successfully.'); -@endif - $this->emit('refreshDatatable'); - } - - public function configure(): void - { - $this->setPrimaryKey('{{ $config->primaryName }}'); - } - - public function columns(): array - { - return [ - {!! $columns !!}, - Column::make("Actions", '{{ $config->primaryName }}') - ->format( - fn($value, $row, Column $column) => view('common.livewire-tables.actions', [ - 'showUrl' => route('{{ $config->modelNames->dashedPlural }}.show', $row->{{ $config->primaryName }}), - 'editUrl' => route('{{ $config->modelNames->dashedPlural }}.edit', $row->{{ $config->primaryName }}), - 'recordId' => $row->{{ $config->primaryName }}, - ]) - ) - ]; - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/user/create_user_request.blade.php b/resources/views/vendor/laravel-generator/scaffold/user/create_user_request.blade.php deleted file mode 100644 index 9f4db568..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/user/create_user_request.blade.php +++ /dev/null @@ -1,37 +0,0 @@ -@php - echo " 'required', - 'email' => 'required|email|unique:users,email', - 'password' => 'required|confirmed' - ]; - - return $rules; - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/user/update_user_request.blade.php b/resources/views/vendor/laravel-generator/scaffold/user/update_user_request.blade.php deleted file mode 100644 index 960a5ad0..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/user/update_user_request.blade.php +++ /dev/null @@ -1,38 +0,0 @@ -@php - echo "route('user'); - $rules = [ - 'name' => 'required', - 'email' => 'required|email|unique:users,email,'.$id, - 'password' => 'confirmed' - ]; - - return $rules; - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/user/user_controller.blade.php b/resources/views/vendor/laravel-generator/scaffold/user/user_controller.blade.php deleted file mode 100644 index 4a14692a..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/user/user_controller.blade.php +++ /dev/null @@ -1,148 +0,0 @@ -@php - echo "userRepository = $userRepo; - } - - /** - * Display a listing of the User. - * - * @param Request $request - */ - public function index(Request $request) - { - $users = $this->userRepository->paginate(10); - - return view('users.index')->with('users', $users); - } - - /** - * Show the form for creating a new User. - */ - public function create() - { - return view('users.create'); - } - - /** - * Store a newly created User in storage. - * - * @param CreateUserRequest $request - */ - public function store(CreateUserRequest $request) - { - $input = $request->all(); - $input['password'] = Hash::make($input['password']); - $user = $this->userRepository->create($input); - - Flash::success('User saved successfully.'); - - return redirect(route('users.index')); - } - - /** - * Display the specified User. - * - * @param int $id - */ - public function show($id) - { - $user = $this->userRepository->find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - - return view('users.show')->with('user', $user); - } - - /** - * Show the form for editing the specified User. - * - * @param int $id - */ - public function edit($id) - { - $user = $this->userRepository->find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - - return view('users.edit')->with('user', $user); - } - - /** - * Update the specified User in storage. - * - * @param int $id - * @param UpdateUserRequest $request - */ - public function update($id, UpdateUserRequest $request) - { - $user = $this->userRepository->find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - $input = $request->all(); - if (!empty($input['password'])) { - $input['password'] = Hash::make($input['password']); - } else { - unset($input['password']); - } - $user = $this->userRepository->update($input, $id); - - Flash::success('User updated successfully.'); - - return redirect(route('users.index')); - } - - /** - * Remove the specified User from storage. - * - * @param int $id - * - * @throws \Exception - */ - public function destroy($id) - { - $user = $this->userRepository->find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - - $this->userRepository->delete($id); - - Flash::success('User deleted successfully.'); - - return redirect(route('users.index')); - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/user/user_controller_without_repository.blade.php b/resources/views/vendor/laravel-generator/scaffold/user/user_controller_without_repository.blade.php deleted file mode 100644 index 52cfca02..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/user/user_controller_without_repository.blade.php +++ /dev/null @@ -1,148 +0,0 @@ -@php - echo "with('users', $users); - } - - /** - * Show the form for creating a new User. - */ - public function create() - { - return view('users.create'); - } - - /** - * Store a newly created User in storage. - * - * @param CreateUserRequest $request - */ - public function store(CreateUserRequest $request) - { - $input = $request->all(); - $input['password'] = Hash::make($input['password']); - /** @var User $user */ - $user = User::create($input); - - Flash::success('User saved successfully.'); - - return redirect(route('users.index')); - } - - /** - * Display the specified User. - * - * @param int $id - */ - public function show($id) - { - /** @var User $user */ - $user = User::find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - - return view('users.show')->with('user', $user); - } - - /** - * Show the form for editing the specified User. - * - * @param int $id - */ - public function edit($id) - { - /** @var User $user */ - $user = User::find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - - return view('users.edit')->with('user', $user); - } - - /** - * Update the specified User in storage. - * - * @param int $id - * @param UpdateUserRequest $request - */ - public function update($id, UpdateUserRequest $request) - { - /** @var User $user */ - $user = User::find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - $input = $request->all(); - if (!empty($input['password'])) { - $input['password'] = Hash::make($input['password']); - } else { - unset($input['password']); - } - $user->fill($input); - $user->save(); - - Flash::success('User updated successfully.'); - - return redirect(route('users.index')); - } - - /** - * Remove the specified User from storage. - * - * @param int $id - * - * @throws \Exception - */ - public function destroy($id) - { - /** @var User $user */ - $user = User::find($id); - - if (empty($user)) { - Flash::error('User not found'); - - return redirect(route('users.index')); - } - - $user->delete(); - - Flash::success('User deleted successfully.'); - - return redirect(route('users.index')); - } -} diff --git a/resources/views/vendor/laravel-generator/scaffold/user/user_repository.blade.php b/resources/views/vendor/laravel-generator/scaffold/user/user_repository.blade.php deleted file mode 100644 index 942024d2..00000000 --- a/resources/views/vendor/laravel-generator/scaffold/user/user_repository.blade.php +++ /dev/null @@ -1,43 +0,0 @@ -@php - echo "fieldSearchable; - } - - /** - * Configure the Model - **/ - public function model(): string - { - return User::class; - } -} diff --git a/resources/views/vendor/laravel-generator/stubs/app_base_controller.blade.php b/resources/views/vendor/laravel-generator/stubs/app_base_controller.blade.php deleted file mode 100644 index be75b9c0..00000000 --- a/resources/views/vendor/laravel-generator/stubs/app_base_controller.blade.php +++ /dev/null @@ -1,37 +0,0 @@ -@php - echo "json(ResponseUtil::makeResponse($message, $result)); - } - - public function sendError($error, $code = 404) - { - return response()->json(ResponseUtil::makeError($error), $code); - } - - public function sendSuccess($message) - { - return response()->json([ - 'success' => true, - 'message' => $message - ], 200); - } -} diff --git a/resources/views/vendor/laravel-generator/stubs/base_repository.blade.php b/resources/views/vendor/laravel-generator/stubs/base_repository.blade.php deleted file mode 100644 index 548f373d..00000000 --- a/resources/views/vendor/laravel-generator/stubs/base_repository.blade.php +++ /dev/null @@ -1,157 +0,0 @@ -@php - echo "makeModel(); - } - - /** - * Get searchable fields array - */ - abstract public function getFieldsSearchable(): array; - - /** - * Configure the Model - */ - abstract public function model(): string; - - /** - * Make Model instance - * - * @throws \Exception - * - * @return Model - */ - public function makeModel() - { - $model = app($this->model()); - - if (!$model instanceof Model) { - throw new \Exception("Class {$this->model()} must be an instance of Illuminate\\Database\\Eloquent\\Model"); - } - - return $this->model = $model; - } - - /** - * Paginate records for scaffold. - */ - public function paginate(int $perPage, array $columns = ['*']): LengthAwarePaginator - { - $query = $this->allQuery(); - - return $query->paginate($perPage, $columns); - } - - /** - * Build a query for retrieving all records. - */ - public function allQuery(array $search = [], int $skip = null, int $limit = null): Builder - { - $query = $this->model->newQuery(); - - if (count($search)) { - foreach($search as $key => $value) { - if (in_array($key, $this->getFieldsSearchable())) { - $query->where($key, $value); - } - } - } - - if (!is_null($skip)) { - $query->skip($skip); - } - - if (!is_null($limit)) { - $query->limit($limit); - } - - return $query; - } - - /** - * Retrieve all records with given filter criteria - */ - public function all(array $search = [], int $skip = null, int $limit = null, array $columns = ['*']): Collection - { - $query = $this->allQuery($search, $skip, $limit); - - return $query->get($columns); - } - - /** - * Create model record - */ - public function create(array $input): Model - { - $model = $this->model->newInstance($input); - - $model->save(); - - return $model; - } - - /** - * Find model record for given id - * - * @return \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Eloquent\Builder[]|\Illuminate\Database\Eloquent\Collection|Model|null - */ - public function find(int $id, array $columns = ['*']) - { - $query = $this->model->newQuery(); - - return $query->find($id, $columns); - } - - /** - * Update model record for given id - * - * @return \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Eloquent\Builder[]|\Illuminate\Database\Eloquent\Collection|Model - */ - public function update(array $input, int $id) - { - $query = $this->model->newQuery(); - - $model = $query->findOrFail($id); - - $model->fill($input); - - $model->save(); - - return $model; - } - - /** - * @throws \Exception - * - * @return bool|mixed|null - */ - public function delete(int $id) - { - $query = $this->model->newQuery(); - - $model = $query->findOrFail($id); - - return $model->delete(); - } -} diff --git a/resources/views/vendor/laravel-generator/transformer/transformer.blade.php b/resources/views/vendor/laravel-generator/transformer/transformer.blade.php deleted file mode 100644 index 118e836d..00000000 --- a/resources/views/vendor/laravel-generator/transformer/transformer.blade.php +++ /dev/null @@ -1,19 +0,0 @@ -@php - echo "namespaces->model }}\{{ $config->modelNames->name }}; -use League\Fractal\TransformerAbstract; - -class {{ $config->modelNames->name }}Transformer extends TransformerAbstract -{ - public function transform({{ $config->modelNames->name }} ${{ Str::lower($config->modelNames->name) }}) - { - return [ - {!! $transforms !!} - ]; - } - -} diff --git a/resources/views/web/partials/search.blade.php b/resources/views/web/partials/search.blade.php index 54e5c022..7f4a8579 100644 --- a/resources/views/web/partials/search.blade.php +++ b/resources/views/web/partials/search.blade.php @@ -2,19 +2,13 @@
      - {!! Form::select('search_kabupaten', [], null, [ - 'class' => 'form-select border-0 py-3', - 'id' => 'filter_kabupaten', - ]) !!} + {!! Html::select('search_kabupaten', [])->class('form-select border-0 py-3')->id('filter_kabupaten')->placeholder('-- Pilih Kabupaten --') !!}
      - {!! Form::select('search_kecamatan', [], null, [ - 'class' => 'form-select border-0 py-3', - 'id' => 'filter_kecamatan', - ]) !!} + {!! Html::select('search_kecamatan', [])->class('form-select border-0 py-3')->id('filter_kecamatan')->placeholder('-- Pilih Kecamatan --') !!}
      - {!! Form::select('search_desa', [], null, ['class' => 'form-select border-0 py-3', 'id' => 'filter_desa']) !!} + {!! Html::select('search_desa', [])->class('form-select border-0 py-3')->id('filter_desa')->placeholder('-- Pilih Desa --') !!}
      diff --git a/resources/views/web/partials/unduhan.blade.php b/resources/views/web/partials/unduhan.blade.php index 46525200..fe176527 100644 --- a/resources/views/web/partials/unduhan.blade.php +++ b/resources/views/web/partials/unduhan.blade.php @@ -17,15 +17,12 @@ {{ $index + 1 }} {{ $unduhan->title }} - @if($unduhan->url) - {!! Form::open(['route' => ['web.download.counter', $unduhan->id], 'method' => 'post', 'target' => '_blank']) !!} - {!! Form::button(' Unduh', [ - 'type' => 'submit', - 'class' => 'btn btn-info btn-sm', - ]) !!} - {!! Form::close() !!} + @if ($unduhan->url) + {!! Html::form('POST', route('web.download.counter', $unduhan->id))->attribute('target', '_blank')->open() !!} + {!! Html::submit(' Unduh')->class('btn btn-info btn-sm') !!} + {!! Html::form()->close() !!} @else - - + - @endif {{ $unduhan->counter?->total ?? 0 }} From e02d1075310bde8868e8b543d59cd3faa1368e6b Mon Sep 17 00:00:00 2001 From: ahmad afandi Date: Tue, 26 Aug 2025 16:50:14 +0700 Subject: [PATCH 3/8] update dulu --- composer.lock | 409 +++++++++++++++++++++++++++++--------------------- 1 file changed, 239 insertions(+), 170 deletions(-) diff --git a/composer.lock b/composer.lock index 9fc711a9..1f8f677b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "ab01ed8927134d0fdba6477b43c6350b", + "content-hash": "4e7ee1edfe6896b0c775d0fe454a198b", "packages": [ { "name": "akaunting/laravel-apexcharts", @@ -75,6 +75,76 @@ }, "time": "2025-04-04T21:02:33+00:00" }, + { + "name": "akaunting/money", + "version": "5.2.2", + "source": { + "type": "git", + "url": "https://github.com/akaunting/laravel-money.git", + "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/akaunting/laravel-money/zipball/d99a9e8e576cac40668d0a5afaf7ea153590aff9", + "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9", + "shasum": "" + }, + "require": { + "illuminate/contracts": "^9.0|^10.0|^11.0", + "illuminate/support": "^9.0|^10.0|^11.0", + "illuminate/validation": "^9.0|^10.0|^11.0", + "illuminate/view": "^9.0|^10.0|^11.0", + "php": "^8.0", + "vlucas/phpdotenv": "^5.4.1" + }, + "require-dev": { + "orchestra/testbench": "^7.4|^8.0|^9.0", + "phpunit/phpunit": "^9.5|^10.0|^11.0", + "vimeo/psalm": "^4.23|^5.1" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "Akaunting\\Money\\Provider" + ] + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Akaunting\\Money\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Denis Duliçi", + "email": "info@akaunting.com", + "homepage": "https://akaunting.com", + "role": "Developer" + } + ], + "description": "Currency formatting and conversion package for Laravel", + "keywords": [ + "convert", + "currency", + "format", + "laravel", + "money" + ], + "support": { + "issues": "https://github.com/akaunting/laravel-money/issues", + "source": "https://github.com/akaunting/laravel-money/tree/5.2.2" + }, + "abandoned": "akaunting/laravel-money", + "time": "2024-09-25T10:06:11+00:00" + }, { "name": "alexusmai/laravel-file-manager", "version": "v3.1.1", @@ -2879,6 +2949,79 @@ }, "time": "2025-01-28T15:15:29+00:00" }, + { + "name": "laravelcollective/html", + "version": "v6.4.1", + "source": { + "type": "git", + "url": "https://github.com/LaravelCollective/html.git", + "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/LaravelCollective/html/zipball/64ddfdcaeeb8d332bd98bef442bef81e39c3910b", + "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b", + "shasum": "" + }, + "require": { + "illuminate/http": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/routing": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/session": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/view": "^6.0|^7.0|^8.0|^9.0|^10.0", + "php": ">=7.2.5" + }, + "require-dev": { + "illuminate/database": "^6.0|^7.0|^8.0|^9.0|^10.0", + "mockery/mockery": "~1.0", + "phpunit/phpunit": "~8.5|^9.5.10" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "6.x-dev" + }, + "laravel": { + "providers": [ + "Collective\\Html\\HtmlServiceProvider" + ], + "aliases": { + "Form": "Collective\\Html\\FormFacade", + "Html": "Collective\\Html\\HtmlFacade" + } + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Collective\\Html\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Adam Engebretson", + "email": "adam@laravelcollective.com" + }, + { + "name": "Taylor Otwell", + "email": "taylorotwell@gmail.com" + } + ], + "description": "HTML and Form Builders for the Laravel Framework", + "homepage": "https://laravelcollective.com", + "support": { + "issues": "https://github.com/LaravelCollective/html/issues", + "source": "https://github.com/LaravelCollective/html" + }, + "abandoned": "spatie/laravel-html", + "time": "2023-04-25T02:46:11+00:00" + }, { "name": "league/commonmark", "version": "2.7.1", @@ -3454,32 +3597,31 @@ }, { "name": "maennchen/zipstream-php", - "version": "3.2.0", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/maennchen/ZipStream-PHP.git", - "reference": "9712d8fa4cdf9240380b01eb4be55ad8dcf71416" + "reference": "6187e9cc4493da94b9b63eb2315821552015fca9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/maennchen/ZipStream-PHP/zipball/9712d8fa4cdf9240380b01eb4be55ad8dcf71416", - "reference": "9712d8fa4cdf9240380b01eb4be55ad8dcf71416", + "url": "https://api.github.com/repos/maennchen/ZipStream-PHP/zipball/6187e9cc4493da94b9b63eb2315821552015fca9", + "reference": "6187e9cc4493da94b9b63eb2315821552015fca9", "shasum": "" }, "require": { "ext-mbstring": "*", "ext-zlib": "*", - "php-64bit": "^8.3" + "php-64bit": "^8.1" }, "require-dev": { - "brianium/paratest": "^7.7", "ext-zip": "*", "friendsofphp/php-cs-fixer": "^3.16", "guzzlehttp/guzzle": "^7.5", "mikey179/vfsstream": "^1.6", "php-coveralls/php-coveralls": "^2.5", - "phpunit/phpunit": "^12.0", - "vimeo/psalm": "^6.0" + "phpunit/phpunit": "^10.0", + "vimeo/psalm": "^5.0" }, "suggest": { "guzzlehttp/psr7": "^2.4", @@ -3520,7 +3662,7 @@ ], "support": { "issues": "https://github.com/maennchen/ZipStream-PHP/issues", - "source": "https://github.com/maennchen/ZipStream-PHP/tree/3.2.0" + "source": "https://github.com/maennchen/ZipStream-PHP/tree/3.1.1" }, "funding": [ { @@ -3528,7 +3670,7 @@ "type": "github" } ], - "time": "2025-07-17T11:15:13+00:00" + "time": "2024-10-10T12:33:01+00:00" }, { "name": "markbaker/complex", @@ -4322,16 +4464,16 @@ }, { "name": "openspout/openspout", - "version": "v4.30.1", + "version": "v4.25.0", "source": { "type": "git", "url": "https://github.com/openspout/openspout.git", - "reference": "4550fc0dbf01aff86d12691f8a7f6ce22d2b2edc" + "reference": "519affe730d92e1598720a6467227fc28550f0e6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/openspout/openspout/zipball/4550fc0dbf01aff86d12691f8a7f6ce22d2b2edc", - "reference": "4550fc0dbf01aff86d12691f8a7f6ce22d2b2edc", + "url": "https://api.github.com/repos/openspout/openspout/zipball/519affe730d92e1598720a6467227fc28550f0e6", + "reference": "519affe730d92e1598720a6467227fc28550f0e6", "shasum": "" }, "require": { @@ -4341,17 +4483,17 @@ "ext-libxml": "*", "ext-xmlreader": "*", "ext-zip": "*", - "php": "~8.3.0 || ~8.4.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "require-dev": { "ext-zlib": "*", - "friendsofphp/php-cs-fixer": "^3.80.0", - "infection/infection": "^0.30.1", - "phpbench/phpbench": "^1.4.1", - "phpstan/phpstan": "^2.1.17", - "phpstan/phpstan-phpunit": "^2.0.6", - "phpstan/phpstan-strict-rules": "^2.0.4", - "phpunit/phpunit": "^12.2.6" + "friendsofphp/php-cs-fixer": "^3.64.0", + "infection/infection": "^0.29.6", + "phpbench/phpbench": "^1.3.1", + "phpstan/phpstan": "^1.12.4", + "phpstan/phpstan-phpunit": "^1.4.0", + "phpstan/phpstan-strict-rules": "^1.6.1", + "phpunit/phpunit": "^10.5.20 || ^11.3.6" }, "suggest": { "ext-iconv": "To handle non UTF-8 CSV files (if \"php-mbstring\" is not already installed or is too limited)", @@ -4399,7 +4541,7 @@ ], "support": { "issues": "https://github.com/openspout/openspout/issues", - "source": "https://github.com/openspout/openspout/tree/v4.30.1" + "source": "https://github.com/openspout/openspout/tree/v4.25.0" }, "funding": [ { @@ -4411,7 +4553,7 @@ "type": "github" } ], - "time": "2025-07-07T06:15:55+00:00" + "time": "2024-09-24T09:03:42+00:00" }, { "name": "opis/closure", @@ -5869,84 +6011,6 @@ ], "time": "2025-02-14T10:43:50+00:00" }, - { - "name": "spatie/laravel-html", - "version": "3.12.0", - "source": { - "type": "git", - "url": "https://github.com/spatie/laravel-html.git", - "reference": "3655f335609d853f51e431698179ddfe05851126" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-html/zipball/3655f335609d853f51e431698179ddfe05851126", - "reference": "3655f335609d853f51e431698179ddfe05851126", - "shasum": "" - }, - "require": { - "illuminate/http": "^10.0|^11.0|^12.0", - "illuminate/support": "^10.0|^11.0|^12.0", - "php": "^8.2" - }, - "require-dev": { - "mockery/mockery": "^1.3", - "orchestra/testbench": "^8.0|^9.0|^10.0", - "pestphp/pest": "^2.34|^3.7" - }, - "type": "library", - "extra": { - "laravel": { - "aliases": { - "Html": "Spatie\\Html\\Facades\\Html" - }, - "providers": [ - "Spatie\\Html\\HtmlServiceProvider" - ] - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Spatie\\Html\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Sebastian De Deyne", - "email": "sebastian@spatie.be", - "homepage": "https://spatie.be", - "role": "Developer" - }, - { - "name": "Freek Van der Herten", - "email": "freek@spatie.be", - "homepage": "https://spatie.be", - "role": "Developer" - } - ], - "description": "A fluent html builder", - "homepage": "https://github.com/spatie/laravel-html", - "keywords": [ - "html", - "spatie" - ], - "support": { - "source": "https://github.com/spatie/laravel-html/tree/3.12.0" - }, - "funding": [ - { - "url": "https://spatie.be/open-source/support-us", - "type": "custom" - } - ], - "time": "2025-03-21T08:58:06+00:00" - }, { "name": "spatie/laravel-json-api-paginate", "version": "1.16.3", @@ -6158,30 +6222,31 @@ }, { "name": "spatie/laravel-query-builder", - "version": "5.8.1", + "version": "5.7.0", "source": { "type": "git", "url": "https://github.com/spatie/laravel-query-builder.git", - "reference": "caa8467fa9e127ba7ea9e0aac93c71324365bae2" + "reference": "ff61a9ea32c5b55cbe63de8e3c6e35a201e6b746" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-query-builder/zipball/caa8467fa9e127ba7ea9e0aac93c71324365bae2", - "reference": "caa8467fa9e127ba7ea9e0aac93c71324365bae2", + "url": "https://api.github.com/repos/spatie/laravel-query-builder/zipball/ff61a9ea32c5b55cbe63de8e3c6e35a201e6b746", + "reference": "ff61a9ea32c5b55cbe63de8e3c6e35a201e6b746", "shasum": "" }, "require": { - "illuminate/database": "^10.0|^11.0", - "illuminate/http": "^10.0|^11.0", - "illuminate/support": "^10.0|^11.0", - "php": "^8.2", + "illuminate/database": "^9.0|^10.0", + "illuminate/http": "^9.0|^10.0", + "illuminate/support": "^9.0|^10.0", + "php": "^8.0", "spatie/laravel-package-tools": "^1.11" }, "require-dev": { "ext-json": "*", "mockery/mockery": "^1.4", "orchestra/testbench": "^7.0|^8.0", - "pestphp/pest": "^2.0", + "pestphp/pest": "^1.20", + "phpunit/phpunit": "^9.6.11", "spatie/invade": "^2.0", "spatie/laravel-ray": "^1.28" }, @@ -6227,7 +6292,7 @@ "type": "custom" } ], - "time": "2024-05-10T08:19:35+00:00" + "time": "2024-01-08T09:57:13+00:00" }, { "name": "stevebauman/location", @@ -6398,20 +6463,20 @@ }, { "name": "symfony/css-selector", - "version": "v7.3.0", + "version": "v6.4.24", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "601a5ce9aaad7bf10797e3663faefce9e26c24e2" + "reference": "9b784413143701aa3c94ac1869a159a9e53e8761" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/601a5ce9aaad7bf10797e3663faefce9e26c24e2", - "reference": "601a5ce9aaad7bf10797e3663faefce9e26c24e2", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/9b784413143701aa3c94ac1869a159a9e53e8761", + "reference": "9b784413143701aa3c94ac1869a159a9e53e8761", "shasum": "" }, "require": { - "php": ">=8.2" + "php": ">=8.1" }, "type": "library", "autoload": { @@ -6443,7 +6508,7 @@ "description": "Converts CSS selectors to XPath expressions", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/css-selector/tree/v7.3.0" + "source": "https://github.com/symfony/css-selector/tree/v6.4.24" }, "funding": [ { @@ -6454,12 +6519,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-09-25T14:21:43+00:00" + "time": "2025-07-10T08:14:14+00:00" }, { "name": "symfony/deprecation-contracts", @@ -6609,24 +6678,24 @@ }, { "name": "symfony/event-dispatcher", - "version": "v7.3.0", + "version": "v6.4.24", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "497f73ac996a598c92409b44ac43b6690c4f666d" + "reference": "307a09d8d7228d14a05e5e05b95fffdacab032b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/497f73ac996a598c92409b44ac43b6690c4f666d", - "reference": "497f73ac996a598c92409b44ac43b6690c4f666d", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/307a09d8d7228d14a05e5e05b95fffdacab032b2", + "reference": "307a09d8d7228d14a05e5e05b95fffdacab032b2", "shasum": "" }, "require": { - "php": ">=8.2", + "php": ">=8.1", "symfony/event-dispatcher-contracts": "^2.5|^3" }, "conflict": { - "symfony/dependency-injection": "<6.4", + "symfony/dependency-injection": "<5.4", "symfony/service-contracts": "<2.5" }, "provide": { @@ -6635,13 +6704,13 @@ }, "require-dev": { "psr/log": "^1|^2|^3", - "symfony/config": "^6.4|^7.0", - "symfony/dependency-injection": "^6.4|^7.0", - "symfony/error-handler": "^6.4|^7.0", - "symfony/expression-language": "^6.4|^7.0", - "symfony/http-foundation": "^6.4|^7.0", + "symfony/config": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/error-handler": "^5.4|^6.0|^7.0", + "symfony/expression-language": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^5.4|^6.0|^7.0", "symfony/service-contracts": "^2.5|^3", - "symfony/stopwatch": "^6.4|^7.0" + "symfony/stopwatch": "^5.4|^6.0|^7.0" }, "type": "library", "autoload": { @@ -6669,7 +6738,7 @@ "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/event-dispatcher/tree/v7.3.0" + "source": "https://github.com/symfony/event-dispatcher/tree/v6.4.24" }, "funding": [ { @@ -6680,12 +6749,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2025-04-22T09:11:45+00:00" + "time": "2025-07-10T08:14:14+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -8109,20 +8182,20 @@ }, { "name": "symfony/string", - "version": "v7.3.2", + "version": "v6.4.24", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "42f505aff654e62ac7ac2ce21033818297ca89ca" + "reference": "f0ce0bd36a3accb4a225435be077b4b4875587f4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/42f505aff654e62ac7ac2ce21033818297ca89ca", - "reference": "42f505aff654e62ac7ac2ce21033818297ca89ca", + "url": "https://api.github.com/repos/symfony/string/zipball/f0ce0bd36a3accb4a225435be077b4b4875587f4", + "reference": "f0ce0bd36a3accb4a225435be077b4b4875587f4", "shasum": "" }, "require": { - "php": ">=8.2", + "php": ">=8.1", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-intl-grapheme": "~1.0", "symfony/polyfill-intl-normalizer": "~1.0", @@ -8132,12 +8205,11 @@ "symfony/translation-contracts": "<2.5" }, "require-dev": { - "symfony/emoji": "^7.1", - "symfony/error-handler": "^6.4|^7.0", - "symfony/http-client": "^6.4|^7.0", - "symfony/intl": "^6.4|^7.0", + "symfony/error-handler": "^5.4|^6.0|^7.0", + "symfony/http-client": "^5.4|^6.0|^7.0", + "symfony/intl": "^6.2|^7.0", "symfony/translation-contracts": "^2.5|^3.0", - "symfony/var-exporter": "^6.4|^7.0" + "symfony/var-exporter": "^5.4|^6.0|^7.0" }, "type": "library", "autoload": { @@ -8176,7 +8248,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v7.3.2" + "source": "https://github.com/symfony/string/tree/v6.4.24" }, "funding": [ { @@ -8196,7 +8268,7 @@ "type": "tidelift" } ], - "time": "2025-07-10T08:47:49+00:00" + "time": "2025-07-10T08:14:14+00:00" }, { "name": "symfony/translation", @@ -9916,16 +9988,16 @@ }, { "name": "laravel/pint", - "version": "v1.24.0", + "version": "v1.20.0", "source": { "type": "git", "url": "https://github.com/laravel/pint.git", - "reference": "0345f3b05f136801af8c339f9d16ef29e6b4df8a" + "reference": "53072e8ea22213a7ed168a8a15b96fbb8b82d44b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/pint/zipball/0345f3b05f136801af8c339f9d16ef29e6b4df8a", - "reference": "0345f3b05f136801af8c339f9d16ef29e6b4df8a", + "url": "https://api.github.com/repos/laravel/pint/zipball/53072e8ea22213a7ed168a8a15b96fbb8b82d44b", + "reference": "53072e8ea22213a7ed168a8a15b96fbb8b82d44b", "shasum": "" }, "require": { @@ -9933,15 +10005,15 @@ "ext-mbstring": "*", "ext-tokenizer": "*", "ext-xml": "*", - "php": "^8.2.0" + "php": "^8.1.0" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^3.82.2", - "illuminate/view": "^11.45.1", - "larastan/larastan": "^3.5.0", - "laravel-zero/framework": "^11.45.0", + "friendsofphp/php-cs-fixer": "^3.66.0", + "illuminate/view": "^10.48.25", + "larastan/larastan": "^2.9.12", + "laravel-zero/framework": "^10.48.25", "mockery/mockery": "^1.6.12", - "nunomaduro/termwind": "^2.3.1", + "nunomaduro/termwind": "^1.17.0", "pestphp/pest": "^2.36.0" }, "bin": [ @@ -9949,9 +10021,6 @@ ], "type": "project", "autoload": { - "files": [ - "overrides/Runner/Parallel/ProcessFactory.php" - ], "psr-4": { "App\\": "app/", "Database\\Seeders\\": "database/seeders/", @@ -9981,7 +10050,7 @@ "issues": "https://github.com/laravel/pint/issues", "source": "https://github.com/laravel/pint" }, - "time": "2025-07-10T18:09:32+00:00" + "time": "2025-01-14T16:20:53+00:00" }, { "name": "laravel/sail", @@ -12218,28 +12287,28 @@ }, { "name": "symfony/yaml", - "version": "v7.3.2", + "version": "v6.4.24", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "b8d7d868da9eb0919e99c8830431ea087d6aae30" + "reference": "742a8efc94027624b36b10ba58e23d402f961f51" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/b8d7d868da9eb0919e99c8830431ea087d6aae30", - "reference": "b8d7d868da9eb0919e99c8830431ea087d6aae30", + "url": "https://api.github.com/repos/symfony/yaml/zipball/742a8efc94027624b36b10ba58e23d402f961f51", + "reference": "742a8efc94027624b36b10ba58e23d402f961f51", "shasum": "" }, "require": { - "php": ">=8.2", - "symfony/deprecation-contracts": "^2.5|^3.0", + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", "symfony/polyfill-ctype": "^1.8" }, "conflict": { - "symfony/console": "<6.4" + "symfony/console": "<5.4" }, "require-dev": { - "symfony/console": "^6.4|^7.0" + "symfony/console": "^5.4|^6.0|^7.0" }, "bin": [ "Resources/bin/yaml-lint" @@ -12270,7 +12339,7 @@ "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/yaml/tree/v7.3.2" + "source": "https://github.com/symfony/yaml/tree/v6.4.24" }, "funding": [ { @@ -12290,7 +12359,7 @@ "type": "tidelift" } ], - "time": "2025-07-10T08:47:49+00:00" + "time": "2025-07-10T08:14:14+00:00" }, { "name": "theseer/tokenizer", From 8b5fa22513f8bff440b3466441d45780949618d9 Mon Sep 17 00:00:00 2001 From: ahmad afandi Date: Wed, 27 Aug 2025 06:07:49 +0700 Subject: [PATCH 4/8] sesuaikan penggunaan laravel-html --- app/Http/Transformers/DownloadTransformer.php | 3 +- app/Http/Transformers/SlideTransformer.php | 3 +- composer.json | 2 +- composer.lock | 223 +++++++----------- playwright.config.js | 12 +- resources/views/articles/edit.blade.php | 2 +- resources/views/categories/edit.blade.php | 2 +- resources/views/categories/fields.blade.php | 6 +- resources/views/departments/edit.blade.php | 2 +- resources/views/departments/fields.blade.php | 4 +- resources/views/downloads/edit.blade.php | 2 +- resources/views/downloads/fields.blade.php | 8 +- resources/views/employees/edit.blade.php | 2 +- resources/views/employees/fields.blade.php | 26 +- resources/views/group/fields.blade.php | 4 +- resources/views/menus/fields.blade.php | 8 +- resources/views/pages/edit.blade.php | 2 +- resources/views/pages/fields.blade.php | 4 +- resources/views/positions/edit.blade.php | 2 +- resources/views/positions/fields.blade.php | 4 +- resources/views/settings/edit.blade.php | 2 +- resources/views/settings/fields.blade.php | 12 +- resources/views/slides/edit.blade.php | 2 +- resources/views/slides/fields.blade.php | 10 +- 24 files changed, 146 insertions(+), 201 deletions(-) diff --git a/app/Http/Transformers/DownloadTransformer.php b/app/Http/Transformers/DownloadTransformer.php index 40912ca3..8deb7427 100644 --- a/app/Http/Transformers/DownloadTransformer.php +++ b/app/Http/Transformers/DownloadTransformer.php @@ -6,6 +6,7 @@ use App\Models\Enums\StatusEnum; use Illuminate\Support\Facades\Storage; use League\Fractal\TransformerAbstract; +use Spatie\Html\Facades\Html; class DownloadTransformer extends TransformerAbstract { @@ -14,7 +15,7 @@ public function transform(Download $download) return [ 'id' => $download->id, 'title' => $download->title, - 'url' => $download->url ? link_to(Storage::url($download->url), 'berkas', ['class' => 'text-primary'])->toHtml() : '', + 'url' => $download->url ? Html::a(Storage::url($download->url), 'berkas')->class('text-primary')->toHtml() : '', 'description' => $download->description, 'state' => $download->state == StatusEnum::aktif ? 'Tampilkan' : 'Tidak', 'created_at' => $download->created_at, diff --git a/app/Http/Transformers/SlideTransformer.php b/app/Http/Transformers/SlideTransformer.php index 1b23b885..ee000a5e 100644 --- a/app/Http/Transformers/SlideTransformer.php +++ b/app/Http/Transformers/SlideTransformer.php @@ -6,6 +6,7 @@ use App\Models\Enums\StatusEnum; use Illuminate\Support\Facades\Storage; use League\Fractal\TransformerAbstract; +use Spatie\Html\Facades\Html; class SlideTransformer extends TransformerAbstract { @@ -14,7 +15,7 @@ public function transform(Slide $slide) return [ 'id' => $slide->id, 'title' => $slide->title, - 'url' => $slide->url ? link_to($slide->url, 'tautan', ['class' => 'text-primary'])->toHtml() : '', + 'url' => $slide->url ? Html::a($slide->url, 'tautan')->class('text-primary')->toHtml() : '', 'thumbnail' => $slide->thumbnail ? Storage::url($slide->thumbnail) : '', 'description' => $slide->description, 'state' => $slide->state == StatusEnum::aktif ? 'Aktif' : 'Non Aktif', diff --git a/composer.json b/composer.json index f86dc06f..de80d462 100644 --- a/composer.json +++ b/composer.json @@ -29,7 +29,7 @@ "spatie/laravel-activitylog": "^4.7", "spatie/laravel-csp": "^2.8", "spatie/laravel-fractal": "^6.0", - "spatie/laravel-html": "^3.12", + "spatie/laravel-html": "^3.5", "spatie/laravel-json-api-paginate": "^1.13", "spatie/laravel-permission": "^6.4", "spatie/laravel-query-builder": "^5.2", diff --git a/composer.lock b/composer.lock index 1f8f677b..1e144a58 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "4e7ee1edfe6896b0c775d0fe454a198b", + "content-hash": "2ffcf31285ea53025ab70e536dafe411", "packages": [ { "name": "akaunting/laravel-apexcharts", @@ -75,76 +75,6 @@ }, "time": "2025-04-04T21:02:33+00:00" }, - { - "name": "akaunting/money", - "version": "5.2.2", - "source": { - "type": "git", - "url": "https://github.com/akaunting/laravel-money.git", - "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/akaunting/laravel-money/zipball/d99a9e8e576cac40668d0a5afaf7ea153590aff9", - "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9", - "shasum": "" - }, - "require": { - "illuminate/contracts": "^9.0|^10.0|^11.0", - "illuminate/support": "^9.0|^10.0|^11.0", - "illuminate/validation": "^9.0|^10.0|^11.0", - "illuminate/view": "^9.0|^10.0|^11.0", - "php": "^8.0", - "vlucas/phpdotenv": "^5.4.1" - }, - "require-dev": { - "orchestra/testbench": "^7.4|^8.0|^9.0", - "phpunit/phpunit": "^9.5|^10.0|^11.0", - "vimeo/psalm": "^4.23|^5.1" - }, - "type": "library", - "extra": { - "laravel": { - "providers": [ - "Akaunting\\Money\\Provider" - ] - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Akaunting\\Money\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Denis Duliçi", - "email": "info@akaunting.com", - "homepage": "https://akaunting.com", - "role": "Developer" - } - ], - "description": "Currency formatting and conversion package for Laravel", - "keywords": [ - "convert", - "currency", - "format", - "laravel", - "money" - ], - "support": { - "issues": "https://github.com/akaunting/laravel-money/issues", - "source": "https://github.com/akaunting/laravel-money/tree/5.2.2" - }, - "abandoned": "akaunting/laravel-money", - "time": "2024-09-25T10:06:11+00:00" - }, { "name": "alexusmai/laravel-file-manager", "version": "v3.1.1", @@ -2949,79 +2879,6 @@ }, "time": "2025-01-28T15:15:29+00:00" }, - { - "name": "laravelcollective/html", - "version": "v6.4.1", - "source": { - "type": "git", - "url": "https://github.com/LaravelCollective/html.git", - "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/LaravelCollective/html/zipball/64ddfdcaeeb8d332bd98bef442bef81e39c3910b", - "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b", - "shasum": "" - }, - "require": { - "illuminate/http": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/routing": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/session": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/view": "^6.0|^7.0|^8.0|^9.0|^10.0", - "php": ">=7.2.5" - }, - "require-dev": { - "illuminate/database": "^6.0|^7.0|^8.0|^9.0|^10.0", - "mockery/mockery": "~1.0", - "phpunit/phpunit": "~8.5|^9.5.10" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "6.x-dev" - }, - "laravel": { - "providers": [ - "Collective\\Html\\HtmlServiceProvider" - ], - "aliases": { - "Form": "Collective\\Html\\FormFacade", - "Html": "Collective\\Html\\HtmlFacade" - } - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Collective\\Html\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Adam Engebretson", - "email": "adam@laravelcollective.com" - }, - { - "name": "Taylor Otwell", - "email": "taylorotwell@gmail.com" - } - ], - "description": "HTML and Form Builders for the Laravel Framework", - "homepage": "https://laravelcollective.com", - "support": { - "issues": "https://github.com/LaravelCollective/html/issues", - "source": "https://github.com/LaravelCollective/html" - }, - "abandoned": "spatie/laravel-html", - "time": "2023-04-25T02:46:11+00:00" - }, { "name": "league/commonmark", "version": "2.7.1", @@ -6011,6 +5868,84 @@ ], "time": "2025-02-14T10:43:50+00:00" }, + { + "name": "spatie/laravel-html", + "version": "3.5.0", + "source": { + "type": "git", + "url": "https://github.com/spatie/laravel-html.git", + "reference": "ead179a8b6802647027486049f5209bd23b610a9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/laravel-html/zipball/ead179a8b6802647027486049f5209bd23b610a9", + "reference": "ead179a8b6802647027486049f5209bd23b610a9", + "shasum": "" + }, + "require": { + "illuminate/http": "^9.0|^8.0|^10.0", + "illuminate/support": "^9.0|^8.0|^10.0", + "php": "^8.0" + }, + "require-dev": { + "mockery/mockery": "^1.3", + "orchestra/testbench": "^7.0|^6.23|^8.0", + "pestphp/pest": "^1.22" + }, + "type": "library", + "extra": { + "laravel": { + "aliases": { + "Html": "Spatie\\Html\\Facades\\Html" + }, + "providers": [ + "Spatie\\Html\\HtmlServiceProvider" + ] + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Spatie\\Html\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Sebastian De Deyne", + "email": "sebastian@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + }, + { + "name": "Freek Van der Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "A fluent html builder", + "homepage": "https://github.com/spatie/laravel-html", + "keywords": [ + "html", + "spatie" + ], + "support": { + "source": "https://github.com/spatie/laravel-html/tree/3.5.0" + }, + "funding": [ + { + "url": "https://spatie.be/open-source/support-us", + "type": "custom" + } + ], + "time": "2024-02-20T15:17:00+00:00" + }, { "name": "spatie/laravel-json-api-paginate", "version": "1.16.3", diff --git a/playwright.config.js b/playwright.config.js index d6e42fb5..7a41bd69 100644 --- a/playwright.config.js +++ b/playwright.config.js @@ -47,10 +47,10 @@ module.exports = defineConfig({ }, ], -// webServer: { -// command: `${configLoader.get('app.phpVersion')} artisan serve`, -// url: configLoader.get('app.baseURL'), -// reuseExistingServer: !process.env.CI, -// timeout: 120 * 1000, -// }, + webServer: { + command: 'php artisan serve', + url: configLoader.get('app.baseURL'), + reuseExistingServer: !process.env.CI, + timeout: 120 * 1000, + }, }); diff --git a/resources/views/articles/edit.blade.php b/resources/views/articles/edit.blade.php index 9badd084..87c3c0e9 100644 --- a/resources/views/articles/edit.blade.php +++ b/resources/views/articles/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Artikel
      - {!! Html::form('PUT', route('articles.update', $article->id))->attribute('enctype', 'multipart/form-data')->bind($article)->open() !!} + {!! Html::form('PUT', route('articles.update', $article->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/categories/edit.blade.php b/resources/views/categories/edit.blade.php index ab40f400..2d458c2b 100644 --- a/resources/views/categories/edit.blade.php +++ b/resources/views/categories/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Kategori
      - {!! Html::form('PUT', route('categories.update', $category->id))->bind($category)->open() !!} + {!! Html::form('PUT', route('categories.update', $category->id))->open() !!}
      diff --git a/resources/views/categories/fields.blade.php b/resources/views/categories/fields.blade.php index 886fc7df..e2669265 100644 --- a/resources/views/categories/fields.blade.php +++ b/resources/views/categories/fields.blade.php @@ -2,7 +2,7 @@
      {!! Html::label('name', 'Nama Kategori')->class('col-3') !!}
      - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('name', old('name', $category->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -12,10 +12,10 @@ {!! Html::label('status', 'Tampilkan')->class('col-3') !!}
      diff --git a/resources/views/departments/edit.blade.php b/resources/views/departments/edit.blade.php index e27fcb15..f07ebe67 100644 --- a/resources/views/departments/edit.blade.php +++ b/resources/views/departments/edit.blade.php @@ -10,7 +10,7 @@  Kembali ke Daftar Department
      - {!! Html::form('PUT', route('departments.update', $department->id))->bind($department)->open() !!} + {!! Html::form('PUT', route('departments.update', $department->id))->open() !!}
      diff --git a/resources/views/departments/fields.blade.php b/resources/views/departments/fields.blade.php index fbc56def..bf8f99f0 100644 --- a/resources/views/departments/fields.blade.php +++ b/resources/views/departments/fields.blade.php @@ -1,14 +1,14 @@
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} + {!! Html::text('name', old('name', $department->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $department->description ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      diff --git a/resources/views/downloads/edit.blade.php b/resources/views/downloads/edit.blade.php index 39fdf42c..aa5b9b83 100644 --- a/resources/views/downloads/edit.blade.php +++ b/resources/views/downloads/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Unduhan
      - {!! Html::form('PUT', route('downloads.update', $download->id))->attribute('enctype', 'multipart/form-data')->bind($download)->open() !!} + {!! Html::form('PUT', route('downloads.update', $download->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/downloads/fields.blade.php b/resources/views/downloads/fields.blade.php index 9c537faa..ab99d381 100644 --- a/resources/views/downloads/fields.blade.php +++ b/resources/views/downloads/fields.blade.php @@ -2,7 +2,7 @@
      {!! Html::label('title', 'Judul')->class('col-3') !!}
      - {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('title', old('title', $download->title ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -19,7 +19,7 @@
      @if (isset($download)) @if ($download->url) - {{ link_to(Storage::url($download->url), 'berkas unduhan', ['class' => 'text-primary', 'target' => '_blank']) }} + {!! Html::a(Storage::url($download->url), 'berkas unduhan')->class('text-primary')->target('_blank') !!} @endif @endif
      @@ -29,7 +29,7 @@
      {!! Html::label('description', 'Keterangan')->class('col-3') !!}
      - {!! Html::textarea('description')->class('form-control')->attribute('rows', 3)->attribute('maxlength', 65535) !!} + {!! Html::textarea('description', old('description', $download->description ?? ''))->class('form-control')->attribute('rows', 3)->attribute('maxlength', 65535) !!}
      @@ -37,7 +37,7 @@
      {!! Html::label('state', 'Status')->class('col-3') !!}
      - {!! Html::select('state', $stateItem)->class('form-control select2')->attribute('required') !!} + {!! Html::select('state', $stateItem, old('state', $download->state ?? ''))->class('form-control select2')->attribute('required') !!}
      diff --git a/resources/views/employees/edit.blade.php b/resources/views/employees/edit.blade.php index a1a1ef4b..77afa453 100644 --- a/resources/views/employees/edit.blade.php +++ b/resources/views/employees/edit.blade.php @@ -10,7 +10,7 @@  Kembali ke Daftar Employee
      - {!! Html::form('PUT', route('employees.update', $employee->id))->attribute('enctype', 'multipart/form-data')->bind($employee)->open() !!} + {!! Html::form('PUT', route('employees.update', $employee->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/employees/fields.blade.php b/resources/views/employees/fields.blade.php index 85e68132..fff87646 100644 --- a/resources/views/employees/fields.blade.php +++ b/resources/views/employees/fields.blade.php @@ -1,7 +1,7 @@
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} + {!! Html::text('name', old('name', $employee->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      @push('page_scripts') @@ -13,25 +13,25 @@
      {!! Html::label('identity_number', 'NIP:') !!} - {!! Html::text('identity_number')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('identity_number', old('identity_number', $employee->identity_number ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      {!! Html::label('email', 'Email:') !!} - {!! Html::email('email')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::email('email', old('email', $employee->email ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $employee->description ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('phone', 'Telepon:') !!} - {!! Html::text('phone')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('phone', old('phone', $employee->phone ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      @@ -43,41 +43,45 @@
      {!! Html::label('department_id', 'Departemen:') !!} - {!! Html::select('department_id', $departments)->class('form-control select2') !!} + {!! Html::select('department_id', $departments, old('department_id', $employee->department_id ?? ''))->class( + 'form-control select2', + ) !!}
      {!! Html::label('identity_number', 'NIP:') !!} - {!! Html::text('identity_number')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('identity_number', old('identity_number', $employee->identity_number ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      {!! Html::label('email', 'Email:') !!} - {!! Html::email('email')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::email('email', old('email', $employee->email ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $employee->description ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('phone', 'Telepon:') !!} - {!! Html::text('phone')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('phone', old('phone', $employee->phone ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      {!! Html::label('position_id', 'Jabatan:') !!} - {!! Html::select('position_id', $positions)->class('form-control select2') !!} + {!! Html::select('position_id', $positions, old('position_id', $employee->position_id ?? ''))->class( + 'form-control select2', + ) !!}
      diff --git a/resources/views/group/fields.blade.php b/resources/views/group/fields.blade.php index 2469ebac..12bd269f 100644 --- a/resources/views/group/fields.blade.php +++ b/resources/views/group/fields.blade.php @@ -60,10 +60,10 @@
      diff --git a/resources/views/menus/fields.blade.php b/resources/views/menus/fields.blade.php index 43514930..900a5903 100644 --- a/resources/views/menus/fields.blade.php +++ b/resources/views/menus/fields.blade.php @@ -59,16 +59,16 @@
      diff --git a/resources/views/pages/edit.blade.php b/resources/views/pages/edit.blade.php index 77057e2a..50714562 100644 --- a/resources/views/pages/edit.blade.php +++ b/resources/views/pages/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Halaman
      - {!! Html::form('PUT', route('pages.update', $page->id))->attribute('enctype', 'multipart/form-data')->bind($page)->open() !!} + {!! Html::form('PUT', route('pages.update', $page->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/pages/fields.blade.php b/resources/views/pages/fields.blade.php index 40d70596..936fd865 100644 --- a/resources/views/pages/fields.blade.php +++ b/resources/views/pages/fields.blade.php @@ -3,13 +3,13 @@
      {!! Html::label('title', 'Judul') !!} - {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 200) !!} + {!! Html::text('title', old('title', $page->title ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 200) !!}
      {!! Html::label('content', 'Isi') !!} - {!! Html::textarea('content')->class('form-control editor')->attribute('required')->attribute('maxlength', 65535) !!} + {!! Html::textarea('content', old('content', $page->content ?? ''))->class('form-control editor')->attribute('required')->attribute('maxlength', 65535) !!}
      diff --git a/resources/views/positions/edit.blade.php b/resources/views/positions/edit.blade.php index 286cf420..5637d799 100644 --- a/resources/views/positions/edit.blade.php +++ b/resources/views/positions/edit.blade.php @@ -10,7 +10,7 @@  Kembali ke Daftar Position
      - {!! Html::form('PUT', route('positions.update', $position->id))->bind($position)->open() !!} + {!! Html::form('PUT', route('positions.update', $position->id))->open() !!}
      diff --git a/resources/views/positions/fields.blade.php b/resources/views/positions/fields.blade.php index 2d7580c7..0f17f536 100644 --- a/resources/views/positions/fields.blade.php +++ b/resources/views/positions/fields.blade.php @@ -1,7 +1,7 @@
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} + {!! Html::text('name', old('name', $position->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      @push('page_scripts') @@ -13,7 +13,7 @@
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $position->description ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      diff --git a/resources/views/settings/edit.blade.php b/resources/views/settings/edit.blade.php index b4f5f864..a495d4a9 100644 --- a/resources/views/settings/edit.blade.php +++ b/resources/views/settings/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Setting
      - {!! Html::form('PUT', route('settings.update', $setting->id))->bind($setting)->open() !!} + {!! Html::form('PUT', route('settings.update', $setting->id))->open() !!}
      diff --git a/resources/views/settings/fields.blade.php b/resources/views/settings/fields.blade.php index 6fc86969..6632567f 100644 --- a/resources/views/settings/fields.blade.php +++ b/resources/views/settings/fields.blade.php @@ -1,14 +1,14 @@
      {!! Html::label('key', 'Kode Kunci:') !!} - {!! Html::text('key')->class('form-control')->attribute('required')->attribute('maxlength', 50)->attribute('disabled') !!} + {!! Html::text('key', old('key', $setting->key ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50)->attribute('disabled') !!}
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('name', old('name', $setting->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -16,12 +16,16 @@ @switch($setting->type) @case('dropdown') {!! Html::label('value', 'Status:') !!} - {!! Html::select('value', collect($setting->attribute)->pluck('text', 'value'), $setting->value)->class('form-control')->attribute('required') !!} + {!! Html::select( + 'value', + collect($setting->attribute)->pluck('text', 'value'), + old('value', $setting->value ?? ''), + )->class('form-control')->attribute('required') !!} @break @default {!! Html::label('value', 'Nilai:') !!} - {!! Html::text('value')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('value', old('value', $setting->value ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} @endswitch
      diff --git a/resources/views/slides/edit.blade.php b/resources/views/slides/edit.blade.php index ded9995f..cd6883e8 100644 --- a/resources/views/slides/edit.blade.php +++ b/resources/views/slides/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Slide
      - {!! Html::form('PUT', route('slides.update', $slide->id))->attribute('enctype', 'multipart/form-data')->bind($slide)->open() !!} + {!! Html::form('PUT', route('slides.update', $slide->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/slides/fields.blade.php b/resources/views/slides/fields.blade.php index f3c6ac61..c20dafbd 100644 --- a/resources/views/slides/fields.blade.php +++ b/resources/views/slides/fields.blade.php @@ -4,7 +4,7 @@ {!! Html::label('title', 'Judul') !!}
      - {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('title', old('title', $slide->title ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -15,7 +15,7 @@ {!! Html::label('url', 'Url') !!}
      - {!! Html::text('url')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::text('url', old('url', $slide->url ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      @@ -25,7 +25,7 @@ {!! Html::label('description', 'Keterangan') !!}
      - {!! Html::textarea('description')->class('form-control')->attribute('rows', 4)->attribute('maxlength', 65535) !!} + {!! Html::textarea('description', old('description', $slide->description ?? ''))->class('form-control')->attribute('rows', 4)->attribute('maxlength', 65535) !!}
      @@ -35,10 +35,10 @@ {!! Html::label('state', 'Status')->class('col-3') !!}
      From c737419deb3f18f901f3ab142bb6c39ddb502971 Mon Sep 17 00:00:00 2001 From: ahmad afandi Date: Wed, 27 Aug 2025 06:07:49 +0700 Subject: [PATCH 5/8] sesuaikan penggunaan laravel-html --- app/Http/Transformers/DownloadTransformer.php | 3 +- app/Http/Transformers/SlideTransformer.php | 3 +- composer.json | 2 +- composer.lock | 223 +++++++----------- playwright.config.js | 12 +- resources/views/articles/edit.blade.php | 2 +- resources/views/categories/edit.blade.php | 2 +- resources/views/categories/fields.blade.php | 6 +- resources/views/departments/edit.blade.php | 2 +- resources/views/departments/fields.blade.php | 4 +- resources/views/downloads/edit.blade.php | 2 +- resources/views/downloads/fields.blade.php | 8 +- resources/views/employees/edit.blade.php | 2 +- resources/views/employees/fields.blade.php | 26 +- resources/views/group/fields.blade.php | 6 +- resources/views/menus/fields.blade.php | 10 +- resources/views/pages/edit.blade.php | 2 +- resources/views/pages/fields.blade.php | 4 +- resources/views/positions/edit.blade.php | 2 +- resources/views/positions/fields.blade.php | 4 +- resources/views/settings/edit.blade.php | 2 +- resources/views/settings/fields.blade.php | 12 +- resources/views/slides/edit.blade.php | 2 +- resources/views/slides/fields.blade.php | 12 +- 24 files changed, 149 insertions(+), 204 deletions(-) diff --git a/app/Http/Transformers/DownloadTransformer.php b/app/Http/Transformers/DownloadTransformer.php index 40912ca3..8deb7427 100644 --- a/app/Http/Transformers/DownloadTransformer.php +++ b/app/Http/Transformers/DownloadTransformer.php @@ -6,6 +6,7 @@ use App\Models\Enums\StatusEnum; use Illuminate\Support\Facades\Storage; use League\Fractal\TransformerAbstract; +use Spatie\Html\Facades\Html; class DownloadTransformer extends TransformerAbstract { @@ -14,7 +15,7 @@ public function transform(Download $download) return [ 'id' => $download->id, 'title' => $download->title, - 'url' => $download->url ? link_to(Storage::url($download->url), 'berkas', ['class' => 'text-primary'])->toHtml() : '', + 'url' => $download->url ? Html::a(Storage::url($download->url), 'berkas')->class('text-primary')->toHtml() : '', 'description' => $download->description, 'state' => $download->state == StatusEnum::aktif ? 'Tampilkan' : 'Tidak', 'created_at' => $download->created_at, diff --git a/app/Http/Transformers/SlideTransformer.php b/app/Http/Transformers/SlideTransformer.php index 1b23b885..ee000a5e 100644 --- a/app/Http/Transformers/SlideTransformer.php +++ b/app/Http/Transformers/SlideTransformer.php @@ -6,6 +6,7 @@ use App\Models\Enums\StatusEnum; use Illuminate\Support\Facades\Storage; use League\Fractal\TransformerAbstract; +use Spatie\Html\Facades\Html; class SlideTransformer extends TransformerAbstract { @@ -14,7 +15,7 @@ public function transform(Slide $slide) return [ 'id' => $slide->id, 'title' => $slide->title, - 'url' => $slide->url ? link_to($slide->url, 'tautan', ['class' => 'text-primary'])->toHtml() : '', + 'url' => $slide->url ? Html::a($slide->url, 'tautan')->class('text-primary')->toHtml() : '', 'thumbnail' => $slide->thumbnail ? Storage::url($slide->thumbnail) : '', 'description' => $slide->description, 'state' => $slide->state == StatusEnum::aktif ? 'Aktif' : 'Non Aktif', diff --git a/composer.json b/composer.json index f86dc06f..de80d462 100644 --- a/composer.json +++ b/composer.json @@ -29,7 +29,7 @@ "spatie/laravel-activitylog": "^4.7", "spatie/laravel-csp": "^2.8", "spatie/laravel-fractal": "^6.0", - "spatie/laravel-html": "^3.12", + "spatie/laravel-html": "^3.5", "spatie/laravel-json-api-paginate": "^1.13", "spatie/laravel-permission": "^6.4", "spatie/laravel-query-builder": "^5.2", diff --git a/composer.lock b/composer.lock index 1f8f677b..1e144a58 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "4e7ee1edfe6896b0c775d0fe454a198b", + "content-hash": "2ffcf31285ea53025ab70e536dafe411", "packages": [ { "name": "akaunting/laravel-apexcharts", @@ -75,76 +75,6 @@ }, "time": "2025-04-04T21:02:33+00:00" }, - { - "name": "akaunting/money", - "version": "5.2.2", - "source": { - "type": "git", - "url": "https://github.com/akaunting/laravel-money.git", - "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/akaunting/laravel-money/zipball/d99a9e8e576cac40668d0a5afaf7ea153590aff9", - "reference": "d99a9e8e576cac40668d0a5afaf7ea153590aff9", - "shasum": "" - }, - "require": { - "illuminate/contracts": "^9.0|^10.0|^11.0", - "illuminate/support": "^9.0|^10.0|^11.0", - "illuminate/validation": "^9.0|^10.0|^11.0", - "illuminate/view": "^9.0|^10.0|^11.0", - "php": "^8.0", - "vlucas/phpdotenv": "^5.4.1" - }, - "require-dev": { - "orchestra/testbench": "^7.4|^8.0|^9.0", - "phpunit/phpunit": "^9.5|^10.0|^11.0", - "vimeo/psalm": "^4.23|^5.1" - }, - "type": "library", - "extra": { - "laravel": { - "providers": [ - "Akaunting\\Money\\Provider" - ] - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Akaunting\\Money\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Denis Duliçi", - "email": "info@akaunting.com", - "homepage": "https://akaunting.com", - "role": "Developer" - } - ], - "description": "Currency formatting and conversion package for Laravel", - "keywords": [ - "convert", - "currency", - "format", - "laravel", - "money" - ], - "support": { - "issues": "https://github.com/akaunting/laravel-money/issues", - "source": "https://github.com/akaunting/laravel-money/tree/5.2.2" - }, - "abandoned": "akaunting/laravel-money", - "time": "2024-09-25T10:06:11+00:00" - }, { "name": "alexusmai/laravel-file-manager", "version": "v3.1.1", @@ -2949,79 +2879,6 @@ }, "time": "2025-01-28T15:15:29+00:00" }, - { - "name": "laravelcollective/html", - "version": "v6.4.1", - "source": { - "type": "git", - "url": "https://github.com/LaravelCollective/html.git", - "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/LaravelCollective/html/zipball/64ddfdcaeeb8d332bd98bef442bef81e39c3910b", - "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b", - "shasum": "" - }, - "require": { - "illuminate/http": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/routing": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/session": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/view": "^6.0|^7.0|^8.0|^9.0|^10.0", - "php": ">=7.2.5" - }, - "require-dev": { - "illuminate/database": "^6.0|^7.0|^8.0|^9.0|^10.0", - "mockery/mockery": "~1.0", - "phpunit/phpunit": "~8.5|^9.5.10" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "6.x-dev" - }, - "laravel": { - "providers": [ - "Collective\\Html\\HtmlServiceProvider" - ], - "aliases": { - "Form": "Collective\\Html\\FormFacade", - "Html": "Collective\\Html\\HtmlFacade" - } - } - }, - "autoload": { - "files": [ - "src/helpers.php" - ], - "psr-4": { - "Collective\\Html\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Adam Engebretson", - "email": "adam@laravelcollective.com" - }, - { - "name": "Taylor Otwell", - "email": "taylorotwell@gmail.com" - } - ], - "description": "HTML and Form Builders for the Laravel Framework", - "homepage": "https://laravelcollective.com", - "support": { - "issues": "https://github.com/LaravelCollective/html/issues", - "source": "https://github.com/LaravelCollective/html" - }, - "abandoned": "spatie/laravel-html", - "time": "2023-04-25T02:46:11+00:00" - }, { "name": "league/commonmark", "version": "2.7.1", @@ -6011,6 +5868,84 @@ ], "time": "2025-02-14T10:43:50+00:00" }, + { + "name": "spatie/laravel-html", + "version": "3.5.0", + "source": { + "type": "git", + "url": "https://github.com/spatie/laravel-html.git", + "reference": "ead179a8b6802647027486049f5209bd23b610a9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/laravel-html/zipball/ead179a8b6802647027486049f5209bd23b610a9", + "reference": "ead179a8b6802647027486049f5209bd23b610a9", + "shasum": "" + }, + "require": { + "illuminate/http": "^9.0|^8.0|^10.0", + "illuminate/support": "^9.0|^8.0|^10.0", + "php": "^8.0" + }, + "require-dev": { + "mockery/mockery": "^1.3", + "orchestra/testbench": "^7.0|^6.23|^8.0", + "pestphp/pest": "^1.22" + }, + "type": "library", + "extra": { + "laravel": { + "aliases": { + "Html": "Spatie\\Html\\Facades\\Html" + }, + "providers": [ + "Spatie\\Html\\HtmlServiceProvider" + ] + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Spatie\\Html\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Sebastian De Deyne", + "email": "sebastian@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + }, + { + "name": "Freek Van der Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "A fluent html builder", + "homepage": "https://github.com/spatie/laravel-html", + "keywords": [ + "html", + "spatie" + ], + "support": { + "source": "https://github.com/spatie/laravel-html/tree/3.5.0" + }, + "funding": [ + { + "url": "https://spatie.be/open-source/support-us", + "type": "custom" + } + ], + "time": "2024-02-20T15:17:00+00:00" + }, { "name": "spatie/laravel-json-api-paginate", "version": "1.16.3", diff --git a/playwright.config.js b/playwright.config.js index d6e42fb5..7a41bd69 100644 --- a/playwright.config.js +++ b/playwright.config.js @@ -47,10 +47,10 @@ module.exports = defineConfig({ }, ], -// webServer: { -// command: `${configLoader.get('app.phpVersion')} artisan serve`, -// url: configLoader.get('app.baseURL'), -// reuseExistingServer: !process.env.CI, -// timeout: 120 * 1000, -// }, + webServer: { + command: 'php artisan serve', + url: configLoader.get('app.baseURL'), + reuseExistingServer: !process.env.CI, + timeout: 120 * 1000, + }, }); diff --git a/resources/views/articles/edit.blade.php b/resources/views/articles/edit.blade.php index 9badd084..87c3c0e9 100644 --- a/resources/views/articles/edit.blade.php +++ b/resources/views/articles/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Artikel
      - {!! Html::form('PUT', route('articles.update', $article->id))->attribute('enctype', 'multipart/form-data')->bind($article)->open() !!} + {!! Html::form('PUT', route('articles.update', $article->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/categories/edit.blade.php b/resources/views/categories/edit.blade.php index ab40f400..2d458c2b 100644 --- a/resources/views/categories/edit.blade.php +++ b/resources/views/categories/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Kategori
      - {!! Html::form('PUT', route('categories.update', $category->id))->bind($category)->open() !!} + {!! Html::form('PUT', route('categories.update', $category->id))->open() !!}
      diff --git a/resources/views/categories/fields.blade.php b/resources/views/categories/fields.blade.php index 886fc7df..4e8e23b0 100644 --- a/resources/views/categories/fields.blade.php +++ b/resources/views/categories/fields.blade.php @@ -2,7 +2,7 @@
      {!! Html::label('name', 'Nama Kategori')->class('col-3') !!}
      - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('name', old('name', $category->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -12,10 +12,10 @@ {!! Html::label('status', 'Tampilkan')->class('col-3') !!}
      diff --git a/resources/views/departments/edit.blade.php b/resources/views/departments/edit.blade.php index e27fcb15..f07ebe67 100644 --- a/resources/views/departments/edit.blade.php +++ b/resources/views/departments/edit.blade.php @@ -10,7 +10,7 @@  Kembali ke Daftar Department
      - {!! Html::form('PUT', route('departments.update', $department->id))->bind($department)->open() !!} + {!! Html::form('PUT', route('departments.update', $department->id))->open() !!}
      diff --git a/resources/views/departments/fields.blade.php b/resources/views/departments/fields.blade.php index fbc56def..bf8f99f0 100644 --- a/resources/views/departments/fields.blade.php +++ b/resources/views/departments/fields.blade.php @@ -1,14 +1,14 @@
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} + {!! Html::text('name', old('name', $department->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $department->description ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      diff --git a/resources/views/downloads/edit.blade.php b/resources/views/downloads/edit.blade.php index 39fdf42c..aa5b9b83 100644 --- a/resources/views/downloads/edit.blade.php +++ b/resources/views/downloads/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Unduhan
      - {!! Html::form('PUT', route('downloads.update', $download->id))->attribute('enctype', 'multipart/form-data')->bind($download)->open() !!} + {!! Html::form('PUT', route('downloads.update', $download->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/downloads/fields.blade.php b/resources/views/downloads/fields.blade.php index 9c537faa..ab99d381 100644 --- a/resources/views/downloads/fields.blade.php +++ b/resources/views/downloads/fields.blade.php @@ -2,7 +2,7 @@
      {!! Html::label('title', 'Judul')->class('col-3') !!}
      - {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('title', old('title', $download->title ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -19,7 +19,7 @@
      @if (isset($download)) @if ($download->url) - {{ link_to(Storage::url($download->url), 'berkas unduhan', ['class' => 'text-primary', 'target' => '_blank']) }} + {!! Html::a(Storage::url($download->url), 'berkas unduhan')->class('text-primary')->target('_blank') !!} @endif @endif
      @@ -29,7 +29,7 @@
      {!! Html::label('description', 'Keterangan')->class('col-3') !!}
      - {!! Html::textarea('description')->class('form-control')->attribute('rows', 3)->attribute('maxlength', 65535) !!} + {!! Html::textarea('description', old('description', $download->description ?? ''))->class('form-control')->attribute('rows', 3)->attribute('maxlength', 65535) !!}
      @@ -37,7 +37,7 @@
      {!! Html::label('state', 'Status')->class('col-3') !!}
      - {!! Html::select('state', $stateItem)->class('form-control select2')->attribute('required') !!} + {!! Html::select('state', $stateItem, old('state', $download->state ?? ''))->class('form-control select2')->attribute('required') !!}
      diff --git a/resources/views/employees/edit.blade.php b/resources/views/employees/edit.blade.php index a1a1ef4b..77afa453 100644 --- a/resources/views/employees/edit.blade.php +++ b/resources/views/employees/edit.blade.php @@ -10,7 +10,7 @@  Kembali ke Daftar Employee
      - {!! Html::form('PUT', route('employees.update', $employee->id))->attribute('enctype', 'multipart/form-data')->bind($employee)->open() !!} + {!! Html::form('PUT', route('employees.update', $employee->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/employees/fields.blade.php b/resources/views/employees/fields.blade.php index 85e68132..fff87646 100644 --- a/resources/views/employees/fields.blade.php +++ b/resources/views/employees/fields.blade.php @@ -1,7 +1,7 @@
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} + {!! Html::text('name', old('name', $employee->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      @push('page_scripts') @@ -13,25 +13,25 @@
      {!! Html::label('identity_number', 'NIP:') !!} - {!! Html::text('identity_number')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('identity_number', old('identity_number', $employee->identity_number ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      {!! Html::label('email', 'Email:') !!} - {!! Html::email('email')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::email('email', old('email', $employee->email ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $employee->description ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('phone', 'Telepon:') !!} - {!! Html::text('phone')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('phone', old('phone', $employee->phone ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      @@ -43,41 +43,45 @@
      {!! Html::label('department_id', 'Departemen:') !!} - {!! Html::select('department_id', $departments)->class('form-control select2') !!} + {!! Html::select('department_id', $departments, old('department_id', $employee->department_id ?? ''))->class( + 'form-control select2', + ) !!}
      {!! Html::label('identity_number', 'NIP:') !!} - {!! Html::text('identity_number')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('identity_number', old('identity_number', $employee->identity_number ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      {!! Html::label('email', 'Email:') !!} - {!! Html::email('email')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::email('email', old('email', $employee->email ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $employee->description ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      {!! Html::label('phone', 'Telepon:') !!} - {!! Html::text('phone')->class('form-control')->attribute('maxlength', 20) !!} + {!! Html::text('phone', old('phone', $employee->phone ?? ''))->class('form-control')->attribute('maxlength', 20) !!}
      {!! Html::label('position_id', 'Jabatan:') !!} - {!! Html::select('position_id', $positions)->class('form-control select2') !!} + {!! Html::select('position_id', $positions, old('position_id', $employee->position_id ?? ''))->class( + 'form-control select2', + ) !!}
      diff --git a/resources/views/group/fields.blade.php b/resources/views/group/fields.blade.php index 2469ebac..1175de3d 100644 --- a/resources/views/group/fields.blade.php +++ b/resources/views/group/fields.blade.php @@ -10,7 +10,7 @@ {!! Html::select( 'icon', [ - '' => 'Select Icon', // Pilihan kosong di awal + '' => 'Pilih Ikon', // Pilihan kosong di awal 'fas fa-list' => 'List', 'fas fa-home' => 'Home', 'fas fa-user' => 'User', @@ -60,10 +60,10 @@
      diff --git a/resources/views/menus/fields.blade.php b/resources/views/menus/fields.blade.php index 43514930..cc7f5905 100644 --- a/resources/views/menus/fields.blade.php +++ b/resources/views/menus/fields.blade.php @@ -8,7 +8,7 @@ {!! Html::select( 'icon', [ - '' => 'Select Icon', // Pilihan kosong di awal + '' => 'Pilih Ikon', // Pilihan kosong di awal 'fas fa-list' => 'List', 'fas fa-home' => 'Home', 'fas fa-user' => 'User', @@ -59,16 +59,16 @@
      diff --git a/resources/views/pages/edit.blade.php b/resources/views/pages/edit.blade.php index 77057e2a..50714562 100644 --- a/resources/views/pages/edit.blade.php +++ b/resources/views/pages/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Halaman
      - {!! Html::form('PUT', route('pages.update', $page->id))->attribute('enctype', 'multipart/form-data')->bind($page)->open() !!} + {!! Html::form('PUT', route('pages.update', $page->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/pages/fields.blade.php b/resources/views/pages/fields.blade.php index 40d70596..936fd865 100644 --- a/resources/views/pages/fields.blade.php +++ b/resources/views/pages/fields.blade.php @@ -3,13 +3,13 @@
      {!! Html::label('title', 'Judul') !!} - {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 200) !!} + {!! Html::text('title', old('title', $page->title ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 200) !!}
      {!! Html::label('content', 'Isi') !!} - {!! Html::textarea('content')->class('form-control editor')->attribute('required')->attribute('maxlength', 65535) !!} + {!! Html::textarea('content', old('content', $page->content ?? ''))->class('form-control editor')->attribute('required')->attribute('maxlength', 65535) !!}
      diff --git a/resources/views/positions/edit.blade.php b/resources/views/positions/edit.blade.php index 286cf420..5637d799 100644 --- a/resources/views/positions/edit.blade.php +++ b/resources/views/positions/edit.blade.php @@ -10,7 +10,7 @@  Kembali ke Daftar Position
      - {!! Html::form('PUT', route('positions.update', $position->id))->bind($position)->open() !!} + {!! Html::form('PUT', route('positions.update', $position->id))->open() !!}
      diff --git a/resources/views/positions/fields.blade.php b/resources/views/positions/fields.blade.php index 2d7580c7..0f17f536 100644 --- a/resources/views/positions/fields.blade.php +++ b/resources/views/positions/fields.blade.php @@ -1,7 +1,7 @@
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 50) !!} + {!! Html::text('name', old('name', $position->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50) !!}
      @push('page_scripts') @@ -13,7 +13,7 @@
      {!! Html::label('description', 'Deskripsi:') !!} - {!! Html::text('description')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('description', old('description', $position->description ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      diff --git a/resources/views/settings/edit.blade.php b/resources/views/settings/edit.blade.php index b4f5f864..a495d4a9 100644 --- a/resources/views/settings/edit.blade.php +++ b/resources/views/settings/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Setting
      - {!! Html::form('PUT', route('settings.update', $setting->id))->bind($setting)->open() !!} + {!! Html::form('PUT', route('settings.update', $setting->id))->open() !!}
      diff --git a/resources/views/settings/fields.blade.php b/resources/views/settings/fields.blade.php index 6fc86969..6632567f 100644 --- a/resources/views/settings/fields.blade.php +++ b/resources/views/settings/fields.blade.php @@ -1,14 +1,14 @@
      {!! Html::label('key', 'Kode Kunci:') !!} - {!! Html::text('key')->class('form-control')->attribute('required')->attribute('maxlength', 50)->attribute('disabled') !!} + {!! Html::text('key', old('key', $setting->key ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 50)->attribute('disabled') !!}
      {!! Html::label('name', 'Nama:') !!} - {!! Html::text('name')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('name', old('name', $setting->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -16,12 +16,16 @@ @switch($setting->type) @case('dropdown') {!! Html::label('value', 'Status:') !!} - {!! Html::select('value', collect($setting->attribute)->pluck('text', 'value'), $setting->value)->class('form-control')->attribute('required') !!} + {!! Html::select( + 'value', + collect($setting->attribute)->pluck('text', 'value'), + old('value', $setting->value ?? ''), + )->class('form-control')->attribute('required') !!} @break @default {!! Html::label('value', 'Nilai:') !!} - {!! Html::text('value')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('value', old('value', $setting->value ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} @endswitch
      diff --git a/resources/views/slides/edit.blade.php b/resources/views/slides/edit.blade.php index ded9995f..cd6883e8 100644 --- a/resources/views/slides/edit.blade.php +++ b/resources/views/slides/edit.blade.php @@ -15,7 +15,7 @@  Kembali ke Daftar Slide
      - {!! Html::form('PUT', route('slides.update', $slide->id))->attribute('enctype', 'multipart/form-data')->bind($slide)->open() !!} + {!! Html::form('PUT', route('slides.update', $slide->id))->attribute('enctype', 'multipart/form-data')->open() !!}
      diff --git a/resources/views/slides/fields.blade.php b/resources/views/slides/fields.blade.php index f3c6ac61..6c4f6d82 100644 --- a/resources/views/slides/fields.blade.php +++ b/resources/views/slides/fields.blade.php @@ -4,7 +4,7 @@ {!! Html::label('title', 'Judul') !!}
      - {!! Html::text('title')->class('form-control')->attribute('required')->attribute('maxlength', 255) !!} + {!! Html::text('title', old('title', $slide->title ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -12,10 +12,10 @@
      - {!! Html::label('url', 'Url') !!} + {!! Html::label('url', 'Tautan') !!}
      - {!! Html::text('url')->class('form-control')->attribute('maxlength', 255) !!} + {!! Html::text('url', old('url', $slide->url ?? ''))->class('form-control')->attribute('maxlength', 255) !!}
      @@ -25,7 +25,7 @@ {!! Html::label('description', 'Keterangan') !!}
      - {!! Html::textarea('description')->class('form-control')->attribute('rows', 4)->attribute('maxlength', 65535) !!} + {!! Html::textarea('description', old('description', $slide->description ?? ''))->class('form-control')->attribute('rows', 4)->attribute('maxlength', 65535) !!}
      @@ -35,10 +35,10 @@ {!! Html::label('state', 'Status')->class('col-3') !!}
      From e9ec66e6b626b0665f3ae9e9ee393d7b39fe97e0 Mon Sep 17 00:00:00 2001 From: ahmad afandi Date: Wed, 27 Aug 2025 07:46:36 +0700 Subject: [PATCH 6/8] Perbaiki label --- composer.lock | 10 +++---- resources/views/articles/fields.blade.php | 10 +++---- .../views/articles/show_fields.blade.php | 12 ++++----- resources/views/categories/fields.blade.php | 4 +-- .../views/categories/show_fields.blade.php | 7 +++-- resources/views/departments/fields.blade.php | 6 ++--- .../views/departments/show_fields.blade.php | 6 ++--- resources/views/downloads/fields.blade.php | 8 +++--- resources/views/employees/fields.blade.php | 26 +++++++++---------- .../views/employees/show_fields.blade.php | 18 ++++++------- resources/views/pages/fields.blade.php | 8 +++--- resources/views/positions/fields.blade.php | 6 ++--- .../views/positions/show_fields.blade.php | 6 ++--- resources/views/settings/fields.blade.php | 10 +++---- .../views/settings/show_fields.blade.php | 13 +++++----- resources/views/slides/fields.blade.php | 10 +++---- 16 files changed, 79 insertions(+), 81 deletions(-) diff --git a/composer.lock b/composer.lock index 1e144a58..d488948f 100644 --- a/composer.lock +++ b/composer.lock @@ -9989,16 +9989,16 @@ }, { "name": "laravel/sail", - "version": "v1.44.0", + "version": "v1.45.0", "source": { "type": "git", "url": "https://github.com/laravel/sail.git", - "reference": "a09097bd2a8a38e23ac472fa6a6cf5b0d1c1d3fe" + "reference": "019a2933ff4a9199f098d4259713f9bc266a874e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/sail/zipball/a09097bd2a8a38e23ac472fa6a6cf5b0d1c1d3fe", - "reference": "a09097bd2a8a38e23ac472fa6a6cf5b0d1c1d3fe", + "url": "https://api.github.com/repos/laravel/sail/zipball/019a2933ff4a9199f098d4259713f9bc266a874e", + "reference": "019a2933ff4a9199f098d4259713f9bc266a874e", "shasum": "" }, "require": { @@ -10048,7 +10048,7 @@ "issues": "https://github.com/laravel/sail/issues", "source": "https://github.com/laravel/sail" }, - "time": "2025-07-04T16:17:06+00:00" + "time": "2025-08-25T19:28:31+00:00" }, { "name": "mockery/mockery", diff --git a/resources/views/articles/fields.blade.php b/resources/views/articles/fields.blade.php index bbcd2205..c30e7734 100644 --- a/resources/views/articles/fields.blade.php +++ b/resources/views/articles/fields.blade.php @@ -3,13 +3,13 @@
      - {!! Html::label('title', 'Judul Artikel') !!} + {!! Html::label('Judul Artikel', 'title') !!} {!! Html::text('title')->class('form-control')->required()->maxlength(255)->value(old('title', $article->title ?? null)) !!}
      - {!! Html::label('content', 'Isi Artikel') !!} + {!! Html::label('Isi Artikel', 'content') !!} {!! Html::textarea('content')->class('form-control editor')->required()->maxlength(65535)->value(old('content', $article->content ?? null)) !!}
      @@ -21,19 +21,19 @@
      - {!! Html::label('category_id', 'Kategori') !!} + {!! Html::label('Kategori', 'category_id') !!} {!! Html::select('category_id', $categories)->class('form-control select2')->required()->value(old('category_id', $article->category_id ?? null)) !!}
      - {!! Html::label('state', 'Status') !!} + {!! Html::label('Status', 'state') !!} {!! Html::select('state', $stateItem)->class('form-control select2')->required()->value(old('state', $article->state ?? null)) !!}
      - {!! Html::label('published_at', 'Tanggal Terbit') !!} + {!! Html::label('Tanggal Terbit', 'published_at') !!} {!! Html::text('published_at')->class('form-control datepicker')->id('published_at')->value(old('published_at', $article?->local_published_at)) !!}
      diff --git a/resources/views/articles/show_fields.blade.php b/resources/views/articles/show_fields.blade.php index f628450e..b7ed77e9 100644 --- a/resources/views/articles/show_fields.blade.php +++ b/resources/views/articles/show_fields.blade.php @@ -1,35 +1,35 @@
      - {!! Html::label('category_id', 'Category Id:') !!} + {!! Html::label('ID Kategori:', 'category_id') !!}

      {{ $article->category_id }}

      - {!! Html::label('published_at', 'Published At:') !!} + {!! Html::label('Tanggal Terbit:', 'published_at') !!}

      {{ $article->published_at }}

      - {!! Html::label('slug', 'Slug:') !!} + {!! Html::label('Slug:', 'slug') !!}

      {{ $article->slug }}

      - {!! Html::label('title', 'Title:') !!} + {!! Html::label('Judul:', 'title') !!}

      {{ $article->title }}

      - {!! Html::label('description', 'Description:') !!} + {!! Html::label('Deskripsi:', 'description') !!}

      {{ $article->description }}

      - {!! Html::label('content', 'Content:') !!} + {!! Html::label('Konten:', 'content') !!}

      {{ $article->content }}

      diff --git a/resources/views/categories/fields.blade.php b/resources/views/categories/fields.blade.php index 4e8e23b0..47e5d005 100644 --- a/resources/views/categories/fields.blade.php +++ b/resources/views/categories/fields.blade.php @@ -1,6 +1,6 @@
      - {!! Html::label('name', 'Nama Kategori')->class('col-3') !!} + {!! Html::label('Nama Kategori', 'name')->class('col-3') !!}
      {!! Html::text('name', old('name', $category->name ?? ''))->class('form-control')->attribute('required')->attribute('maxlength', 255) !!}
      @@ -9,7 +9,7 @@
      - {!! Html::label('status', 'Tampilkan')->class('col-3') !!} + {!! Html::label('Tampilkan', 'status')->class('col-3') !!}