purchase.html 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>Aisky-Sixth</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
  7. <!-- 新 Bootstrap4 核心 CSS 文件 -->
  8. <link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/4.1.0/css/bootstrap.min.css">
  9. <!-- jQuery文件。务必在bootstrap.min.js 之前引入 -->
  10. <script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
  11. <!-- popper.min.js 用于弹窗、提示、下拉菜单 -->
  12. <script src="https://cdn.bootcss.com/popper.js/1.12.5/umd/popper.min.js"></script>
  13. <!-- 最新的 Bootstrap4 核心 JavaScript 文件 -->
  14. <script src="https://cdn.bootcss.com/bootstrap/4.1.0/js/bootstrap.min.js"></script>
  15. <!--可用來建立使用者小圖示-->
  16. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
  17. <script>
  18. function Monitor(){
  19. window.location.href='/monitor';
  20. };
  21. $(function(){
  22. var purchase_form = document.getElementById('purchase_form');
  23. var outside = document.getElementById('outside');
  24. var inside = document.getElementById('inside');
  25. var net_4g = document.getElementById('4g');
  26. var wifi = document.getElementById('wifi');
  27. var ethernet = document.getElementById('ethernet');
  28. purchase_form.onsubmit = function(){
  29. if($("input[name=length]").val() == '' || $("input[name=width]").val() == '' || $("input[name=monitor_num]").val() == '' || (outside.checked == false && inside.checked == false) || (net_4g.checked == false && wifi.checked == false && ethernet.checked == false)){
  30. alert("請輸入您的完整資訊,謝謝!");
  31. return false;
  32. }else{
  33. return true;
  34. };
  35. };
  36. });
  37. </script>
  38. <style>
  39. body {
  40. margin:0;
  41. }
  42. .navbar-dark .navbar-nav .nav-link {
  43. color: white;
  44. cursor: pointer;
  45. text-decoration:none;
  46. width: 110px;
  47. height: 46px;
  48. }
  49. .nav-top {
  50. line-height:40px;
  51. background-color: #C4C4C4;
  52. }
  53. .website_title{
  54. font-family: Roboto;
  55. font-style: normal;
  56. font-weight: normal;
  57. font-size: 30px;
  58. color: #000000;
  59. }
  60. .navbar-nav > li{
  61. float: none;
  62. display: inline-block;
  63. width: 110px;
  64. margin: 0 auto;
  65. text-align: center;
  66. }
  67. .navbar-nav > li a{
  68. font-size: 20px;
  69. }
  70. .main-page {
  71. margin-top: 200px;
  72. }
  73. .page-title {
  74. font-family: Roboto;
  75. font-style: normal;
  76. font-weight: bold;
  77. font-size: 36px;
  78. }
  79. .flex {
  80. display: flex;
  81. flex-direction: row;
  82. flex-wrap: wrap;
  83. justify-content: center;
  84. }
  85. .set-link {
  86. display: inline-block;
  87. width: 350px;
  88. height: 100px;
  89. line-height: 100px;
  90. background: #008CBA;
  91. border: 1px solid #CFCFCF;
  92. box-sizing: border-box;
  93. color: #FFFFFF;
  94. border-radius: 10px;
  95. font-size: 36px;
  96. }
  97. .page-bottom {
  98. margin-top: 70px;
  99. }
  100. .form-control {
  101. background: #008CBA;
  102. border: 1px solid #CFCFCF;
  103. box-sizing: border-box;
  104. border-radius: 5px;
  105. width: 120px;
  106. height: 58px;
  107. text-align: center;
  108. line-height: 50px;
  109. font-size:20px;
  110. color: #FFFFFF;
  111. display: inline-block;
  112. }
  113. .fa{
  114. display: inline-block;
  115. font: normal normal normal 14px/1 FontAwesome;
  116. font-size: inherit;
  117. text-rendering: auto;
  118. -webkit-font-smoothing: antialiased;
  119. }
  120. .fa-user-o:before{
  121. content: "\f2c0";
  122. }
  123. @media(max-width:373px){
  124. .card {
  125. margin-right: 0px;
  126. }
  127. }
  128. @media(max-width:577px){
  129. }
  130. @media(min-width:576px){
  131. }
  132. @media(min-width:768px){
  133. .navbar-nav > li {
  134. margin-left: 0px;
  135. }
  136. .navbar-nav .li-block {
  137. display:none;
  138. }
  139. }
  140. @media(min-width:991px){
  141. .navbar-nav > li {
  142. margin-left: 20px;
  143. }
  144. .navbar-nav .li-block {
  145. display:none;
  146. }
  147. .page-bottom input:last-child {
  148. margin-left: 100px;
  149. }
  150. }
  151. @media(min-width:1200px){
  152. .navbar-nav > li {
  153. margin-left: 35px;
  154. }
  155. .navbar-nav .li-block {
  156. display: inline-block;
  157. width: 100px;
  158. }
  159. .page-bottom input:last-child {
  160. margin-left: 100px;
  161. }
  162. }
  163. @media(min-width:1400px){
  164. .navbar-nav .li-block {
  165. display: inline-block;
  166. width: 200px;
  167. }
  168. .page-bottom input:last-child {
  169. margin-left: 100px;
  170. }
  171. }
  172. @media(min-width:1689px) {
  173. .navbar-nav > li {
  174. margin-left: 50px;
  175. }
  176. .navbar-nav .li-block {
  177. display: inline-block;
  178. width: 500px;
  179. }
  180. .page-bottom input:last-child {
  181. margin-left: 100px;
  182. }
  183. }
  184. </style>
  185. <body>
  186. <nav class="fixed-top">
  187. <nav class="navbar navbar-expand-md nav-top justify-content-center">
  188. <div>
  189. <span class="website_title">採購</span>
  190. </div>
  191. </nav>
  192. <nav class="navbar navbar-expand-md bg-dark navbar-dark nav-bottom">
  193. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#collapsibleNavbar">
  194. <span class="navbar-toggler-icon"></span>
  195. </button>
  196. <div class="collapse navbar-collapse" id="collapsibleNavbar">
  197. <ul class="navbar-nav">
  198. <li class="nav-item">
  199. <a class="nav-link" href="/">首頁</a>
  200. </li>
  201. <li class="nav-item">
  202. <a class="nav-link" href="#">關於我們</a>
  203. </li>
  204. <li class="nav-item">
  205. <a class="nav-link" href="#">案場資訊</a>
  206. </li>
  207. <li class="nav-item">
  208. <a class="nav-link" href="#">聯絡方法</a>
  209. </li>
  210. <li class="nav-item">
  211. <a class="nav-link" href="#">案場地圖</a>
  212. </li>
  213. <li class="nav-item">
  214. <a class="nav-link" href="#">環境資訊</a>
  215. </li>
  216. <li class="li-block"></li>
  217. <li class="nav-item">
  218. <a class="nav-link" href="#"><i class="fa fa-user-o"></i> {{params.username}}</a>
  219. </li>
  220. <li class="nav-item">
  221. <a class="nav-link" href="/logout">Logout</a>
  222. </li>
  223. </ul>
  224. </div>
  225. </nav>
  226. </nav>
  227. <div class="main-page">
  228. <form method="post" action="/purchase" id="purchase_form">
  229. <div class="container">
  230. <sapn style="color:#008CBA;font-size:22px;">親愛的顧客您好,在您的環境檢測開始之前,請先幫我們填妥下列資料,謝謝!</sapn>
  231. <table class="table table-bordered" style="font-size:23px;margin-top:30px;">
  232. <tbody>
  233. <tr>
  234. <td>1.</td>
  235. <td>您需要的監控面積有多大</td>
  236. <td>
  237. 長&nbsp;&nbsp;<input type="text" placeholder="單位公尺" name="length">
  238. &nbsp;&nbsp;寬&nbsp;&nbsp;<input type="text" placeholder="單位公尺" name="width"></td>
  239. </tr>
  240. <tr>
  241. <td>2.</td>
  242. <td>您監控的地點在露天或室內</td>
  243. <td>
  244. <label for="outside">露天&nbsp;&nbsp;</label><input type="radio" id="outside" name="location" value="outside">
  245. &nbsp;&nbsp;<label for="inside">室內&nbsp;&nbsp;</label><input type="radio" id="inside" name="location" value="inside">
  246. </td>
  247. </tr>
  248. <tr>
  249. <td>3.</td>
  250. <td>您要設置幾個監控點</td>
  251. <td>
  252. 數量&nbsp;&nbsp;<input type="number" maxlength="2" name="monitor_num">
  253. </td>
  254. </tr>
  255. <tr>
  256. <td>4.</td>
  257. <td>您的連接方式為</td>
  258. <td>
  259. <label for="4g">4G&nbsp;&nbsp;</label><input type="radio" id="4g" name="connection" value="4g">
  260. &nbsp;&nbsp;<label for="wifi">WIFI&nbsp;&nbsp;</label><input type="radio" id="wifi" name="connection" value="wifi">
  261. &nbsp;&nbsp;<label for="ethernet">網路線&nbsp;&nbsp;</label><input type="radio" id="ethernet" name="connection" value="ethernet">
  262. </td>
  263. </tr>
  264. </tbody>
  265. </table>
  266. <div class="row page-bottom">
  267. <div class="col"></div>
  268. <div class="col-xl-4 col-lg-6 col-md-8 col-sm-10 col-xs-10" style="text-align:center;">
  269. <div class="form-group">
  270. <input type="reset" class="form-control" value="重設" style="margin-right:70px;">
  271. <input type="submit" class="form-control" value="送出">
  272. <input type="button" class="form-control" value="下一頁" onclick="Monitor();">
  273. </div>
  274. </div>
  275. <div class="col"></div>
  276. </div>
  277. </div>
  278. </form>
  279. </div>
  280. </body>
  281. </html>