📄 projectreportentrylog.cs
字号:
using System;
using System.Configuration;
using System.Data;
using qminoa.DA;
namespace qminoa.BLL.PM
{
public class ProjectReportEntryLog
{
private decimal _duration;
private string _fullName;
private DateTime _maxEntryDate, _minEntryDate;
private int _userID;
private string _userName;
public ProjectReportEntryLog()
{
_userName = string.Empty;
_duration = 0M;
_userID = 0;
_minEntryDate = DateTime.MinValue;
_maxEntryDate = DateTime.MinValue;
_fullName = string.Empty;
}
public decimal Duration
{
get { return _duration; }
set { _duration = value; }
}
public string FullName
{
get { return _fullName; }
set { _fullName = value; }
}
public int UserID
{
get { return _userID; }
set { _userID = value; }
}
public string UserName
{
get { return _userName; }
set { _userName = value; }
}
public DateTime MaxEntryDate
{
get { return _maxEntryDate; }
set { _maxEntryDate = value; }
}
public DateTime MinEntryDate
{
get { return _minEntryDate; }
set { _minEntryDate = value; }
}
public static ProjectReportEntryLogCollection GetEntrySummary(int categoryID)
{
DataSet dsData = SqlHelper.ExecuteDataset(ConfigurationSettings.AppSettings["ConnectionString"],
"PM_ListTimeEntriesByCategory", categoryID);
ProjectReportEntryLogCollection entryList = new ProjectReportEntryLogCollection();
foreach(DataRow row in dsData.Tables[0].Rows)
{
ProjectReportEntryLog entry = new ProjectReportEntryLog();
string firstName = string.Empty;
string lastName = string.Empty;
entry.UserName = row["UserName"].ToString();
entry.Duration = Convert.ToDecimal(row["Duration"]);
entry.UserID = Convert.ToInt32(row["UserID"]);
entry.MinEntryDate = Convert.ToDateTime(row["MinEntryDate"]);
entry.MaxEntryDate = Convert.ToDateTime(row["MaxEntryDate"]);
entry.FullName = entry.UserName;
entryList.Add(entry);
}
return entryList;
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -