当前位置: 首页>>代码示例>>PHP>>正文


PHP Settings::isPermissive方法代码示例

本文整理汇总了PHP中thebuggenie\core\framework\Settings::isPermissive方法的典型用法代码示例。如果您正苦于以下问题:PHP Settings::isPermissive方法的具体用法?PHP Settings::isPermissive怎么用?PHP Settings::isPermissive使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在thebuggenie\core\framework\Settings的用法示例。


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

示例1: canCreatePublicSearches

 /**
  * Return if the user can create public saved searches
  *
  * @return boolean
  */
 public function canCreatePublicSearches()
 {
     return $this->_dualPermissionsCheck('cancreatepublicsearches', 0, 'canfindissuesandsavesearches', 0, framework\Settings::isPermissive());
 }
开发者ID:underblaze,项目名称:thebuggenie-4.1.0,代码行数:9,代码来源:User.php

示例2: canUserSet

 public function canUserSet(\thebuggenie\core\entities\User $user)
 {
     $retval = $user->hasPermission($this->getPermissionsKey(), $this->getID(), 'core');
     $retval = $retval === null ? $user->hasPermission($this->getPermissionsKey(), 0, 'core') : $retval;
     return $retval !== null ? $retval : \thebuggenie\core\framework\Settings::isPermissive();
 }
开发者ID:founderio,项目名称:thebuggenie,代码行数:6,代码来源:DatatypeBase.php

示例3: _dualPermissionsCheck

 protected function _dualPermissionsCheck($permission_1, $permission_2, $fallback = null)
 {
     $retval = $this->permissionCheck($permission_1);
     $retval = $retval === null ? $this->permissionCheck($permission_2) : $retval;
     if ($retval !== null) {
         return $retval;
     } else {
         return $fallback !== null ? $fallback : framework\Settings::isPermissive();
     }
 }
开发者ID:pkdevboxy,项目名称:thebuggenie,代码行数:10,代码来源:Project.php

示例4: image_tag

 if (is_bool($val)) {
     ?>
             <?php 
     $image_tag = $val ? image_tag('permission_set_ok.png') : image_tag('permission_set_denied.png');
     ?>
         <?php 
 } elseif ($mode == 'datatype') {
     ?>
             <?php 
     $image_tag = image_tag('permission_unset_ok.png');
     ?>
         <?php 
 } elseif ($mode == 'general' && $type == 'everyone') {
     ?>
             <?php 
     $image_tag = \thebuggenie\core\framework\Settings::isPermissive() ? image_tag('permission_unset_ok.png') : image_tag('permission_unset_denied.png');
     ?>
         <?php 
 } elseif ($mode == 'configuration' && $type == 'everyone') {
     ?>
             <?php 
     $image_tag = image_tag('permission_unset_denied.png');
     ?>
         <?php 
 } elseif ($mode == 'pages' && $type == 'everyone') {
     ?>
             <?php 
     $image_tag = image_tag('permission_unset_ok.png');
     ?>
         <?php 
 } elseif ($mode == 'user' && $type == 'everyone') {
开发者ID:founderio,项目名称:thebuggenie,代码行数:31,代码来源:_permissionsinfoitem.inc.php

示例5: _canPermissionsOrExtraInformation

 protected function _canPermissionsOrExtraInformation($permission)
 {
     if (isset($this->_can_permission_cache[$permission])) {
         return $this->_can_permission_cache[$permission];
     }
     $retval = $this->_permissionCheck($permission);
     $retval = $retval === null ? $this->canAddExtraInformation() : $retval;
     $this->_can_permission_cache[$permission] = $retval;
     return $retval !== null ? $retval : \thebuggenie\core\framework\Settings::isPermissive();
 }
开发者ID:AzerothShard,项目名称:thebuggenie,代码行数:10,代码来源:Issue.php

示例6: canUserDeleteOwnComment

 /**
  * Return if the user can delete own comment
  *
  * @return boolean
  */
 public function canUserDeleteOwnComment()
 {
     $retval = $this->_canPermissionOrSeeAndEditComments('candeletecommentsown');
     return $retval !== null ? $retval : framework\Settings::isPermissive();
 }
开发者ID:founderio,项目名称:thebuggenie,代码行数:10,代码来源:Comment.php

示例7: __

 disabled<?php 
}
?>
>
                <option value=1<?php 
if (\thebuggenie\core\framework\Settings::isPermissive()) {
    ?>
 selected<?php 
}
?>
><?php 
echo __('Permissive');
?>
</option>
                <option value=0<?php 
if (!\thebuggenie\core\framework\Settings::isPermissive()) {
    ?>
 selected<?php 
}
?>
><?php 
echo __('Restrictive');
?>
</option>
            </select>

            <?php 
echo config_explanation(__("%restrictive: With this security policy, users don't automatically get access to projects, modules, etc., but must be granted access specifically.", array('%restrictive' => '<b>' . __('Restrictive') . '</b>')) . "<br>" . __("%permissive: This security policy assume you have access to things like projects, pages, etc.", array('%permissive' => '<b>' . __('Permissive') . '</b>')) . "<br><br>" . __("If you're running a public tracker, or a tracker with several projects you probably want to use a restrictive security policy - however, with smaller teams or and simpler projects, permissive security policy will be most efficient.") . "<br><br><i>" . __("Some permissions, such as configuration access are not affected by this setting, but must always be explicitly defined") . "</i>");
?>
        </td>
    </tr>
开发者ID:pkdevboxy,项目名称:thebuggenie,代码行数:31,代码来源:_user.inc.php


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