Improved compatibility to Xentral 20 database

This commit is contained in:
root 2022-09-04 09:57:00 +00:00
parent 2bb3130b00
commit 383524f348
2 changed files with 1216 additions and 1203 deletions

File diff suppressed because it is too large Load Diff

View File

@ -890,18 +890,23 @@ $this->app->Tpl->Add('TODOFORUSER',"<tr><td width=\"90%\">".$tmp[$i]['aufgabe'].
$this->app->erp->RunHook('welcome_start', 1 , $this);
if(empty($this->app->User->GetField('role')) || $this->app->acl->IsAdminadmin()) {
$this->app->ModuleScriptCache->IncludeWidgetNew('ClickByClickAssistant');
$this->app->ModuleScriptCache->IncludeJavascriptFiles(
// Xentral 20 database compatibility
if ($this->app->DB->Select("SHOW COLUMNS FROM `user` LIKE 'role'")) {
if(empty($this->app->User->GetField('role')) || $this->app->acl->IsAdminadmin()) {
$this->app->ModuleScriptCache->IncludeWidgetNew('ClickByClickAssistant');
$this->app->ModuleScriptCache->IncludeJavascriptFiles(
'welcome',
[
'body' => [
'./classes/Modules/Welcome/www/js/welcome_firststart.js',
],
]
);
$this->app->Tpl->Parse('AUFGABENPOPUP', 'welcome_firststart.tpl');
);
$this->app->Tpl->Parse('AUFGABENPOPUP', 'welcome_firststart.tpl');
}
}
if($this->app->User->GetType() === 'admin') {
$this->app->Tpl->Set('COLROWTASKS', '6');
}