mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-17 15:52:15 +00:00
force migration
added maintenance mode
This commit is contained in:
@@ -125,6 +125,28 @@ class UpgradeAppController extends Controller
|
||||
return response('Done', 200);
|
||||
}
|
||||
|
||||
/**
|
||||
* Start maintenance mode
|
||||
*/
|
||||
public function up() {
|
||||
$command = Artisan::call('up');
|
||||
|
||||
if ($command === 0) {
|
||||
echo 'System is in production mode';
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* End maintenance mode
|
||||
*/
|
||||
public function down() {
|
||||
$command = Artisan::call('down');
|
||||
|
||||
if ($command === 0) {
|
||||
echo 'System is in maintenance mode';
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Upgrade database
|
||||
*/
|
||||
@@ -137,7 +159,9 @@ class UpgradeAppController extends Controller
|
||||
*/
|
||||
if (! Schema::hasColumn('shares', 'expire_in')) {
|
||||
|
||||
$command = Artisan::call('migrate');
|
||||
$command = Artisan::call('migrate', [
|
||||
'--force' => true
|
||||
]);
|
||||
|
||||
if ($command === 0) {
|
||||
echo 'Operation was successful.';
|
||||
|
||||
Reference in New Issue
Block a user