From d14b82fec13361486c49165371b5dee1b7089c09 Mon Sep 17 00:00:00 2001 From: username@email.com <yzy2002yzy@163.com> Date: 星期四, 09 十二月 2021 13:35:23 +0800 Subject: [PATCH] 提交 --- zhengcaioa/zhengcaioa/Controllers/SysCodeController.cs | 28 +++++++++++++++++++++++++--- 1 files changed, 25 insertions(+), 3 deletions(-) diff --git a/zhengcaioa/zhengcaioa/Controllers/SysCodeController.cs b/zhengcaioa/zhengcaioa/Controllers/SysCodeController.cs index 0473139..ef524e0 100644 --- a/zhengcaioa/zhengcaioa/Controllers/SysCodeController.cs +++ b/zhengcaioa/zhengcaioa/Controllers/SysCodeController.cs @@ -669,6 +669,8 @@ actionEntity1.ActionName = "鏂板"; actionlist.Add(actionEntity1); ViewData["ActionInfo"] = actionlist; + ViewBag.falv = _liaotianService.GetSYScode("expert_test_topicjiexi", "falv").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList(); + ViewBag.question = _liaotianService.GetSYScode("t_challenge_items", "question").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList(); return View(); } @@ -681,7 +683,27 @@ searchEntity.CodeTable = "t_complaint_items"; searchEntity.CodeField = "law"; searchEntity.Sort = "CodeSn"; - return new JsonResult(_sysCodeService.SearchSysCodeDtlPaging(searchEntity)); + + ResultDataEntity<SysCodeDtlEntity> resultDataEntity = _sysCodeService.SearchSysCodeDtlPaging(searchEntity); + + + var sysCodeDtls = _liaotianService.GetSYScode("expert_test_topicjiexi", "falv"); + + foreach(var sysCodeDtlEntity in resultDataEntity.DataList) + { + var sysCodeDtl = sysCodeDtls.Where(x => x.CodeSn == sysCodeDtlEntity.Comments).FirstOrDefault(); + if (sysCodeDtl != null) + sysCodeDtlEntity.CommentsName = sysCodeDtl.Comments; + } + sysCodeDtls = _liaotianService.GetSYScode("t_challenge_items", "question"); + foreach (var sysCodeDtlEntity in resultDataEntity.DataList) + { + var sysCodeDtl = sysCodeDtls.Where(x => x.CodeSn == sysCodeDtlEntity.Classify1).FirstOrDefault(); + if(sysCodeDtl!=null) + sysCodeDtlEntity.Classify1Name = sysCodeDtl.Comments; + } + + return new JsonResult(resultDataEntity); } @@ -700,8 +722,8 @@ ViewData.Model = sysCodeDtlEntity; - - + ViewBag.falv = _liaotianService.GetSYScode("expert_test_topicjiexi", "falv"); + ViewBag.question = _liaotianService.GetSYScode("t_challenge_items", "question"); return View(); } -- Gitblit v1.9.1