移动端
Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.

projectDetail.vue 8.2 KiB

2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
2 anni fa
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262
  1. <template>
  2. <div class="home_wrapper">
  3. <!-- 头部开始 -->
  4. <div class="header">
  5. <div class="header_left" @click="onClickLeft">
  6. <img src="../../../../static/images/agriculturalTrusteeship/return.png">
  7. </div>
  8. <div class="header_right" @click="onClickLeft">
  9. <img src="../../../../static/images/agriculturalTrusteeship/share.png">
  10. </div>
  11. </div>
  12. <!-- 头部结束 -->
  13. <!-- 内容开始 -->
  14. <div class="main">
  15. <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white">
  16. <van-swipe-item v-for="(item,index) in supplyDemand.supplyMasterMapList" :key="index"><img :src="item"></van-swipe-item>
  17. </van-swipe>
  18. <div class="main_content">
  19. <div class="tab">
  20. <p>¥<span>{{supplyDemand.unitPrice}}</span>/{{supplyDemand.unit}}</p>
  21. <p><span>销 {{supplyDemand.orderNum}}</span><span>分 {{supplyDemand.orderScore}}</span></p>
  22. </div>
  23. <p class="tt">{{supplyDemand.supplyDemandName}}</p>
  24. <p class="name" @click="$router.push({name:'agriculturalTrusteeshipSocietyProjectList',query:{id:supplyDemand.entityId,entityName:supplyDemand.entityName}})">{{supplyDemand.entityName}}<span>{{supplyDemand.createTime}}</span></p>
  25. </div>
  26. <div class="main_box">
  27. <van-cell title="产品类型" :border="false" :value="supplyDemand.productType" />
  28. <van-cell title="产品规格" :border="false" :value="supplyDemand.specification" />
  29. <van-cell title="产品数量" :border="false" :value="supplyDemand.number" />
  30. <van-cell title="服务区域" :border="false" :value="supplyDemand.serviceDeptName" />
  31. <van-cell title="产品简介" :border="false" :value="supplyDemand.introduction" />
  32. <van-cell title="公司地址" :border="false" :value="supplyDemand.address" />
  33. </div>
  34. <div class="main_box">
  35. <van-cell title="联系人" :border="false" :value="supplyDemand.linker" />
  36. <van-cell title="联系方式" :border="false" :value="supplyDemand.supplyDemandTal" />
  37. </div>
  38. <div class="main_box" style="padding: 0;">
  39. <baidu-map :center="center" panBy="[50,50]" :zoom="zoom" :scroll-wheel-zoom="true" :pinch-to-zoom="true" map-type="BMAP_NORMAL_MAP" style="height:25vh" >
  40. <!-- 必须给容器指高度,不然地图将显示在一个高度为0的容器中,看不到 -->
  41. <bm-geolocation anchor="BMAP_ANCHOR_BOTTOM_RIGHT" :showAddressBar="true" :autoLocation="true"></bm-geolocation>
  42. <bm-marker :position="center" :dragging="true" animation="BMAP_ANIMATION_BOUNCE" :icon="{url: '../../../../static/images/lawEnforcement/new/address.gif', size: {width: 50, height: 50}}"></bm-marker>
  43. </baidu-map>
  44. </div>
  45. </div>
  46. <!-- 内容结束 -->
  47. <!-- 底部提交按钮 -->
  48. <!-- <div class="footer">-->
  49. <!-- <p>温馨提示:下单前请先与商家沟通联系</p>-->
  50. <!-- <img src="../../../../static/images/agriculturalTrusteeship/insurance/submit_shop_btn.png">-->
  51. <!-- </div>-->
  52. </div>
  53. </template>
  54. <script>
  55. import Cookies from "js-cookie";
  56. import {productTypes, supplyDemandGet} from "@/api/agriculturalTrusteeship";
  57. export default {
  58. name: "agriculturalTrusteeshipInsuranceDetail",
  59. data() {
  60. return {
  61. activeKey: 0,
  62. active: 0,
  63. loading: false,
  64. finished: false,
  65. center: { lng: 122.089726, lat: 37.540728 }, //经纬度
  66. zoom: 15, //地图展示级别
  67. supplyDemand:{},
  68. projectTypeOptions:[],
  69. productList:[],
  70. productList1:[],
  71. demandTypeOptions:[],
  72. productTypeOptions:[],
  73. supplyMasterMapArr:[],
  74. bodyTypeOptions:[],
  75. };
  76. },
  77. created() {
  78. let query = {
  79. parentId : null,
  80. tree:true
  81. }
  82. let query1 = {
  83. parentId : null,
  84. tree : false
  85. }
  86. productTypes(query).then(response => {
  87. this.productList = response.data;
  88. });
  89. productTypes(query1).then(response => {
  90. this.productList1 = response.data;
  91. });
  92. this.getDicts("newBusinessEntity_statistics_project").then(response => {
  93. for (var i = 0; i < response.data.length; i++) {
  94. this.projectTypeOptions.push({text: response.data[i].dictLabel, value: response.data[i].dictValue});
  95. }
  96. this.bodyTypeOptions = response.data;
  97. });
  98. this.getDetail();
  99. },
  100. methods: {
  101. getDetail(){
  102. supplyDemandGet(this.$route.query.id).then(response => {
  103. response.data.bodyType = this.selectDictLabel(this.bodyTypeOptions, response.data.bodyType);
  104. response.data.productType = this.productList1.filter(function (e) { return e.id == response.data.productType; })[0].dictName;
  105. response.data.createTime = response.data.createTime.substr(0,10)
  106. if (response.data.supplyMasterMap){
  107. response.data.supplyMasterMapList = [];
  108. var attachement = response.data.supplyMasterMap.split( "," );
  109. this.supplyMasterMapArr = response.data.supplyMasterMap.split( "," );
  110. attachement.forEach(responseAttach=>{
  111. response.data.supplyMasterMapList.push('/api' + responseAttach);
  112. })
  113. }
  114. this.supplyDemand = response.data;
  115. });
  116. },
  117. },
  118. }
  119. </script>
  120. <style scoped lang="scss">
  121. .home_wrapper{
  122. padding-bottom: 15vh;
  123. }
  124. /*头部*/
  125. .header{
  126. display: flex;
  127. align-items: center;
  128. justify-content: space-between;
  129. padding: 2vh 4% 2vh;
  130. position: absolute;
  131. top: 0;
  132. z-index: 99999999;
  133. width: 100%;
  134. .header_left{
  135. display: flex;
  136. align-items: center;
  137. p{
  138. font-size: .4rem;
  139. color: #ffffff;
  140. line-height: 1;
  141. margin-left: 10PX;
  142. }
  143. }
  144. .header_right{
  145. }
  146. }
  147. /* 内容 */
  148. .main{
  149. .my-swipe{
  150. height: 250PX;
  151. img{
  152. width: 100%;
  153. height: 100%;
  154. }
  155. }
  156. .my-swipe .van-swipe-item {
  157. color: #fff;
  158. font-size: 20px;
  159. text-align: center;
  160. }
  161. .main_content{
  162. background: #ffffff;
  163. padding: 2vh 4%;
  164. width: 92%;
  165. margin: 0 auto;
  166. border-radius: 10PX;
  167. margin-top: 2vh;
  168. box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);
  169. .tt{
  170. font-size: .4rem;
  171. margin-bottom: 10PX;
  172. }
  173. .name{
  174. color: #4E7FFF;
  175. background: url("../../../../static/images/agriculturalTrusteeship/index/name_icon.png") no-repeat left center;
  176. padding-left: 18PX;
  177. display: flex;
  178. span{
  179. color: #334281;
  180. margin-left: auto;
  181. padding:0 0 0 18PX;
  182. background: url("../../../../static/images/agriculturalTrusteeship/socialization/socialization_icon_clock.png") no-repeat left center
  183. }
  184. }
  185. .tab{
  186. display: flex;
  187. justify-content: space-between;
  188. align-items: center;
  189. margin-bottom: 10PX;
  190. p{
  191. &:nth-child(1){
  192. flex: 1;
  193. color: #FF5E00;
  194. span{
  195. font-size: .45rem;
  196. }
  197. }
  198. &:nth-child(2){
  199. span{
  200. display: inline-block;
  201. text-align: center;
  202. padding: 2PX 10PX;
  203. &:nth-child(1){
  204. color: #497CE8;
  205. background: #E2E9FD;
  206. border-top-left-radius: 10PX;
  207. }
  208. &:nth-child(2){
  209. color: #ffffff;
  210. background-image: linear-gradient(to right , #5D87FA , #5FD5F5);
  211. border-bottom-right-radius: 10PX;
  212. }
  213. }
  214. }
  215. }
  216. }
  217. }
  218. .main_box{
  219. width: 92%;
  220. margin: 0 auto;
  221. margin-top: 2vh;
  222. border-radius: 10PX;
  223. box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);
  224. overflow: hidden;
  225. background-color: #FFF;
  226. padding: 2vh 4%;
  227. /deep/ .van-cell{
  228. padding: 0;
  229. margin-bottom: 10PX;
  230. &:last-child{
  231. margin-bottom: 0;
  232. }
  233. }
  234. }
  235. }
  236. .footer{
  237. display: flex;
  238. justify-content: space-between;
  239. align-items: center;
  240. background: #ffffff;
  241. position: fixed;
  242. bottom: 0;
  243. padding: 1vh 4%;
  244. width: 100%;
  245. p{
  246. color: #989898;
  247. background: #F2F2F2;
  248. padding: 5PX 10PX;
  249. text-align: center;
  250. border-radius: 8PX;
  251. }
  252. }
  253. </style>