コード例 #1
0
        public RoleTargetRecord AddRoleRuleCollection(string roleName, RoleCollectionRecord collection)
        {
            var model = new RoleTargetRecord()
                            {
                                RoleCollectionRecord = collection,
                                RoleName = roleName,
                            };

            collection.RoleTargetRecords.Add(model);

            this.roleTargetRecordRepository.Create(model);

            return model;
        }
コード例 #2
0
        public RegistrationRuleRecord AddRule(bool checkUserOnRegistration, string rule, string ruleOperator, string ruleAction, bool inculusionRule, RoleTargetRecord roleTarget)
        {
            var model = new RegistrationRuleRecord()
                            {
                                RuleName = rule,
                                Operator = ruleOperator,
                                RuleAction = ruleAction,
                                InculusionRule = inculusionRule,
                                RoleTargetRecord = roleTarget
                            };

            this.ruleRepository.Create(model);

            return model;
        }
コード例 #3
0
 public void RemoveRole(RoleTargetRecord roleTarget)
 {
     this.roleTargetRecordRepository.Delete(roleTarget);
 }