62 lines
2.3 KiB
C#
62 lines
2.3 KiB
C#
using Ease.Core.DataAccess;
|
|
using HRM.BO;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Data;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace HRM.DA
|
|
{
|
|
internal class ExitCleraceTaskHandoverDA
|
|
{
|
|
#region Constructor
|
|
|
|
private ExitCleraceTaskHandoverDA()
|
|
{
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Insert function
|
|
|
|
internal static void Insert(TransactionContext tc, ExitCleraceTaskHandover item)
|
|
{
|
|
tc.ExecuteNonQuery(
|
|
"INSERT INTO ExitCleraceTaskHandover (ExitCleraceTaskHandoverID, ResignationRequestID, SubmitDate, Responsiblity, CurrentStatus, Remarks, LMID, LMRemarks, LMRemarksDate, CREATEDBY, CREATIONDATE)" +
|
|
" VALUES(%n, %n, %d, %s, %n, %s, %n, %s, %d, %n, %D)", item.ID, item.ResignationRequestID, item.SubmitDate, item.Responsiblity, item.CurrentStatus, item.Remarks, item.LmID, item.LMRemarks, item.LMRemarksDate, item.CreatedBy, item.CreatedDate);
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Update function
|
|
|
|
internal static void Update(TransactionContext tc, ExitCleraceTaskHandover item)
|
|
{
|
|
tc.ExecuteNonQuery(
|
|
"UPDATE ExitCleraceTaskHandover" +
|
|
" SET ResignationRequestID = %n,SubmitDate = %d, Responsiblity = %s, CurrentStatus = %n, Remarks = %s, LMID = %n, LMRemarks = %s, LMRemarksDate = %d, MODIFIEDBY = %n, MODIFIEDDATE = %D" +
|
|
" WHERE ExitCleraceTaskHandoverID=%n", item.ResignationRequestID, item.SubmitDate, item.Responsiblity,
|
|
item.CurrentStatus, item.Remarks, item.LmID, item.LMRemarks, item.LMRemarksDate, item.ModifiedBy,
|
|
item.ModifiedDate, item.ID);
|
|
}
|
|
|
|
#endregion
|
|
|
|
internal static IDataReader Get(TransactionContext tc)
|
|
{
|
|
return tc.ExecuteReader(@"SELECT * FROM ExitCleraceTaskHandover");
|
|
}
|
|
internal static IDataReader Get(TransactionContext tc, int nID)
|
|
{
|
|
return tc.ExecuteReader("SELECT * FROM ExitCleraceTaskHandover Where ExitCleraceTaskHandoverID=%n", nID);
|
|
}
|
|
internal static IDataReader GetByResignationRequestID(TransactionContext tc, int resignationRequestID)
|
|
{
|
|
return tc.ExecuteReader("SELECT * FROM ExitCleraceTaskHandover Where ResignationRequestID=%n", resignationRequestID);
|
|
}
|
|
|
|
}
|
|
}
|