using System; using System.Collections.Generic; using System.Text; using System.Data; namespace DAL { public class ClsCrm_LinkManBill_View:DBUtility.ClsGy_Base_View { // public Model.ClsCrm_LinkManBillMain omodel = new Model.ClsCrm_LinkManBillMain(); SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); public ClsCrm_LinkManBill_View() { base.MvarReportTitle = "联系人设置"; base.MvarItemKey = "h_v_Crm_LinkManBillList"; base.SQLName = "Select HMainID,HCusID,姓名,客户,负责人 from h_v_Crm_LinkManBillList Order by HMainID "; } // public void Dispose() { GC.SuppressFinalize(this); } // //返回项目信息 public override bool GetInfoByID(Int64 sItemID) { DataSet DS ; try { DS = oCn.RunProcReturn("Select * from " + MvarItemKey + " Where HMainID='" + sItemID + "'", MvarItemKey, ref DBUtility.ClsPub.sExeReturnInfo); if (DS.Tables[0].Rows.Count == 0) return false; else { return GetInfo(DS); } } catch (Exception e) { throw (e); } } //返回项目信息 public override bool GetInfo(DataSet Ds) { try { omodel = new Model.ClsCrm_LinkManBillMain(); omodel.HInterID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HMainID"]); omodel.HName = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["姓名"]); omodel.HCallName = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["称呼"]); omodel.HPost = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["英文名"]); omodel.HCusID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HCusID"]); omodel.HLinkPhone = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["办公电话"]); omodel.HMovePhone = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["手机"]); omodel.HQQ = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["QQ"]); omodel.HEmail = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["邮箱"]); omodel.HFax = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["传真"]); omodel.HCusFrom = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["客户来源"]); omodel.HFstLinkMan = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["首要联系人"]); omodel.HHomePhone = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["家庭电话"]); omodel.HManager = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["负责人"]); omodel.HDept = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["部门"]); omodel.HLead = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["上级"]); // return true; } catch (Exception e) { throw (e); } } } }