Advertisement
Guest User

Untitled

a guest
Jun 15th, 2017
492
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.95 KB | None | 0 0
  1. @model Cmentarz.ViewModels.KwateryViewModel
  2.  
  3. <div class="col-lg-12">
  4. <hr>
  5. <h2 class="intro-text text-center">
  6. <strong>Informacje o grobie</strong>
  7. </h2>
  8. <hr>
  9. <div class="col-lg-4">
  10. <div class="picture1">
  11. <img id="myImg" src="@($"{Url.Content(Model.zdjecie)}?x={DateTime.Now}")" alt="zdjęcie" class="picture4" />
  12. </div>
  13. </div>
  14. <div class="col-lg-8">
  15. <div class="loc">
  16. <div class="coord">
  17. <div class="var">SEKTOR</div>
  18. <div class="val">@Html.DisplayFor(model => model.sektor)</div>
  19. </div>
  20. <div class="coord">
  21. <div class="var">RZĄD</div>
  22. <div class="val">@Html.DisplayFor(model => model.rzad)</div>
  23. </div>
  24. <div class="coord">
  25. <div class="var">KWATERA</div>
  26. <div class="val">@Html.DisplayFor(model => model.pozycja)</div>
  27. </div>
  28. </div>
  29. @if (ViewBag.Admin == false)
  30. {
  31. <label>Opłacony do: </label>
  32. }
  33. @if (ViewBag.Admin == true)
  34. {
  35. <label>Prolongata do: </label>
  36. }
  37.  
  38. @Html.DisplayFor(model => model.prolongata)<br />
  39. @if (ViewBag.Admin == true)
  40. {
  41. <label>Głębinowy:</label> <br />
  42. @Html.DisplayFor(model => model.glebiniowy, new { @transform = "scale(1.5)", @type = "checkbox" })
  43. <br />
  44. }
  45. @if (ViewBag.Admin == true)
  46. {
  47. <label>Uwagi do kwatery: </label><br />
  48. @Html.DisplayFor(model => model.uwagi)
  49. }
  50.  
  51. <br />
  52.  
  53. <br />
  54.  
  55. @if (ViewBag.pusta != true)
  56. {
  57. <label>Osoby pochowane w tym grobie:</label>
  58. <table class="table">
  59. <tr class="header">
  60. <th>Nazwisko</th>
  61. <th>Imię</th>
  62. <th>Data śmierci</th>
  63. </tr>
  64. @foreach (var osoba in Model.Osoba)
  65. {
  66. <tr>
  67. <td class="data">@osoba.nazwisko</td>
  68. <td class="data">@osoba.imie</td>
  69. <td>@osoba.data_smierci</td>
  70. <td>
  71. <td>
  72. @if (ViewBag.Admin == true)
  73. {
  74. <button class="btn btn-default" onclick="location.href='@Url.Action("Edit","Osoba", new {id = osoba.osobaId })';return false;">Edytuj </button>
  75. <button class="btn btn-default" onclick="Confirm.render('Na pewno chcesz usunąć dane o wybranej osobie?', 'delete_post', '@osoba.osobaId')">Usuń</button>
  76. }
  77. </tr>
  78. }
  79. </table><br />
  80. <br /><br />
  81. }
  82. @if (ViewBag.Admin == true)
  83. {
  84. <button class="btn btn-default" onclick="location.href='@Url.Action("Edit","Kwatera", new {id = Model.kwateraId})';return false;">Edytuj dane o kwaterze</button>
  85. <button class="btn btn-default" onclick="location.href='@Url.Action("Create","Osoba", new {id = Model.kwateraId})';return false;">Dodaj osobę do kwatery</button>
  86. }
  87. </div>
  88.  
  89. </div>
  90. <script>
  91. var modal = document.getElementById('FullImg');
  92. var img = document.getElementById('myImg');
  93. var modalImg = document.getElementById("img01");
  94. img.onclick = function () {
  95. if (window.innerWidth > 1200) {
  96. document.getElementById('model').style.display = "none";
  97. modal.style.display = "block";
  98. modalImg.src = this.src;
  99. }
  100.  
  101. }
  102. var span = document.getElementsByClassName("close")[0];
  103. span.onclick = function () {
  104. modal.style.display = "none";
  105. document.getElementById('model').style.display = "block";
  106. }
  107. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement