Upgraded to Laravel 9

This commit is contained in:
Fahim Anzam Dip 2023-07-28 14:17:57 +06:00
parent 8ce456ec7b
commit 58c8ae636f
28 changed files with 1668 additions and 1680 deletions

12
.htaccess Normal file
View File

@ -0,0 +1,12 @@
DirectoryIndex index.php
RewriteEngine On
RewriteRule ^$ public/index.php [L]
RewriteRule ^((?!public/).*)$ public/$1 [L,NC]
# php -- BEGIN cPanel-generated handler, do not edit
# Set the “ea-php74” package as the default “PHP” programming language.
<IfModule mime_module>
AddHandler application/x-httpd-ea-php74 .php .php7 .phtml
</IfModule>
# php -- END cPanel-generated handler, do not edit

View File

@ -67,7 +67,7 @@ class AdjustmentsDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Adjustments_' . date('YmdHis');
}
}

View File

@ -72,7 +72,7 @@ class CurrencyDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Currency_' . date('YmdHis');
}
}

View File

@ -66,7 +66,7 @@ class ExpenseCategoriesDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'ExpenseCategories_' . date('YmdHis');
}
}

View File

@ -76,7 +76,7 @@ class ExpensesDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Expenses_' . date('YmdHis');
}
}

View File

@ -67,7 +67,7 @@ class CustomersDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Customers_' . date('YmdHis');
}
}

View File

@ -67,7 +67,7 @@ class SuppliersDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Suppliers_' . date('YmdHis');
}
}

View File

@ -66,7 +66,7 @@ class ProductCategoriesDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'ProductCategories_' . date('YmdHis');
}
}

View File

@ -101,7 +101,7 @@ class ProductDataTable extends DataTable
*
* @return string
*/
protected function filename()
protected function filename(): string
{
return 'Product_' . date('YmdHis');
}

View File

@ -22,6 +22,11 @@
</div>
<div class="row mt-4">
<div class="col-md-12">
<div class="alert alert-info">
<strong>NOTE: Product Code must be a number to generate barcodes!</strong>
</div>
</div>
<div class="col-md-12">
<livewire:barcode.product-table/>
</div>

View File

@ -94,7 +94,7 @@ class PurchaseDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Purchase_' . date('YmdHis');
}
}

View File

@ -71,7 +71,7 @@ class PurchasePaymentsDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'PurchasePayments_' . date('YmdHis');
}
}

View File

@ -11,6 +11,7 @@ use Yajra\DataTables\Services\DataTable;
class PurchaseReturnPaymentsDataTable extends DataTable
{
public function dataTable($query) {
return datatables()
->eloquent($query)
@ -71,8 +72,7 @@ class PurchaseReturnPaymentsDataTable extends DataTable
];
}
protected function filename()
{
protected function filename(): string {
return 'PurchaseReturnPayments_' . date('YmdHis');
}
}

View File

@ -11,6 +11,7 @@ use Yajra\DataTables\Services\DataTable;
class PurchaseReturnsDataTable extends DataTable
{
public function dataTable($query) {
return datatables()
->eloquent($query)
@ -92,8 +93,8 @@ class PurchaseReturnsDataTable extends DataTable
->visible(false)
];
}
protected function filename()
{
protected function filename(): string {
return 'PurchaseReturns_' . date('YmdHis');
}
}

View File

@ -79,7 +79,7 @@ class QuotationsDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Quotations_' . date('YmdHis');
}
}

View File

@ -72,7 +72,7 @@ class SalePaymentsDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'SalePayments_' . date('YmdHis');
}
}

View File

@ -94,7 +94,7 @@ class SalesDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Sales_' . date('YmdHis');
}
}

View File

@ -108,7 +108,7 @@
<td class="right">{{ format_currency($sale->tax_amount) }}</td>
</tr>
<tr>
<td class="left"><strong>Shipping)</strong></td>
<td class="left"><strong>Shipping</strong></td>
<td class="right">{{ format_currency($sale->shipping_amount) }}</td>
</tr>
<tr>

View File

@ -11,6 +11,7 @@ use Yajra\DataTables\Services\DataTable;
class SaleReturnPaymentsDataTable extends DataTable
{
public function dataTable($query) {
return datatables()
->eloquent($query)
@ -71,8 +72,7 @@ class SaleReturnPaymentsDataTable extends DataTable
];
}
protected function filename()
{
protected function filename(): string {
return 'SaleReturnPayments_' . date('YmdHis');
}
}

View File

@ -11,6 +11,7 @@ use Yajra\DataTables\Services\DataTable;
class SaleReturnsDataTable extends DataTable
{
public function dataTable($query) {
return datatables()
->eloquent($query)
@ -93,8 +94,7 @@ class SaleReturnsDataTable extends DataTable
];
}
protected function filename()
{
protected function filename(): string {
return 'SaleReturns_' . date('YmdHis');
}
}

View File

@ -79,7 +79,7 @@ class RolesDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Roles_' . date('YmdHis');
}
}

View File

@ -96,7 +96,7 @@ class UsersDataTable extends DataTable
];
}
protected function filename() {
protected function filename(): string {
return 'Users_' . date('YmdHis');
}
}

View File

@ -35,6 +35,10 @@ class ProductTable extends Component
return session()->flash('message', 'Max quantity is 100 per barcode generation!');
}
if (!is_int($product->product_code)) {
return session()->flash('message', 'Can not generate Barcode with this type of Product Code');
}
$this->barcodes = [];
for ($i = 1; $i <= $quantity; $i++) {

View File

@ -5,31 +5,31 @@
"keywords": ["framework", "laravel"],
"license": "MIT",
"require": {
"php": "^7.3|^8.0",
"barryvdh/laravel-snappy": "^0.4.8",
"php": "^8.1",
"barryvdh/laravel-snappy": "^1.0",
"bumbummen99/shoppingcart": "^4.0",
"fideloper/proxy": "^4.4",
"fruitcake/laravel-cors": "^2.0",
"guzzlehttp/guzzle": "^7.0.1",
"h4cc/wkhtmltopdf-amd64": "^0.12.4",
"laravel/framework": "^8.40",
"laravel/framework": "^9.0",
"laravel/tinker": "^2.5",
"laravel/ui": "^3.3",
"livewire/livewire": "^2.5",
"milon/barcode": "^8.0",
"milon/barcode": "^9.0",
"nwidart/laravel-modules": "8.2",
"realrashid/sweet-alert": "^4.0",
"spatie/laravel-medialibrary": "^9.0.0",
"spatie/laravel-permission": "^4.2",
"yajra/laravel-datatables": "^1.5"
"realrashid/sweet-alert": "^5.0",
"spatie/laravel-medialibrary": "^10.0",
"spatie/laravel-permission": "^5.0",
"yajra/laravel-datatables": "^9.0"
},
"require-dev": {
"barryvdh/laravel-debugbar": "^3.6",
"facade/ignition": "^2.5",
"spatie/laravel-ignition": "^1.0",
"fakerphp/faker": "^1.9.1",
"laravel/sail": "^1.0.1",
"mockery/mockery": "^1.4.2",
"nunomaduro/collision": "^5.0",
"nunomaduro/collision": "^6.1",
"phpunit/phpunit": "^9.3.3"
},
"autoload": {

3248
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -35,8 +35,8 @@ return [
'pdf' => [
'enabled' => true,
'binary' => env('WKHTML_PDF_BINARY', base_path('vendor/h4cc/wkhtmltopdf-amd64/bin/wkhtmltopdf-amd64'),),
//'binary' => env('WKHTML_PDF_BINARY', base_path('"C:\Program Files\wkhtmltopdf\bin\wkhtmltopdf.exe"'),),
//'binary' => env('WKHTML_PDF_BINARY', base_path('vendor/h4cc/wkhtmltopdf-amd64/bin/wkhtmltopdf-amd64'),),
'binary' => env('WKHTML_PDF_BINARY', 'C:\\wkhtmltopdf\\bin\\wkhtmltopdf.exe'),
'timeout' => false,
'options' => [
'enable-local-file-access' => true,
@ -47,7 +47,7 @@ return [
'image' => [
'enabled' => true,
'binary' => env('WKHTML_IMG_BINARY', '"C:\Program Files\wkhtmltopdf\bin\wkhtmltoimage.exe"'),
'binary' => env('WKHTML_IMG_BINARY', ''),
'timeout' => false,
'options' => [
'enable-local-file-access' => true

View File

@ -1,5 +1,5 @@
<footer class="c-footer">
<div>Triangle Pos © {{ date('Y') }} || Developed by <strong><a target="_blank" href="https://fahimanzamdip.github.io">Fahim Anzam Dip</a></strong></div>
<div class="mfs-auto d-md-down-none">Version <strong class="text-danger">1.0.0</strong></div>
<div class="mfs-auto d-md-down-none">Version <strong class="text-danger">1.1.0</strong></div>
</footer>

View File

@ -9,7 +9,7 @@
</div>
</div>
@forelse($products as $product)
<div wire:click.prevent="selectProduct({{ $product }})" class="col-lg-4 col-md-6" style="cursor: pointer;">
<div wire:click.prevent="selectProduct({{ $product }})" class="col-lg-4 col-md-6 col-xl-3" style="cursor: pointer;">
<div class="card border-0 shadow h-100">
<div class="position-relative">
<img height="200" src="{{ $product->getFirstMediaUrl('images') }}" class="card-img-top" alt="Product Image">