void DirectResign() { var confirmEventArg = new GeneralEventArgs <bool>(false); DirectResignCancelled = false; OnRequireDirectResign(confirmEventArg); if (!confirmEventArg.Data) { DirectResignCancelled = true; return; } //确认直接改签 var resignResult = Session.NetClient.Create <string>(HttpMethod.Post, "pay/payConfirm" + ParamData.GetValue("pay_mode"), "payOrder/init", new { parOrderDTOJson = ParamData.GetValue("parOrderDTOJson"), oldTicketDTOJson = ParamData.GetValue("oldTicketDTOJson"), sequence_no = ParamData.GetValue("sequence_no"), batch_no = ParamData.GetValue("batch_no"), _json_att = Session.Attributes ?? "" }).Send(); if (!resignResult.IsValid()) { Error = "无效的服务器响应"; return; } try { var resignData = JsonConvert.DeserializeAnonymousType(resignResult.Result, new { status = true, data = new { resignStatus = false, errorMessage = "" }, messages = new string[0] }); if (!resignData.status || resignData.data == null) { Error = "服务器返回操作失败: " + resignData.messages.JoinAsString("").DefaultForEmpty(resignResult.Result); return; } if (!resignData.data.resignStatus) { Error = "无法完成改签: " + resignData.data.errorMessage.DefaultForEmpty("未知错误"); return; } } catch (Exception) { Error = "无法解析服务器响应: " + resignResult.Result; return; } }