Esempio n. 1
0
        /// <summary>
        /// 帳號與權限
        /// </summary>
        public EmployeeAuthorityLogic(IAuthenticationConditionProvider authCondition)
            : this()
        {
            this.authCondition = authCondition;

            if (authCondition != null)
            {
                opIdOfPage  = authCondition.GetOpIdOfPage();
                empAccount  = authCondition.GetEmpAccount();
                roleName    = authCondition.GetRoleName();
                isRoleAdmin = authCondition.IsInRole("admin");
                deptId      = authCondition.GetDeptId();

                if (authCondition is ICustomEmployeeAuthorizationResult)
                {
                    custEmpAuthResult = (ICustomEmployeeAuthorizationResult)authCondition;
                }
            }
        }
Esempio n. 2
0
 public void SetCustomEmployeeAuthorizationResult(ICustomEmployeeAuthorizationResult custEmpAuthResult)
 {
     this.custEmpAuthResult = custEmpAuthResult;
 }