- Added approval and rejection functionality for products, including new routes and methods in the ProductController. - Implemented UI changes to display product status (pending, rejected) with appropriate badges and actions. - Introduced a RejectDialog component for providing rejection reasons. - Updated product columns to handle new actions for approving and rejecting products. - Enhanced variant management to restrict actions based on product status. - Refactored various components to improve code organization and readability.
32 lines
910 B
PHP
32 lines
910 B
PHP
<?php
|
|
|
|
namespace App\OldDataMigrations;
|
|
|
|
class SystemConfigMigration extends BaseOldDataMigration
|
|
{
|
|
public function priority(): int
|
|
{
|
|
return 11;
|
|
}
|
|
|
|
public function migrate(): array
|
|
{
|
|
$results = [];
|
|
|
|
$results['system_configurations'] = $this->migrateTable('system_configurations');
|
|
$results['push_subscriptions'] = $this->migrateTable('push_subscriptions', function ($row) {
|
|
if (isset($row['user_id']) && $row['user_id'] !== null) {
|
|
$row['subscribable_type'] = 'App\\Models\\User';
|
|
$row['subscribable_id'] = $row['user_id'];
|
|
}
|
|
unset($row['user_id']);
|
|
|
|
return $row;
|
|
});
|
|
$results['homepage_configurations'] = $this->migrateTable('homepage_configurations');
|
|
$results['notifications'] = $this->migrateTable('notifications');
|
|
|
|
return $results;
|
|
}
|
|
}
|