/// <summary> /// Set /// </summary> /// <param name="column"></param> /// <param name="value"></param> /// <returns></returns> public IFrom <T> Set(Expression <Func <T, object> > column, object value) { var name = ConditionVisitor <T> .GetColumnName(column.Body); Set(name, value); return(this); }
/// <summary> /// Set /// </summary> /// <param name="column">字段</param> /// <param name="value">表达式</param> /// <returns></returns> public IFrom <T> Set(Expression <Func <T, object> > column, Expression <Func <T, object> > value) { _set.AppendFormat("{0}{1} = {2}", _set.Length == 0 ? "" : ",", ConditionVisitor <T> .GetColumnName(column.Body), new FunctionVisitor <T>().Build(Param, value, false)); return(this); }