protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                string redirectUrl = "FinancingRepoApplyCanRepoPledgeList.aspx";

                if (!UserOperate.Contains(OperateEnum.录入))
                    btnSave.Style.Add("display", "none");
                if (!UserOperate.Contains(OperateEnum.录入) || !UserOperate.Contains(OperateEnum.提交审核))
                    btnSubmit.Style.Add("display", "none");

                navigation1.Routes.Add("赎回申请单列表", "FinancingRepoApplyList.aspx");
                navigation1.Routes.Add("可赎回质押申请单列表", redirectUrl);
                navigation1.Routes.Add("赎回申请单新增", string.Empty);

                if (string.IsNullOrEmpty(Request.QueryString["pledgeApplyId"]) || !int.TryParse(Request.QueryString["pledgeApplyId"], out pledgeApplyId) || pledgeApplyId <= 0)
                    this.WarmAlert("参数错误", redirectUrl);

                PledgeApplyBLL pledgeApplyBLL = new PledgeApplyBLL();
                ResultModel result = pledgeApplyBLL.Get(User, pledgeApplyId);
                if (result.ResultStatus != 0)
                    this.WarmAlert(result.Message, redirectUrl);

                CurPledgeApply = result.ReturnValue as PledgeApply;
                if (CurPledgeApply == null || CurPledgeApply.PledgeApplyId <= 0)
                    this.WarmAlert("获取质押申请单错误", redirectUrl);

                FinService service = new FinService();
                selectedJson = service.GetFinPledgeApplyStockDetailForRepoList(1, 500, "pasd.StockDetailId desc", pledgeApplyId);
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                if (!UserOperate.Contains(OperateEnum.提交审核))
                    btnAudit.Style.Add("display", "none");
                if (!UserOperate.Contains(OperateEnum.作废))
                    btnInvalid.Style.Add("display", "none");
                if (!UserOperate.Contains(OperateEnum.撤返))
                    btnGoBack.Style.Add("display", "none");
                if (!UserOperate.Contains(OperateEnum.关闭))
                    btnClose.Style.Add("display", "none");

                string redirectUrl = "FinancingPledgeApplyList.aspx";

                navigation1.Routes.Add("质押申请单列表", redirectUrl);
                navigation1.Routes.Add("质押申请单明细", string.Empty);

                int pledgeApplyId = 0;
                if (string.IsNullOrEmpty(Request.QueryString["id"]) || !int.TryParse(Request.QueryString["id"], out pledgeApplyId) || pledgeApplyId <= 0)
                    this.WarmAlert("参数错误", redirectUrl);

                PledgeApplyBLL pledgeApplyBLL = new PledgeApplyBLL();
                ResultModel result = pledgeApplyBLL.Get(User, pledgeApplyId);
                if (result.ResultStatus != 0)
                    this.WarmAlert(result.Message, redirectUrl);

                CurPledgeApply = result.ReturnValue as PledgeApply;
                if (CurPledgeApply == null || CurPledgeApply.PledgeApplyId <= 0)
                    this.WarmAlert("获取质押申请单错误", redirectUrl);

                FinService service = new FinService();
                repoInfoJson = service.GetFinancingPledgeApplyRepoInfoList(1, 500, "ra.RepoApplyId", pledgeApplyId);

                JavaScriptSerializer serializer = new JavaScriptSerializer();
                string json = serializer.Serialize(CurPledgeApply);
                hidModel.Value = json;

                NFMT.Finance.EmailInfoProvider provider = new NFMT.Finance.EmailInfoProvider(NFMT.Finance.FinType.质押, pledgeApplyId);
                result = provider.GetEmailInfo(User);
                if (result.ResultStatus == 0)
                    emailStr = result.ReturnValue.ToString();

                this.hidMailInfo.Value = emailStr;
            }
        }