Ejemplo n.º 1
0
        public static clsModelGroup getModelPortfolioClientList(string strIFACode, string strModelGroup, string strModelName)
        {
            clsModelGroup       _clsModelGroup = new clsModelGroup();
            List <clsPortfolio> listPortfolio  = new List <clsPortfolio>();
            SqlConnection       con            = new clsSystem_DBConnection(clsSystem_DBConnection.strConnectionString.NavIntegrationDB).propConnection;
            SqlCommand          cmd            = new SqlCommand();
            SqlDataReader       dr;
            string strClientID    = string.Empty;
            string strPortfolioID = string.Empty;

            con.Open();
            cmd.Connection  = con;
            cmd.CommandType = System.Data.CommandType.StoredProcedure;
            cmd.CommandText = "SWITCH_ModelPortfolioClientGet";

            cmd.Parameters.Add("", System.Data.SqlDbType.NVarChar).Value = strIFACode;
            cmd.Parameters.Add("", System.Data.SqlDbType.NVarChar).Value = strModelGroup;
            cmd.Parameters.Add("", System.Data.SqlDbType.NVarChar).Value = strModelName;

            dr = cmd.ExecuteReader();

            while (dr.Read())
            {
                _clsModelGroup.propModelID    = dr["ModelID"].ToString();
                _clsModelGroup.propModelIFA   = dr["ModelIFA"].ToString();
                _clsModelGroup.propModelGroup = dr["ModelGroup"].ToString();
                _clsModelGroup.propModelName  = dr["ModelName"].ToString();

                strClientID    = dr["ClientID"].ToString();
                strPortfolioID = dr["ClientPortfolioID"].ToString();

                clsPortfolio _clsPortfolio = new clsPortfolio();
                //_clsPortfolio.(strClientID, strPortfolioID);
                _clsPortfolio.propClient = new clsClient(strClientID);
                listPortfolio.Add(_clsPortfolio);
            }
            return(_clsModelGroup);
        }
Ejemplo n.º 2
0
        public static clsModelGroup getModelPortfolioClientList(string strIFACode, string strModelGroup, string strModelName)
        {
            clsModelGroup _clsModelGroup = new clsModelGroup();
            List<clsPortfolio> listPortfolio = new List<clsPortfolio>();
            SqlConnection con = new clsSystem_DBConnection(clsSystem_DBConnection.strConnectionString.NavIntegrationDB).propConnection;
            SqlCommand cmd = new SqlCommand();
            SqlDataReader dr;
            string strClientID = string.Empty;
            string strPortfolioID = string.Empty;
            con.Open();
            cmd.Connection = con;
            cmd.CommandType = System.Data.CommandType.StoredProcedure;
            cmd.CommandText = "SWITCH_ModelPortfolioClientGet";

            cmd.Parameters.Add("", System.Data.SqlDbType.NVarChar).Value = strIFACode;
            cmd.Parameters.Add("", System.Data.SqlDbType.NVarChar).Value = strModelGroup;
            cmd.Parameters.Add("", System.Data.SqlDbType.NVarChar).Value = strModelName;

            dr = cmd.ExecuteReader();

            while (dr.Read())
            {
                _clsModelGroup.propModelID = dr["ModelID"].ToString();
                _clsModelGroup.propModelIFA = dr["ModelIFA"].ToString();
                _clsModelGroup.propModelGroup = dr["ModelGroup"].ToString();
                _clsModelGroup.propModelName = dr["ModelName"].ToString();

                strClientID = dr["ClientID"].ToString();
                strPortfolioID = dr["ClientPortfolioID"].ToString();

                clsPortfolio _clsPortfolio = new clsPortfolio();
                //_clsPortfolio.(strClientID, strPortfolioID);
                _clsPortfolio.propClient = new clsClient(strClientID);
                listPortfolio.Add(_clsPortfolio);
            }
            return _clsModelGroup;
        }