index.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386
  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. >{{ handleSize }}</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. >{{ readSize }}</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, getReadSizeByTypes } from "@/js_sdk/http";
  75. import EnterpriseSide from "./components/enterpriseSide.vue";
  76. export default {
  77. components: { EnterpriseSide },
  78. data() {
  79. return {
  80. readSize: 0,
  81. handleSize: 0,
  82. userType: false,
  83. mapList: [
  84. // {
  85. // label: "智慧党建",
  86. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  87. // path: "/pages/subPackages/buildmap/index",
  88. // },
  89. // {
  90. // label: "经发填报",
  91. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  92. // path: "/pages/subPackages/companyHouse/companyHouse",
  93. // },
  94. {
  95. label: "企业库",
  96. url: "https://www.idea-co-sf.com/gardenProduct/image/qyk.png",
  97. path: "/pages/subPackages/companyHouse/companyHouse",
  98. },
  99. {
  100. label: "走访上报",
  101. url: "https://www.idea-co-sf.com/gardenProduct/image/zfsb.png",
  102. path: "/pages/subPackages/companyreport/companyreport",
  103. },
  104. {
  105. label: "资源预约",
  106. url: "https://www.idea-co-sf.com/gardenProduct/image/tupian1.png",
  107. path: "/pages/subPackages/resourceReservation_manage/index",
  108. },
  109. // {
  110. // label: "上市跟进",
  111. // url: https://www.idea-co-sf.com/gardenProduct/image/ssgj.png"),
  112. // },
  113. {
  114. label: "招商管理",
  115. url: "https://www.idea-co-sf.com/gardenProduct/image/zsgl.png",
  116. path: "/pages/subPackages/merchants/merchants",
  117. },
  118. // {
  119. // label: "活动发布",
  120. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/3@2x.png",
  121. // path: "/pages/subPackages/eventRelease/index",
  122. // },
  123. // {
  124. // label: "安全管理自检",
  125. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/8@2x.png",
  126. // path: "/pages/subPackages/secureselftest2/index",
  127. // },
  128. // {
  129. // label: "安全管理统计",
  130. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/8@2x.png",
  131. // path: "/pages/subPackages/secureselftest/index",
  132. // },
  133. // {
  134. // label: "安全自检计划",
  135. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/9@2x.png",
  136. // path: "/pages/subPackages/secureselfplan/index",
  137. // },
  138. {
  139. label: "报修受理",
  140. url: "https://www.idea-co-sf.com/gardenProduct/image/bxpd.png",
  141. path: "/pages/subPackages/todo/repairAcceptance",
  142. },
  143. // {
  144. // label: "报修处理",
  145. // url: "https://www.idea-co-sf.com/gardenProduct/image/bxcl.png",
  146. // path: "/pages/subPackages/todo/repairAcceptance",
  147. // },
  148. {
  149. label: "房间管理",
  150. url: "https://www.idea-co-sf.com/gardenProduct/image/fjgl.png",
  151. path: "/pages/subPackages/propertyManagement/maintenance",
  152. },
  153. // {
  154. // label: "园区通知",
  155. // url: "https://www.idea-co-sf.com/gardenProduct/image/tzfb.png",
  156. // // path: "",
  157. // },
  158. {
  159. label: "物业通知",
  160. url: "https://www.idea-co-sf.com/gardenProduct/image/tupian2.png",
  161. path: "/pages/subPackages/propertyNotice_manage/index?type=2",
  162. },
  163. {
  164. label: "园区通知",
  165. url: "https://www.idea-co-sf.com/gardenProduct/image/tupian2.png",
  166. path: "/pages/subPackages/propertyNotice_manage/index?type=1",
  167. },
  168. {
  169. label: "活动发布",
  170. url: "https://www.idea-co-sf.com/gardenProduct/image/hdfb.png",
  171. path: "/pages/subPackages/activityPromulgate/list",
  172. },
  173. {
  174. label: "周边发布",
  175. url: "https://www.idea-co-sf.com/gardenProduct/image/zbfb.png",
  176. path: "/pages/subPackages/surroundingReleases/index",
  177. },
  178. // {
  179. // label: "整改填报",
  180. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/15@2x.png",
  181. // path: "/pages/subPackages/modifyReport/index",
  182. // },
  183. // {
  184. // label: "整改派单",
  185. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/14@2x.png",
  186. // path: "/pages/subPackages/modifySend/index",
  187. // },
  188. // {
  189. // label: "整改处理",
  190. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/13@2x.png",
  191. // path: "/pages/subPackages/modifyHandle/index",
  192. // },
  193. // {
  194. // label: "活动核销",
  195. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  196. // path: "/pages/subPackages/activity/index",
  197. // },
  198. // {
  199. // label: "可视化大屏",
  200. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  201. // path: "/pages/subPackages/bigscreen/bigscreen",
  202. // },
  203. // {
  204. // label: "场馆审核",
  205. // url: "https://hswkxc.idea-sf.com/fileService/static/slices/1@2x.png",
  206. // path: "/pages/subPackages/venueRoom/meetingroom",
  207. // },
  208. ],
  209. };
  210. },
  211. onShareAppMessage() {},
  212. mounted() {
  213. // demo();
  214. },
  215. onShow() {
  216. this.getUserPower();
  217. this.getReadSize()
  218. },
  219. onLoad(e) {
  220. // uni.$on("userType", (userType) => {
  221. // if (userType === "OK") {
  222. // this.userType = !this.userType;
  223. // }
  224. // });
  225. },
  226. methods: {
  227. getReadSize(){
  228. const data = {
  229. userId: getUserLocalStorageInfo().userId,
  230. types: '1'
  231. }
  232. getReadSizeByTypes(data).then(res=>{
  233. this.readSize = res
  234. })
  235. },
  236. getHandleSize(){
  237. },
  238. toMsgPage(e) {
  239. uni.navigateTo({
  240. url: e,
  241. fail: (fail) => {},
  242. });
  243. },
  244. // getUserLocalStorageInfo
  245. async getUserPower() {
  246. let that = this;
  247. console.log('getUserLocalStorageInfo',getUserLocalStorageInfo());
  248. that.userType = getUserLocalStorageInfo().userType;
  249. if (that.userType == 3) {
  250. uni.showModal({
  251. title: "提示",
  252. cancelText: "暂不",
  253. confirmText: "去切换",
  254. content: "您还不是企业用户,请切换登录身份后再进行相关操作。",
  255. success: function (res) {
  256. if (res.confirm) {
  257. uni.navigateTo({
  258. url: "/pages/login2/login",
  259. success: function (e) {
  260. // uni.$emit('userType', 'OK')
  261. },
  262. });
  263. } else if (res.cancel) {
  264. console.log("用户点击取消");
  265. }
  266. },
  267. });
  268. }
  269. // if (getUserLocalStorageInfo().user.id == 1) return;
  270. // let newList = [];
  271. // let { data } = await getUserPower(getUserLocalStorageInfo().user.id);
  272. // for (let i = 0; i < that.mapList.length; i++) {
  273. // let index = data.findIndex((e) => e == that.mapList[i].label);
  274. // if (index != -1) {
  275. // newList.push(that.mapList[i]);
  276. // }
  277. // }
  278. // that.mapList = newList;
  279. },
  280. jumpPage(path) {
  281. uni.navigateTo({
  282. url: path,
  283. fail: (fail) => {},
  284. });
  285. },
  286. },
  287. };
  288. </script>
  289. <style lang="scss">
  290. page {
  291. background: white;
  292. }
  293. .managementBody {
  294. padding: 4vw;
  295. }
  296. .banner {
  297. width: 92vw;
  298. height: 250rpx;
  299. //position: absolute;
  300. z-index: 1;
  301. }
  302. .mapdom {
  303. width: 25%;
  304. height: 184rpx;
  305. }
  306. .maptxt {
  307. width: 100%;
  308. height: 34rpx;
  309. font-size: 24rpx;
  310. font-family: PingFang SC-Medium, PingFang SC;
  311. font-weight: 500;
  312. color: #18172a;
  313. text-align: center;
  314. margin-top: 8rpx;
  315. }
  316. .mapIcon {
  317. width: 65rpx;
  318. height: 80rpx;
  319. //background: linear-gradient(141deg, #89BCFF 0%, #2782FA 100%);
  320. display: block;
  321. margin: auto;
  322. }
  323. .map {
  324. //position: absolute;
  325. z-index: 2;
  326. width: calc(100% - 24rpx);
  327. //height: 770rpx;
  328. border-radius: 48rpx 48rpx 0rpx 0rpx;
  329. background: white;
  330. //margin-top: 402rpx;
  331. padding: 24rpx 12rpx;
  332. overflow-y: auto;
  333. }
  334. .needBox {
  335. display: flex;
  336. align-items: center;
  337. justify-content: space-between;
  338. margin: 2vw 0;
  339. .needLeft {
  340. display: flex;
  341. justify-content: space-around;
  342. background: rgba(238, 244, 255, 1);
  343. border-radius: 8rpx;
  344. align-items: center;
  345. width: 45vw;
  346. height: 23vw;
  347. }
  348. .needRight {
  349. display: flex;
  350. justify-content: space-around;
  351. background: #def6f8;
  352. border-radius: 8rpx;
  353. align-items: center;
  354. width: 45vw;
  355. height: 23vw;
  356. }
  357. .needLeftLeft {
  358. display: flex;
  359. flex-direction: column;
  360. }
  361. .needImg {
  362. width: 100rpx;
  363. height: 100rpx;
  364. }
  365. }
  366. .titleTips {
  367. display: flex;
  368. align-items: center;
  369. font-size: 4.7vw;
  370. font-weight: 600;
  371. color: #18172a;
  372. margin: 4vw 0 2vw 0;
  373. .myLine {
  374. width: 13rpx;
  375. height: 40rpx;
  376. background: linear-gradient(180deg, #509fff 0%, #034df7 100%);
  377. margin-right: 20rpx;
  378. }
  379. }
  380. </style>