fix: add null check for media model in CustomPathGenerator and remove duplicate transaction permissions in RolePermissionSeeder
This commit is contained in:
parent
a5185eab56
commit
7f91ce22db
@ -11,7 +11,7 @@ public function getPath(Media $media): string
|
||||
{
|
||||
$model = $media->model;
|
||||
|
||||
if (method_exists($model, 'getMediaPath')) {
|
||||
if ($model && method_exists($model, 'getMediaPath')) {
|
||||
return $model->getMediaPath($media).'/';
|
||||
}
|
||||
|
||||
|
||||
@ -31,7 +31,6 @@ public function run(): void
|
||||
'cutting' => ['view', 'create', 'update', 'delete'],
|
||||
'restock' => ['view', 'create', 'update', 'delete'],
|
||||
'transaction' => ['view', 'create', 'update', 'delete'],
|
||||
'transaction' => ['view', 'create', 'update', 'delete'],
|
||||
'dashboard' => ['attendance', 'revenue', 'expense', 'orders_channel', 'orders_payment', 'orders_marketing', 'orders_status'],
|
||||
'analysis' => ['attendance', 'cash', 'raw_materials', 'product_stock', 'revenue', 'expense', 'profit_gross', 'profit_hpp', 'profit_orders', 'marketing_sales', 'top_suppliers', 'top_products', 'top_customers', 'busy_hours'],
|
||||
];
|
||||
|
||||
Loading…
Reference in New Issue
Block a user