AI营销辅助 普强使用
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.
 
 
 

298 рядки
7.2 KiB

  1. <template>
  2. <view class="main">
  3. <view class="backTop"></view>
  4. <!-- 头部开始 -->
  5. <view class="header box">
  6. <view class="header-zuo">
  7. <u-avatar
  8. :src="photo?photo:'https://qufang.oss-cn-beijing.aliyuncs.com/upload/icon/xcx/zkgj/headPicture.png'"
  9. size="148"></u-avatar>
  10. </view>
  11. <view class="header-you">
  12. <view class="userName">{{name}}</view>
  13. <view class="mobile">{{mobile}}</view>
  14. </view>
  15. </view>
  16. <view class="settingGroup box">
  17. <navigator class="line" url="/pages/mine/messageList">
  18. <view class="title" style="width: 21%;">
  19. <image src="/static/images/studyhot.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  20. 消息
  21. </view>
  22. <view class="right" style="display: flex;align-items: center;">
  23. <view class="count" v-if="count!=0">{{count}}</view>
  24. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  25. </view>
  26. </navigator>
  27. <!-- <navigator class="line" url="/pages/mine/subscribe">
  28. <view class="title">
  29. <image src="/static/images/studyhot.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  30. 订阅消息
  31. </view>
  32. <view class="right">
  33. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  34. </view>
  35. </navigator> -->
  36. <navigator class="line" url="/pages/mine/Myprofile">
  37. <view class="title">
  38. <image src="/static/images/setting.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  39. 编辑资料
  40. </view>
  41. <view class="right">
  42. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  43. </view>
  44. </navigator>
  45. <view class="line" @click="phone">
  46. <view class="title">
  47. <image src="/static/images/Customer.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  48. 客服电话
  49. </view>
  50. <view class="right">
  51. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  52. </view>
  53. </view>
  54. <!-- <view class="line" @click="scan">
  55. <view class="title" style="width: 220rpx;">
  56. <image src="/static/images/reg.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  57. 访客登记码
  58. </view>
  59. <view class="right">
  60. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  61. </view>
  62. </view> -->
  63. <view class="line" @click="Changehepassword">
  64. <view class="title">
  65. <image src="/static/images/password.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  66. 修改密码
  67. </view>
  68. <view class="right">
  69. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  70. </view>
  71. </view>
  72. <view class="line" @click="logout" style="border: none;">
  73. <view class="title">
  74. <image src="/static/images/exit.png" style="width: 36rpx;height: 36rpx;" mode=""></image>
  75. 退出登录
  76. </view>
  77. <view class="right">
  78. <image src="/static/images/arrow.png" style="width: 18rpx;height: 32rpx;" mode=""></image>
  79. </view>
  80. </view>
  81. </view>
  82. <u-tabbar activeColor="#1296db" inactiveColor="#999999" v-model="current" :list="tabbarList"></u-tabbar>
  83. </view>
  84. </template>
  85. <script>
  86. var app = getApp();
  87. var util = require("../../utils/util.js");
  88. var config = require("../../config");
  89. import tabbarList from '@/utils/tabbar.js'
  90. export default {
  91. data() {
  92. return {
  93. tabbarList:tabbarList,
  94. current: 0,
  95. count:0,
  96. name: "",
  97. photo: "",
  98. mobile: "",
  99. };
  100. },
  101. onShow: function() {
  102. var userInfos = uni.getStorageSync('weapp_session_userInfo_data');
  103. this.name = userInfos.name,
  104. this.photo = userInfos.picUrl,
  105. this.mobile = userInfos.loginName
  106. this.updateInit()
  107. },
  108. methods: {
  109. updateInit() {
  110. uni.request({
  111. url: config.service.notReadNum,
  112. method: "GET",
  113. data: {
  114. id: uni.getStorageSync('weapp_session_userInfo_data').accountId
  115. },
  116. header: {
  117. 'content-type': 'application/json',
  118. 'Access-Token': uni.getStorageSync('weapp_session_login_data').token
  119. },
  120. success: (res) => {
  121. this.count = res.data.data
  122. this.tabbarList[3].count = res.data.data
  123. }
  124. })
  125. },
  126. scan(){
  127. uni.navigateTo({
  128. url:"../mine/registerCode"
  129. })
  130. },
  131. //拨打电话
  132. phone() {
  133. wx.makePhoneCall({
  134. phoneNumber: '010-82306399-7707' //仅为示例,并非真实的电话号码
  135. })
  136. },
  137. //修改密码
  138. Changehepassword() {
  139. uni.navigateTo({
  140. url: '/pages/mine/Changehepassword'
  141. });
  142. },
  143. //退出
  144. logout() {
  145. uni.showModal({
  146. title: '提示',
  147. content: '确定要退出?',
  148. cancelColor: "#999999",
  149. showCancel: true,
  150. success(res) {
  151. if (res.confirm) {
  152. app.Closewebsocke()
  153. uni.clearStorageSync(); //清除缓存
  154. uni.showToast({
  155. icon: "none",
  156. title: "退出成功"
  157. })
  158. uni.reLaunch({
  159. url: '/pages/login/index'
  160. });
  161. }
  162. }
  163. });
  164. },
  165. // tosubscr(){
  166. // let that=this;
  167. // wx.login({
  168. // success (res) {
  169. // if (res.code) {
  170. // let appid ='wxd9748307889cbe0d';
  171. // let secret = 'cfc40d2b86b650e216e900a2c430cd2b'
  172. // let url = 'https://api.weixin.qq.com/sns/jscode2session?appid=' + appid + '&secret=' + secret + '&js_code=' +res.code + '&grant_type=authorization_code';
  173. // uni.request({
  174. // url: url, // 请求路径
  175. // success: result => {
  176. // that.$u.get("/user/bindMessage",{
  177. // openId:result.data.openid,
  178. // loginName:that.mobile
  179. // }).then(data => {
  180. // console.log(data)
  181. // })
  182. // }
  183. // })
  184. // } else {
  185. // console.log('登录失败!' + res.errMsg)
  186. // }
  187. // }
  188. // })
  189. // // /pages/mine/subscribe
  190. // },
  191. }
  192. };
  193. </script>
  194. <style lang="scss" scoped>
  195. .count{
  196. background: red;
  197. width: 50rpx;
  198. height: 50rpx;
  199. border-radius: 40rpx;
  200. color: #FFFFFF;
  201. display: flex;
  202. justify-content: center;
  203. align-items: center;
  204. font-size: 24rpx;
  205. margin-right: 20rpx;
  206. }
  207. .main {
  208. padding: 0 30rpx;
  209. background: #F8F8F8;
  210. display: flex;
  211. flex-direction: column;
  212. min-height: 100vh;
  213. padding-bottom: 40rpx;
  214. .backTop {
  215. background: #2671E2;
  216. position: absolute;
  217. left: 0;
  218. top: 0;
  219. width: 750rpx;
  220. height: 171rpx;
  221. }
  222. .box {
  223. background: #ffffff;
  224. }
  225. }
  226. .header {
  227. z-index: 2;
  228. width: 100%;
  229. height: 212rpx;
  230. border-radius: 12rpx;
  231. margin-top: 42rpx;
  232. display: flex;
  233. .header-zuo {
  234. width: 148rpx;
  235. height: 148rpx;
  236. margin-top: 32rpx;
  237. margin-left: 30rpx;
  238. }
  239. .header-you {
  240. margin-left: 20rpx;
  241. .userName {
  242. font-size: 36rpx;
  243. font-weight: 500;
  244. color: #303030;
  245. margin-top: 56rpx;
  246. }
  247. .mobile {
  248. font-size: 30rpx;
  249. color: #BDBDBD;
  250. margin-top: 20rpx;
  251. }
  252. }
  253. }
  254. .settingGroup {
  255. box-shadow: 0px 0px 12px 0px rgba(224, 224, 224, 0.3);
  256. border-radius: 12rpx;
  257. margin-top: 30rpx;
  258. color: #333333;
  259. font-size: 30rpx;
  260. display: flex;
  261. flex-direction: column;
  262. .line {
  263. height: 118rpx;
  264. border-bottom: 1rpx solid #EEEEEE;
  265. margin: 0 38rpx 0 30rpx;
  266. display: flex;
  267. align-items: center;
  268. justify-content: space-between;
  269. .title {
  270. display: flex;
  271. align-items: center;
  272. width: 190rpx;
  273. justify-content: space-between;
  274. }
  275. }
  276. }
  277. </style>