mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-29 07:12:15 +09:00
Change blacklist to 2-dimensional array
관리 편의를 위해 블랙리스트를 자료 종류별로 구분합니다. 단, 기존과 같이 Context::isBlacklistedPlugin()을 호출하면 자료 종류 구분 없이 블랙리스트 여부를 알려줍니다.
This commit is contained in:
parent
6b32bc6789
commit
1ec6e1ec7a
9 changed files with 54 additions and 26 deletions
|
|
@ -47,7 +47,7 @@ class addonAdminModel extends addon
|
|||
foreach($addonList as $key => $addon)
|
||||
{
|
||||
// check blacklist
|
||||
$addonList[$key]->isBlacklisted = Context::isBlacklistedPlugin($addon->addon);
|
||||
$addonList[$key]->isBlacklisted = Context::isBlacklistedPlugin($addon->addon, 'addon');
|
||||
|
||||
// get easyinstall remove url
|
||||
$packageSrl = $oAutoinstallModel->getPackageSrlByPath($addon->path);
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ class addonController extends addon
|
|||
$addon_list = $oAddonModel->getInsertedAddons($site_srl, $gtype);
|
||||
foreach($addon_list as $addon => $val)
|
||||
{
|
||||
if(Context::isBlacklistedPlugin($addon)
|
||||
if(Context::isBlacklistedPlugin($addon, 'addon')
|
||||
|| ($type == "pc" && $val->is_used != 'Y')
|
||||
|| ($type == "mobile" && $val->is_used_m != 'Y')
|
||||
|| ($gtype == 'global' && $val->is_fixed != 'Y')
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@
|
|||
<tr loop="$addon_list => $addon">
|
||||
<td class="title">
|
||||
<p><strong style="color:#aaa"|cond="$addon->isBlacklisted">{$addon->title}</strong></p>
|
||||
<p>{$addon->description}</p>
|
||||
<p style="color:#aaa"|cond="$addon->isBlacklisted">{$addon->description}</p>
|
||||
<p cond="$addon->need_update == 'Y'" class="update">
|
||||
{$lang->msg_avail_easy_update} <a href="{$addon->update_url}&return_url={urlencode(getRequestUriByServerEnviroment())}">{$lang->msg_do_you_like_update}</a>
|
||||
</p>
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div cond="Context::isBlacklistedPlugin($addon_info->addon_name)" class="message error">
|
||||
<div cond="Context::isBlacklistedPlugin($addon_info->addon_name, 'addon')" class="message error">
|
||||
<p><em class="x_label x_label-important">{$lang->msg_warning}</em> {$lang->msg_blacklisted_module}<br />{$lang->get('admin.msg_blacklisted_reason.'.$addon_info->addon_name)}</p>
|
||||
</div>
|
||||
<div cond="$XE_VALIDATOR_MESSAGE && $XE_VALIDATOR_ID == 'modules/addon/tpl/setup_addon/1'" class="message {$XE_VALIDATOR_MESSAGE_TYPE}">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue