protected void Page_Load(object sender, EventArgs e) { AlipayClass.QianYue qianyue = new AlipayClass.QianYue( AlipayParameters.Partner, AlipayParameters.SignType, AlipayParameters.Key, AlipayParameters.Input_Charset); HyperLink1.NavigateUrl = qianyue.Create_url(); TrustRefund trust = new TrustRefund(TenpayParameters.Bargainor_ID); HyperLink2.NavigateUrl = trust.CreateUrl(); }
/// <summary> /// 根据支付接口,生成相应的签约URL /// </summary> /// <param name="type">支付接口类型</param> /// <param name="accountNumber">支付帐户</param> /// <returns></returns> private string GetQianYueUrl(EyouSoft.Model.TicketStructure.TicketAccountType type, string accountNumber) { string url = string.Empty; switch (type) { case EyouSoft.Model.TicketStructure.TicketAccountType.财付通: TrustRefund trust = new TrustRefund(TenpayParameters.Bargainor_ID); url = trust.CreateUrl(); break; case EyouSoft.Model.TicketStructure.TicketAccountType.支付宝: QianYue qianyue = new QianYue(AlipayParameters.Partner, AlipayParameters.SignType, AlipayParameters.Key, AlipayParameters.Input_Charset, accountNumber); url = qianyue.Create_url(); break; } return(url); }