Beispiel #1
0
 public static function can_i($actions, $name = false, $category = false, $module = false)
 {
     if (!$module) {
         $module = __CLASS__;
     }
     return parent::can_i($actions, $name, $category, $module);
 }
Beispiel #2
0
 public static function is_plugin_enabled()
 {
     if (!class_exists('module_social')) {
         return false;
     }
     return parent::is_plugin_enabled();
 }
Beispiel #3
0
 function link($page = '', $args = array(), $module = false, $include_parent = -1, $object_data = array(), $options = array())
 {
     $keys = $this->get_data_link_keys();
     //$keys[] = 'data_type_id'; // doesn't work cancelling out of settings window
     foreach ($keys as $key) {
         if (isset($_REQUEST[$key]) && !isset($args[$key])) {
             $args[$key] = $_REQUEST[$key];
         }
     }
     return parent::link($page, $args, $module, $include_parent, $object_data, $options);
 }
Beispiel #4
0
function is_installed()
{
    if (defined('_DB_NAME') && _DB_NAME != '') {
        // check for config table.
        if (db_connect() === false) {
            return false;
            // db connection failed.
        }
        return module_base::db_table_exists('config');
    }
    return false;
    //not installed
    /*if(!defined('_UCM_INSTALLED') || !_UCM_INSTALLED){
          return false;
      }else{
          return true;
      }*/
}