You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
93 lines
3.2 KiB
93 lines
3.2 KiB
4 years ago
|
using System;
|
||
|
using System.Collections.Generic;
|
||
|
using System.Linq;
|
||
|
using System.Text;
|
||
|
using QMFrameWork.Data;
|
||
|
using QMAPP.Entity.Sys;
|
||
|
using System.Data;
|
||
|
using QMAPP.MD.Entity.Sys;
|
||
|
|
||
|
namespace QMAPP.DAL.Sys
|
||
|
{
|
||
|
/// <summary>
|
||
|
/// 超时提醒数据层对象
|
||
|
/// 创建者:
|
||
|
/// 创建日期:
|
||
|
/// </summary>
|
||
|
public class OverTimeRemindDAL : BaseDAL
|
||
|
{
|
||
|
|
||
|
#region 获取未处理问题列表
|
||
|
/// <summary>
|
||
|
/// 获取未处理问题列表
|
||
|
/// </summary>
|
||
|
/// <param name="condition">条件</param>
|
||
|
/// <param name="page">数据页</param>
|
||
|
/// <returns>数据页</returns>
|
||
|
public List<OverTimeRemind> GetOverTimeRemindList(string userId)
|
||
|
{
|
||
|
StringBuilder sb = new StringBuilder();
|
||
|
List<DataParameter> parameters = new List<DataParameter>();
|
||
|
List<OverTimeRemind> resultList = null;
|
||
|
try
|
||
|
{
|
||
|
sb.Append(" SELECT DEAL.ACTIONTIME,ZP.SDEPT,ZP.PDESP FROM T_QM_ZPDEALINFO DEAL LEFT JOIN T_QM_ZPDDB ZP ON DEAL.ZPDDB_PID = ZP.PID ");
|
||
|
sb.Append(" WHERE DEAL.ZPDDB_PID IN ");
|
||
|
sb.Append(" (SELECT PID FROM T_QM_ZPDDB DBB WHERE ECIND = 0 AND SUSER IS NOT NULL ");
|
||
|
if (!string.IsNullOrEmpty(userId))
|
||
|
{
|
||
|
sb.Append(" AND SUSER = @USERID ");
|
||
|
parameters.Add(new DataParameter { ParameterName = "USERID", DataType = DbType.String, Value = userId });
|
||
|
}
|
||
|
|
||
|
sb.Append(" ) ");
|
||
|
sb.Append(" AND DEAL.ACTION = '创建' ");
|
||
|
|
||
|
using (IDataSession session = AppDataFactory.CreateMainSession())
|
||
|
{
|
||
|
string sql = this.ChangeSqlByDB(sb.ToString(), session);
|
||
|
resultList = session.GetList<OverTimeRemind>(sql, parameters.ToArray()).ToList<OverTimeRemind>();
|
||
|
}
|
||
|
return resultList;
|
||
|
}
|
||
|
catch (Exception ex)
|
||
|
{
|
||
|
throw ex;
|
||
|
}
|
||
|
}
|
||
|
#endregion
|
||
|
|
||
|
#region 获取所有的业务管理员列表
|
||
|
|
||
|
/// <summary>
|
||
|
/// 获取未处理问题列表
|
||
|
/// </summary>
|
||
|
/// <param name="condition">条件</param>
|
||
|
/// <param name="page">数据页</param>
|
||
|
/// <returns>数据页</returns>
|
||
|
public List<User> GetBusinessManage()
|
||
|
{
|
||
|
StringBuilder sb = new StringBuilder();
|
||
|
List<DataParameter> parameters = new List<DataParameter>();
|
||
|
List<User> resultList = null;
|
||
|
try
|
||
|
{
|
||
|
sb.Append(" SELECT USERID,ORGANID,EMAIL FROM T_QM_USER WHERE USERTYPE = 'LO' AND ACTIVATEFLG = 1 AND FLGDEL = 0 ");
|
||
|
|
||
|
using (IDataSession session = AppDataFactory.CreateMainSession())
|
||
|
{
|
||
|
string sql = this.ChangeSqlByDB(sb.ToString(), session);
|
||
|
resultList = session.GetList<User>(sql, parameters.ToArray()).ToList<User>();
|
||
|
}
|
||
|
return resultList;
|
||
|
}
|
||
|
catch (Exception ex)
|
||
|
{
|
||
|
throw ex;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
#endregion
|
||
|
}
|
||
|
}
|