Example #1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            //获取传递参数
            string fundcodes = "";
            string ipocodes  = "";
            string analystid = "0";

            if (Request.QueryString["fcode"] != null)
            {
                fundcodes = Request.QueryString["fcode"].ToString();
            }

            if (Request.QueryString["scode"] != null)
            {
                ipocodes = Request.QueryString["scode"].ToString();
            }

            if (Request.QueryString["acode"] != null)
            {
                analystid = Request.QueryString["acode"].ToString();
            }

            //存储
            this.hFundCodes.Value = fundcodes;
            this.hIPOCodes.Value  = ipocodes;

            //新股代码
            ipocodes = "('" + ipocodes.Replace(",", "','") + "')";
            DataTable dtIPOs = DataService.GetInstance().GetIPOs("");
            dtIPOs.DefaultView.RowFilter = "Symbol IN " + ipocodes;
            dtIPOs.DefaultView.Sort      = "Symbol";
            dtIPOs = dtIPOs.DefaultView.ToTable();
            GridViewIPOInfo.DataSource = dtIPOs;
            GridViewIPOInfo.DataBind();
            GridViewIPOQuote.DataSource = dtIPOs;
            GridViewIPOQuote.DataBind();

            //经办人
            DataTable dtAnalysts = DataService.GetInstance().GetAnalyst();
            ddlAnalyst.DataSource     = dtAnalysts;
            ddlAnalyst.DataValueField = "AnalystId";
            ddlAnalyst.DataTextField  = "AnalystName";
            ddlAnalyst.DataBind();
            ddlAnalyst.Items.Insert(0, new ListItem("--未填--", "0"));
            ddlAnalyst.SelectedValue = analystid;
            this.LoadAnalystInfo(Convert.ToInt16(analystid));

            //日期
            tbDate.Text = DateTime.Today.ToString("yyyy-MM-dd");

            //投资方案
            this.loadDetail(dtIPOs, fundcodes);
            this.loadSummary(dtIPOs, fundcodes);

            //承销商
            this.loadUnderwriters(ipocodes);
        }
    }
Example #2
0
    private void LoadIPOTable()
    {
        string    code = txtCode.Text;
        DataTable dt   = DataService.GetInstance().GetIPOs(code);

        GridViewIPOInfo.DataSource = dt;
        GridViewIPOInfo.DataBind();
    }