Esempio n. 1
0
        private static bool HasViewAccessRight(ApplicationFroms form)
        {
            AccessRight right = new AccessRightService().GetSingle(new AccessRight {
                FormID = form.ToString(), UserID = CurrentUser.User.UserID
            });

            return(right == null ? false : right.CanView.Value);
        }
Esempio n. 2
0
        private static bool HasViewAccessRight(ApplicationFroms form)
        {
            //if (form == null) return false;

            AccessRight right = new GenericService <AccessRight>().GetSingle(a => a.FormID == form.ToString() && a.UserID == CurrentUser.User.UserID && a.CanView.Value == true);

            return(right == null ? false : right.CanView.Value);
        }
Esempio n. 3
0
 void UpdateAccessRight(AccessRight rights, ApplicationFroms form)
 {
     _accessRightService.Update(rights, r => r.UserID == _userID && r.FormID == form.ToString());
 }