Ejemplo n.º 1
0
        public HrmResultEntity <bool> SavePermission(StaffRolePermissionEntity staffRolePermisson, List <MenuPermissionType> menuPermissions, string dbName)
        {
            var par = new DynamicParameters();

            par.Add("@DataId", staffRolePermisson.DataId);
            par.Add("@DataTypeName", staffRolePermisson.DataTypeName);
            par.Add("@Name", staffRolePermisson.Name);
            par.Add("@Description", staffRolePermisson.Description);
            par.Add("@DbName", dbName);
            par.Add("@MenuPermission", menuPermissions.ConvertToUserDefinedDataTable(), DbType.Object);
            return(Procedure("Permission_Update_SavePermission", par));
        }
Ejemplo n.º 2
0
        public string SavePermission(StaffRolePermissionEntity staffRolePermisson, List <MenuPermissionType> menuPermissions)
        {
            var response = this._permissionRepository.SavePermission(staffRolePermisson, menuPermissions, _dbName);

            return(JsonConvert.SerializeObject(response));
        }