mine.vue 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282
  1. <template>
  2. <view>
  3. <view class="background">
  4. <!-- 个人信息 -->
  5. <view class="person-infos" @click="gotoUrl('/pages/mine/personInfos')" >
  6. <view class="photo">
  7. <image class="img" src="@/assets/img/photo@x1.png" mode=""></image>
  8. </view>
  9. <view class="else">
  10. <view class="name">
  11. {{personInfo.contacts}}
  12. </view>
  13. <view class="company">
  14. {{companyInfo.name}}
  15. </view>
  16. </view>
  17. </view>
  18. <!-- 地址 -->
  19. <view class="address-box" v-if="false">
  20. <view class="address">
  21. <view class="address-title">
  22. 荆鹏软件园
  23. </view>
  24. <view class="address-value">
  25. <u-icon name="map"></u-icon>荆州市沙市区江津东路附155号
  26. </view>
  27. </view>
  28. <view class="image">
  29. <image class="img" src="@/assets/img/mineBackground.svg" mode=""></image>
  30. </view>
  31. </view>
  32. </view>
  33. <!-- 功能 -->
  34. <view class="function-group">
  35. <view class="function-item" v-if="false" @click="gotoUrl('/pages/mine/tenantInformation')" >
  36. <view class="icon">
  37. <image class="img" src="@/assets/img/riLine-contacts-book-line.svg" mode=""></image>
  38. </view>
  39. <view class="name">
  40. 用户信息
  41. </view>
  42. <view class="arrow">
  43. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  44. </view>
  45. </view>
  46. <view class="function-item" v-if="false">
  47. <view class="icon">
  48. <image class="img" src="@/assets/img/riLine-pie-chart-line.svg" mode=""></image>
  49. </view>
  50. <view class="name">
  51. 用电监控
  52. </view>
  53. <view class="arrow">
  54. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  55. </view>
  56. </view>
  57. <view class="function-item" v-if="false">
  58. <view class="icon">
  59. <image class="img" src="@/assets/img/riLine-book-2-line.svg" mode=""></image>
  60. </view>
  61. <view class="name">
  62. 用电常识
  63. </view>
  64. <view class="arrow">
  65. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  66. </view>
  67. </view>
  68. <view class="function-item" @click="gotoUrl('/pages/invoiceManagement/invoiceManagement')" >
  69. <view class="icon">
  70. <image class="img" src="@/assets/img/iconPark-order2.svg" mode=""></image>
  71. </view>
  72. <view class="name">
  73. 发票管理
  74. </view>
  75. <view class="arrow">
  76. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  77. </view>
  78. </view>
  79. <view class="function-item" @click="gotoUrl('/pages/mine/contactService')" >
  80. <view class="icon">
  81. <image class="img" src="@/assets/img/riLine-customer-service-2-line.svg" mode=""></image>
  82. </view>
  83. <view class="name">
  84. 客服热线
  85. </view>
  86. <view class="arrow">
  87. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  88. </view>
  89. </view>
  90. </view>
  91. <view class="function-group" v-if="false">
  92. <view class="function-item">
  93. <view class="icon">
  94. <image class="img" src="@/assets/img/riLine-user-settings-line.svg" mode=""></image>
  95. </view>
  96. <view class="name">
  97. 个人信息
  98. </view>
  99. <view class="arrow">
  100. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  101. </view>
  102. </view>
  103. </view>
  104. <view class="function-group" >
  105. <view class="function-item" @click="gotoUrl('/pages/mine/setting')">
  106. <view class="icon">
  107. <image class="img" src="@/assets/img/riLine-settings-2-line.svg" mode=""></image>
  108. </view>
  109. <view class="name">
  110. 设置
  111. </view>
  112. <view class="arrow">
  113. <u-icon name="arrow-right" color="#b2b2b2"></u-icon>
  114. </view>
  115. </view>
  116. </view>
  117. <Tabbar :current="2" ></Tabbar>
  118. </view>
  119. </template>
  120. <script>
  121. import * as API from '@/apis/pagejs/index.js'
  122. import * as API_user from '@/apis/pagejs/user.js'
  123. import Tabbar from '@/components/Tabbar.vue'
  124. export default {
  125. components: {
  126. Tabbar
  127. },
  128. data() {
  129. return {
  130. companyInfo:{},
  131. }
  132. },
  133. onLoad() {
  134. this.homePage()
  135. //this.personalCenter()
  136. },
  137. methods: {
  138. personalCenter(){
  139. uni.showLoading({
  140. title: "加载中",
  141. mask: true,
  142. })
  143. API_user.personalCenter({
  144. }).then((response) => {
  145. uni.hideLoading();
  146. //this.companyInfo=response.data.companyInfo;
  147. }).catch(error => {
  148. uni.hideLoading();
  149. })
  150. },
  151. homePage(){
  152. uni.showLoading({
  153. title: "加载中",
  154. mask: true,
  155. })
  156. API.homePage({
  157. }).then((response) => {
  158. uni.hideLoading();
  159. this.companyInfo=response.data.companyInfo;
  160. }).catch(error => {
  161. uni.hideLoading();
  162. })
  163. }
  164. }
  165. }
  166. </script>
  167. <style lang="scss" scoped>
  168. .background{
  169. background: linear-gradient(180deg, rgba(194,219,255,1) 53%,rgba(180,211,255,0) 100%);
  170. padding: 72rpx 32rpx;
  171. // 个人信息
  172. .person-infos{
  173. display: flex;
  174. align-items: center;
  175. .photo{
  176. width: 112rpx;
  177. height: 112rpx;
  178. border-radius: 50px;
  179. .img{
  180. width: 100%;
  181. height: 100%;
  182. }
  183. }
  184. .else{
  185. margin-left: 24rpx;
  186. .name{
  187. color: rgb(16,16,16);
  188. font-size: 36rpx;
  189. }
  190. .company{
  191. color: rgba(16,16,16,1);
  192. }
  193. }
  194. }
  195. // 地址
  196. .address-box{
  197. border-radius: 8px;
  198. background: linear-gradient(90deg, rgba(49,110,207,1) 2%,rgba(20,73,159,1) 100%);
  199. color: #fff;
  200. padding:40rpx 32rpx;
  201. margin-top: 40rpx;
  202. display: flex;
  203. align-items: center;
  204. position: relative;
  205. .address{
  206. .address-title{
  207. font-size: 40rpx;
  208. }
  209. .address-value{
  210. font-size: 24rpx;
  211. margin-top: 8rpx;
  212. }
  213. }
  214. .image {
  215. width: 174rpx;
  216. height: 174rpx;
  217. position: absolute;
  218. right: 0;
  219. top: 20rpx;
  220. .img {
  221. width: 100%;
  222. height: 100%;
  223. }
  224. }
  225. }
  226. }
  227. // 功能
  228. .function-group{
  229. border-radius: 8px;
  230. background-color: #fff;
  231. margin: 0 32rpx 24rpx;
  232. .function-item{
  233. display: flex;
  234. align-items: center;
  235. padding: 26rpx 26rpx 26rpx 0;
  236. margin-left: 26rpx;
  237. border-bottom: 1px solid rgba(221,221,221,1);
  238. .icon{
  239. width: 40rpx;
  240. height: 40rpx;
  241. .img{
  242. width: 100%;
  243. height: 100%;
  244. }
  245. }
  246. .name{
  247. color: rgba(51,51,51,1);
  248. font-size: 30rpx;
  249. margin-left: 26rpx;
  250. }
  251. .arrow{
  252. margin-left: auto;
  253. }
  254. }
  255. }
  256. </style>