using SqlSugar;
|
using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
using System.Threading.Tasks;
|
|
namespace IStation.DAL
|
{
|
/// <summary>
|
///
|
/// </summary>
|
public partial class BaseTraceDAL_TreeSorter_UseStatus<T> : BaseTraceDAL_TreeSorter<T> where T : Entity.BaseTraceEntity, Entity.ITreeSorter, Entity.IUseStatus, new()
|
{
|
/// <summary>
|
/// 更新使用状态
|
/// </summary>
|
public virtual bool UpdateUseStatus(long ID, int UseStatus, long UpdateUserID, DateTime UpdateTime)
|
{
|
using (SqlSugarClient db = new SqlSugarClient(ConnectionConfig))
|
{
|
return db.Updateable<T>()
|
.SetColumns(x => x.UseStatus == UseStatus)
|
.SetColumns(x => x.UpdateUserID == UpdateUserID)
|
.SetColumns(x => x.UpdateTime == UpdateTime)
|
.Where(x => x.ID == ID)
|
.ExecuteCommandHasChange();
|
}
|
}
|
}
|
}
|