56 lines
1.9 KiB
C#
56 lines
1.9 KiB
C#
|
|
using System;
|
|||
|
|
using System.Collections.Generic;
|
|||
|
|
using System.Linq;
|
|||
|
|
using System.Text;
|
|||
|
|
using System.Data;
|
|||
|
|
using WMS.Model.Stock;
|
|||
|
|
using WMS.IData;using Oracle.ManagedDataAccess.Client;
|
|||
|
|
using WMS.IData.IReport;
|
|||
|
|
using WMS.Model.Report;
|
|||
|
|
|
|||
|
|
namespace WMS.SqlServerData.ReportData
|
|||
|
|
{
|
|||
|
|
public class RKReportData : IRKReport
|
|||
|
|
{
|
|||
|
|
/// <summary>
|
|||
|
|
///
|
|||
|
|
/// </summary>
|
|||
|
|
/// <param name="model"></param>
|
|||
|
|
/// <returns></returns>
|
|||
|
|
public DataTable GetRKReportDT(RKReportModel model)
|
|||
|
|
{
|
|||
|
|
StringBuilder strSql = new StringBuilder();
|
|||
|
|
strSql.Append(@" select * from VIEW_RKREPORT where 1 = 1 ");
|
|||
|
|
if (!string.IsNullOrEmpty(model.GOODSID))
|
|||
|
|
{
|
|||
|
|
strSql.AppendLine(" and GOODSID ='" + model.GOODSID + "'");
|
|||
|
|
}
|
|||
|
|
if (!string.IsNullOrEmpty(model.STORAGE_ID))
|
|||
|
|
{
|
|||
|
|
strSql.AppendLine(" and STORAGE_ID ='" + model.STORAGE_ID + "'");
|
|||
|
|
}
|
|||
|
|
if (model.ONDATE != DateTime.MinValue || model.ONDATE != DateTime.MinValue)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
strSql.Append(" and ondate between to_date('" + model.ONDATE.ToString("yyyy-MM-dd HH:mm:ss") + "','yyyy-MM-dd HH24:mi:ss') and to_date('" + model.ONDATE.ToString("yyyy-MM-dd HH:mm:ss") + "','yyyy-MM-dd HH24:mi:ss') ORDER BY rk_date DESC ");
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
return SystemDataObject.Instance.GetDataTable(strSql.ToString());
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
public DataTable GetRKReportDT2(String DATE1,String DATE2)
|
|||
|
|
{
|
|||
|
|
StringBuilder strSql = new StringBuilder();
|
|||
|
|
strSql.Append(@" select * from VIEW_RKREPORT where 1 = 1 ");
|
|||
|
|
|
|||
|
|
strSql.Append(" and ondate between to_date('" + DATE1 + "','yyyy-MM-dd HH24:mi:ss') and to_date('" +DATE2 + "','yyyy-MM-dd HH24:mi:ss') ORDER BY ondate DESC ");
|
|||
|
|
|
|||
|
|
|
|||
|
|
return SystemDataObject.Instance.GetDataTable(strSql.ToString());
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
}
|