예제 #1
0
        public static int Delete(this Database.Tables.题.题_连线_选项 o, ColumnEnums.Tables.题.题_连线_选项.Handler conditionCols = null)
        {
            if (conditionCols == null)
            {
                return(Database.Tables.题.题_连线_选项.Delete(t =>
                                                        t.题编号 == o.题编号 &
                                                        t.连线序号 == o.连线序号
                                                        ));
            }
            var cols = conditionCols(new DAL.ColumnEnums.Tables.题.题_连线_选项());
            var exp  = new DAL.Expressions.Tables.题.题_连线_选项();

            if (cols.Contains(0))
            {
                exp.And(t => t.题编号 == o.题编号);
            }
            if (cols.Contains(1))
            {
                exp.And(t => t.连线序号 == o.连线序号);
            }
            if (cols.Contains(2))
            {
                exp.And(t => t.组序号 == o.组序号);
            }
            if (cols.Contains(3))
            {
                exp.And(t => t.显示模板 == o.显示模板);
            }
            return(Database.Tables.题.题_连线_选项.Delete(exp));
        }
예제 #2
0
 public static int Update(this Database.Tables.题.题_连线_选项 o, Expressions.Tables.题.题_连线_选项.Handler eh = null, ColumnEnums.Tables.题.题_连线_选项.Handler updateCols = null, ColumnEnums.Tables.题.题_连线_选项.Handler fillCols = null, bool isFillAfterUpdate = true)
 {
     return(Database.Tables.题.题_连线_选项.Update(o, eh, updateCols, fillCols, isFillAfterUpdate));
 }
예제 #3
0
 public static int Insert(this Database.Tables.题.题_连线_选项 o, ColumnEnums.Tables.题.题_连线_选项.Handler insertCols = null, ColumnEnums.Tables.题.题_连线_选项.Handler fillCols = null, bool isFillAfterInsert = true)
 {
     return(Database.Tables.题.题_连线_选项.Insert(o, insertCols, fillCols, isFillAfterInsert));
 }