account-setting.html 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8"/>
  5. <meta name="author" content=""/>
  6. <meta name="description" content=""/>
  7. <meta name="keywords" content="扫码支付,线上投币,运营数据,物联网"/>
  8. <meta name="format-detection" content="telphone=no,email=no"/>
  9. <meta name="viewport"
  10. content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
  11. <meta http-equiv="pragma" content="no-cache">
  12. <meta http-equiv="cache-control" content="no-cache">
  13. <meta http-equiv="expires" content="0">
  14. <title>测试员:账号设置</title>
  15. <link rel="stylesheet" href="/components/lib/mui.min.css"/>
  16. <link rel="stylesheet" href="/components/custom/css/common.css"/>
  17. <link rel="stylesheet" href="/app/css/xyf.common.min.css">
  18. </head>
  19. <body>
  20. <div class="mui-content" style="bottom: 0;top: 0;position: absolute;width: 100%;">
  21. <ul class="mui-table-view account-hd">
  22. <li class="mui-table-view-cell mui-media" id="userInfo">
  23. <img id="headImg" src="/app/img/headImg.jpg" class="mui-media-object mui-pull-left">
  24. <div class="mui-media-body">
  25. <span id="name"></span>
  26. <p class='mui-ellipsis' id="telephone"></p>
  27. </div>
  28. </li>
  29. </ul>
  30. <ul class="mui-table-view custom-top account-bd">
  31. <li class="mui-table-view-cell">
  32. <a href="password-newpass.html" class="mui-navigate-right">
  33. <i class="iconfont icon-password c-primary"></i>设置密码
  34. </a>
  35. </li>
  36. </ul>
  37. <div class="custom-top">
  38. <a href="javascript:void(0);" onclick="logout()" class="custom-btn-vertical">退出账号</a>
  39. </div>
  40. </div>
  41. </body>
  42. <script src="/components/lib/jquery.min.js"></script>
  43. <script src="/components/lib/mui.min.js"></script>
  44. <script src="/components/custom/js/common.js"></script>
  45. <script src="/app/js/xyf.common.js"></script>
  46. <script>
  47. $(function () {
  48. //获取用户个人信息
  49. showLoading();
  50. sendRequestWithHeaders("/test/accountInfo", "GET", get_token_headers("Tester"), null, function (response) {
  51. hideLoading();
  52. if (response.result == 1) {
  53. $("#headImg").attr("src", response.para.avatar);
  54. $("#name").html(response.para.name);
  55. $("#telephone").html(response.para.tel);
  56. } else {
  57. mui.toast(response.description);
  58. }
  59. });
  60. });
  61. function logout() {
  62. var btnArray = ['取消', '确认'];
  63. mui.confirm('确定要退出当前账号?', '温馨提示', btnArray, function (e) {
  64. if (e.index == 1) {
  65. localStorage.removeItem(get_token_session_key("Tester"));
  66. var url = "login.html";
  67. goPage(url);
  68. }
  69. });
  70. }
  71. </script>
  72. </html>