Пример #1
0
 public Error.Types Delete(SiteSettings ss, bool notice = false)
 {
     Rds.ExecuteNonQuery(
         transactional: true,
         statements: new SqlStatement[]
     {
         Rds.DeleteGroups(
             where : Rds.GroupsWhere().GroupId(GroupId)),
         Rds.PhysicalDeleteGroupMembers(
             where : Rds.GroupMembersWhere()
             .GroupId(GroupId)),
         StatusUtilities.UpdateStatus(StatusUtilities.Types.GroupsUpdated)
     });
     return(Error.Types.None);
 }
Пример #2
0
        public Error.Types Delete(SiteSettings ss, bool notice = false)
        {
            var statements = new List <SqlStatement>();

            statements.AddRange(new List <SqlStatement>
            {
                Rds.DeleteGroups(
                    where : Rds.GroupsWhere().GroupId(GroupId)),
                Rds.PhysicalDeleteGroupMembers(
                    where : Rds.GroupMembersWhere()
                    .GroupId(GroupId)),
                StatusUtilities.UpdateStatus(StatusUtilities.Types.GroupsUpdated)
            });
            Rds.ExecuteNonQuery(
                transactional: true,
                statements: statements.ToArray());
            return(Error.Types.None);
        }
Пример #3
0
 public ErrorData Delete(Context context, SiteSettings ss, bool notice = false)
 {
     var statements = new List<SqlStatement>();
     var where = Rds.GroupsWhere().GroupId(GroupId);
     statements.AddRange(new List<SqlStatement>
     {
         Rds.DeleteGroups(where: where),
         Rds.PhysicalDeleteGroupMembers(
             where: Rds.GroupMembersWhere()
                 .GroupId(GroupId)),
         StatusUtilities.UpdateStatus(
             tenantId: context.TenantId,
             type: StatusUtilities.Types.GroupsUpdated),
     });
     var response = Rds.ExecuteScalar_response(
         context: context,
         transactional: true,
         statements: statements.ToArray());
     return new ErrorData(type: Error.Types.None);
 }