View.cshtml 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  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. Basisverzeichnis:<br/>
  52. <i>@Model.BaseDirectory</i>
  53. <div style="width: 90%; margin: 0 5%; text-align: center">
  54. <h3 style="color: #009688">
  55. Aktuelle Programmpaketversion
  56. </h3>
  57. <div style="font-size: 40px; margin: 12px 0">
  58. v<span>@GreenTree.Nachtragsmanagement.Core.AppendixVersion.CurrentVersion</span>
  59. </div>
  60. @if (userContext.CurrentUser.HasFunction("Administration-AppInfo-Update"))
  61. {
  62. Html.DevExpress().Button(t =>
  63. {
  64. t.Name = "devButtonUpdate";
  65. t.Text = "Auf Update prüfen";
  66. t.ClientSideEvents.Click = "function (s, e) { checkUpdate(); }";
  67. }).GetHtml();
  68. }
  69. @if (Model.IsUpdate)
  70. {
  71. <div style="margin-top: 12px; color: green; font-size: 28px">
  72. Update erfolgreich!
  73. </div>
  74. }
  75. </div>
  76. </td>
  77. </tr>
  78. </tbody>
  79. </table>
  80. @Html.DevExpress().LoadingPanel(t =>
  81. {
  82. t.Name = "devLoadingPanelUpdate";
  83. t.Text = "Es wird nach Updates geprüft... bitte warten!";
  84. t.Modal = true;
  85. t.Styles.LoadingDiv.Opacity = 0;
  86. }).GetHtml()