zxDetail.vue 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253
  1. <template>
  2. <view class="container">
  3. <top></top>
  4. <view class="content1">
  5. <view class="left">
  6. <view class="nav-title">
  7. 首页 / 资讯 / 资讯详情
  8. </view>
  9. <view class="content-title">
  10. {{dataObj.title}}
  11. </view>
  12. <view class="ej-title">
  13. <view class="fb-time">
  14. {{dataObj.issuingDate}}
  15. </view>
  16. <view class="ly">
  17. <view class="ly-text">
  18. 来源:
  19. </view>
  20. <view class="ly-name">
  21. {{dataObj.issuingAgency}}
  22. </view>
  23. </view>
  24. </view>
  25. <u-line color="#F5F5F5" style='margin:44px 0'></u-line>
  26. <view class="" v-html="dataObj.releaseContent"></view>
  27. </view>
  28. <view class="right">
  29. <view class="right-title">
  30. <view class="">
  31. 行业资讯
  32. </view>
  33. <view class="more" @click="moreClick">
  34. 更多 >
  35. </view>
  36. </view>
  37. <view class="list">
  38. <view class="item" v-for="item in tableData">
  39. <view class="point">
  40. </view>
  41. <view class="content-text">
  42. <view class="row1">
  43. {{item.title}}
  44. </view>
  45. <view class="date">
  46. {{item.issuingDate}}
  47. </view>
  48. </view>
  49. </view>
  50. </view>
  51. </view>
  52. </view>
  53. <bottom></bottom>
  54. </view>
  55. </template>
  56. <script>
  57. import {
  58. mapState
  59. } from 'vuex';
  60. import top from '@/components/top.vue'
  61. import bottom from '@/components/bottom.vue'
  62. export default {
  63. components: {
  64. top,
  65. bottom
  66. },
  67. data() {
  68. return {
  69. navTitle: '',
  70. type: "",
  71. id: '',
  72. dataObj: {},
  73. tableData: [],
  74. pageSize: 10,
  75. // 当前页
  76. currentPage: 1,
  77. }
  78. },
  79. onLoad(options) {
  80. this.id = options.id
  81. this.init()
  82. },
  83. methods: {
  84. init() {
  85. this.$request.baseRequest('get', '/hyPublicConsultation/getHyPublicConsultation', {
  86. id: this.id,
  87. }).then(res => {
  88. console.log("res", res)
  89. if (res.code == 200) {
  90. this.dataObj = res.data
  91. uni.hideLoading()
  92. } else {
  93. uni.hideLoading()
  94. uni.showToast({
  95. title: res.message,
  96. icon: 'none',
  97. duration: 2000
  98. })
  99. }
  100. })
  101. .catch(res => {
  102. uni.showToast({
  103. title: res.message,
  104. icon: 'none',
  105. duration: 2000
  106. })
  107. });
  108. this.$request.baseRequest('get', '/hyPublicConsultation/selectHyPublicConsultation', {
  109. currentPage: this.currentPage,
  110. pageSize: this.pageSize,
  111. searchKeyWord: '',
  112. searchType: '资讯'
  113. }).then(res => {
  114. console.log("res", res)
  115. if (res.code == 200) {
  116. this.tableData = res.data.records
  117. this.total = res.data.total
  118. uni.hideLoading()
  119. } else {
  120. uni.hideLoading()
  121. uni.showToast({
  122. title: res.message,
  123. icon: 'none',
  124. duration: 2000
  125. })
  126. }
  127. })
  128. .catch(res => {
  129. uni.showToast({
  130. title: res.message,
  131. icon: 'none',
  132. duration: 2000
  133. })
  134. });
  135. },
  136. moreClick(type) {
  137. uni.navigateTo({
  138. url: "/pages/index/zx"
  139. })
  140. },
  141. }
  142. }
  143. </script>
  144. <style scoped lang="scss">
  145. .content1 {
  146. width: 80%;
  147. // background: white;
  148. margin: 80rpx auto;
  149. padding: 40rpx 0;
  150. box-sizing: border-box;
  151. display: flex;
  152. justify-content: space-between;
  153. .left {
  154. width: 65%;
  155. background: white;
  156. padding: 40rpx 80rpx;
  157. }
  158. .right {
  159. margin-left: 40rpx;
  160. width: 30%;
  161. background: white;
  162. }
  163. .nav-title {
  164. font-size: 28rpx;
  165. color: #66686C;
  166. line-height: 20px;
  167. }
  168. .content-title {
  169. display: flex;
  170. justify-content: center;
  171. font-size: 68rpx;
  172. font-weight: 500;
  173. color: #0B0B0B;
  174. line-height: 48px;
  175. margin: 40rpx 0;
  176. }
  177. .ej-title {
  178. display: flex;
  179. .ly {
  180. margin-left: 40rpx;
  181. display: flex;
  182. font-size: 28rpx;
  183. color: #A7A7A7;
  184. line-height: 40rpx;
  185. .ly-name {
  186. color: #0B0B0B
  187. }
  188. }
  189. .fb-time {
  190. font-size: 28rpx;
  191. color: #A7A7A7;
  192. line-height: 40rpx;
  193. }
  194. }
  195. .right {
  196. .right-title {
  197. background: #e9dcdc;
  198. display: flex;
  199. justify-content: space-between;
  200. padding: 10px;
  201. }
  202. .more {
  203. color: #2F54EF;
  204. }
  205. .item {
  206. border-bottom: 1px solid #F5F5F5;
  207. }
  208. .content-text {
  209. padding: 40rpx;
  210. box-sizing: border-box;
  211. .row1 {
  212. font-size: 36rpx;
  213. color: #333333;
  214. }
  215. .date {
  216. font-size: 36rpx;
  217. color: #90969B;
  218. margin-top: 10rpx;
  219. }
  220. }
  221. .item:nth-of-type(5) {
  222. border: 0;
  223. }
  224. }
  225. }
  226. </style>