This commit is contained in:
wangyuting2
2022-09-27 03:07:47 +00:00
parent b43b1c844a
commit 3874a3e22b
2 changed files with 43 additions and 1 deletions
+3 -1
View File
@@ -635,11 +635,13 @@ class custom extends control
if($mode == 'lean' and empty($program)) return $this->send(array('result' => 'fail', 'message' => array('program' => $this->lang->custom->switchModeHelper)));
$this->loadModel('setting')->setItem('system.common.global.mode', $mode);
$this->loadModel('setting')->setItem('system.common.global.defaultProgram', $program);
$this->setting->setItem('system.common.global.defaultProgram', $program);
/* 只有没有关联项目集的产品和项目关联到默认项目集下. */
$this->loadModel('upgrade')->relationDefaultProgram($program);
$this->custom->disableFeaturesByMode($mode);
if($mode == 'lean') $this->custom->processProjectAcl();
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'top'));