using System; using System.Collections.Generic; using System.Text; using System.Data; namespace BLL { public class ClsIF_Source_View { /// /// 根据过滤条件返回生产资源列表 /// /// 过滤条件 /// 错误信息 /// public DataSet GetList(string sWhere, ref string sErr) { try { DAL.ClsIF_Source_View dal = new DAL.ClsIF_Source_View(); return dal.GetList(sWhere); } catch (Exception e) { sErr = sErr + "," + e.Message; return null; } } /// /// 根据代码返回生产资源信息 /// /// 代码 /// 错误信息 /// public Model.ClsGy_Source_Model GetInfoByNumber(string sWhere, ref string sErr) { try { DAL.ClsIF_Source_View dal = new DAL.ClsIF_Source_View(); if (dal.GetInfoByNumber(sWhere)) { return dal.omodel; } else { return null; } } catch (Exception e) { sErr = sErr + "," + e.Message; return null; } } /// /// 根据名称返回生产资源信息 /// /// 名称 /// 错误信息 /// public Model.ClsGy_Source_Model GetInfoByName(string sWhere, ref string sErr) { try { DAL.ClsIF_Source_View dal = new DAL.ClsIF_Source_View(); if (dal.GetInfoByName(sWhere)) { return dal.omodel; } else { return null; } } catch (Exception e) { sErr = sErr + "," + e.Message; return null; } } /// /// 根据内码返回生产资源信息 /// /// 内码 /// 错误信息 /// public Model.ClsGy_Source_Model GetInfoByID(long sWhere, ref string sErr) { try { DAL.ClsIF_Source_View dal = new DAL.ClsIF_Source_View(); if (dal.GetInfoByID(sWhere)) { return dal.omodel; } else { return null; } } catch (Exception e) { sErr = sErr + "," + e.Message; return null; } } } }