最新文章專題視頻專題問答1問答10問答100問答1000問答2000關(guān)鍵字專題1關(guān)鍵字專題50關(guān)鍵字專題500關(guān)鍵字專題1500TAG最新視頻文章推薦1 推薦3 推薦5 推薦7 推薦9 推薦11 推薦13 推薦15 推薦17 推薦19 推薦21 推薦23 推薦25 推薦27 推薦29 推薦31 推薦33 推薦35 推薦37視頻文章20視頻文章30視頻文章40視頻文章50視頻文章60 視頻文章70視頻文章80視頻文章90視頻文章100視頻文章120視頻文章140 視頻2關(guān)鍵字專題關(guān)鍵字專題tag2tag3文章專題文章專題2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章專題3
問答文章1 問答文章501 問答文章1001 問答文章1501 問答文章2001 問答文章2501 問答文章3001 問答文章3501 問答文章4001 問答文章4501 問答文章5001 問答文章5501 問答文章6001 問答文章6501 問答文章7001 問答文章7501 問答文章8001 問答文章8501 問答文章9001 問答文章9501
當(dāng)前位置: 首頁 - 科技 - 知識(shí)百科 - 正文

Elasticsearch.Net使用教程 MVC4圖書管理系統(tǒng)(2)

來源:懂視網(wǎng) 責(zé)編:小OO 時(shí)間:2020-11-27 22:36:18
文檔

Elasticsearch.Net使用教程 MVC4圖書管理系統(tǒng)(2)

本文實(shí)例為大家分享了MVC4圖書管理系統(tǒng)的制作教程,供大家參考,具體內(nèi)容如下:首先項(xiàng)目結(jié)構(gòu)圖。Model層的相關(guān)代碼如下:Book.cs代碼如下:public class Book{[Key][DatabaseGenerated(DatabaseGeneratedOption.Identity)]public Guid Id { get;set;} [MaxLength(500)] [Display(Name = "標(biāo)題")]public string Title { get;set;} [MaxLength(5000)][Display(Name = "前言")]public string Foreword { get;set;set;set;}}。
推薦度:
導(dǎo)讀本文實(shí)例為大家分享了MVC4圖書管理系統(tǒng)的制作教程,供大家參考,具體內(nèi)容如下:首先項(xiàng)目結(jié)構(gòu)圖。Model層的相關(guān)代碼如下:Book.cs代碼如下:public class Book{[Key][DatabaseGenerated(DatabaseGeneratedOption.Identity)]public Guid Id { get;set;} [MaxLength(500)] [Display(Name = "標(biāo)題")]public string Title { get;set;} [MaxLength(5000)][Display(Name = "前言")]public string Foreword { get;set;set;set;}}。

本文實(shí)例為大家分享了MVC4圖書管理系統(tǒng)的制作教程,供大家參考,具體內(nèi)容如下

首先項(xiàng)目結(jié)構(gòu)圖:

Model層的相關(guān)代碼如下:
Book.cs代碼如下:

public class Book 
 { 
 [Key] 
 [DatabaseGenerated(DatabaseGeneratedOption.Identity)] 
 public Guid Id { get; set; } 
 
 [MaxLength(500)] 
 
 [Display(Name = "標(biāo)題")] 
 public string Title { get; set; } 
 
 [MaxLength(5000)] 
 [Display(Name = "前言")] 
 public string Foreword { get; set; } 
 
 [Display(Name = "總頁數(shù)")] 
 public int Pages { get; set; } 
 
 [Display(Name = "作者")] 
 public string Author { get; set; } 
 } 
public class AppContext:DbContext 
 { 
 public AppContext() 
 { 
 
 } 
 public DbSet<Book> Books { get; set; } 
 } 

ViewModels的相關(guān):

public class SearchViewModel 
 { 
 public string Query { get; set; } 
 
 public IEnumerable<IHit<Book>> Results { get; set; } 
 
 public IDictionary<string, Suggest[]> Suggestions { get; set; } 
 
 public long Elapsed { get; set; } 
 
 } 

接下來就HomeController.cs和BooksController.cs的代碼:

public class HomeController : Controller 
 { 
 private SearchService _searchService; 
 public HomeController() 
 { 
 _searchService = new SearchService(); 
 } 
 public ActionResult Index() 
 { 
 
 return View(); 
 } 
 
 public ActionResult Search(string query, int page = 0, int pageSize = 10) 
 { 
 
 var result = _searchService.Find(query, page, pageSize); 
 var suggestion = _searchService.FindPhraseSuggestion(query, 0, 3); 
 
 var viewModel = new SearchViewModel { Query = query, Results = result.Item1,Elapsed = result.Item2, Suggestions = suggestion }; 
 
 
 return View("Index", viewModel); 
 } 
 
 } 
public class BooksController : Controller 
 { 
 private AppContext db = new AppContext(); 
 
 public ActionResult Index() 
 { 
 return View(db.Books.ToList()); 
 } 
 
 public ActionResult Details(Guid? id) 
 { 
 if (id == null) 
 { 
 return new HttpStatusCodeResult(HttpStatusCode.BadRequest); 
 } 
 Book book = db.Books.Find(id); 
 if (book == null) 
 { 
 return HttpNotFound(); 
 } 
 return View(book); 
 } 
 
 public ActionResult Create() 
 { 
 return View(); 
 } 
 
 
 [HttpPost] 
 [ValidateAntiForgeryToken] 
 public ActionResult Create([Bind(Include="Id,Title,Foreword,Pages,Author")] Book book) 
 { 
 if (ModelState.IsValid) 
 { 
 book.Id = Guid.NewGuid(); 
 db.Books.Add(book); 
 db.SaveChanges(); 
 
 //添加書 
 Elasticsearch.Elasticsearch.Client.Index<Book>(book); 
 
 
 
 return RedirectToAction("Index"); 
 } 
 
 return View(book); 
 } 
 
 public ActionResult Edit(Guid? id) 
 { 
 if (id == null) 
 { 
 return new HttpStatusCodeResult(HttpStatusCode.BadRequest); 
 } 
 Book book = db.Books.Find(id); 
 if (book == null) 
 { 
 return HttpNotFound(); 
 } 
 return View(book); 
 } 
 
 
 [HttpPost] 
 [ValidateAntiForgeryToken] 
 public ActionResult Edit([Bind(Include="Id,Title,Foreword,Pages,Author")] Book book) 
 { 
 if (ModelState.IsValid) 
 { 
 db.Entry(book).State = EntityState.Modified; 
 db.SaveChanges(); 
 return RedirectToAction("Index"); 
 } 
 return View(book); 
 } 
 
 public ActionResult Delete(Guid? id) 
 { 
 if (id == null) 
 { 
 return new HttpStatusCodeResult(HttpStatusCode.BadRequest); 
 } 
 Book book = db.Books.Find(id); 
 if (book == null) 
 { 
 return HttpNotFound(); 
 } 
 return View(book); 
 } 
 
 [HttpPost, ActionName("Delete")] 
 [ValidateAntiForgeryToken] 
 public ActionResult DeleteConfirmed(Guid id) 
 { 
 Book book = db.Books.Find(id); 
 db.Books.Remove(book); 
 db.SaveChanges(); 
 return RedirectToAction("Index"); 
 } 
 
 public JsonResult Reindex() 
 { 
 foreach (var book in db.Books) 
 { 
 //Indexing book 
 Elasticsearch.Elasticsearch.Client.Index<Book>(book); 
 } 
 return Json("OK",JsonRequestBehavior.AllowGet); 
 } 
 
 protected override void Dispose(bool disposing) 
 { 
 if (disposing) 
 { 
 db.Dispose(); 
 } 
 base.Dispose(disposing); 
 } 
 } 

Elasticsearch輔助類:
首先是Elasticsearch.cs

public class Elasticsearch 
 { 
 private static ElasticClient _client; 
 public static ElasticClient Client 
 { 
 get 
 { 
 if (_client == null) 
 { 
 //連接配置 
 var setting = new ConnectionSettings(ElasticsearchConfiguration.Connection,ElasticsearchConfiguration.DefaultIndex); 
 _client = new ElasticClient(setting); 
 } 
 return _client; 
 } 
 
 } 
 } 

ElasticsearchConfiguration.cs類

public static class ElasticsearchConfiguration 
 { 
 public static string Host { get { return "http://localhost"; } } 
 
 public static long Port { get { return 9200; } } 
 
 public static Uri Connection 
 { 
 get { return new Uri(string.Format("{0}:{1}", Host, Port)); } 
 } 
 
 public static string DefaultIndex 
 { 
 get { return "library"; } 
 } 
 } 

SearchService.cs代碼:

public class SearchService 
 { 
 public double MinScore { get {return 0.0005; }} 
 
 //高亮標(biāo)記前綴 
 public string PreHighlightTag 
 { 
 get { return @"<strong>"; } 
 } 
 
 //高亮標(biāo)記后綴 
 public string PostHighlightTag 
 { 
 get { return @"</strong>"; } 
 } 
 
 
 public Tuple< IEnumerable<IHit<Book>>,long> Find(string query, int page = 0, int pageSize = 10) 
 { 
 var result = Elasticsearch.Elasticsearch.Client.Search<Book>(s => s 
 .From(page * pageSize) 
 .Size(pageSize) 
 .MinScore(MinScore) 
 .Highlight(h => h 
 .PreTags(PreHighlightTag) 
 .PostTags(PostHighlightTag) 
 .OnFields( 
 f => f.OnField(b => b.Foreword), 
 f => f.OnField(b => b.Title) 
 )) 
 .Query(q => q.QueryString(qs => qs.Query(query).UseDisMax()))); 
 
 return new Tuple<IEnumerable<IHit<Book>>, long>(result.Hits,result.ElapsedMilliseconds); 
 } 
 
 //查找短語建議 
 public IDictionary<string, Suggest[]> FindPhraseSuggestion(string phrase, int page = 0, int pageSize = 5) 
 { 
 var result = Elasticsearch.Elasticsearch.Client.Search<Book>(s => s 
 .From(page*pageSize) 
 .Size(pageSize) 
 .SuggestPhrase("did-you-mean", ps => ps 
 .Text(phrase) 
 .OnField(f => f.Foreword)) 
 .Query(q => q.MatchAll())); 
 
 return result.Suggest; 
 } 
 
 
 public IEnumerable<IHit<Book>> FindAll() 
 { 
 var result = Elasticsearch.Elasticsearch.Client.Search<Book>(s => s.AllIndices()); 
 return result.Hits; 
 } 
 
 } 

Views視圖
Books文件夾下:
Index.cshtml:

@model IEnumerable<Library.Web.Models.Book> 
 
@{ 
 ViewBag.Title = "Index"; 
 Layout = "~/Views/Shared/_Layout.cshtml"; 
} 
 
<h2>Index</h2> 
 
<p> 
 @Html.ActionLink("創(chuàng)建新書", "Create") 
</p> 
<table class="table"> 
 <tr> 
 <th> 
 @Html.DisplayNameFor(model => model.Title) 
 </th> 
 <th> 
 @Html.DisplayNameFor(model => model.Foreword) 
 </th> 
 <th> 
 @Html.DisplayNameFor(model => model.Pages) 
 </th> 
 <th> 
 @Html.DisplayNameFor(model => model.Author) 
 </th> 
 <th></th> 
 </tr> 
 
@foreach (var item in Model) { 
 <tr> 
 <td> 
 @Html.DisplayFor(modelItem => item.Title) 
 </td> 
 <td> 
 @Html.DisplayFor(modelItem => item.Foreword) 
 </td> 
 <td> 
 @Html.DisplayFor(modelItem => item.Pages) 
 </td> 
 <td> 
 @Html.DisplayFor(modelItem => item.Author) 
 </td> 
 <td> 
 @Html.ActionLink("編輯", "Edit", new { id=item.Id }) | 
 @Html.ActionLink("詳細(xì)", "Details", new { id=item.Id }) | 
 @Html.ActionLink("刪除", "Delete", new { id=item.Id }) 
 </td> 
 </tr> 
} 
 
</table> 

Edit.cshtml:

@model Library.Web.Models.Book 
 
@{ 
 ViewBag.Title = "Edit"; 
 Layout = "~/Views/Shared/_Layout.cshtml"; 
} 
 
<h2>Edit</h2> 
 
 
@using (Html.BeginForm()) 
{ 
 @Html.AntiForgeryToken() 
 
 <div class="form-horizontal"> 
 <h4>Book</h4> 
 <hr /> 
 @Html.ValidationSummary(true) 
 @Html.HiddenFor(model => model.Id) 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Title, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.EditorFor(model => model.Title) 
 @Html.ValidationMessageFor(model => model.Title) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Foreword, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.TextAreaFor(model => model.Foreword) 
 @Html.ValidationMessageFor(model => model.Foreword) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Pages, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.EditorFor(model => model.Pages) 
 @Html.ValidationMessageFor(model => model.Pages) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Author, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.EditorFor(model => model.Author) 
 @Html.ValidationMessageFor(model => model.Author) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 <div class="col-md-offset-2 col-md-10"> 
 <input type="submit" value="Save" class="btn btn-default" /> 
 </div> 
 </div> 
 </div> 
} 
 
<div> 
 @Html.ActionLink("返回列表", "Index") 
</div> 
 
@section Scripts { 
 @Scripts.Render("~/bundles/jqueryval") 
} 

Details.cshtml:

@model Library.Web.Models.Book 
 
@{ 
 ViewBag.Title = "Details"; 
 Layout = "~/Views/Shared/_Layout.cshtml"; 
} 
 
<h2>Details</h2> 
 
<div> 
 <h4>Book</h4> 
 <hr /> 
 <dl class="dl-horizontal"> 
 <dt> 
 @Html.DisplayNameFor(model => model.Title) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Title) 
 </dd> 
 
 <dt> 
 @Html.DisplayNameFor(model => model.Foreword) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Foreword) 
 </dd> 
 
 <dt> 
 @Html.DisplayNameFor(model => model.Pages) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Pages) 
 </dd> 
 
 <dt> 
 @Html.DisplayNameFor(model => model.Author) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Author) 
 </dd> 
 
 </dl> 
</div> 
<p> 
 @Html.ActionLink("編輯", "Edit", new { id = Model.Id }) | 
 @Html.ActionLink("返回列表", "Index") 
</p> 

Delete.cshtml:

@model Library.Web.Models.Book 
 
@{ 
 ViewBag.Title = "Delete"; 
 Layout = "~/Views/Shared/_Layout.cshtml"; 
} 
 
<h2>Delete</h2> 
 
<h3>Are you sure you want to delete this?</h3> 
<div> 
 <h4>Book</h4> 
 <hr /> 
 <dl class="dl-horizontal"> 
 <dt> 
 @Html.DisplayNameFor(model => model.Title) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Title) 
 </dd> 
 
 <dt> 
 @Html.DisplayNameFor(model => model.Foreword) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Foreword) 
 </dd> 
 
 <dt> 
 @Html.DisplayNameFor(model => model.Pages) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Pages) 
 </dd> 
 
 <dt> 
 @Html.DisplayNameFor(model => model.Author) 
 </dt> 
 
 <dd> 
 @Html.DisplayFor(model => model.Author) 
 </dd> 
 
 </dl> 
 
 @using (Html.BeginForm()) { 
 @Html.AntiForgeryToken() 
 
 <div class="form-actions no-color"> 
 <input type="submit" value="Delete" class="btn btn-default" /> | 
 @Html.ActionLink("返回列表", "Index") 
 </div> 
 } 
</div> 

Create.cshtml:

@model Library.Web.Models.Book 
 
@{ 
 ViewBag.Title = "Create"; 
 Layout = "~/Views/Shared/_Layout.cshtml"; 
} 
 
<h2>創(chuàng)建</h2> 
 
 
@using (Html.BeginForm()) 
{ 
 @Html.AntiForgeryToken() 
 
 <div class="form-horizontal"> 
 <h4>Book</h4> 
 <hr /> 
 @Html.ValidationSummary(true) 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Title, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.EditorFor(model => model.Title) 
 @Html.ValidationMessageFor(model => model.Title) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Foreword, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.TextAreaFor(model => model.Foreword) 
 @Html.ValidationMessageFor(model => model.Foreword) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Pages, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.EditorFor(model => model.Pages) 
 @Html.ValidationMessageFor(model => model.Pages) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 @Html.LabelFor(model => model.Author, new { @class = "control-label col-md-2" }) 
 <div class="col-md-10"> 
 @Html.EditorFor(model => model.Author) 
 @Html.ValidationMessageFor(model => model.Author) 
 </div> 
 </div> 
 
 <div class="form-group"> 
 <div class="col-md-offset-2 col-md-10"> 
 <input type="submit" value="創(chuàng)建" class="btn btn-default" /> 
 </div> 
 </div> 
 </div> 
} 
 
<div> 
 @Html.ActionLink("回到列表", "Index") 
</div> 
 
@section Scripts { 
 @Scripts.Render("~/bundles/jqueryval") 
} 

Home->Index.cshtml

@model Library.Web.ViewModels.SearchViewModel 
@{ 
 ViewBag.Title = "Elasticsearch"; 
} 
 
<div class="jumbotron"> 
 <h1>Elasticsearch入門</h1> 
 <p class="lead">安裝和配置群集</p> 
 <ol> 
 <li> 
 <a href="http://www.oracle.com/technetwork/java/ 
javase/downloads/index.html">安裝Java</a> 
 </li> 
 <li> 
 <a href="http://www.elasticsearch.org/ 
download/">安裝Elasticsearch</a> 
 </li> 
 <li>運(yùn)行Elasticsearch</li> 
 <li><a href="/Books/Create">增加一些書籍</a></li> 
 </ol> 
</div> 
 
 
@if (Model == null) 
{ 
 return; 
} 
<div style="margin-top: 30px;"> 
 @if (Model.Suggestions.Any(x => x.Key == "did-you-mean")) 
 { 
 <span>你的意思是: </span> 
 foreach (var suggestions in Model.Suggestions["did-you-mean"]) 
 { 
 var count = 0; 
 foreach (var suggestion in suggestions.Options) 
 { 
 <a href="/Home/Search?query=@suggestion.Text"><strong>@suggestion.Text </strong> </a> 
 count++; 
 } 
 if (count == 0) 
 { 
 <span class="alert-danger">沒有建議!</span> 
 } 
 
 } 
 } 
</div> 
 
<h3><strong>Results for:</strong> @Model.Query</h3> 
 
@if (Model != null) 
{ 
 <table class="table table-condensed"> 
 <thead> 
 <tr><th>文檔的分?jǐn)?shù)(排名相關(guān)度)</th><th>Title</th><th>Content</th><th>Author</th></tr> 
 </thead> 
 
 <tbody> 
 @foreach (var result in Model.Results) 
 { 
 <tr> 
 <td>@result.Score</td> 
 <td> 
 <a href="/Books/Details/@result.Id"> 
 @if (result.Highlights != null && result.Highlights.Any(x => x.Key == "title")) 
 { 
 var hl = result.Highlights.FirstOrDefault(x => x.Key == "title"); 
 foreach (var h in hl.Value.Highlights) 
 { 
 WriteLiteral(h); 
 } 
 } 
 else 
 { 
 WriteLiteral(result.Source.Title); 
 } 
 </a> 
 </td> 
 
 <td> 
 @if (result.Highlights != null && result.Highlights.Any(x => x.Key == "foreword")) 
 { 
 var hl = result.Highlights.FirstOrDefault(x => x.Key == "foreword"); 
 foreach (var h in hl.Value.Highlights) 
 { 
 WriteLiteral(h + "..."); 
 } 
 } 
 
 </td> 
 
 <td>@result.Source.Author</td> 
 </tr> 
 
 } 
 @if (!Model.Results.Any()) 
 { 
 <tr> 
 <td colspan="4" class="alert alert-danger" style="text-align:center;">沒有結(jié)果發(fā)現(xiàn):(</td> 
 </tr> 
 } 
 </tbody> 
 
 </table> 
 <h4><span class="label label-default">@Model.Results.Count()</span>搜索結(jié)果用了 @Model.Elapsed 毫秒</h4> 
} 

_Layout.cshtml

<!DOCTYPE html> 
<html> 
<head> 
 <meta charset="utf-8" /> 
 <meta name="viewport" content="width=device-width, initial-scale=1.0"> 
 <title>@ViewBag.Title</title> 
 @Styles.Render("~/Content/css") 
 @Scripts.Render("~/bundles/modernizr") 
 
</head> 
<body> 
 <div class="navbar navbar-inverse navbar-fixed-top"> 
 <div class="container"> 
 <div class="navbar-header"> 
 <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse"> 
 <span class="icon-bar"></span> 
 <span class="icon-bar"></span> 
 <span class="icon-bar"></span> 
 </button> 
 @Html.ActionLink("Elasticsearch MVC示例", "Index", "Home", null, new { @class = "navbar-brand" }) 
 </div> 
 <div class="navbar-collapse collapse"> 
 <ul class="nav navbar-nav"> 
 <li>@Html.ActionLink("Home", "Index", "Home")</li> 
 <li>@Html.ActionLink("Books", "Index", "Books")</li> 
 </ul> 
 
 
 @using (Html.BeginForm("Search", "Home", FormMethod.Get,new {@class = "navbar-form navbar-left"})) 
 { 
 <div class="form-group"> 
 <input class="form-control" type="text" placeholder="搜索" name="query" /> 
 </div> 
 <button type="submit" class="btn btn-default">提交</button> 
 } 
 
 
 
 </div> 
 
 </div> 
 </div> 
 <div class="container body-content"> 
 @RenderBody() 
 <hr /> 
 <footer> 
 <p>© @DateTime.Now.Year - Elasticsearch, Nest, ASP.NET 應(yīng)用</p> 
 </footer> 
 </div> 
 
 @Scripts.Render("~/bundles/jquery") 
 @Scripts.Render("~/bundles/bootstrap") 
 @RenderSection("scripts", required: false) 
</body> 
</html> 

結(jié)果如圖:


列表頁


創(chuàng)建頁:


搜索結(jié)果頁:


聲明:本網(wǎng)頁內(nèi)容旨在傳播知識(shí),若有侵權(quán)等問題請(qǐng)及時(shí)與本網(wǎng)聯(lián)系,我們將在第一時(shí)間刪除處理。TEL:177 7030 7066 E-MAIL:11247931@qq.com

文檔

Elasticsearch.Net使用教程 MVC4圖書管理系統(tǒng)(2)

本文實(shí)例為大家分享了MVC4圖書管理系統(tǒng)的制作教程,供大家參考,具體內(nèi)容如下:首先項(xiàng)目結(jié)構(gòu)圖。Model層的相關(guān)代碼如下:Book.cs代碼如下:public class Book{[Key][DatabaseGenerated(DatabaseGeneratedOption.Identity)]public Guid Id { get;set;} [MaxLength(500)] [Display(Name = "標(biāo)題")]public string Title { get;set;} [MaxLength(5000)][Display(Name = "前言")]public string Foreword { get;set;set;set;}}。
推薦度:
標(biāo)簽: 教程 管理系統(tǒng) (2)
  • 熱門焦點(diǎn)

最新推薦

猜你喜歡

熱門推薦

專題
Top