✏️ 正在编辑: AuthService.php
路径:
/srv/systems_dir/yuppiecred/application/services/AuthService.php
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
<?php class Service_AuthService { /** * @return int */ public function getUsuarioEmpresaResolve(): int { return Yuppie_Auth::getIdentity() ? Yuppie_Auth::getIdentity()->empresa_id : (model('empresa'))->getPrimeiraEmpresaAtiva()['id'] ; } /** * @return string */ public function getUsuarioLogadoResolve(): string { return Yuppie_Auth::getIdentity() ? Yuppie_Auth::getIdentity()->login : 'Web Service' ; } /** * @param Zend_Session_Namespace $ns * @param string $permission * @return bool */ public function isAllowed( Zend_Session_Namespace $ns, string $permission ): bool { return isset($ns->acl) && $ns->acl->isAllowed(Yuppie_Auth::getIdentity()->grupo, $permission); } }
💾 保存文件
← 返回文件管理器