resetPsw.vue 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305
  1. <template>
  2. <div class="family text-[14px] leading-[1.42857143] text-[#333] bg-[#fff]">
  3. <div class="header h-80px">
  4. <nav
  5. class="nav-header-password col-md-12 leading-[80px] relative min-h-1px px-15px"
  6. >
  7. <div class="logo p-0">
  8. <!-- 此处a需不需要改 -->
  9. <a
  10. href="https://17pdf.com"
  11. class="text-[#666] text-[24px] no-underline bg-transparent"
  12. >
  13. <span class="logo-img m-0 py-20px pl-170px"></span>
  14. <span>17PDF Reader</span>
  15. </a>
  16. </div>
  17. </nav>
  18. </div>
  19. <div class="pc-container px-15px mx-auto sm:w-750px">
  20. <section class="password-reset-form py-72px px-0">
  21. <div class="px-15px mx-auto sm:w-750px">
  22. <div class="row mx-[-15px]">
  23. <div class="col-md-3 relative min-h-1px px-15px"></div>
  24. <div
  25. class="col-md-6 relative min-h-1px px-15px tiny:w-[70%] tiny:my-0 tiny:mx-auto"
  26. >
  27. <h2
  28. class="text-center text-[#00bbd3] text-[30px] mb-32px text-center mt-20px leading-[1.1] font-medium"
  29. >
  30. 设置新密码
  31. </h2>
  32. </div>
  33. </div>
  34. <div class="row form-wrapper mx-[-15px]">
  35. <div class="col-md-3 relative min-h-1px px-15px"></div>
  36. <div
  37. class="col-md-6 relative min-h-1px px-15px tiny:w-[70%] tiny:my-0 tiny:mx-auto"
  38. >
  39. <h3
  40. v-show="showError"
  41. class="warning text-[24px] mt-20px mb-10px font-medium laeding-[1.1]"
  42. >
  43. 密码重置失败,请确认两次密码一致!
  44. </h3>
  45. <input type="hidden" name="_method" value="put" /><input
  46. type="hidden"
  47. name="authenticity_token"
  48. value="QBgQOkuMzY9y68DxLhdc/7SYTXa5vCi1AOwaPmWairZQEy8t4DnUteFfBA8cJWji/bkgBGwDpQrcSnHum6baJQ=="
  49. />
  50. <div class="form-group mb-34px">
  51. <label
  52. for="password"
  53. class="text-[#333] text-[14px] font-normal max-w-full mb-5px"
  54. >请输入新密码</label
  55. >
  56. <input
  57. id="password"
  58. v-model="newPassword"
  59. type="password"
  60. class="form-control h-40px w-full py-6px px-12px text-[14px] leading-[1.42857143] text-[#555] bg-[#fff] border border-solid border-gray-[#ccc] m-0"
  61. />
  62. </div>
  63. <div class="form-group mb-34px">
  64. <label
  65. for="password-confirmation"
  66. class="text-[#666] text-[14px] font-normal max-w-full mb-5px"
  67. >请输入新密码</label
  68. >
  69. <input
  70. id="password-confirmation"
  71. v-model="confirm_newPassword"
  72. type="password"
  73. class="form-control h-40px w-full py-6px px-12px text-[14px] leading-[1.42857143] text-[#555] bg-[#fff] border border-solid border-gray-[#ccc] m-0"
  74. />
  75. </div>
  76. <button
  77. class="btn btn-block bg-[#fdc656] text-[#fff] h-50px w-full py-6px px-12px mb-0 text-[14px] m-0 font-normal leading-[1.42857143] text-center whitespace-nowrap align-middle cursor-pointer border border-solid border-transparent"
  78. type="submit"
  79. @click="resetPassword"
  80. >
  81. 确认修改
  82. </button>
  83. </div>
  84. </div>
  85. </div>
  86. </section>
  87. </div>
  88. <footer class="footer-password">
  89. <div
  90. class="container-password footer-container w-full bg-[#222] text-[#fff] text-[18px] text-center px-15px mx-auto"
  91. >
  92. <div class="row footer-row py-50px px-100px text-left mx-[-15px]">
  93. <div
  94. class="col-xs-2 w-[16.66666667%] float-left relative min-h-1px px-15px"
  95. ></div>
  96. <div class="col-xs-3 w-[25%] float-left relative min-h-1px px-15px">
  97. <h4 class="title text-[18px] my-10px font-medium leading-[1.1]">
  98. PDF
  99. </h4>
  100. <ul class="p-0 mt-0 mb-10px">
  101. <li class="list-none text-[16px] mt-24px">
  102. <a
  103. href="https://17pdf.com"
  104. class="opacity-30 text-[#fff] no-underline bg-transparent"
  105. >产品</a
  106. >
  107. </li>
  108. <li class="list-none text-[16px] mt-24px">
  109. <a
  110. href="https://17pdf.com/sdk"
  111. class="opacity-30 text-[#fff] no-underline bg-transparent"
  112. >SDK介绍</a
  113. >
  114. </li>
  115. </ul>
  116. </div>
  117. <div class="col-xs-3 w-[25%] float-left relative min-h-1px px-15px">
  118. <h4 class="title text-[18px] my-10px font-medium leading-[1.1]">
  119. 下载
  120. </h4>
  121. <ul class="p-0 mt-0 mb-10px">
  122. <li class="list-none text-[16px] mt-24px">
  123. <a
  124. target="_blank"
  125. href="https://www.kdanmobile.com/zh-cn/pdf-reader/"
  126. class="opacity-30 text-[#fff] no-underline bg-transparent"
  127. >PDF Reader</a
  128. >
  129. </li>
  130. <li class="list-none text-[16px] mt-24px">
  131. <a
  132. target="_blank"
  133. href="https://markups.kdanmobile.com/"
  134. class="opacity-30 text-[#fff] no-underline bg-transparent"
  135. >Markup</a
  136. >
  137. </li>
  138. <li class="list-none text-[16px] mt-24px">
  139. <a
  140. target="_blank"
  141. href="https://www.kdanmobile.com/zh-cn/pdf-reader/"
  142. class="opacity-30 text-[#fff] no-underline bg-transparent"
  143. >Connoisser</a
  144. >
  145. </li>
  146. <li class="list-none text-[16px] mt-24px">
  147. <a
  148. target="_blank"
  149. href="https://chrome.google.com/webstore/detail/pdf-markup-my-web-markups/cbjngbfjehiofmihfpodinolkcokdojp"
  150. class="opacity-30 text-[#fff] no-underline bg-transparent"
  151. >网页插件</a
  152. >
  153. </li>
  154. </ul>
  155. </div>
  156. <div class="col-xs-3 w-[25%] float-left relative min-h-1px px-15px">
  157. <h4 class="title text-[18px] my-10px font-medium leading-[1.1]">
  158. 联系我们
  159. </h4>
  160. <div class="icon mt-28px">
  161. <a
  162. class="call mt-20px mr-20px no-underline"
  163. title="0731-84225961"
  164. ></a>
  165. <a
  166. target="_blank"
  167. href="http://weibo.com/kdanmobilesoftware"
  168. class="weibo mt-20px mr-20px no-underline"
  169. ></a>
  170. <a
  171. class="qq mt-20px mr-20px no-underline"
  172. href="tencent://message/?uin=231368992&amp;Site"
  173. ></a>
  174. </div>
  175. </div>
  176. </div>
  177. <p class="text-muted text-[14px] text-[#777] mb-10px mt-0 mx-0">
  178. <a target="_blank" href="https://17pdf.com/terms" class="text-muted"
  179. >服务条款</a
  180. >
  181. |
  182. <a target="_blank" href="https://17pdf.com/privacy" class="text-muted"
  183. >隐私政策</a
  184. >
  185. | ©2022 Kdanmobile All Rights Reserved.
  186. </p>
  187. <p class="text-muted text-[14px] text-[#777] mb-10px mt-0 mx-0">
  188. 凯钿公司 版权所有
  189. </p>
  190. </div>
  191. </footer>
  192. </div>
  193. </template>
  194. <script>
  195. import qs from 'qs'
  196. export default {
  197. layout: 'custom',
  198. data() {
  199. return {
  200. confirm_newPassword: '',
  201. newPassword: '',
  202. showError: false
  203. }
  204. },
  205. methods: {
  206. resetPassword() {
  207. if(this.newPassword === '' || this.confirm_newPassword !== this.newPassword || this.newPassword.length < 6) {
  208. this.showError = true
  209. return
  210. }
  211. const data = qs.parse(location.href.split('?')[1])
  212. const params = {
  213. account: data.account,
  214. verifyCode: data.verifyCode,
  215. type: '0',
  216. newPassword: this.newPassword
  217. }
  218. this.$axios.post('members/resetPassword', params).then((res) => {
  219. if(res.code === 200) {
  220. this.$router.push('/')
  221. }
  222. })
  223. }
  224. }
  225. }
  226. </script>
  227. <style>
  228. /* 字体 */
  229. .family {
  230. font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  231. }
  232. /* 头部边框 */
  233. .nav-header-password {
  234. border-bottom: 1px solid #dadada;
  235. }
  236. /* logo背景图 */
  237. .logo-img {
  238. background: url(~/assets/images/password/logo_pdf_top_red-f4311f231ebc70c4ba5ac8e1e6af907a48ea69f1f159c501a277ade70dfd7022.png)
  239. no-repeat 85% 50%;
  240. }
  241. /* input被focus */
  242. .form-control:focus {
  243. border-color: #66afe9;
  244. outline: 0;
  245. -webkit-box-shadow: inset 0 1px 1px rgb(0 0 0 / 8%),
  246. 0 0 8px rgb(102 175 233 / 60%);
  247. box-shadow: inset 0 1px 1px rgb(0 0 0 / 8%), 0 0 8px rgb(102 175 233 / 60%);
  248. }
  249. .btn:hover {
  250. background-color: #fab93d;
  251. }
  252. .container-password::before,
  253. .container-password::after,
  254. .row::before,
  255. .row::after {
  256. content: ' ';
  257. display: table;
  258. clear: both;
  259. }
  260. /* windi css不能实现的 */
  261. .form-control {
  262. -webkit-box-shadow: inset 0 1px 1px rgb(0 0 0 / 8%);
  263. box-shadow: inset 0 1px 1px rgb(0 0 0 / 8%);
  264. -webkit-transition: border-color ease-in-out 0.15s,
  265. -webkit-box-shadow ease-in-out 0.15s;
  266. -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
  267. transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
  268. }
  269. /* 确认按钮 */
  270. .btn {
  271. -ms-touch-action: manipulation;
  272. touch-action: manipulation;
  273. -webkit-user-select: none;
  274. -moz-user-select: none;
  275. -ms-user-select: none;
  276. user-select: none;
  277. }
  278. /* 底部图标 */
  279. .call:before {
  280. content: url(~/assets/images/password/ic_foot_phone_normal-6c4b69f54ec3fd9ba9c181a1a776c0ea4695c2c4f26c134b88f41796d14c72af.png);
  281. }
  282. .weibo:before {
  283. content: url(~/assets/images/password/ic_foot_weibo_normal-c0b566a8cc73aa0577487c8f179327856e74b0572a787211917c3a2e671f8628.png);
  284. }
  285. .qq:before {
  286. content: url(~/assets/images/password/ic_foot_qq_normal-e67510e549266f75e77757d308306b01185370fffc5a105438d91601b6a486ec.png);
  287. }
  288. </style>