mirror of
https://github.com/grocy/grocy.git
synced 2025-04-29 01:32:38 +00:00
20 lines
449 B
PHP
20 lines
449 B
PHP
<?php
|
|
|
|
namespace Grocy\Controllers;
|
|
|
|
use Grocy\Services\ApplicationService;
|
|
use Grocy\Services\DatabaseMigrationService;
|
|
|
|
class CliController extends BaseController
|
|
{
|
|
public function RecreateDemo($request, $response, $args)
|
|
{
|
|
$applicationService = new ApplicationService();
|
|
if ($applicationService->IsDemoInstallation())
|
|
{
|
|
$databaseMigrationService = new DatabaseMigrationService();
|
|
$databaseMigrationService->RecreateDemo();
|
|
}
|
|
}
|
|
}
|