index.vue 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475
  1. <template>
  2. <view class="content">
  3. <view class="page-section-spacing" style="width: 100%;">
  4. <swiper class="swiper"
  5. indicator-dots="true"
  6. autoplay="true"
  7. duration="500"
  8. style="height:400rpx">
  9. <swiper-item v-for="(item , index) in swiperList" :key="index">
  10. <image :src="item.pic_path" mode="aspectFill" style="width: 100%;height: 100%;"></image>
  11. </swiper-item>
  12. </swiper>
  13. </view>
  14. <view class="page-nav-box">
  15. <navigator v-for="(item , index) in navList" :key="index" :url="item.path" open-type="navigate" class="nav-content">
  16. <image :src="item.url" mode="aspectFit" style="width: 38px;height: 38px;"></image>
  17. <view>{{item.content}}</view>
  18. </navigator>
  19. </view>
  20. <view class="notice-box">
  21. <view class="notice-title-box">
  22. <view class="notice-font">通知公告</view>
  23. <view class="notice-more-font">
  24. <view style="margin-right: 8rpx;font-size: 22rpx;">更多</view>
  25. <image src="../../static/right-arrow-blue.png" mode="aspectFill" style="width: 12rpx;height: 16rpx;"></image>
  26. </view>
  27. </view>
  28. <view class="notice-content-box" v-for="(item , index) in noticeList" :key="index">
  29. <image :src="item.url" mode="aspectFit" style="width:34px;height:34px;"></image>
  30. <view class="notice-content display-around-column">
  31. <view class="notice-content-font">{{item.title}}</view>
  32. <view class="notice-content-time">{{item.time}}</view>
  33. </view>
  34. </view>
  35. </view>
  36. <view class="notice-box" style="margin-top: 40rpx;">
  37. <view class="notice-title-box">
  38. <view class="notice-font">推荐园区</view>
  39. <view class="notice-more-font">
  40. <view style="margin-right: 8rpx;font-size: 22rpx;">更多</view>
  41. <image src="/static/right-arrow-blue.png" mode="aspectFill" style="width: 12rpx;height: 16rpx;"></image>
  42. </view>
  43. </view>
  44. <view class="display-flex-start" style=" overflow:scroll;position:relative">
  45. <view class="park-box" v-for="(item , index) in parkList" :key="index">
  46. <image :src="item.url" mode="aspectFill" style="width:452rpx;height:250rpx;border-radius:32rpx 32rpx 0 0;"></image>
  47. <view class="park-content-box">
  48. <view class="park-title">{{item.title}}</view>
  49. <view class="park-address display-flex-start">
  50. <view class="display-flex-start" style="margin-right: 10rpx;"><image src="/static/park/park-time.png" mode="aspectFill" class="park-title-img"></image>{{item.time}}建成</view>
  51. <view class="display-flex-start"><image src="/static/park/park-name.png" mode="aspectFill" class="park-title-img"></image>{{item.title}}</view>
  52. </view>
  53. <view class="park-footer-box display-between">
  54. <view class="display-between-column width-30">
  55. <view class="display-flex-start"><image src="/static/park/park-num.png" mode="aspectFill" class="park-footer-img"></image>{{item.num}}</view>
  56. <view class="park-footer-font">企业数量</view>
  57. </view>
  58. <view class="display-between-column width-30">
  59. <view class="display-flex-start">
  60. <image src="/static/park/park-area.png" mode="aspectFill" class="park-footer-img"></image>
  61. {{item.area1}}<text style="font-size: 12rpx;">万㎡</text></view>
  62. <view class="park-footer-font">占地面积</view>
  63. </view>
  64. <view class="display-between-column width-30">
  65. <view class="display-flex-start">
  66. <image src="/static/park/park-area2.png" mode="aspectFill" class="park-footer-img"></image>
  67. {{item.area2}}<text style="font-size: 12rpx;">万㎡</text></view>
  68. <view class="park-footer-font">建设面积</view>
  69. </view>
  70. </view>
  71. </view>
  72. </view>
  73. </view>
  74. </view>
  75. <view class="notice-box" style="margin-top:20rpx;">
  76. <view class="notice-title-box">
  77. <view class="notice-font">招商专区</view>
  78. <view class="notice-more-font">
  79. <view style="margin-right: 8rpx;font-size: 22rpx;">更多</view>
  80. <image src="/static/right-arrow-blue.png" mode="aspectFill" style="width: 12rpx;height: 16rpx;"></image>
  81. </view>
  82. </view>
  83. <view class="notice-content-box" v-for="(item , index) in attractList" :key="index" style="justify-content: start;">
  84. <image :src="item.url" mode="aspectFit" style="width:112rpx;height:112rpx;margin-right: 20rpx;"></image>
  85. <view class="notice-content">
  86. <view class="notice-content-font">{{item.title}}</view>
  87. <view class="attract-content">{{item.subtitle}}</view>
  88. <view class="notice-content-time" style="margin-top: 20rpx;">{{item.time}}</view>
  89. </view>
  90. </view>
  91. </view>
  92. <view class="notice-box" style="margin-top:20rpx;">
  93. <view class="notice-title-box">
  94. <view class="notice-font">区内活动</view>
  95. <view class="notice-more-font">
  96. <view style="margin-right: 8rpx;font-size: 22rpx;">更多</view>
  97. <image src="/static/right-arrow-blue.png" mode="aspectFill" style="width: 12rpx;height: 16rpx;"></image>
  98. </view>
  99. </view>
  100. <view class="notice-content-box" v-for="(item , index) in activityList" :key="index" style="justify-content: start;padding: 30rpx 0 30rpx 30rpx;">
  101. <image :src="item.url" mode="aspectFit" style="width:128rpx;height:128rpx;margin-right: 20rpx;"></image>
  102. <view class="notice-content" style="width: 70%;">
  103. <view class="notice-content-font" style="white-space: break-spaces;">{{item.title}}</view>
  104. <view class="display-flex-start" style="margin-top: 20rpx;">
  105. <view class="notice-content-time display-flex-start color-a7adba" v-show="item.isOnline"><view class="online-box"></view>线上</view>
  106. <view class="notice-content-time display-flex-start color-a7adba" v-show="!item.isOnline"><view class="offline-box"></view>线下</view>
  107. <view class="notice-content-time color-a7adba" >{{item.department}}</view>
  108. <view class="notice-content-time color-a7adba" >{{item.time}}</view>
  109. </view>
  110. <view class="display-flex-end" style="margin-top: 20rpx;">
  111. <view class="notice-content-time">浏览 {{item.browe}}</view>
  112. <view class="notice-content-time">分享 {{item.share}}</view>
  113. </view>
  114. </view>
  115. </view>
  116. </view>
  117. </view>
  118. </template>
  119. <script>
  120. import md5 from '@/common/md5.js';
  121. export default {
  122. data() {
  123. return {
  124. swiperList:[
  125. {
  126. img:'/static/swiper/swiper1.jpg'
  127. },
  128. {
  129. img:'/static/swiper/swiper2.jpg'
  130. },
  131. ],
  132. navList:[
  133. {
  134. url:'/static/navList/appeal.png',
  135. path:'/pages/appeal/index',
  136. content:'提诉求'
  137. },
  138. {
  139. url:'/static/navList/policy.png',
  140. path:'/pages/policy/index',
  141. content:'搜政策'
  142. },
  143. {
  144. url:'/static/navList/park.png',
  145. path:'/pages/park/index',
  146. content:'找园区'
  147. },
  148. {
  149. url:'/static/navList/activity.png',
  150. path:'/pages/activity/index',
  151. content:'找活动'
  152. },
  153. {
  154. url:'/static/navList/supply.png',
  155. path:'/pages/supply/index',
  156. content:'发供需'
  157. },
  158. {
  159. url:'/static/navList/enterprise.png',
  160. path:'/pages/enterprise/index',
  161. content:'查企业'
  162. },
  163. {
  164. url:'/static/navList/service.png',
  165. path:'/pages/service/index',
  166. content:'找服务'
  167. },
  168. ],
  169. noticeList:[
  170. {
  171. url:'/static/navList/policy-icon.png',
  172. title:'政策速览 | 小微企业、个体工商户税费...',
  173. time:'2021-08-05'
  174. },
  175. {
  176. url:'/static/navList/activity-icon.png',
  177. title:'活动预告 | 想了解跨境电商?8月5日带...',
  178. time:'2021-08-04'
  179. },
  180. {
  181. url:'/static/navList/policy-icon.png',
  182. title:'政策速览 | 2022年首批次重点新材料扶...',
  183. time:'2021-08-03'
  184. },
  185. ],
  186. parkList:[
  187. {
  188. url:'/static/park/1.png',
  189. title:'华潮科技产业园',
  190. time:'2015-10-25',
  191. num:484,
  192. area1:1.72,
  193. area2:1.01
  194. },
  195. {
  196. url:'/static/park/1.png',
  197. title:'华潮科技产业园',
  198. time:'2015-10-25',
  199. num:484,
  200. area1:1.72,
  201. area2:1.01
  202. },
  203. {
  204. url:'/static/park/1.png',
  205. title:'华潮科技产业园',
  206. time:'2015-10-25',
  207. num:484,
  208. area1:1.72,
  209. area2:1.01
  210. },
  211. ],
  212. attractList:[
  213. {
  214. url:'/static/attract/1.png',
  215. title:'工业互联网',
  216. subtitle:'工业互联网是全球工业系统与高级计算、分析、...',
  217. time:'2021-09-05'
  218. },
  219. {
  220. url:'/static/attract/2.png',
  221. title:'生产性服务业',
  222. subtitle:'生产性服务业是指为保持工业生产过程的连续性...',
  223. time:'2021-09-05'
  224. },
  225. ],
  226. activityList:[
  227. {
  228. url:'/static/activity/2.png',
  229. title:'400场讲座,200门课程,免费送上门!就等你申请',
  230. isOnline:1,
  231. department:'区人力资源局',
  232. time:'2021-09-05',
  233. browe:'322',
  234. share:'2'
  235. },
  236. {
  237. url:'/static/activity/1.png',
  238. title:'智能制造商标品牌培育系列培训活动',
  239. isOnline:0,
  240. department:'市场监督管理局',
  241. time:'2021-09-05',
  242. browe:'322',
  243. share:'2'
  244. },
  245. ],
  246. }
  247. },
  248. onLoad() {
  249. this.getSwiperList()
  250. },
  251. methods: {
  252. getSwiperList(){
  253. let md5Sign = md5("method="+'common'+"&timestamp="+getApp().globalData.globalTimestamp+"&secret="+getApp().globalData.secret)
  254. let url = getApp().globalData.shareUrl+'api/api.php'+'?method=common&source=main_pics&action=list&timestamp='+getApp().globalData.globalTimestamp +'&sign='+md5Sign
  255. uni.request({
  256. url:url,
  257. method: 'POST',
  258. header: {
  259. 'content-type': 'application/x-www-form-urlencoded'
  260. },
  261. data: {
  262. size:5,
  263. page:1,
  264. s_status:1
  265. },
  266. success: (res) => {
  267. console.log(res)
  268. if(res.data.code === 200){
  269. res.data.data.list.forEach((item)=>{item.pic_path = getApp().globalData.shareUrl + item.pic_path})
  270. this.swiperList = res.data.data.list;
  271. }
  272. },
  273. fail: () => {
  274. console.log("连接失败");
  275. }
  276. });
  277. }
  278. }
  279. }
  280. </script>
  281. <style>
  282. .content {
  283. display: flex;
  284. flex-direction: column;
  285. align-items: center;
  286. justify-content: center;
  287. }
  288. .logo {
  289. height: 200rpx;
  290. width: 200rpx;
  291. margin-top: 200rpx;
  292. margin-left: auto;
  293. margin-right: auto;
  294. margin-bottom: 50rpx;
  295. }
  296. .text-area {
  297. display: flex;
  298. justify-content: center;
  299. }
  300. .title {
  301. font-size: 36rpx;
  302. color: #8f8f94;
  303. }
  304. .page-nav-box {
  305. width: 80%;
  306. /* height: 320rpx; */
  307. display: flex;
  308. flex-wrap: wrap;
  309. padding: 20rpx 10rpx 30rpx 10rpx;
  310. box-shadow: 0px 2px 16px rgba(0, 0, 0, 0.1);
  311. border-radius: 32rpx;
  312. position: absolute;
  313. top: 300rpx;
  314. background-color: #fff;
  315. }
  316. .nav-content {
  317. width: 25%;
  318. height: 130rpx;
  319. display: flex;
  320. flex-direction: column;
  321. align-items: center;
  322. margin-top: 20rpx;
  323. font-size: 22rpx;
  324. justify-content: space-around;
  325. letter-spacing: 0.02em;
  326. color: #0D1937;
  327. font-family: PingFang SC;
  328. font-style: normal;
  329. font-weight: 600;
  330. }
  331. .notice-box{
  332. width: 83%;
  333. margin-top: 300rpx;
  334. margin-bottom:20rpx;
  335. }
  336. .notice-title-box{
  337. width: 100%;
  338. display: flex;
  339. justify-content: space-between;
  340. align-items: center;
  341. margin-bottom:40rpx;
  342. }
  343. .notice-font {
  344. font-family: PingFang SC;
  345. font-style: normal;
  346. font-weight: 600;
  347. font-size: 32rpx;
  348. letter-spacing: 0.02em;
  349. color: #0D1937;
  350. }
  351. .notice-more-font {
  352. font-size: 24rpx;
  353. color: #146AFB;
  354. display: flex;
  355. align-items: center;
  356. }
  357. .notice-content-box {
  358. display: flex;
  359. padding: 30rpx;
  360. background-color: #FFFFFF;
  361. box-shadow: 0px 4rpx 32rpx rgba(0, 0, 0, 0.1);
  362. border-radius: 32rpx;
  363. margin-top: 20rpx;
  364. justify-content: space-between;
  365. }
  366. .notice-content-font {
  367. font-size:26rpx;
  368. color: #0D1937;
  369. font-weight: 600;
  370. overflow: hidden;
  371. text-overflow: ellipsis;
  372. white-space: nowrap;
  373. }
  374. .notice-content-time {
  375. font-size: 18rpx;
  376. letter-spacing: 0.02em;
  377. color: #CFCFCF;
  378. margin-right: 14rpx;
  379. }
  380. .park-box {
  381. border-radius: 32rpx;
  382. margin-right: 20rpx;
  383. position: relative;
  384. height: 450rpx;
  385. }
  386. .park-content-box {
  387. width: 394rpx;
  388. background-color: #FFFFFF;
  389. border-radius: 56rpx 0px 32rpx 32rpx;
  390. position: absolute;
  391. top: 210rpx;
  392. font-size: 24rpx;
  393. padding: 30rpx;
  394. box-shadow: 0px 2px 16px rgba(0, 0, 0, 0.1);
  395. }
  396. .park-title {
  397. font-weight: 600;
  398. line-height: 36rpx;
  399. letter-spacing: 0.02em;
  400. color: #0D1937;
  401. }
  402. .park-address {
  403. font-weight: 600;
  404. font-size: 19rpx;
  405. letter-spacing: 0.02em;
  406. color: #CFCFCF;
  407. margin-top: 10rpx;
  408. }
  409. .park-title-img {
  410. width: 16rpx;
  411. height: 16rpx;
  412. margin-right: 4rpx;
  413. }
  414. .park-footer-box {
  415. margin-top: 30rpx;
  416. }
  417. .park-footer-img{
  418. width: 24rpx;
  419. height: 24rpx;
  420. margin-right: 6rpx;
  421. }
  422. .park-footer-font {
  423. color: #CFCFCF;
  424. font-size: 19rpx;
  425. margin-top: 10rpx;
  426. }
  427. .width-30 {
  428. width: 30%;
  429. }
  430. .attract-content {
  431. color: #697594;
  432. font-weight: 600;
  433. font-size: 20rpx;
  434. margin-top: 8rpx;
  435. overflow: hidden;
  436. text-overflow: ellipsis;
  437. white-space: nowrap;
  438. }
  439. .online-box {
  440. width: 12rpx;
  441. height: 12rpx;
  442. border-radius: 50%;
  443. background-color:#589CFF;
  444. margin-right:5rpx;
  445. }
  446. .offline-box {
  447. width: 12rpx;
  448. height: 12rpx;
  449. border-radius: 50%;
  450. background-color:#FFCF86;
  451. margin-right:5rpx;
  452. }
  453. .color-a7adba{
  454. color: #A7ADBA;
  455. }
  456. </style>