using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CoreFS.CA06;
using System.Data;
using System.Collections;
using Core.Mes.Client.Common;
using Core.LgMes.Client.lgDbMgt;
namespace Core.LgMes.Client.lgServiceMgt.LgResService
{
public class LgStlLfsOptinfoDAL : Core.LgMes.Client.lgServiceMgt.BaseService.LgBaseService
{
private const string SQL_STL_LFS_OPTION = "select * from stl_lfs_optinfo where 1 = 1 {0}";
private const string HIS_SQL_STL_LFS_OPTION = "select * from j#stl_lfs_optinfo where 1 = 1 {0}";
private const string SQL_STL_LFS_OPTION_All = "select * from stl_lfs_optinfo where 1 = 1 {0} union all select * from j#stl_lfs_optinfo where 1 = 1 {0}";
///
/// stl_lfs_optinfo
///
///
///
public DataSet GetStlLfsOption(ClientParamWithSqlConditionAndOpenBase param)
{
DataSet ds = new DataSet();
string sqlStr = "";
try
{
sqlStr = string.Format(SQL_STL_LFS_OPTION,param.sqlCondition);
ds = base.dbCommond.ExecuteReader(new DbClientParam(sqlStr, param.ob));
}
catch
{
}
return ds;
}
///
/// j#stl_lfs_optinfo
///
///
///
public DataSet GetStlLfsOptionHis(ClientParamWithSqlConditionAndOpenBase param)
{
DataSet ds = new DataSet();
string sqlStr = "";
try
{
sqlStr = string.Format(HIS_SQL_STL_LFS_OPTION, param.sqlCondition);
ds = base.dbCommond.ExecuteReader(new DbClientParam(sqlStr, param.ob));
}
catch
{
}
return ds;
}
///
/// stl_lfs_optinfo j#stl_lfs_optinfo
///
///
///
public DataSet GetStlLfsOptionAll(ClientParamWithSqlConditionAndOpenBase param)
{
DataSet ds = new DataSet();
string sqlStr = "";
try
{
sqlStr = string.Format(SQL_STL_LFS_OPTION_All, param.sqlCondition);
ds = base.dbCommond.ExecuteReader(new DbClientParam(sqlStr, param.ob));
}
catch
{
}
return ds;
}
///
/// 通过一炉号获取实绩信息
///
///
///
public DataSet GetStlLfsOptionByHeatNo(ClientParamWithSqlConditionAndOpenBase param)
{
ClientParamWithSqlConditionAndOpenBase pa = new ClientParamWithSqlConditionAndOpenBase();
pa.sqlCondition = string.Format(" and heatno = '{0}' ",param.sqlCondition);
pa.ob = param.ob;
return GetStlLfsOptionAll(pa);
}
}
}