mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-09 20:12:14 +09:00
Add ModuleController->updateModuleMenuSrl()
This commit is contained in:
parent
bf8591a9d2
commit
1ba3110c8a
2 changed files with 37 additions and 2 deletions
|
|
@ -751,9 +751,11 @@ class ModuleController extends Module
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Update menu_srl of mid which belongs to menu_srl
|
* Update menu_srl of mid which belongs to menu_srl
|
||||||
|
*
|
||||||
|
* @deprecated
|
||||||
*/
|
*/
|
||||||
function updateModuleMenu($args)
|
public function updateModuleMenu($args)
|
||||||
{
|
{
|
||||||
$output = executeQuery('module.updateModuleMenu', $args);
|
$output = executeQuery('module.updateModuleMenu', $args);
|
||||||
|
|
||||||
|
|
@ -761,6 +763,28 @@ class ModuleController extends Module
|
||||||
return $output;
|
return $output;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update menu_srl of a module.
|
||||||
|
*
|
||||||
|
* @param int $module_srl
|
||||||
|
* @param int $menu_srl
|
||||||
|
* @param bool $clear_cache
|
||||||
|
* @return BaseObject
|
||||||
|
*/
|
||||||
|
public function updateModuleMenuSrl(int $module_srl, int $menu_srl, bool $clear_cache = true): BaseObject
|
||||||
|
{
|
||||||
|
$output = executeQuery('module.updateModuleMenuSrl', [
|
||||||
|
'module_srl' => $module_srl,
|
||||||
|
'menu_srl' => $menu_srl,
|
||||||
|
]);
|
||||||
|
|
||||||
|
if ($clear_cache)
|
||||||
|
{
|
||||||
|
Rhymix\Framework\Cache::clearGroup('site_and_module');
|
||||||
|
}
|
||||||
|
return $output;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Update layout_srl of mid which belongs to menu_srl
|
* @brief Update layout_srl of mid which belongs to menu_srl
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
11
modules/module/queries/updateModuleMenuSrl.xml
Normal file
11
modules/module/queries/updateModuleMenuSrl.xml
Normal file
|
|
@ -0,0 +1,11 @@
|
||||||
|
<query id="updateModuleMenuSrl" action="update">
|
||||||
|
<tables>
|
||||||
|
<table name="modules" />
|
||||||
|
</tables>
|
||||||
|
<columns>
|
||||||
|
<column name="menu_srl" var="menu_srl" filter="number" notnull="notnull" />
|
||||||
|
</columns>
|
||||||
|
<conditions>
|
||||||
|
<condition operation="equal" column="module_srl" var="module_srl" filter="number" notnull="notnull" />
|
||||||
|
</conditions>
|
||||||
|
</query>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue