• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP Base_AclCommon类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中Base_AclCommon的典型用法代码示例。如果您正苦于以下问题:PHP Base_AclCommon类的具体用法?PHP Base_AclCommon怎么用?PHP Base_AclCommon使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了Base_AclCommon类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: applet_caption

 public static function applet_caption()
 {
     if (!Base_AclCommon::check_permission('Calendar')) {
         return false;
     }
     return __('Agenda');
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:7,代码来源:CalendarCommon_0.php


示例2: menu

 public static function menu()
 {
     if (!Acl::is_user() || !Base_AclCommon::check_permission('Fax - Browse')) {
         return array();
     }
     return array(_M('CRM') => array('__submenu__' => 1, _M('Fax') => array()));
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:7,代码来源:FaxCommon_0.php


示例3: uninstall

 public function uninstall()
 {
     Base_AclCommon::delete_permission('Fax - Browse');
     Base_AclCommon::delete_permission('Fax - Send');
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     return true;
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:7,代码来源:FaxInstall.php


示例4: menu

 public static function menu()
 {
     if (Base_AclCommon::check_permission('Advanced User Settings')) {
         return array(_M('My settings') => array('__weight__' => 10, '__submenu__' => 1, _M('Control panel') => array()));
     }
     return array();
 }
开发者ID:62BRAINS,项目名称:EPESI,代码行数:7,代码来源:SettingsCommon_0.php


示例5: uninstall

 public function uninstall()
 {
     Base_AclCommon::delete_permission('Calendar');
     DB::DropTable('crm_calendar_custom_events_handlers');
     Base_ThemeCommon::uninstall_default_theme('CRM/Calendar');
     return true;
 }
开发者ID:62BRAINS,项目名称:EPESI,代码行数:7,代码来源:CalendarInstall.php


示例6: uninstall

	public function uninstall() {
		Base_AclCommon::delete_permission('Messenger Alerts');
		$ret = true;
		$ret &= DB::DropTable('utils_messenger_users');
		$ret &= DB::DropTable('utils_messenger_message');
		return $ret;
	}
开发者ID:62BRAINS,项目名称:EPESI,代码行数:7,代码来源:MessengerInstall.php


示例7: menu

 public static function menu()
 {
     if (Base_AclCommon::check_permission('Search')) {
         return array(_M('Search') => array());
     }
     return array();
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:7,代码来源:SearchCommon_0.php


示例8: uninstall

 public function uninstall()
 {
     $ret = true;
     $ret &= DB::DropTable('apps_shoutbox_messages');
     Base_AclCommon::delete_permission('Shoutbox');
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     return $ret;
 }
开发者ID:62BRAINS,项目名称:EPESI,代码行数:8,代码来源:ShoutboxInstall.php


示例9: uninstall

 public function uninstall()
 {
     Base_AclCommon::delete_permission('Advanced User Settings');
     global $database;
     $ret = true;
     $ret &= DB::DropTable('base_user_settings');
     Base_ThemeCommon::uninstall_default_theme(Base_User_SettingsInstall::module_name());
     return $ret;
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:9,代码来源:SettingsInstall.php


示例10: uninstall

 public function uninstall()
 {
     Base_AclCommon::delete_permission('Manage Perspective');
     $ret = true;
     $ret &= DB::DropTable('crm_filters_contacts');
     $ret &= DB::DropTable('crm_filters_group');
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     return $ret;
 }
开发者ID:62BRAINS,项目名称:EPESI,代码行数:9,代码来源:FiltersInstall.php


示例11: menu

 public static function menu()
 {
     if (Base_AclCommon::check_permission('Dashboard')) {
         $tray_settings = Utils_TrayCommon::get_trays();
         if (count($tray_settings) > 0) {
             return array(_M('Tray') => array('__icon__' => 'pile_small.png'));
         }
     }
     return array();
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:10,代码来源:TrayCommon_0.php


示例12: admin_access

 public static function admin_access()
 {
     if (DEMO_MODE) {
         return false;
     }
     if (Variable::get('anonymous_setup')) {
         return true;
     }
     return Base_AclCommon::i_am_admin();
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:10,代码来源:SetupCommon_0.php


示例13: uninstall

 public function uninstall()
 {
     Base_AclCommon::delete_permission('Attachments - view full download history');
     $ret = true;
     $ret &= DB::DropTable('utils_attachment_download');
     $ret &= DB::DropTable('utils_attachment_file');
     $ret &= DB::DropTable('utils_attachment_local');
     Utils_RecordBrowserCommon::uninstall_recordset('utils_attachment');
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     return $ret;
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:11,代码来源:AttachmentInstall.php


示例14: uninstall

 public function uninstall()
 {
     Base_AclCommon::delete_permission('Dashboard');
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     $ret = true;
     $ret &= DB::DropTable('base_dashboard_settings');
     $ret &= DB::DropTable('base_dashboard_applets');
     $ret &= DB::DropTable('base_dashboard_default_settings');
     $ret &= DB::DropTable('base_dashboard_default_applets');
     $ret &= DB::DropTable('base_dashboard_users');
     return $ret;
 }
开发者ID:62BRAINS,项目名称:EPESI,代码行数:12,代码来源:DashboardInstall.php


示例15: create_admin_modules_instances

 private function create_admin_modules_instances()
 {
     foreach (get_declared_classes() as $class) {
         $rclass = new ReflectionClass($class);
         if ($rclass->isSubclassOf("AdminModule") && !$rclass->isAbstract()) {
             $module = new $class();
             if (Base_AclCommon::i_am_sa() || Base_AclCommon::i_am_admin() && $module->access_admin() || Base_AclCommon::i_am_user() && $module->access_user()) {
                 $this->admin_modules[$class] = $module;
             }
         }
     }
     ksort($this->admin_modules);
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:13,代码来源:AdminIndex.php


示例16: replace_special_values

 /**
  * Replace all registered special values.
  *
  * Object will be cloned. Current object will not be changed.
  *
  * @param bool $human_readable Use special value or it's human readable form
  *
  * @return Utils_RecordBrowser_CritsInterface New object with replaced values
  */
 public function replace_special_values($human_readable = false)
 {
     $new = clone $this;
     $user = Base_AclCommon::get_user();
     $replace_values = self::get_replace_values($user);
     /** @var Utils_RecordBrowser_ReplaceValue $rv */
     foreach ($replace_values as $rv) {
         $replacement = $human_readable ? $rv->get_human_readable() : $rv->get_replace();
         $deactivate = $human_readable ? false : $rv->get_deactivate();
         $new->replace_value($rv->get_value(), $replacement, $deactivate);
     }
     return $new;
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:22,代码来源:Crits.php


示例17: update_observer

 public function update_observer($type, $message, $errfile, $errline, $errcontext, $backtrace)
 {
     $mail = Variable::get('error_mail');
     if ($mail) {
         $backtrace = htmlspecialchars_decode(str_replace(array('<br />', '&nbsp;'), array("\n", ' '), $backtrace));
         $x = "who=" . Base_AclCommon::get_user() . "\ntype=" . $type . "\nmessage=" . $message . "\nerror file=" . $errfile . "\nerror line=" . $errline . "\n" . $backtrace;
         $d = ModuleManager::get_data_dir('Base/Error') . md5($x) . '.txt';
         file_put_contents($d, $x);
         $url = get_epesi_url();
         Base_MailCommon::send($mail, 'Epesi Error - ' . $url, substr($x, 0, strpos($x, "error backtrace")) . "\n" . $url . '/' . $d, null, null, false, true);
     }
     return true;
 }
开发者ID:62BRAINS,项目名称:EPESI,代码行数:13,代码来源:ErrorCommon_0.php


示例18: load_epesi

 protected function load_epesi()
 {
     if (self::$epesi_loaded) {
         return;
     }
     define('CID', false);
     define('READ_ONLY_SESSION', true);
     require_once '../../../include.php';
     ModuleManager::load_modules();
     self::$epesi_loaded = true;
     if (!Base_AclCommon::is_user()) {
         throw new ErrorException('Not logged in');
     }
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:14,代码来源:Handle.php


示例19: install

	public function install() {
		Base_ThemeCommon::install_default_theme($this->get_type());
		$ret = true;
		$ret &= DB::CreateTable('utils_watchdog_category',
					'id I AUTO KEY,'.
					'name C(32),'.
					'callback C(128)',
			array('constraints'=>''));
		if(!$ret){
			print('Unable to create table utils_watchdog_category.<br>');
			return false;
		}
		$ret &= DB::CreateTable('utils_watchdog_event',
					'id I AUTO KEY,'.
					'category_id I,'.
					'internal_id I,'.
					'message C(64),'.
					'event_time T',
			array('constraints'=>', FOREIGN KEY (category_id) REFERENCES utils_watchdog_category(id)'));
		if(!$ret){
			print('Unable to create table utils_watchdog_event.<br>');
			return false;
		}
		$ret &= DB::CreateTable('utils_watchdog_subscription',
					'category_id I,'.
					'internal_id I,'.
					'last_seen_event I,'.
					'user_id I',
			array('constraints'=>', FOREIGN KEY (user_id) REFERENCES user_login(id)'));
		if(!$ret){
			print('Unable to create table utils_watchdog_subscription.<br>');
			return false;
		}
		$ret &= DB::CreateTable('utils_watchdog_category_subscription',
					'category_id I,'.
					'user_id I',
			array('constraints'=>', FOREIGN KEY (user_id) REFERENCES user_login(id), FOREIGN KEY (category_id) REFERENCES utils_watchdog_category(id)'));
		if(!$ret){
			print('Unable to create table utils_watchdog_category_subscription.<br>');
			return false;
		}

		DB::CreateIndex('utils_watchdog_event__internal_id__idx', 'utils_watchdog_event', 'internal_id');
		DB::CreateIndex('utils_watchdog_event__cat_int__idx', 'utils_watchdog_event', array('category_id','internal_id'));
		DB::CreateIndex('utils_watchdog_subscription__cat_int__idx', 'utils_watchdog_subscription', array('category_id','internal_id'));
		DB::CreateIndex('utils_watchdog_subscription__user__idx', 'utils_watchdog_subscription', 'user_id');
		Base_AclCommon::add_permission(_M('Watchdog - subscribe to categories'),array('ACCESS:employee','ACCESS:manager'));
		return $ret;
	}
开发者ID:62BRAINS,项目名称:EPESI,代码行数:49,代码来源:WatchdogInstall.php


示例20: get_my_homepage

 public static function get_my_homepage()
 {
     $clearance = Base_AclCommon::get_clearance();
     $sql = 'SELECT home_page FROM base_home_page AS bhp WHERE ';
     $vals = array();
     if ($clearance != null) {
         $sql .= ' NOT EXISTS (SELECT * FROM base_home_page_clearance WHERE home_page_id=bhp.id AND ' . implode(' AND ', array_fill(0, count($clearance), 'clearance!=%s')) . ')';
         $vals = array_values($clearance);
     } else {
         $sql .= ' NOT EXISTS (SELECT * FROM base_home_page_clearance WHERE home_page_id=bhp.id)';
     }
     $sql .= ' ORDER BY priority';
     $page = DB::GetOne($sql, $vals);
     $pages = self::get_home_pages();
     return isset($pages[$page]) ? $pages[$page] : array();
 }
开发者ID:cretzu89,项目名称:EPESI,代码行数:16,代码来源:HomePageCommon_0.php



注:本文中的Base_AclCommon类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Base_Common类代码示例发布时间:2022-05-23
下一篇:
PHP BaseView类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap