View.cshtml 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. @using GreenTree.Nachtragsmanagement.Web.Models.Global;
  2. @{
  3. Layout = "~/Views/Shared/_FunctionLayout.cshtml";
  4. }
  5. @{
  6. var userContext = GreenTree.Nachtragsmanagement.Core.CommonHelper.UserContext();
  7. }
  8. @model GreenTree.Nachtragsmanagement.Web.Models.Admin.AppInfo.AppInfoDataModel
  9. <script>
  10. function checkUpdate() {
  11. devLoadingPanelUpdate.Show();
  12. $.ajax({
  13. url: '@Url.Action("PartialCheckUpdate", "Admin")',
  14. success: function (response) {
  15. if (!response) return;
  16. setTimeout(function () {
  17. devLoadingPanelUpdate.Hide();
  18. $(".updateContainer").remove();
  19. $("body").append(response);
  20. }, 200);
  21. },
  22. error: function () {
  23. devLoadingPanelUpdate.Hide();
  24. alert("error occured");
  25. }
  26. });
  27. }
  28. </script>
  29. <img src="@Url.Content("~/Content/Images/appInfo.png")" style="width: 90%; margin: 38px 5%" />
  30. <table style="margin: 0 5%; width: 90%">
  31. <tbody>
  32. <tr>
  33. <td style="width: 49%">
  34. <div style="margin-bottom: 6px; vertical-align: top">
  35. <b>Verwendete Bibliotheken</b>
  36. </div>
  37. @Html.DevExpress().ListBox(t =>
  38. {
  39. t.Name = "devListBoxAssemblies";
  40. t.Width = new Unit(100, UnitType.Percentage);
  41. t.Height = new Unit(260, UnitType.Pixel);
  42. t.Properties.Columns.Add("Manufacturer", "Hersteller", new Unit(75, UnitType.Percentage));
  43. t.Properties.Columns.Add("Name", "Bibliothek", new Unit(75, UnitType.Percentage));
  44. t.Properties.Columns.Add("Version", "Version", new Unit(25, UnitType.Percentage));
  45. }).BindList(Model.Assemblies).GetHtml()
  46. </td>
  47. <td style="width: 51%; padding-left: 18px; vertical-align: top">
  48. <div style="padding-bottom: 3px; margin-bottom: 3px; vertical-align: top; border-bottom: 1px solid #009688">
  49. <b>Sonstige Informationen</b>
  50. </div>
  51. <ul>
  52. <li>
  53. Basisverzeichnis: <i>@Model.BaseDirectory</i>
  54. </li>
  55. <li>
  56. ASP.NET Info: <i>v<span>@Model.AspNetVersion</span></i>
  57. </li>
  58. <li>
  59. Betriebssystem: <i>@Model.OperatingSystem (@(Model.Is64BitOs ? "64Bit" : "32Bit"))</i>
  60. </li>
  61. </ul>
  62. <div style="width: 90%; margin: 0 5%; text-align: center">
  63. <h3 style="color: #009688">
  64. Aktuelle Programmpaketversion
  65. </h3>
  66. <div style="font-size: 40px; margin: 12px 0">
  67. v<span>@GreenTree.Nachtragsmanagement.Core.AppendixVersion.CurrentVersion</span>
  68. </div>
  69. @if (userContext.CurrentUser.HasFunction("Administration-AppInfo-Update"))
  70. {
  71. Html.DevExpress().Button(t =>
  72. {
  73. t.Name = "devButtonUpdate";
  74. t.Text = "Auf Update prüfen";
  75. t.ClientSideEvents.Click = "function (s, e) { checkUpdate(); }";
  76. }).GetHtml();
  77. }
  78. @if (Model.IsUpdate)
  79. {
  80. <div style="margin-top: 12px; color: green; font-size: 28px">
  81. Update erfolgreich!
  82. </div>
  83. }
  84. </div>
  85. </td>
  86. </tr>
  87. </tbody>
  88. </table>
  89. @Html.DevExpress().LoadingPanel(t =>
  90. {
  91. t.Name = "devLoadingPanelUpdate";
  92. t.Text = "Es wird nach Updates geprüft... bitte warten!";
  93. t.Modal = true;
  94. t.Styles.LoadingDiv.Opacity = 0;
  95. }).GetHtml()