ACL Extension  0.3
 All Data Structures Namespaces Files Functions Variables
PmPermission.php
Go to the documentation of this file.
1 <?php
2 
10 class PmPermission extends Permission{
11 
18  public static function deleteByObject(AclObject $obj, array $paths = NULL){
19  $type = Util::getDataBaseType($obj);
20 
21  if($paths === NULL)
22  $paths = $obj->getPaths();
23 
24  $condition = PmPathManager::buildMultiplePathCondition($type.'_path', $paths);
25 
26  return PmPermission::model()->deleteAll($condition);
27  }
28 
29  public static function getPathFieldForType($type){
30  return $type.'_path';
31  }
32 }
33 
34 ?>