login2.html 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260
  1. {% load staticfiles %}
  2. <!DOCTYPE html>
  3. <html lang="en">
  4. <head>
  5. <meta charset="UTF-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <meta http-equiv="X-UA-Compatible" content="ie=edge">
  8. <title>登录界面</title>
  9. <link rel="stylesheet" href="{% static '/lib/css/swiper.min.css' %}">
  10. <link rel="stylesheet" href="{% static '/lib/font/fontIcon/iconfont.css' %}">
  11. <link rel="stylesheet" href="{% static '/lib/font-awesome/4.5.0/css/font-awesome.css' %}">
  12. <!-- <link rel="stylesheet" href="{% static '/lib/css/video-js.min.css' %}"> -->
  13. <link rel="stylesheet" href="https://a.amap.com/jsapi_demos/static/demo-center/css/demo-center.css">
  14. <link rel="stylesheet" href="{% static '/lib/css/reset.css' %}">
  15. <link rel="stylesheet" href="{% static '/css/common.css' %}">
  16. <link rel="stylesheet" href="{% static '/css/header.css' %}">
  17. <link rel="stylesheet" href="{% static '/css/login.css' %}">
  18. </head>
  19. <body>
  20. <div class="header">
  21. <div class="headerTop wrapper">
  22. <div class="logoTxt">
  23. <a href="">
  24. <h1>休闲农业旅游网</h1>
  25. <p>www.XXNYLY.CN</p>
  26. </a>
  27. </div>
  28. <div class="LocateCover">
  29. <div class="currCity">
  30. <span>全国</span>
  31. <i class="fa fa-map-marker" aria-hidden="true"></i>
  32. </div>
  33. <div class="selectCityCover">
  34. <ul>
  35. <li>河南</li>
  36. <li>河南</li>
  37. <li>河南</li>
  38. <li>河南</li>
  39. </ul>
  40. </div>
  41. </div>
  42. <div class="searchCover">
  43. <div class="searchBoxBj">
  44. <input type="text" placeholder="请输入农庄名称">
  45. <button>搜索</button>
  46. </div>
  47. </div>
  48. <div class="loginCover">
  49. <a href="login2" target="_blank">登录</a>
  50. <a href="" target="_blank">注册</a>
  51. </div>
  52. </div>
  53. <!-- 登录内容 -->
  54. </div>
  55. <!-- 主体部分 -->
  56. <div class="content">
  57. <!-- 登录框 -->
  58. <div class="loginBj">
  59. <div class="borderline">
  60. <div class="loginBox">
  61. <div class="title">用户登录</div>
  62. <div class="loginInp">
  63. <input type="text" id="username" placeholder="用户名">
  64. </div>
  65. <div class="loginInp">
  66. <input type="password" id="password" placeholder="密码">
  67. <a href="">忘记密码?</a>
  68. </div>
  69. <div class="loginBtnCover">
  70. <button id="loginBtn" onclick="login()">登 录</button>
  71. </div>
  72. <div class="remPswCover">
  73. <div class="remPwdInpBox">
  74. <input type="checkbox" id="remPwdFlag">
  75. <div></div>
  76. </div>
  77. <label for="remPwdFlag">记住密码</label>
  78. </div>
  79. </div>
  80. </div>
  81. </div>
  82. <div class="wrapper">
  83. <!-- 合作伙伴 -->
  84. <div class="partnerCover">
  85. <div class="title">
  86. <i class="fa fa-handshake-o" aria-hidden="true"></i>
  87. <span>合作伙伴 </span>
  88. </div>
  89. <div class="partnerInner">
  90. <ul class="partnerInnerList">
  91. <li class="partnerInnerItem">
  92. <a href="">
  93. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  94. </a>
  95. </li>
  96. <li class="partnerInnerItem">
  97. <a href="">
  98. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  99. </a>
  100. </li>
  101. <li class="partnerInnerItem">
  102. <a href="">
  103. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  104. </a>
  105. </li>
  106. <li class="partnerInnerItem">
  107. <a href="">
  108. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  109. </a>
  110. </li>
  111. <li class="partnerInnerItem">
  112. <a href="">
  113. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  114. </a>
  115. </li>
  116. <li class="partnerInnerItem">
  117. <a href="">
  118. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  119. </a>
  120. </li>
  121. <li class="partnerInnerItem">
  122. <a href="">
  123. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  124. </a>
  125. </li>
  126. <li class="partnerInnerItem">
  127. <a href="">
  128. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  129. </a>
  130. </li>
  131. <li class="partnerInnerItem">
  132. <a href="">
  133. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  134. </a>
  135. </li>
  136. <li class="partnerInnerItem">
  137. <a href="">
  138. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  139. </a>
  140. </li>
  141. <li class="partnerInnerItem">
  142. <a href="">
  143. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  144. </a>
  145. </li>
  146. <li class="partnerInnerItem">
  147. <a href="">
  148. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  149. </a>
  150. </li>
  151. <li class="partnerInnerItem">
  152. <a href="">
  153. <img src="http://www.xbxxnyggw.cn/file/upload/201901/22/230441831.jpg" alt="">
  154. </a>
  155. </li>
  156. <li style="clear: both;"></li>
  157. </ul>
  158. </div>
  159. </div>
  160. </div>
  161. </div>
  162. <!-- 底部版权 -->
  163. <div class="footer bjColor">
  164. <div class="wrapper">
  165. <div class="floatDiv">
  166. <div class="copyrightTxt">
  167. <div>休闲农业旅游网</div>
  168. <div>联系人:李四  联系电话:13811111111</div>
  169. <div>地址:河南省郑州市XXXXXXXXXXXXXXXXXXXXXXXXXX</div>
  170. </div>
  171. <div class="WeChatCode">
  172. <img src="{% static '/imgs/WeChatCode.jpg' %}" alt="">
  173. <p>关注公众号</p>
  174. </div>
  175. </div>
  176. <div class="copyright">
  177. 版权所有XXXXXXXXXXXXXXXXXXXXXX
  178. </div>
  179. </div>
  180. </div>
  181. <!-- 返回顶部 -->
  182. <div id="back2top" class="back2top" style="display: block;">
  183. <a href="javascript:void(0);" onclick="goUp()" title="返回顶部">&nbsp;</a>
  184. </div>
  185. <script src="{% static '/lib/js/jquery-2.1.4.min.js'%}"></script>
  186. <script
  187. src="https://webapi.amap.com/maps?v=1.4.15&key=3939967b919a8003377dd113fc445a3d&plugin=AMap.Driving"></script>
  188. <!-- <script src="{% static '/lib/layui/layui.js'%}"></script> -->
  189. <!-- <script src="{% static '/js/index2.js'%}"></script> -->
  190. <script>
  191. // 登录
  192. function login() {
  193. var username = $("#username").val();
  194. var password = $("#password").val();
  195. if (!username) {
  196. $("#username").focus();
  197. return;
  198. }
  199. if (!password) {
  200. $("#password").focus();
  201. return;
  202. }
  203. // $('.notLogin').toggle();
  204. // $('.isLogin').toggle();
  205. // window.open("back_manage");
  206. $.ajax({
  207. url: 'user_land',
  208. data: {
  209. username: username,
  210. password: password
  211. },
  212. type: 'post',
  213. dataType: 'json',
  214. success: function (data) {
  215. if (data.code == 1) {
  216. // var hrefstr = 'person_farm?name=' + data.username;
  217. window.location = 'home2'
  218. window.open('back_manage')
  219. // $('.isLogin').toggle();
  220. // $('#person_farm').attr('href', hrefstr)
  221. // $('.userPhoto').attr('src', data.user_img)
  222. // $('.notLogin').hide();
  223. // $('.isLogin').show();
  224. } else if (data == 0) {
  225. $('body').append('<div class="hint">用户不存在</div>')
  226. setTimeout(function () {
  227. $('.hint').remove();
  228. }, 1000)
  229. } else if (data == 2) {
  230. $('body').append('<div class="hint">用户名错误</div>')
  231. setTimeout(function () {
  232. $('.hint').remove();
  233. }, 1000)
  234. } else if (data == 3) {
  235. $('body').append('<div class="hint">密码错误</div>')
  236. setTimeout(function () {
  237. $('.hint').remove();
  238. }, 1000)
  239. } else {
  240. $('body').append('<div class="hint">登录失败</div>')
  241. setTimeout(function () {
  242. $('.hint').remove();
  243. }, 1000)
  244. }
  245. },
  246. error: function (type) {
  247. }
  248. })
  249. }
  250. </script>
  251. </body>
  252. </html>