<?php
namespace Claromentis\People\Entity\Map;

$GLOBALS["__65da1b1ec2d6653e8a0" . "ab7848e536215"] = (@$GLOBALS["__65da1b1ec2d6653e8a0ab78" . "48e536215"] ?: array()) + array("_adbffcf1128327d7a0a7c" . "dc2164b7256" => base64_decode("cm" . "9s" . "ZW" . "lk"), "_c8f7f72ce1bbf" . "96c92e1b24081d" . "f9250" => base64_decode("dXNlcl9yb2xlcw=" . "="), "user" . "id" => base64_decode("dXNlc" . "mlk"), "_35b54f844f87c3db31eca" . "42284fefc39" => base64_decode("ZXhfYX" . "JlYV9p" . "ZA=="));
use Analogue\ORM\Exceptions\MappingException;
use Analogue\ORM\Relationships\BelongsTo;
use Analogue\ORM\Relationships\BelongsToMany;
use Claromentis\Core\ORM\EntityMap;
use Claromentis\People\Entity\Extranet;
use Claromentis\People\Entity\Role;
use Claromentis\People\Entity\User;







class RoleMap extends EntityMap
{
    
    
    
    
    
    
    protected $table = 'roles';
    
    
    
    
    
    
    protected $primaryKey = 'roleid';
    
    
    
    
    
    
    protected $attributes = ['id', 'name', 'description', 'inactive', 'date_created', 'default_skin', 'owner_id', 'extranet_id'];
    
    
    
    
    
    
    protected $mappings = ['roleid' => 'id', 'rolename' => 'name', 'ex_area_id' => 'extranet_id', 'owner' => 'owner_id'];
    
    
    
    
    
    
    
    
    
    
    public function extranet(Role $_d1071a032215f0eb5c4a8ef175f7049d)
    {
        return $this->belongsTo($_d1071a032215f0eb5c4a8ef175f7049d, Extranet::class, $GLOBALS["__65da1b1ec2d6" . "653e8a0ab7848e" . "536215"]["_35b54f844f87c3d" . "b31eca42284fefc3" . "9"]);
    }
    
    
    
    
    
    
    
    
    
    
    public function users(Role $_d1071a032215f0eb5c4a8ef175f7049d)
    {
        return $this->belongsToMany($_d1071a032215f0eb5c4a8ef175f7049d, User::class, $GLOBALS["__65da1b1ec2d" . "6653e8a0ab784" . "8e536215"]["_c8f7f72ce1bbf9" . "6c92e1b24081df9" . "250"], $GLOBALS["__65da1b1ec" . "2d6653e8a0a" . "b7848e53621" . "5"]["_adbffcf1128327d7a0a7" . "cdc2164b7256"], $GLOBALS["__65da1b1ec2" . "d6653e8a0ab7" . "848e536215"]["us" . "er" . "id"]);
    }
}