mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-04 01:23:32 +09:00
Support user config of notification types, fixes #994
코어에서 지원하는 알림 종류 및 알림 수신 방법이 늘어남에 따라, 관리자가 설정한 범위 내에서 회원들이 알림 수신 방법을 선택할 수 있도록 합니다. 기존에는 수신 여부만 선택할 수 있었으나 이제 더 세부적인 설정이 가능합니다. 예를 들어 웹 알림과 푸시알림은 받고, 메일 알림과 문자 알림은 끌 수 있습니다. 이 기능을 지원하기 위해 ncenterlite_user_set 테이블 스키마를 대폭 조정합니다. 기존 설정은 가능하면 그대로 유지하려고 노력하였습니다.
This commit is contained in:
parent
3032784ca7
commit
c52187a8f2
14 changed files with 435 additions and 531 deletions
|
|
@ -11,28 +11,11 @@ class ncenterliteAdminView extends ncenterlite
|
|||
{
|
||||
$oNcenterliteModel = getModel('ncenterlite');
|
||||
|
||||
if(Rhymix\Framework\SMS::getDefaultDriver()->getName() === 'Dummy')
|
||||
{
|
||||
$sms_available = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
$sms_available = true;
|
||||
}
|
||||
|
||||
if(count(Rhymix\Framework\Config::get('push.types')))
|
||||
{
|
||||
$push_avaliable = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
$push_avaliable = false;
|
||||
}
|
||||
|
||||
$config = $oNcenterliteModel->getConfig();
|
||||
Context::set('config', $config);
|
||||
Context::set('sms_available', $sms_available);
|
||||
Context::set('push_available', $push_avaliable);
|
||||
Context::set('notify_types', NcenterliteModel::getNotifyTypes());
|
||||
Context::set('sms_available', Rhymix\Framework\SMS::getDefaultDriver()->getName() !== 'Dummy');
|
||||
Context::set('push_available', count(Rhymix\Framework\Config::get('push.types')) > 0);
|
||||
}
|
||||
|
||||
function dispNcenterliteAdminSeletedmid()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue