From ac64cf6f86f8d9b42941cb2a25597e3af1931a26 Mon Sep 17 00:00:00 2001 From: liangkun Date: Tue, 6 Sep 2022 17:17:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E5=91=8A=E9=80=9A=E7=9F=A5=E6=9F=A5?= =?UTF-8?q?=E7=9C=8B=E9=A1=B5=E9=9D=A2=E5=B5=8C=E5=A5=97iframe?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/UtilityController.cs | 11 +++++++++++ .../Views/Utility/ListContentIndex.cshtml | 5 +++-- .../Views/Utility/ListContentIndex.js | 3 ++- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/UtilityController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/UtilityController.cs index c46d958fb..2f5a72623 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/UtilityController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/UtilityController.cs @@ -5,7 +5,9 @@ using System.Collections.Generic; using System.Data; using System.IO; using System.Linq; +using System.Net.Http; using System.Web.Mvc; +using Learun.Application.OA; namespace Learun.Application.Web.Controllers { @@ -595,6 +597,15 @@ namespace Learun.Application.Web.Controllers { return View(); } + + private NoticeIBLL noticeIBLL = new NoticeBLL(); + [HttpGet] + public ActionResult ListContentView(string keyValue) + { + var data = noticeIBLL.GetEntity(keyValue); + data.F_NewsContent = WebHelper.HtmlDecode(data.F_NewsContent); + return Content(data.F_NewsContent); + } /// /// 失物招领 /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.cshtml index aae7a7269..8d31bb3b1 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.cshtml @@ -23,9 +23,10 @@ 信息来源: 公告类别: -
+ @*
-
+
*@ +
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.js index 2158a57a3..e991f9dc9 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Utility/ListContentIndex.js @@ -27,7 +27,8 @@ var bootstrap = function ($, learun) { $("#F_CreateDate").text(data.F_CreateDate); $("#F_CreateUserName").text(data.F_SourceName == null ? "" : data.F_SourceName); $("#F_Category").text(data.F_Category); - $("#F_NewsContent").html($('
').html(data.F_NewsContent)); + //$("#F_NewsContent").html($('
').html(data.F_NewsContent)); + $("#newscontentframe").attr("src","/Utility/ListContentView?keyValue="+id); $('#F_NewsImage').lrUploaderSet(data.F_NewsImage); }); }