major ui updates
This commit is contained in:
@@ -18,7 +18,7 @@ class CreateNewUser implements CreatesNewUsers
|
||||
/**
|
||||
* Validate and create a newly registered user with an isolated company tenant.
|
||||
*
|
||||
* @param array<string, string> $input
|
||||
* @param array<string, string> $input
|
||||
*/
|
||||
public function create(array $input): User
|
||||
{
|
||||
@@ -29,11 +29,11 @@ class CreateNewUser implements CreatesNewUsers
|
||||
])->validate();
|
||||
|
||||
return DB::transaction(function () use ($input): User {
|
||||
$companyName = $input['company_name'] ?? ($input['name'] . ' Company');
|
||||
$companyName = $input['company_name'] ?? ($input['name'].' Company');
|
||||
|
||||
$company = Company::create([
|
||||
'name' => $companyName,
|
||||
'slug' => Str::slug($companyName . '-' . Str::random(6)),
|
||||
'slug' => Str::slug($companyName.'-'.Str::random(6)),
|
||||
'status' => 'active',
|
||||
'timezone' => 'Europe/London',
|
||||
]);
|
||||
|
||||
@@ -2,6 +2,4 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
class Company extends \Modules\Platform\app\Models\Company
|
||||
{
|
||||
}
|
||||
class Company extends \Modules\Platform\app\Models\Company {}
|
||||
|
||||
@@ -2,6 +2,4 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
class LicenseKey extends \Modules\Platform\app\Models\LicenseKey
|
||||
{
|
||||
}
|
||||
class LicenseKey extends \Modules\Platform\app\Models\LicenseKey {}
|
||||
|
||||
@@ -2,6 +2,4 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
class Payment extends \Modules\Platform\app\Models\Payment
|
||||
{
|
||||
}
|
||||
class Payment extends \Modules\Platform\app\Models\Payment {}
|
||||
|
||||
@@ -2,6 +2,4 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
class Warehouse extends \Modules\Warehouse\app\Models\Warehouse
|
||||
{
|
||||
}
|
||||
class Warehouse extends \Modules\Warehouse\app\Models\Warehouse {}
|
||||
|
||||
@@ -2,6 +2,4 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
class WarehouseValidationRule extends \Modules\Warehouse\app\Models\WarehouseValidationRule
|
||||
{
|
||||
}
|
||||
class WarehouseValidationRule extends \Modules\Warehouse\app\Models\WarehouseValidationRule {}
|
||||
|
||||
@@ -4,6 +4,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use Illuminate\Contracts\Http\Kernel;
|
||||
use Illuminate\Support\Facades\Event;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
@@ -142,7 +143,7 @@ class TenancyServiceProvider extends ServiceProvider
|
||||
];
|
||||
|
||||
foreach (array_reverse($tenancyMiddleware) as $middleware) {
|
||||
$this->app[\Illuminate\Contracts\Http\Kernel::class]->prependToMiddlewarePriority($middleware);
|
||||
$this->app[Kernel::class]->prependToMiddlewarePriority($middleware);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,11 +75,11 @@ final class DashboardChartService
|
||||
|
||||
try {
|
||||
$rows = DB::connection('odbc')->select(
|
||||
"SELECT DATE(A5PICKCMTS) AS PICK_DATE, COUNT(*) AS TOTAL
|
||||
'SELECT DATE(A5PICKCMTS) AS PICK_DATE, COUNT(*) AS TOTAL
|
||||
FROM EWDAT.ICM688M2
|
||||
WHERE A5PICKCMTS >= CURRENT DATE - 7 DAYS
|
||||
GROUP BY DATE(A5PICKCMTS)
|
||||
ORDER BY PICK_DATE"
|
||||
ORDER BY PICK_DATE'
|
||||
);
|
||||
|
||||
foreach ($rows as $row) {
|
||||
@@ -171,12 +171,12 @@ final class DashboardChartService
|
||||
|
||||
try {
|
||||
$rows = DB::connection('odbc')->select(
|
||||
"SELECT TRIM(AT9WHS) AS WAREHOUSE, COUNT(*) AS TOTAL
|
||||
'SELECT TRIM(AT9WHS) AS WAREHOUSE, COUNT(*) AS TOTAL
|
||||
FROM EWDAT.ICM709M
|
||||
WHERE AT9QTY <= AT9WRN
|
||||
GROUP BY TRIM(AT9WHS)
|
||||
ORDER BY TOTAL DESC
|
||||
FETCH FIRST 6 ROWS ONLY"
|
||||
FETCH FIRST 6 ROWS ONLY'
|
||||
);
|
||||
|
||||
if (! empty($rows)) {
|
||||
@@ -204,12 +204,12 @@ final class DashboardChartService
|
||||
|
||||
try {
|
||||
$rows = DB::connection('odbc')->select(
|
||||
"SELECT
|
||||
'SELECT
|
||||
SUM(A5RSVQTY) AS RESERVED_QTY,
|
||||
SUM(A5PACKED) AS PACKED_QTY,
|
||||
SUM(A5RSVQTY - A5PACKED) AS REMAINING_QTY
|
||||
FROM EWDAT.ICM688M2
|
||||
WHERE A5RSVQTY > 0"
|
||||
WHERE A5RSVQTY > 0'
|
||||
);
|
||||
|
||||
if (! empty($rows)) {
|
||||
@@ -260,7 +260,7 @@ final class DashboardChartService
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, string> $labels
|
||||
* @return array<string, int>
|
||||
*/
|
||||
private function emptySeries(array $labels): array
|
||||
@@ -287,8 +287,8 @@ final class DashboardChartService
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, int> $data
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, int> $data
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
private function lineChart(array $labels, array $data, string $label): array
|
||||
@@ -305,8 +305,8 @@ final class DashboardChartService
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, int> $data
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, int> $data
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
private function barChart(array $labels, array $data, string $label): array
|
||||
@@ -322,8 +322,8 @@ final class DashboardChartService
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, int> $data
|
||||
* @param array<int, string> $labels
|
||||
* @param array<int, int> $data
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
private function doughnutChart(array $labels, array $data, string $label): array
|
||||
|
||||
Reference in New Issue
Block a user