protected MpConfigModel GetMpConfigModel() { var mpconfig = _vipDal.GetAll <MPConfig>().FirstOrDefault(); return(mpconfig == null ? null : Newtonsoft.Json.JsonConvert.DeserializeObject <MpConfigModel>(mpconfig.ConfigValue, new Newtonsoft.Json.JsonSerializerSettings { MissingMemberHandling = Newtonsoft.Json.MissingMemberHandling.Ignore })); }
private void DoRefund(Vip entity) { var vipFee = _dal.GetAll <VipFee>().Where(p => p.VipId == entity.Id && p.Status == (int)PayStatus.支付成功).OrderByDescending(p => p.FeeTime).FirstOrDefault(); if (vipFee != null && entity.FeeStatus == (int)PayStatus.支付成功) { var refundReqData = RefundRequestData.GetRefundRequestData((int)vipFee.Fee, vipFee.OrderCode, Server.MapPath("~/App_Data/apiclient_cert.p12")); _dal.Insert <VipFeeRefund>(new VipFeeRefund { RtnOrderCode = refundReqData.RtnOrderCode, OrderCode = vipFee.OrderCode, VipId = vipFee.VipId, VipName = entity.VipName, RefundFee = vipFee.Fee, WXRtnOrderCode = refundReqData.WxRtnOrderCode, Remark = refundReqData.Remark }); if (refundReqData.RefundResult.ToLower() == "success") { //entity.IsReturnFee = true; entity.FeeStatus = (int)PayStatus.待支付; } } }
public ActionResult PayLog() { ViewBag.Title = "我的缴费"; var vipFees = _dal.GetAll <VipFee>().Where(p => p.VipId == CurrentVip.VipId && p.Status == 1).OrderByDescending(p => p.FeeTime).ToList(); return(View(vipFees)); }