server staging

This commit is contained in:
Server
2023-12-17 11:40:57 +08:00
parent 32b91e9e61
commit 8579d5feea
6 changed files with 653 additions and 372 deletions
@@ -24,12 +24,13 @@ class AddOnepercentToGadaiTable extends Migration
$db_connection = array_filter($config_db,function($connection){
try{
if($connection == 'mysql7')
if($connection == 'mysql7' || $connection == 'lelong')
return false;
$db = DB::connection($connection)->getPdo();
return true;
} catch(\Exception $e){
Log::info($connection);
return false;
}
});
@@ -21,16 +21,28 @@ class AddOnepercentToTebusTable extends Migration
public function getActiveDB()
{
$config_db = array_keys(config("database.connections"));
<<<<<<< Updated upstream
$db_connection = array_filter($config_db, function ($connection) {
try {
if ($connection == 'mysql7') {
=======
$db_connection = array_filter($config_db,function($connection){
try{
if($connection == 'mysql7' || $connection == 'lelong')
>>>>>>> Stashed changes
return false;
}
$db = DB::connection($connection)->getPdo();
return true;
<<<<<<< Updated upstream
} catch (\Exception $e) {
=======
} catch(\Exception $e){
Log::info($connection);
>>>>>>> Stashed changes
return false;
}
});