Merge remote-tracking branch 'origin/feature/HOR-3559' into feature/HOR-3629

This commit is contained in:
Ronald Quenta
2017-08-10 22:01:13 -04:00
19 changed files with 2959 additions and 496 deletions

View File

@@ -201,6 +201,12 @@ class workspaceTools
$stop = microtime(true);
CLI::logging("<*> Updating rows in Web Entry table for classic processes took " . ($stop - $start) . " seconds.\n");
$start = microtime(true);
CLI::logging("> Update framework paths...\n");
$this->updateFrameworkPaths($workSpace);
$stop = microtime(true);
CLI::logging("<*> Update framework paths took " . ($stop - $start) . " seconds.\n");
$start = microtime(true);
CLI::logging("> Migrating and populating plugin singleton data...\n");
$this->migrateSingleton($workSpace);
@@ -3927,4 +3933,22 @@ class workspaceTools
CLI::logging(CLI::error("Error:" . "Error updating generated class files for PM Tables, proceed to regenerate manually: " . $e));
}
}
/**
* Updating framework directory structure
*
*/
private function updateFrameworkPaths($workSpace = SYS_SYS)
{
$paths = [
PATH_DATA.'framework' => 0770,
PATH_DATA.'framework' . DIRECTORY_SEPARATOR . 'cache' => 0770,
];
foreach ($paths as $path => $permission) {
if (!file_exists($path)) {
G::mk_dir($path, $permission);
}
CLI::logging(" $path [" . (file_exists($path) ? 'OK' : 'MISSING') . "]\n");
}
}
}

View File

@@ -285,7 +285,7 @@ class Translation extends BaseTranslation
/* Load strings from plugin translation.php.
* @parameter $languageId (es|en|...).
*/
public function generateFileTranslationPlugin ($plugin, $languageId = '')
public static function generateFileTranslationPlugin ($plugin, $languageId = '')
{
if (!file_exists(PATH_PLUGINS . $plugin . PATH_SEP . 'translations' . PATH_SEP . 'translations.php')) {
return;