public VerifyViewModel(int id) { var bizProcessesAudit = BizFactory.BizProcessesAudit.ChangeStatusByAuditFlowV1(id, Enumeration.AuditFlowV1Status.InVerify, this.Operater, null, "已取单,正在核实"); if (bizProcessesAudit != null) { _bizProcessesAudit = bizProcessesAudit; if (_bizProcessesAudit.Auditor.Value != this.Operater) { this.IsHasOperater = true; this.OperaterName = SysFactory.SysUser.GetFullName(_bizProcessesAudit.Auditor.Value); } var orderToApplyLossAssess = CurrentDb.OrderToApplyLossAssess.Where(m => m.Id == bizProcessesAudit.AduitReferenceId).FirstOrDefault(); if (orderToApplyLossAssess != null) { _orderToApplyLossAssess = orderToApplyLossAssess; var merchant = CurrentDb.Merchant.Where(m => m.Id == orderToApplyLossAssess.MerchantId).FirstOrDefault(); if (merchant != null) { _merchant = merchant; } } } }
public DetailsViewModel(int id) { var orderToApplyLossAssess = CurrentDb.OrderToApplyLossAssess.Where(m => m.Id == id).FirstOrDefault(); if (orderToApplyLossAssess != null) { _orderToApplyLossAssess = orderToApplyLossAssess; var merchant = CurrentDb.Merchant.Where(m => m.Id == orderToApplyLossAssess.MerchantId).FirstOrDefault(); if (merchant != null) { _merchant = merchant; } _bizProcessesAuditDetails = BizFactory.BizProcessesAudit.GetDetails(Enumeration.BizProcessesAuditType.OrderToApplyLossAssess, id); } }