index.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366
  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" @click="toMsgPage('/pages/subPackages/todo/index')">
  10. <div
  11. class="needLeftLeft"
  12. >
  13. <span style="color: #18172a; font-size: 4.5vw; margin-bottom: 1vw"
  14. >我的待办</span
  15. >
  16. <span style="color: #666666; font-size: 3.5vw"
  17. >需处理待办<span
  18. style="color: #0365f9; font-weight: 600; margin-left: 0.5vw"
  19. >3</span
  20. ></span
  21. >
  22. </div>
  23. <img
  24. src="https://www.idea-co-sf.com/gardenProduct/image/dbImage.png"
  25. class="needImg"
  26. />
  27. </div>
  28. <div
  29. class="needRight"
  30. @tap.stop="toMsgPage('/pages/subPackages/toread/index')"
  31. >
  32. <div class="needLeftLeft">
  33. <span style="color: #18172a; font-size: 4.5vw; margin-bottom: 1vw"
  34. >我的待阅</span
  35. >
  36. <span style="color: #666666; font-size: 3.5vw"
  37. >需处理待阅<span
  38. style="color: #22b565; font-weight: 600; margin-left: 0.5vw"
  39. >12</span
  40. ></span
  41. >
  42. </div>
  43. <img
  44. src="https://www.idea-co-sf.com/gardenProduct/image/dyImage.png"
  45. class="needImg"
  46. />
  47. </div>
  48. </div>
  49. <div class="titleTips">
  50. <div class="myLine"></div>
  51. <div>服务入口</div>
  52. </div>
  53. <div class="map">
  54. <div
  55. class="mapdom"
  56. style="float: left"
  57. v-for="(item, index) in mapList"
  58. :key="index"
  59. @click="jumpPage(item.path)"
  60. >
  61. <img class="mapIcon" :src="item.url" />
  62. <div class="maptxt">{{ item.label }}</div>
  63. </div>
  64. </div>
  65. </div>
  66. <!-- 企业端页面-->
  67. <div class="enterpriseBody" v-show="userType == 1 || userType == 3">
  68. <enterprise-side></enterprise-side>
  69. </div>
  70. </view>
  71. </template>
  72. <script>
  73. // import {demo} from "@/js_sdk/http"
  74. import { getUserPower, getUserLocalStorageInfo } from "@/js_sdk/http";
  75. import EnterpriseSide from "./components/enterpriseSide.vue";
  76. export default {
  77. components: { EnterpriseSide },
  78. data() {
  79. return {
  80. userType: false,
  81. mapList: [
  82. // {
  83. // label: "智慧党建",
  84. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  85. // path: "/pages/subPackages/buildmap/index",
  86. // },
  87. // {
  88. // label: "经发填报",
  89. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  90. // path: "/pages/subPackages/companyHouse/companyHouse",
  91. // },
  92. {
  93. label: "企业库",
  94. url: "https://www.idea-co-sf.com/gardenProduct/image/qyk.png",
  95. path: "/pages/subPackages/companyHouse/companyHouse",
  96. },
  97. {
  98. label: "走访上报",
  99. url: "https://www.idea-co-sf.com/gardenProduct/image/zfsb.png",
  100. path: "/pages/subPackages/companyreport/companyreport",
  101. },
  102. {
  103. label: "资源预约",
  104. url: "https://www.idea-co-sf.com/gardenProduct/image/tupian1.png",
  105. path: "/pages/subPackages/resourceReservation_manage/index",
  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/todo/repairAcceptance",
  145. },
  146. {
  147. label: "房间管理",
  148. url: "https://www.idea-co-sf.com/gardenProduct/image/fjgl.png",
  149. path: "/pages/subPackages/propertyManagement/maintenance",
  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: "/pages/subPackages/propertyNotice_manage/index",
  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/surroundingReleases/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. onShow() {
  209. this.getUserPower();
  210. },
  211. onLoad(e) {
  212. // uni.$on("userType", (userType) => {
  213. // if (userType === "OK") {
  214. // this.userType = !this.userType;
  215. // }
  216. // });
  217. },
  218. methods: {
  219. toMsgPage(e) {
  220. uni.navigateTo({
  221. url: e,
  222. fail: (fail) => {},
  223. });
  224. },
  225. // getUserLocalStorageInfo
  226. async getUserPower() {
  227. let that = this;
  228. console.log('getUserLocalStorageInfo',getUserLocalStorageInfo());
  229. that.userType = getUserLocalStorageInfo().userType;
  230. if (that.userType == 3) {
  231. uni.showModal({
  232. title: "提示",
  233. cancelText: "暂不",
  234. confirmText: "去切换",
  235. content: "您还不是企业用户,请切换登录身份后再进行相关操作。",
  236. success: function (res) {
  237. if (res.confirm) {
  238. uni.navigateTo({
  239. url: "/pages/login2/login",
  240. success: function (e) {
  241. // uni.$emit('userType', 'OK')
  242. },
  243. });
  244. } else if (res.cancel) {
  245. console.log("用户点击取消");
  246. }
  247. },
  248. });
  249. }
  250. // if (getUserLocalStorageInfo().user.id == 1) return;
  251. // let newList = [];
  252. // let { data } = await getUserPower(getUserLocalStorageInfo().user.id);
  253. // for (let i = 0; i < that.mapList.length; i++) {
  254. // let index = data.findIndex((e) => e == that.mapList[i].label);
  255. // if (index != -1) {
  256. // newList.push(that.mapList[i]);
  257. // }
  258. // }
  259. // that.mapList = newList;
  260. },
  261. jumpPage(path) {
  262. uni.navigateTo({
  263. url: path,
  264. fail: (fail) => {},
  265. });
  266. },
  267. },
  268. };
  269. </script>
  270. <style lang="scss">
  271. page {
  272. background: white;
  273. }
  274. .managementBody {
  275. padding: 4vw;
  276. }
  277. .banner {
  278. width: 92vw;
  279. height: 250rpx;
  280. //position: absolute;
  281. z-index: 1;
  282. }
  283. .mapdom {
  284. width: 25%;
  285. height: 184rpx;
  286. }
  287. .maptxt {
  288. width: 100%;
  289. height: 34rpx;
  290. font-size: 24rpx;
  291. font-family: PingFang SC-Medium, PingFang SC;
  292. font-weight: 500;
  293. color: #18172a;
  294. text-align: center;
  295. margin-top: 8rpx;
  296. }
  297. .mapIcon {
  298. width: 65rpx;
  299. height: 80rpx;
  300. //background: linear-gradient(141deg, #89BCFF 0%, #2782FA 100%);
  301. display: block;
  302. margin: auto;
  303. }
  304. .map {
  305. //position: absolute;
  306. z-index: 2;
  307. width: calc(100% - 24rpx);
  308. //height: 770rpx;
  309. border-radius: 48rpx 48rpx 0rpx 0rpx;
  310. background: white;
  311. //margin-top: 402rpx;
  312. padding: 24rpx 12rpx;
  313. overflow-y: auto;
  314. }
  315. .needBox {
  316. display: flex;
  317. align-items: center;
  318. justify-content: space-between;
  319. margin: 2vw 0;
  320. .needLeft {
  321. display: flex;
  322. justify-content: space-around;
  323. background: rgba(238, 244, 255, 1);
  324. border-radius: 8rpx;
  325. align-items: center;
  326. width: 45vw;
  327. height: 23vw;
  328. }
  329. .needRight {
  330. display: flex;
  331. justify-content: space-around;
  332. background: #def6f8;
  333. border-radius: 8rpx;
  334. align-items: center;
  335. width: 45vw;
  336. height: 23vw;
  337. }
  338. .needLeftLeft {
  339. display: flex;
  340. flex-direction: column;
  341. }
  342. .needImg {
  343. width: 100rpx;
  344. height: 100rpx;
  345. }
  346. }
  347. .titleTips {
  348. display: flex;
  349. align-items: center;
  350. font-size: 4.7vw;
  351. font-weight: 600;
  352. color: #18172a;
  353. margin: 4vw 0 2vw 0;
  354. .myLine {
  355. width: 13rpx;
  356. height: 40rpx;
  357. background: linear-gradient(180deg, #509fff 0%, #034df7 100%);
  358. margin-right: 20rpx;
  359. }
  360. }
  361. </style>