示例#1
0
 public PreapprovalResponse GetStatus(PreapprovalRequest req)
 {
     // var req = new PreapprovalRequest { preapproval_id = preapproval_id };
     PreapprovalResponse response;
     try
     {
         response = new WePayClient().Invoke<PreapprovalRequest, PreapprovalResponse>(req, req.actionUrl);
     }
     catch (WePayException ex)
     {
         response = new PreapprovalResponse { state = ex.error, amount = 0, Error = ex };
     }
     return response;
 }
示例#2
0
        public PreapprovalResponse GetStatus(PreapprovalRequest req)
        {
            // var req = new PreapprovalRequest { preapproval_id = preapproval_id };
            PreapprovalResponse response;

            try
            {
                response = new WePayClient().Invoke <PreapprovalRequest, PreapprovalResponse>(req, req.actionUrl);
            }
            catch (WePayException ex)
            {
                response = new PreapprovalResponse {
                    state = ex.error, amount = 0, Error = ex
                };
            }
            return(response);
        }