AI销管
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.
 
 
 
 

273 lines
6.3 KiB

  1. <template>
  2. <view class="main">
  3. <u-navbar title="我的" :is-back="false" :background="{background: 'none'}" :border-bottom="false" title-color="#333"> </u-navbar>
  4. <view class="header">
  5. <view class="header-zuo">
  6. <u-avatar
  7. :src="photo?photo:'/static/images/avatar.png'"
  8. size="128"></u-avatar>
  9. </view>
  10. <view class="header-you">
  11. <view class="userName u-line-2">
  12. {{name}}
  13. </view>
  14. <view class="mobile">{{mobile}}</view>
  15. </view>
  16. </view>
  17. <view class="settingGroup">
  18. <!-- <navigator class="line" url="/pages/mine/messageList">
  19. <view class="title" style="width: 19%;">
  20. <image src="/static/images/studyhot.png" mode=""></image>
  21. 消息
  22. </view>
  23. <view class="right">
  24. <image src="/static/images/right-arrow.png" mode=""></image>
  25. </view>
  26. </navigator> -->
  27. <navigator class="line" url="/pages/mine/Myprofile">
  28. <view class="title">
  29. <image src="/static/images/setting.png" mode=""></image>
  30. 个人资料
  31. </view>
  32. <view class="right">
  33. <image src="/static/images/right-arrow.png" mode=""></image>
  34. </view>
  35. </navigator>
  36. <view class="line" @click="Changehepassword">
  37. <view class="title">
  38. <image src="/static/images/password.png" mode=""></image>
  39. 修改密码
  40. </view>
  41. <view class="right">
  42. <image src="/static/images/right-arrow.png" mode=""></image>
  43. </view>
  44. </view>
  45. <view class="line" @click="phone">
  46. <view class="title">
  47. <image src="/static/images/concat.png" mode=""></image>
  48. 联系客服
  49. </view>
  50. <view class="right">
  51. <image src="/static/images/right-arrow.png" mode=""></image>
  52. </view>
  53. </view>
  54. <!-- <view class="line" @click="help">
  55. <view class="title">
  56. <image src="/static/images/concat.png" mode=""></image>
  57. 帮助中心
  58. </view>
  59. <view class="right">
  60. <image src="/static/images/right-arrow.png" mode=""></image>
  61. </view>
  62. </view> -->
  63. <view class="line" @click="scan">
  64. <view class="title">
  65. <image src="/static/images/visitCode.png" mode=""></image>
  66. 访客登记码
  67. </view>
  68. <view class="right">
  69. <image src="/static/images/right-arrow.png" mode=""></image>
  70. </view>
  71. </view>
  72. <view class="loginout" @click="logout" style="border: none;">
  73. <view class="title">
  74. 退出登录
  75. </view>
  76. </view>
  77. </view>
  78. <!-- 底部导航栏 -->
  79. <!-- <u-tabbar :isBtnTop="false" :mid-button="true" activeColor="#1296db" inactiveColor="#999999" v-model="current" :list="tabbarList"></u-tabbar> -->
  80. </view>
  81. </template>
  82. <script>
  83. var app = getApp();
  84. var util = require("../../utils/util.js");
  85. var config = require("../../config");
  86. import tabbarList from '@/utils/tabbar.js'
  87. export default {
  88. data() {
  89. return {
  90. // tabbar配置项
  91. current: 0,
  92. tabbarList: tabbarList,
  93. //--- end --- tabbar配置项
  94. name: "",
  95. photo: "",
  96. mobile: "",
  97. };
  98. },
  99. onShow: function() {
  100. var userInfos = uni.getStorageSync('weapp_session_userInfo_data');
  101. this.name = userInfos.name,
  102. this.photo = userInfos.avatar,
  103. this.mobile = userInfos.username
  104. },
  105. methods: {
  106. //拨打电话
  107. phone() {
  108. wx.makePhoneCall({
  109. phoneNumber: '4008191707,8888' //仅为示例,并非真实的电话号码
  110. })
  111. },
  112. scan(){
  113. uni.navigateTo({
  114. url:"../mine/registerCode"
  115. })
  116. },
  117. help(){
  118. uni.navigateTo({
  119. url:"../mine/help/index"
  120. })
  121. },
  122. //修改密码
  123. Changehepassword() {
  124. uni.navigateTo({
  125. url: '/pages/mine/Changehepassword'
  126. });
  127. },
  128. //退出
  129. logout() {
  130. uni.showModal({
  131. title: '提示',
  132. content: '确定要退出?',
  133. cancelColor: "#999999",
  134. showCancel: true,
  135. success(res) {
  136. if (res.confirm) {
  137. uni.request({
  138. url: config.service.logout,
  139. header: {
  140. 'Authorization': 'Basic dGVzdDp0ZXN0',
  141. 'content-type': 'application/x-www-form-urlencoded'
  142. },
  143. method: "DELETE",
  144. success: function(result) {
  145. var data = result.data; //console.log("登录信息", data);
  146. if (data.data == true) {
  147. // app.Closewebsocke()
  148. uni.clearStorageSync(); //清除缓存
  149. uni.showToast({
  150. icon: "none",
  151. title: "退出成功"
  152. })
  153. uni.reLaunch({
  154. url: '/pages/login/index'
  155. });
  156. }
  157. },
  158. // 响应错误
  159. fail: function(loginResponseError) {
  160. util.showNone("网络异常,请重试");
  161. return false;
  162. }
  163. });
  164. }
  165. }
  166. });
  167. }
  168. }
  169. };
  170. </script>
  171. <style lang="scss" scoped>
  172. .main {
  173. width: 100vw;
  174. height: 100vh;
  175. display: flex;
  176. flex-direction: column;
  177. background: url('https://static.quhouse.com/f5e2422890044cd1a620abd078e63442.png') no-repeat;
  178. background-size: 750rpx 540rpx;
  179. }
  180. .header {
  181. width: 670rpx;
  182. height: 248rpx;
  183. display: flex;
  184. align-items: center;
  185. background: url('https://static.quhouse.com/10fa8f6fe7fa4104a5c4149be4735311.png') no-repeat;
  186. background-size: 670rpx 248rpx;
  187. margin: 0 40rpx 60rpx;
  188. border-radius: 18rpx;
  189. box-shadow: 0 10rpx 20rpx #999;
  190. .header-zuo {
  191. width: 128rpx;
  192. height: 128rpx;
  193. margin-left: 40rpx;
  194. }
  195. .header-you {
  196. margin-left: 30rpx;
  197. .userName {
  198. margin-bottom: 20rpx;
  199. font-size: 36rpx;
  200. font-weight: 500;
  201. color: #fff;
  202. font-family: PingFangSC-Medium, PingFang SC;
  203. }
  204. .mobile {
  205. font-size: 30rpx;
  206. color: #fff;
  207. }
  208. }
  209. }
  210. .settingGroup {
  211. position: relative;
  212. margin-top: 30rpx;
  213. flex-grow: 1;
  214. display: flex;
  215. flex-direction: column;
  216. color: #333333;
  217. font-size: 30rpx;
  218. border-radius: 12rpx;
  219. background-color: #fff;
  220. .line {
  221. height: 44rpx;
  222. margin: 0 50rpx 60rpx;
  223. display: flex;
  224. align-items: center;
  225. justify-content: space-between;
  226. .title {
  227. display: flex;
  228. align-items: center;
  229. width: 300rpx;
  230. height:44rpx;
  231. line-height: 44rpx;
  232. font-size: 32rpx;
  233. font-family: PingFangSC-Regular, PingFang SC;
  234. font-weight: 400;
  235. color: #333333;
  236. image{
  237. width: 36rpx;
  238. height: 36rpx;
  239. margin-right: 20rpx;
  240. }
  241. }
  242. .right{
  243. image{
  244. width: 12rpx;
  245. height: 28rpx;
  246. }
  247. }
  248. }
  249. .loginout {
  250. position: absolute;
  251. left: 40rpx;
  252. right: 40rpx;
  253. bottom: 50rpx;
  254. width: 670rpx;
  255. height: 92rpx;
  256. background: #F8F8F8;
  257. border-radius: 8rpx;
  258. display: flex;
  259. align-items: center;
  260. justify-content: center;
  261. }
  262. }
  263. </style>