index.vue 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214
  1. <template>
  2. <view>
  3. <image src="../../static/index/banner.png" class="banner"></image>
  4. <div class="map">
  5. <div
  6. class="mapdom"
  7. style="float: left"
  8. v-for="(item, index) in mapList"
  9. :key="index"
  10. @click="jumpPage(item.path)"
  11. >
  12. <img class="mapIcon" :src="item.url" />
  13. <div class="maptxt">{{ item.label }}</div>
  14. </div>
  15. </div>
  16. </view>
  17. </template>
  18. <script>
  19. // import {demo} from "@/js_sdk/http"
  20. import { getUserPower, getUserLocalStorageInfo } from "@/js_sdk/http";
  21. export default {
  22. data() {
  23. return {
  24. mapList: [
  25. // {
  26. // label: "智慧党建",
  27. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  28. // path: "/pages/subPackages/buildmap/index",
  29. // },
  30. // {
  31. // label: "经发填报",
  32. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  33. // path: "/pages/subPackages/companyHouse/companyHouse",
  34. // },
  35. // {
  36. // label: "企业库",
  37. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/2@2x.png",
  38. // path: "/pages/subPackages/companyHouse/companyHouse",
  39. // },
  40. // {
  41. // label: "走访上报",
  42. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/3@2x.png",
  43. // path: "/pages/subPackages/companyreport/companyreport",
  44. // },
  45. // {
  46. // label: "上市跟进",
  47. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/4@2x.png",
  48. // },
  49. // {
  50. // label: "招商管理",
  51. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/5@2x.png",
  52. // path: "/pages/subPackages/merchants/merchants",
  53. // },
  54. // {
  55. // label: "我的待办",
  56. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/7@2x.png",
  57. // path: "/pages/subPackages/todo/index",
  58. // },
  59. // {
  60. // label: "我的待阅",
  61. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/6@2x.png",
  62. // path: "/pages/subPackages/toread/index",
  63. // },
  64. {
  65. label: "会议室审核",
  66. url: "https://hswkxc.idea-sf.com/fileService/static/slices/12@2x.png",
  67. path: "/pages/subPackages/meetingroom/meetingroom",
  68. },
  69. {
  70. label: "周边发布",
  71. url: "https://hswkxc.idea-sf.com/fileService/static/slices/3@2x.png",
  72. path: "/pages/subPackages/peripheralService/index",
  73. },
  74. {
  75. label: "活动发布",
  76. url: "https://hswkxc.idea-sf.com/fileService/static/slices/3@2x.png",
  77. path: "/pages/subPackages/eventRelease/index",
  78. },
  79. // {
  80. // label: "安全管理自检",
  81. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/8@2x.png",
  82. // path: "/pages/subPackages/secureselftest2/index",
  83. // },
  84. // {
  85. // label: "安全管理统计",
  86. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/8@2x.png",
  87. // path: "/pages/subPackages/secureselftest/index",
  88. // },
  89. // {
  90. // label: "安全自检计划",
  91. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/9@2x.png",
  92. // path: "/pages/subPackages/secureselfplan/index",
  93. // },
  94. {
  95. label: "报修派单",
  96. url: "https://hswkxc.idea-sf.com/fileService/static/slices/11@2x.png",
  97. path: "/pages/subPackages/repairDispatch-app/index",
  98. },
  99. {
  100. label: "报修处理",
  101. url: "https://hswkxc.idea-sf.com/fileService/static/slices/10@2x.png",
  102. path: "/pages/subPackages/repairprocessing-app/index",
  103. },
  104. // {
  105. // label: "整改填报",
  106. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/15@2x.png",
  107. // path: "/pages/subPackages/modifyReport/index",
  108. // },
  109. // {
  110. // label: "整改派单",
  111. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/14@2x.png",
  112. // path: "/pages/subPackages/modifySend/index",
  113. // },
  114. // {
  115. // label: "整改处理",
  116. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/13@2x.png",
  117. // path: "/pages/subPackages/modifyHandle/index",
  118. // },
  119. // {
  120. // label: "活动核销",
  121. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  122. // path: "/pages/subPackages/activity/index",
  123. // },
  124. // {
  125. // label: "可视化大屏",
  126. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  127. // path: "/pages/subPackages/bigscreen/bigscreen",
  128. // },
  129. // {
  130. // label: "场馆审核",
  131. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  132. // path: "/pages/subPackages/venueRoom/meetingroom",
  133. // },
  134. ],
  135. };
  136. },
  137. onShareAppMessage() {},
  138. mounted() {
  139. // demo();
  140. },
  141. onLoad() {
  142. this.getUserPower();
  143. },
  144. methods: {
  145. // getUserLocalStorageInfo
  146. async getUserPower() {
  147. if (getUserLocalStorageInfo().user.id == 1) return;
  148. let that = this;
  149. let newList = [];
  150. let { data } = await getUserPower(getUserLocalStorageInfo().user.id);
  151. for (let i = 0; i < that.mapList.length; i++) {
  152. let index = data.findIndex((e) => e == that.mapList[i].label);
  153. if (index != -1) {
  154. newList.push(that.mapList[i]);
  155. }
  156. }
  157. that.mapList = newList;
  158. },
  159. jumpPage(path) {
  160. uni.navigateTo({
  161. url: path,
  162. fail: (fail) => {},
  163. });
  164. },
  165. },
  166. };
  167. </script>
  168. <style lang="scss">
  169. page {
  170. background: white;
  171. }
  172. .banner {
  173. width: 100%;
  174. height: 450rpx;
  175. position: absolute;
  176. z-index: 1;
  177. }
  178. .mapdom {
  179. width: 25%;
  180. height: 184rpx;
  181. }
  182. .maptxt {
  183. width: 100%;
  184. height: 34rpx;
  185. font-size: 24rpx;
  186. font-family: PingFang SC-Medium, PingFang SC;
  187. font-weight: 500;
  188. color: #333333;
  189. text-align: center;
  190. }
  191. .mapIcon {
  192. width: 160rpx;
  193. height: 160rpx;
  194. //background: linear-gradient(141deg, #89BCFF 0%, #2782FA 100%);
  195. display: block;
  196. margin: auto;
  197. }
  198. .map {
  199. position: absolute;
  200. z-index: 2;
  201. width: calc(100% - 64rpx);
  202. height: 770rpx;
  203. border-radius: 48rpx 48rpx 0rpx 0rpx;
  204. background: white;
  205. margin-top: 402rpx;
  206. padding: 48rpx 32rpx;
  207. overflow-y: auto;
  208. }
  209. </style>