* Adjust block module code.
This commit is contained in:
@@ -14,6 +14,10 @@ $config->block->version = 2;
|
|||||||
$config->block->editor = new stdclass();
|
$config->block->editor = new stdclass();
|
||||||
$config->block->editor->set = array('id' => 'html', 'tools' => 'simple');
|
$config->block->editor->set = array('id' => 'html', 'tools' => 'simple');
|
||||||
|
|
||||||
|
$config->block->moduleIndex = array();
|
||||||
|
$config->block->moduleIndex['program'] = 'project';
|
||||||
|
$config->block->moduleIndex['project'] = 'execution';
|
||||||
|
|
||||||
$config->block->longBlock = array();
|
$config->block->longBlock = array();
|
||||||
$config->block->longBlock['']['flowchart'] = 'flowchart';
|
$config->block->longBlock['']['flowchart'] = 'flowchart';
|
||||||
$config->block->longBlock['']['welcome'] = 'welcome';
|
$config->block->longBlock['']['welcome'] = 'welcome';
|
||||||
|
|||||||
@@ -39,6 +39,7 @@ class block extends control
|
|||||||
|
|
||||||
$title = $id == 0 ? $this->lang->block->createBlock : $this->lang->block->editBlock;
|
$title = $id == 0 ? $this->lang->block->createBlock : $this->lang->block->editBlock;
|
||||||
|
|
||||||
|
$module = zget($this->config->block->moduleIndex, $module, $module);
|
||||||
if($module == 'my')
|
if($module == 'my')
|
||||||
{
|
{
|
||||||
$modules = $this->lang->block->moduleList;
|
$modules = $this->lang->block->moduleList;
|
||||||
@@ -69,7 +70,6 @@ class block extends control
|
|||||||
$this->view->blocks = $this->fetch('block', 'main', "module=$module&id=$id");
|
$this->view->blocks = $this->fetch('block', 'main', "module=$module&id=$id");
|
||||||
$this->view->module = $module;
|
$this->view->module = $module;
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->view->title = $title;
|
$this->view->title = $title;
|
||||||
$this->view->block = $this->block->getByID($id);
|
$this->view->block = $this->block->getByID($id);
|
||||||
$this->view->blockID = $id;
|
$this->view->blockID = $id;
|
||||||
|
|||||||
Reference in New Issue
Block a user