PMCORE-3663 [27018] No translation on the left bar on the Home Tab - France

This commit is contained in:
Roly Gutierrez
2022-02-17 12:46:44 -04:00
parent 75f714d3ae
commit fa5ea92c68
3 changed files with 19 additions and 11 deletions

View File

@@ -455,9 +455,25 @@ class WorkspaceTools
$this->dbRbacUser = $values["DB_RBAC_USER"];
$this->dbRbacPass = $values["DB_RBAC_PASS"];
$this->setDataBaseConnectionPropertiesForEloquent();
return $this->dbInfo = $values;
}
/**
* This used for eloquent model.
*/
public function setDataBaseConnectionPropertiesForEloquent(): void
{
$dbHost = explode(':', $this->dbHost);
config(['database.connections.workflow.host' => $dbHost[0]]);
config(['database.connections.workflow.database' => $this->dbName]);
config(['database.connections.workflow.username' => $this->dbUser]);
config(['database.connections.workflow.password' => $this->dbPass]);
if (count($dbHost) > 1) {
config(['database.connections.workflow.port' => $dbHost[1]]);
}
}
private function resetDBInfoCallback($matches)
{
/* This function changes the values of defines while keeping their formatting
@@ -5086,14 +5102,6 @@ class WorkspaceTools
) {
// Initialize DB connections
$this->initPropel();
$dbHost = explode(':', $this->dbHost);
config(['database.connections.workflow.host' => $dbHost[0]]);
config(['database.connections.workflow.database' => $this->dbName]);
config(['database.connections.workflow.username' => $this->dbUser]);
config(['database.connections.workflow.password' => $this->dbPass]);
if (count($dbHost) > 1) {
config(['database.connections.workflow.port' => $dbHost[1]]);
}
// Get fields and some specific field types
$fields = [];