index.vue 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365
  1. <template>
  2. <view>
  3. <div class="managementBody" v-show="userType == 2">
  4. <image
  5. src="https://www.idea-co-sf.com/gardenProduct/image/banner.png"
  6. class="banner"
  7. ></image>
  8. <div class="needBox">
  9. <div class="needLeft">
  10. <div
  11. class="needLeftLeft"
  12. @click="toMsgPage('/pages/subPackages/todo/index')"
  13. >
  14. <span style="color: #18172a; font-size: 4.5vw; margin-bottom: 1vw"
  15. >我的待办</span
  16. >
  17. <span style="color: #666666; font-size: 3.5vw"
  18. >需处理待办<span
  19. style="color: #0365f9; font-weight: 600; margin-left: 0.5vw"
  20. >3</span
  21. ></span
  22. >
  23. </div>
  24. <img
  25. src="https://www.idea-co-sf.com/gardenProduct/image/dbImage.png"
  26. class="needImg"
  27. />
  28. </div>
  29. <div
  30. class="needRight"
  31. @click="toMsgPage('/pages/subPackages/toread/index')"
  32. >
  33. <div class="needLeftLeft">
  34. <span style="color: #18172a; font-size: 4.5vw; margin-bottom: 1vw"
  35. >我的待阅</span
  36. >
  37. <span style="color: #666666; font-size: 3.5vw"
  38. >需处理待阅<span
  39. style="color: #22b565; font-weight: 600; margin-left: 0.5vw"
  40. >12</span
  41. ></span
  42. >
  43. </div>
  44. <img
  45. src="https://www.idea-co-sf.com/gardenProduct/image/dyImage.png"
  46. class="needImg"
  47. />
  48. </div>
  49. </div>
  50. <div class="titleTips">
  51. <div class="myLine"></div>
  52. <div>服务入口</div>
  53. </div>
  54. <div class="map">
  55. <div
  56. class="mapdom"
  57. style="float: left"
  58. v-for="(item, index) in mapList"
  59. :key="index"
  60. @click="jumpPage(item.path)"
  61. >
  62. <img class="mapIcon" :src="item.url" />
  63. <div class="maptxt">{{ item.label }}</div>
  64. </div>
  65. </div>
  66. </div>
  67. <!-- 企业端页面-->
  68. <div class="enterpriseBody" v-show="userType == 1 || userType == 3">
  69. <enterprise-side></enterprise-side>
  70. </div>
  71. </view>
  72. </template>
  73. <script>
  74. // import {demo} from "@/js_sdk/http"
  75. import { getUserPower, getUserLocalStorageInfo } from "@/js_sdk/http";
  76. import EnterpriseSide from "./components/enterpriseSide.vue";
  77. export default {
  78. components: { EnterpriseSide },
  79. data() {
  80. return {
  81. userType: false,
  82. mapList: [
  83. // {
  84. // label: "智慧党建",
  85. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  86. // path: "/pages/subPackages/buildmap/index",
  87. // },
  88. // {
  89. // label: "经发填报",
  90. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  91. // path: "/pages/subPackages/companyHouse/companyHouse",
  92. // },
  93. {
  94. label: "企业库",
  95. url: "https://www.idea-co-sf.com/gardenProduct/image/qyk.png",
  96. path: "/pages/subPackages/companyHouse/companyHouse",
  97. },
  98. {
  99. label: "走访上报",
  100. url: "https://www.idea-co-sf.com/gardenProduct/image/zfsb.png",
  101. path: "/pages/subPackages/companyreport/companyreport",
  102. },
  103. {
  104. label: "会议室审核",
  105. url: "https://www.idea-co-sf.com/gardenProduct/image/tupian1.png",
  106. },
  107. // {
  108. // label: "上市跟进",
  109. // url: https://www.idea-co-sf.com/gardenProduct/image/ssgj.png"),
  110. // },
  111. {
  112. label: "招商管理",
  113. url: "https://www.idea-co-sf.com/gardenProduct/image/zsgl.png",
  114. path: "/pages/subPackages/merchants/merchants",
  115. },
  116. // {
  117. // label: "活动发布",
  118. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/3@2x.png",
  119. // path: "/pages/subPackages/eventRelease/index",
  120. // },
  121. // {
  122. // label: "安全管理自检",
  123. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/8@2x.png",
  124. // path: "/pages/subPackages/secureselftest2/index",
  125. // },
  126. // {
  127. // label: "安全管理统计",
  128. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/8@2x.png",
  129. // path: "/pages/subPackages/secureselftest/index",
  130. // },
  131. // {
  132. // label: "安全自检计划",
  133. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/9@2x.png",
  134. // path: "/pages/subPackages/secureselfplan/index",
  135. // },
  136. {
  137. label: "报修派单",
  138. url: "https://www.idea-co-sf.com/gardenProduct/image/bxpd.png",
  139. path: "/pages/subPackages/repairDispatch-app/index",
  140. },
  141. {
  142. label: "报修处理",
  143. url: "https://www.idea-co-sf.com/gardenProduct/image/bxcl.png",
  144. path: "/pages/subPackages/repairprocessing-app/index",
  145. },
  146. {
  147. label: "房间管理",
  148. url: "https://www.idea-co-sf.com/gardenProduct/image/fjgl.png",
  149. // path: "/pages/subPackages/repairprocessing-app/index",
  150. },
  151. {
  152. label: "园区通知",
  153. url: "https://www.idea-co-sf.com/gardenProduct/image/tzfb.png",
  154. // path: "",
  155. },
  156. {
  157. label: "物业通知",
  158. url: "https://www.idea-co-sf.com/gardenProduct/image/tupian2.png",
  159. // path: "",
  160. },
  161. {
  162. label: "活动发布",
  163. url: "https://www.idea-co-sf.com/gardenProduct/image/hdfb.png",
  164. path: "/pages/subPackages/activityPromulgate/list",
  165. },
  166. // {
  167. // label: "周边发布",
  168. // url: https://www.idea-co-sf.com/gardenProduct/image/zbfb.png"),
  169. // path: "/pages/subPackages/repairprocessing-app/index",
  170. // },
  171. // {
  172. // label: "整改填报",
  173. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/15@2x.png",
  174. // path: "/pages/subPackages/modifyReport/index",
  175. // },
  176. // {
  177. // label: "整改派单",
  178. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/14@2x.png",
  179. // path: "/pages/subPackages/modifySend/index",
  180. // },
  181. // {
  182. // label: "整改处理",
  183. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/13@2x.png",
  184. // path: "/pages/subPackages/modifyHandle/index",
  185. // },
  186. // {
  187. // label: "活动核销",
  188. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  189. // path: "/pages/subPackages/activity/index",
  190. // },
  191. // {
  192. // label: "可视化大屏",
  193. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  194. // path: "/pages/subPackages/bigscreen/bigscreen",
  195. // },
  196. // {
  197. // label: "场馆审核",
  198. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  199. // path: "/pages/subPackages/venueRoom/meetingroom",
  200. // },
  201. ],
  202. };
  203. },
  204. onShareAppMessage() {},
  205. mounted() {
  206. // demo();
  207. },
  208. onLoad(e) {
  209. // uni.$on("userType", (userType) => {
  210. // if (userType === "OK") {
  211. // this.userType = !this.userType;
  212. // }
  213. // });
  214. this.getUserPower();
  215. },
  216. methods: {
  217. toMsgPage(e) {
  218. uni.navigateTo({
  219. url: e,
  220. fail: (fail) => {},
  221. });
  222. },
  223. // getUserLocalStorageInfo
  224. async getUserPower() {
  225. let that = this;
  226. console.log(getUserLocalStorageInfo());
  227. that.userType = getUserLocalStorageInfo().userType;
  228. if (that.userType == 3) {
  229. uni.showModal({
  230. title: "提示",
  231. cancelText: "暂不",
  232. confirmText: "去切换",
  233. content: "您还不是企业用户,请切换登录身份后再进行相关操作。",
  234. success: function (res) {
  235. if (res.confirm) {
  236. uni.navigateTo({
  237. url: "/pages/login2/login",
  238. success: function (e) {
  239. // uni.$emit('userType', 'OK')
  240. },
  241. });
  242. } else if (res.cancel) {
  243. console.log("用户点击取消");
  244. }
  245. },
  246. });
  247. }
  248. // if (getUserLocalStorageInfo().user.id == 1) return;
  249. // let newList = [];
  250. // let { data } = await getUserPower(getUserLocalStorageInfo().user.id);
  251. // for (let i = 0; i < that.mapList.length; i++) {
  252. // let index = data.findIndex((e) => e == that.mapList[i].label);
  253. // if (index != -1) {
  254. // newList.push(that.mapList[i]);
  255. // }
  256. // }
  257. // that.mapList = newList;
  258. },
  259. jumpPage(path) {
  260. uni.navigateTo({
  261. url: path,
  262. fail: (fail) => {},
  263. });
  264. },
  265. },
  266. };
  267. </script>
  268. <style lang="scss">
  269. page {
  270. background: white;
  271. }
  272. .managementBody {
  273. padding: 4vw;
  274. }
  275. .banner {
  276. width: 92vw;
  277. height: 250rpx;
  278. //position: absolute;
  279. z-index: 1;
  280. }
  281. .mapdom {
  282. width: 25%;
  283. height: 184rpx;
  284. }
  285. .maptxt {
  286. width: 100%;
  287. height: 34rpx;
  288. font-size: 24rpx;
  289. font-family: PingFang SC-Medium, PingFang SC;
  290. font-weight: 500;
  291. color: #18172a;
  292. text-align: center;
  293. margin-top: 8rpx;
  294. }
  295. .mapIcon {
  296. width: 65rpx;
  297. height: 80rpx;
  298. //background: linear-gradient(141deg, #89BCFF 0%, #2782FA 100%);
  299. display: block;
  300. margin: auto;
  301. }
  302. .map {
  303. //position: absolute;
  304. z-index: 2;
  305. width: calc(100% - 24rpx);
  306. //height: 770rpx;
  307. border-radius: 48rpx 48rpx 0rpx 0rpx;
  308. background: white;
  309. //margin-top: 402rpx;
  310. padding: 24rpx 12rpx;
  311. overflow-y: auto;
  312. }
  313. .needBox {
  314. display: flex;
  315. align-items: center;
  316. justify-content: space-between;
  317. margin: 2vw 0;
  318. .needLeft {
  319. display: flex;
  320. justify-content: space-around;
  321. background: rgba(238, 244, 255, 1);
  322. border-radius: 8rpx;
  323. align-items: center;
  324. width: 45vw;
  325. height: 23vw;
  326. }
  327. .needRight {
  328. display: flex;
  329. justify-content: space-around;
  330. background: #def6f8;
  331. border-radius: 8rpx;
  332. align-items: center;
  333. width: 45vw;
  334. height: 23vw;
  335. }
  336. .needLeftLeft {
  337. display: flex;
  338. flex-direction: column;
  339. }
  340. .needImg {
  341. width: 100rpx;
  342. height: 100rpx;
  343. }
  344. }
  345. .titleTips {
  346. display: flex;
  347. align-items: center;
  348. font-size: 4.7vw;
  349. font-weight: 600;
  350. color: #18172a;
  351. margin: 4vw 0 2vw 0;
  352. .myLine {
  353. width: 13rpx;
  354. height: 40rpx;
  355. background: linear-gradient(180deg, #509fff 0%, #034df7 100%);
  356. margin-right: 20rpx;
  357. }
  358. }
  359. </style>