mirror of
https://github.com/crater-invoice/crater.git
synced 2025-10-27 19:51:09 -04:00
Merge branch 'build-201' into 'master'
Build 201 See merge request mohit.panjvani/crater-web!113
This commit is contained in:
@ -15,7 +15,7 @@ class Listener
|
||||
protected function isListenerFired($event)
|
||||
{
|
||||
// Do not apply to the same or newer versions
|
||||
if (version_compare(static::VERSION, $event->old, '<')) {
|
||||
if (version_compare(static::VERSION, $event->old, '<=')) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@ -49,20 +49,22 @@ class EnvironmentManager
|
||||
'DB_PASSWORD='.$request->database_password."\n\n";
|
||||
|
||||
try {
|
||||
if ($this->checkDatabaseConnection($request)) {
|
||||
if(\Schema::hasTable('users') ) {
|
||||
return [
|
||||
'error' => 'database_should_be_empty'
|
||||
];
|
||||
}
|
||||
|
||||
$this->checkDatabaseConnection($request);
|
||||
|
||||
if(\Schema::hasTable('users') ) {
|
||||
return [
|
||||
'error' => 'database_should_be_empty'
|
||||
];
|
||||
}
|
||||
|
||||
} catch (Exception $e) {
|
||||
|
||||
return [
|
||||
'error' => $e->getMessage()
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
|
||||
file_put_contents($this->envPath, str_replace(
|
||||
@ -120,8 +122,6 @@ class EnvironmentManager
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
} catch (Exception $e) {
|
||||
return [
|
||||
'error' => 'mail_variables_save_error'
|
||||
@ -318,12 +318,6 @@ class EnvironmentManager
|
||||
],
|
||||
]);
|
||||
|
||||
try {
|
||||
DB::connection()->getPdo();
|
||||
|
||||
return true;
|
||||
} catch (Exception $e) {
|
||||
return $e;
|
||||
}
|
||||
return DB::connection()->getPdo();
|
||||
}
|
||||
}
|
||||
|
||||
@ -9,6 +9,6 @@ return [
|
||||
|
|
||||
*/
|
||||
|
||||
'version' => '2.0.0',
|
||||
'version' => '2.0.1',
|
||||
|
||||
];
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -1,4 +1,4 @@
|
||||
{
|
||||
"/assets/js/app.js": "/assets/js/app.js?id=03057c22d0c8dd7a3478",
|
||||
"/assets/js/app.js": "/assets/js/app.js?id=334224502420e0ff495c",
|
||||
"/assets/css/crater.css": "/assets/css/crater.css?id=108e3a8d009e7d38018c"
|
||||
}
|
||||
|
||||
@ -86,7 +86,7 @@ export default {
|
||||
setTimeout(() => {
|
||||
location.reload()
|
||||
}, 2000)
|
||||
}, 5000)
|
||||
}, 1000)
|
||||
} else {
|
||||
console.log(res.data)
|
||||
window.toastr['error'](res.data.error)
|
||||
|
||||
@ -206,10 +206,10 @@ export default {
|
||||
} else {
|
||||
window.toastr['error'](this.$t('wizard.errors.' + response.data.error))
|
||||
}
|
||||
this.loading = false
|
||||
} catch (e) {
|
||||
console.log(e.response)
|
||||
window.toastr['error'](e.response.data.message)
|
||||
} finally {
|
||||
this.loading = false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user