source: PostgreSqlDotnetCore/Views/Blog/Create.cshtml@ e9bb9d1

main
Last change on this file since e9bb9d1 was 57fc402, checked in by ElenaMoskova <elena.moskova99@…>, 3 months ago

Аsync, access permission, and other fixes.

Regulation of access permissions. Which fields can be accessed by different users.

  • Property mode set to 100644
File size: 2.4 KB
Line 
1@model PostgreSqlDotnetCore.Models.BlogPostConsultation
2
3@{
4 ViewBag.Title = "Create";
5}
6
7<h2>Create</h2>
8
9
10@using (Html.BeginForm())
11{
12 @Html.AntiForgeryToken()
13
14 <div class="form-horizontal">
15 <h4>BlogPostConsultation</h4>
16 <hr />
17 @Html.ValidationSummary(true, "", new { @class = "text-danger" })
18
19 @* <div class="form-group">
20 @Html.LabelFor(model => model.date_askes, htmlAttributes: new { @class = "control-label col-md-2" })
21 <div class="col-md-10">
22 @Html.EditorFor(model => model.date_askes, "{0:d}", new { htmlAttributes = new { @class = "form-control" } })
23 @Html.ValidationMessageFor(model => model.date_askes, "", new { @class = "text-danger" })
24 </div>
25 </div>
26 *@
27 @* <div class="form-group">
28 @Html.LabelFor(model => model.date_askes, htmlAttributes: new { @class = "control-label col-md-2" })
29 <div class="col-md-10">
30 @Html.EditorFor(model => model.date_askes, new { htmlAttributes = new { @class = "form-control", @type = "date", value = DateTime.UtcNow.ToString("yyyy-MM-dd") } })
31 @Html.ValidationMessageFor(model => model.date_askes, "", new { @class = "text-danger" })
32 </div>
33 </div>
34 *@
35
36
37
38
39
40
41 <div class="form-group">
42 @Html.LabelFor(model => model.title, htmlAttributes: new { @class = "control-label col-md-2" })
43 <div class="col-md-10">
44 @Html.EditorFor(model => model.title, new { htmlAttributes = new { @class = "form-control" } })
45 @Html.ValidationMessageFor(model => model.title, "", new { @class = "text-danger" })
46 </div>
47 </div>
48
49 <div class="form-group">
50 @Html.LabelFor(model => model.description, htmlAttributes: new { @class = "control-label col-md-2" })
51 <div class="col-md-10">
52 @Html.EditorFor(model => model.description, new { htmlAttributes = new { @class = "form-control" } })
53 @Html.ValidationMessageFor(model => model.description, "", new { @class = "text-danger" })
54 </div>
55 </div>
56
57
58
59 <div class="form-group">
60 <div class="col-md-offset-2 col-md-10">
61 <br />
62 <input type="submit" value="Published" class="btn btn-dark" />
63 </div>
64 </div>
65 </div>
66}
67
68<div>
69 @Html.ActionLink("Back to List", "Index")
70</div>
71
Note: See TracBrowser for help on using the repository browser.