Changeset 72b1da2 for PostgreSqlDotnetCore/Views
- Timestamp:
- 08/23/24 03:03:32 (3 months ago)
- Branches:
- main
- Children:
- 118e414
- Parents:
- 57fc402
- Location:
- PostgreSqlDotnetCore/Views
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
PostgreSqlDotnetCore/Views/Blog/Edit.cshtml
r57fc402 r72b1da2 41 41 </div> 42 42 </div> 43 <div class="form-group">43 @*<div class="form-group"> 44 44 @Html.LabelFor(model => model.users_id, htmlAttributes: new { @class = "control-label col-md-2" }) 45 45 <div class="col-md-10"> … … 48 48 </div> 49 49 </div> 50 50 *@ 51 51 <div class="form-group"> 52 52 <div class="col-md-offset-2 col-md-10"> -
PostgreSqlDotnetCore/Views/Blog/Index.cshtml
r57fc402 r72b1da2 45 45 </th> 46 46 47 47 @*<td> 48 48 @Html.ActionLink("Edit", "Edit", new { id = item.id }) | 49 49 @Html.ActionLink("Answers", "Details", new { id = item.id }) | 50 50 @Html.ActionLink("Delete", "Delete", new { id = item.id }) 51 51 </td> 52 *@ 53 54 55 56 57 @if (item.users_id == ViewBag.CurrentUserId) 58 { 59 <td> 60 @Html.ActionLink("Edit", "Edit", new { id = item.id }) 61 @Html.ActionLink("Delete", "Delete", new { id = item.id }) 62 63 </td> 64 } 65 66 67 68 @if (item.users_id == ViewBag.CurrentUserId || item.users_id != ViewBag.CurrentUserId) 69 { 70 <td> 71 72 @Html.ActionLink("Answers", "Details", new { id = item.id }) 73 74 75 </td> 76 } 77 78 79 80 81 82 52 83 </tr> 53 84 } -
PostgreSqlDotnetCore/Views/Products/Index.cshtml
r57fc402 r72b1da2 98 98 <div class="col-md-6 col-xs-6"> 99 99 <h3>@item.name</h3> 100 @if (SignInManager.IsSignedIn(User)) 100 @if (SignInManager.IsSignedIn(User) && ViewBag.hasAccess != null) 101 // SignInManager.IsSignedIn(User) && ViewBag.hasAccess != null 102 //SignInManager.IsSignedIn(User) && ViewBag.hasAccess != null && ViewBag.hasAccess == true 103 104 101 105 { 102 106 <div class="edit-crud-products"> … … 107 111 } 108 112 </div> 113 114 109 115 <div class="col-md-6 col-xs-6 price"> 110 116 <h3> -
PostgreSqlDotnetCore/Views/VetCenter/Index.cshtml
r57fc402 r72b1da2 85 85 </td> 86 86 87 @if (SignInManager.IsSignedIn(User)) 87 88 89 @* @if ((SignInManager.IsSignedIn(User))) 88 90 { 89 91 <td> … … 95 97 </td> 96 98 } 99 *@ 100 101 @* Додадете условие за проверка на улогите *@ 102 @if (SignInManager.IsSignedIn(User) && (ViewBag.hasAccess != null && ViewBag.hasAccess == true)) 103 { 104 <td> 105 @Html.ActionLink("Edit", "Edit", new { id = item.id }) | 106 @Html.ActionLink("Details", "Details", new { id = item.id }) | 107 @Html.ActionLink("Delete", "Delete", new { id = item.id }) 108 </td> 109 } 97 110 98 111 </tr>
Note:
See TracChangeset
for help on using the changeset viewer.