Beispiel #1
0
 public void renderSendFormIfNecessary(TextWriter tw)
 {
     if (postPaymentRequestToRender != null)
     {
       postPaymentRequestToRender.RenderPaymentRequestForm(tw);
       postPaymentRequestToRender = null;
     }
 }
Beispiel #2
0
    private void createPaymentRequest(IPaymentRequest pr)
    {
        resetPaymentRequest();

        bool validationResult = pr.Validate();

        PaymentRequestCreationLogControl.IsValid = validationResult;

        if (validationResult)
        {
          if (pr is EPaymentMessage)
          {
        PaymentRequestCreationLogControl.UncryptedSignature = ((EPaymentMessage)pr).SignatureBase;
          }
          pr.SignMessage(tbSharedSecret.Text);
          if (pr is EPaymentMessage)
          {
        PaymentRequestCreationLogControl.CryptedSignature = ((EPaymentMessage)pr).Signature;
          }

          if (pr is IHttpRedirectPaymentRequest)
          {
        displayPaymentRequestLink(((IHttpRedirectPaymentRequest)pr).PaymentRequestUrl);
          }
          else
          {
        hlPaymentRequest.NavigateUrl = null;
        hlPaymentRequest.Visible = false;
          }

          if (pr is IHttpPostPaymentRequest)
          {
        postPaymentRequestToRender = (IHttpPostPaymentRequest)pr;
          }
        }
    }