protected static string $_name = 'content';
+ protected static $_basePath = '';
+
protected $_operations = [ExcelExportOperation::class, ExcelImportOperation::class];
public function __construct(array $attributes = [])
public function getExtensions()
{
- return array_merge(parent::getExtensions(), ['js']);
+ return parent::getExtensions() + ['js'];
}
- public static function getAllTranslations($force = false)
+ public static function getAllTranslations($force = true)
{
if (null === static::$_allTranslations) {
$cacheKey = 'all_' . static::$_name . '_translations';
return $all[$locale] ?? [];
}
+ public function getPaths()
+ {
+ $res = [];
+ foreach (static::getActiveBranches() as $branch) {
+ $res['Player - git:' . $branch] = static::$_basePath . '/branches/' . $branch;
+ $res['Player - local:' . $branch] = static::$_basePath . '/local/' . $branch;
+ }
+ return $res;
+ }
+
}
use QuizBranches;
protected $table = 'elearning_translate';
- protected static string $_name='elearning';
+ protected static string $_name = 'elearning';
+ protected static $_basePath='resources/quiz/player';
protected $_enableRevisions = false;
'oneinstance' => true];
protected $_operations = [ExcelExportOperation::class, ExcelImportOperation::class];
-
-
- public function getPaths()
- {
- $res = [];
- foreach (self::getActiveBranches() as $branch) {
- $res['Player - git:' . $branch] = 'resources/quiz/player/branches/' . $branch . '/js';
- $res['Player - local:' . $branch] = 'resources/quiz/player/local/' . $branch . '/js';
- }
- //$res[__('Compilateur')]='resources/compiler';
- //$res[__('Application')]=''resources/html5app';
- return $res;
- }
-
}
protected $table = 'fluidbook_translate';
protected static string $_name = 'elearning';
+ protected static $_basePath = 'resources/fluidbookpublication/player';
protected static $_allTranslations = null;
parent::setFields();
}
- public function getPaths()
- {
- $res = [];
- foreach (self::getActiveBranches() as $branch) {
- $res['Player - git:' . $branch] = 'resources/fluidbookpublication/player/branches/' . $branch . '/js';
- $res['Player - local:' . $branch] = 'resources/fluidbookpublication/player/local/' . $branch . '/js';
- }
- //$res[__('Compilateur')]='resources/compiler';
- //$res[__('Application')]=''resources/html5app';
- return $res;
- }
-
-
public static function getAllFluidbookTranslations($force = false)
{
return static::getAllTranslations($force);