Advertisement
Guest User

Untitled

a guest
Jan 4th, 2018
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
ASP 1.30 KB | None | 0 0
  1. @model WebApplication2.Models.BookModels
  2. @using WebApplication2.Models
  3. @*@model dynamic*@
  4. @{
  5.     ViewBag.Title = "Details";
  6. }
  7.  
  8. <h2>Details</h2>
  9.  
  10. <div>
  11.     <h4>BookModels</h4>
  12.     <hr />
  13.     <dl class="dl-horizontal">
  14.         <dt>
  15.            
  16.             @Html.DisplayNameFor(model => model.Title)
  17.         </dt>
  18.  
  19.         <dd>
  20.             @Html.DisplayFor(model => model.Title)
  21.         </dd>
  22.         <dt>
  23.             Person
  24.         </dt>
  25.         <dd>
  26.             <select>
  27.                 @{
  28.                     foreach (var perm in ViewBag.persons)
  29.                     {
  30.                         <option value="perm.Id" customAttribute="item.Name">
  31.                             @perm.Name
  32.                         </option>
  33.                     }
  34.                 }
  35.             </select>
  36.         </dd>
  37.         <dt>
  38.             @Html.DisplayNameFor(model => model.Pages)
  39.         </dt>
  40.  
  41.         <dd>
  42.             @Html.DisplayFor(model => model.Pages)
  43.         </dd>
  44.  
  45.         <dt>
  46.             @Html.DisplayNameFor(model => model.Created)
  47.         </dt>
  48.  
  49.         <dd>
  50.             @Html.DisplayFor(model => model.Created)
  51.         </dd>
  52.        
  53.        
  54. </dl>
  55. </div>
  56. <p>
  57.     @Html.ActionLink("Edit", "Edit", new { id = Model.Id }) |
  58.     @Html.ActionLink("Back to List", "Index")
  59. </p>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement