Ohm-Management - Projektarbeit B-ME
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.html 6.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <!-- NOTE: Meta Tags -->
  5. <meta charset="utf-8">
  6. <meta name="description" content="Ohm management app">
  7. <meta name="keywords" content="">
  8. <meta name="author" content="">
  9. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  10. <!-- <meta http-equiv="refresh" content="30"> -->
  11. <!-- NOTE: iOS - Add to Homescreen -->
  12. <!-- Icon: No transparency allowed -->
  13. <link rel="apple-touch-icon" href="img/ios-icon/th_ohmicon_192x192.png"> <!-- iphone -->
  14. <link rel="apple-touch-icon" sizes="152x152" href="img/ios-icon/th_ohmicon_152x152.png"><!-- ipad -->
  15. <link rel="apple-touch-icon" sizes="180x180" href="img/ios-icon/th_ohmicon_180x180.png"><!-- iphone-retina -->
  16. <link rel="apple-touch-icon" sizes="167x167" href="img/ios-icon/th_ohmicon_167x167.png"><!-- ipad-retina -->
  17. <!-- Splash screen: If not set, will be white screen -->
  18. <meta name="apple-mobile-web-app-capable" content="yes" />
  19. <link rel="apple-touch-startup-image" sizes="2048x2732" href="/ios-splash/apple_splash_2048.png" /><!-- Tablet -->
  20. <link rel="apple-touch-startup-image" sizes="1668x2224"href="/ios-splash/apple_splash_1668.png" /><!-- Tablet -->
  21. <link rel="apple-touch-startup-image" sizes="1536x2048" href="/ios-splash/apple_splash_1536.png" /><!-- Tablet -->
  22. <link rel="apple-touch-startup-image" sizes="1125x2436" href="/ios-splash/apple_splash_1125.png" /><!-- Tablet ? Phone -->
  23. <link rel="apple-touch-startup-image" sizes="1242x2208" href="/ios-splash/apple_splash_1242.png" /><!-- Tablet ? Phone -->
  24. <link rel="apple-touch-startup-image" sizes="750x1334" href="/ios-splash/apple_splash_750.png" /><!-- Phone -->
  25. <link rel="apple-touch-startup-image" sizes="640x1136" href="/ios-splash/apple_splash_640.png" /><!-- Phone -->
  26. <!-- NOTE: CSS -->
  27. <!-- CSS_Material Design for Bootstrap fonts and icons -->
  28. <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700|Material+Icons">
  29. <!-- CSS_Material Design for Bootstrap minified CSS -->
  30. <link rel="stylesheet" href="https://unpkg.com/bootstrap-material-design@4.1.1/dist/css/bootstrap-material-design.min.css" integrity="sha384-wXznGJNEXNG1NFsbm0ugrLFMQPWswR3lds2VeinahP8N0zJw9VWSopbjv2x7WCvX" crossorigin="anonymous">
  31. <!-- CSS_Custom Design -->
  32. <link rel="stylesheet" type="text/css" href="style/style.css">
  33. <!-- NOTE: Call manifest.json -->
  34. <link rel="manifest" href="manifest.json">
  35. <!-- NOTE: VUE.js und VueRouter -->
  36. <script src=lib/jquery-3.3.1.min.js></script>
  37. <script src=lib/vue.js></script>
  38. <script src=lib/vue-router.js></script>
  39. <!-- NOTE: JavaScript Libs & Files -->
  40. <script src="home.js"></script>
  41. <script src="files.js"></script>
  42. <script src="createMessage.js"></script>
  43. <script src="bookmark.js"></script>
  44. <script src="profil.js"></script>
  45. <script src="msgCard.js"></script>
  46. <script src="messageData.js"></script>
  47. <script src="profilCard.js"></script>
  48. <script src="profilData.js"></script>
  49. <title>OMApp</title>
  50. </head>
  51. <body>
  52. <div id="api">
  53. <div class="om-header-container">
  54. <div class="om-header">
  55. <a href="index.html"><img src="img/th_nbg_ohmicon_amp.png" width=55px height=55px></a>
  56. <form class="om-searchbar">
  57. <input type="search" placeholder="Search...">
  58. </form>
  59. </div>
  60. </div>
  61. <div class="om-content">
  62. <div id=xxx></div>
  63. <router-view></router-view>
  64. </div>
  65. <nav class="nav nav-tabs nav-justified om-nav" v-if="$route.path !=='/createMessage' ">
  66. <router-link to="/home" class="nav-item nav-link"><i class="material-icons">home</i></router-link>
  67. <router-link to="/files" class="nav-item nav-link"><i class="material-icons">language</i></router-link>
  68. <router-link to="/createMessage" class="nav-item nav-link outlined"><i class="material-icons">add_circle</i></router-link>
  69. <router-link to="/bookmark" class="nav-item nav-link"><i class="material-icons">bookmark</i></router-link>
  70. <router-link to="/profil" class="nav-item nav-link"><i class="material-icons">person</i></router-link>
  71. </nav>
  72. <!--test to put information into db by ajax-->
  73. <div class="container">
  74. <div class="col-sm-4">
  75. <h3>Ajax Test</h3>
  76. <div>
  77. <form id="messageForm">
  78. <div class="form-group">
  79. <label for="id">Id:</label>
  80. <input type="text" class="form-control" id="id" placeholder="Enter Id"/>
  81. </div>
  82. <div class="form-group">
  83. <label for="message">Message:</label>
  84. <input type="text" class="form-control" id="message" placeholder="Enter Message"/>
  85. </div>
  86. <div id="res">
  87. </div>
  88. <button type="submit" class="btn btn-default" @click.prevent=testform>Submit</button>
  89. </form>
  90. </div>
  91. </div>
  92. </div>
  93. </div>
  94. <script>
  95. const routes = [
  96. { path: "/", component: HomeRouter },
  97. { path: "/home", component: HomeRouter },
  98. { path: "/files", component: FileRouter },
  99. { path: "/createMessage", component: CreateMsgRouter },
  100. { path: "/bookmark", component: BookmarkRouter },
  101. { path: "/profil", component: ProfilRouter },
  102. ];
  103. const router = new VueRouter({
  104. routes
  105. });
  106. var app = new Vue({
  107. router,
  108. el: '#api',
  109. methods: {
  110. testform: function() {
  111. var id=$("#id").val();
  112. var message=$("#message").val();
  113. console.log ("test "+id+" "+message);
  114. $.ajax ({ url: "/api/test/"+id, data: {msg: message}, method: "GET" }) .done (have_result) .fail (have_error);
  115. function have_result (res) {
  116. console.log (res);
  117. $("#res").text (res[0].message);
  118. }
  119. function have_error (err) {
  120. console.log ("error:");
  121. console.log (err);
  122. }
  123. },
  124. },
  125. });
  126. </script>
  127. <!-- CDN_Vue.js minified lib -->
  128. <!-- <script src="https://cdn.jsdelivr.net/npm/vue@2.5.17/dist/vue.min.js"></script> -->
  129. <!-- CDN_jQuery minified lib -->
  130. <!--<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" crossorigin="anonymous"></script>-->
  131. <!-- CDN_Popper.js lib -->
  132. <script src="https://unpkg.com/popper.js@1.12.6/dist/umd/popper.js" integrity="sha384-fA23ZRQ3G/J53mElWqVJEGJzU0sTs+SvzG8fXVWP+kJQ1lwFAOkcUOysnlKJC33U" crossorigin="anonymous"></script>
  133. <!-- CDN_Bootstrap JS lib -->
  134. <script src="https://unpkg.com/bootstrap-material-design@4.1.1/dist/js/bootstrap-material-design.js" integrity="sha384-CauSuKpEqAFajSpkdjv3z9t8E7RlpJ1UP0lKM/+NdtSarroVKu069AlsRPKkFBz9" crossorigin="anonymous"></script>
  135. <!-- NOTE: Call main.js -->
  136. <script src="main.js"></script>
  137. </body>
  138. </html>