project_detail.vue 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337
  1. <template>
  2. <view class="wrap">
  3. <view class="serve_title">
  4. <view class="company">
  5. <view class="iconfont company_icon"></view>
  6. {{allData.providerName}}
  7. </view>
  8. <view class="fuwu_title">{{allData.name}}</view>
  9. <view class="add">
  10. <view class="add_lf">服务有效期:</view>
  11. <view class="add_lf" v-if="allData.validityDateFormat != ''">有效期至{{allData.validityDateFormat}}</view>
  12. <view class="add_lf" v-else>长期有效</view>
  13. </view>
  14. <view class="add">
  15. <view class="add_lf">服务预约:</view>
  16. <view class="add_lf" v-if="allData.aheadDays != ''">提前{{allData.aheadDays}}天预约</view>
  17. <view class="add_lf" wx:else>无需预约</view>
  18. </view>
  19. <view class="fuwu_jianjie">
  20. <view class="fuwu_title2">服务次数:{{allData.serviceTime}}</view>
  21. <view class="fuwu_title3"><text class="dis">¥{{allData.disPrice}}元</text> <text class="price">¥{{allData.price}}元</text></view>
  22. </view>
  23. </view>
  24. <!-- 空白 -->
  25. <view class="back"></view>
  26. <!-- 图文详情 -->
  27. <view class="detail">
  28. <view class="detail_line">
  29. <view class="detail_title">图文详情</view>
  30. </view>
  31. <view class="detail_content">
  32. <view>{{allData.serviceIntroduce}}</view>
  33. <image v-for="item,index in allData.imgList" :key="index" :src="url + item" mode="widthFix" class="fuwu_banner_img"></image>
  34. </view>
  35. </view>
  36. <!-- 底部 -->
  37. <view class="footer">
  38. <navigator open-type="reLaunch" url="../../serviceView/serviceView" hover-class="none" class="to_index">
  39. <view class="iconfont back_index"></view>
  40. </navigator>
  41. <navigator v-if="allData.isEnter == 0" url="" class="ruzhu" hover-class="none">免费入驻</navigator>
  42. <navigator v-if="allData.isEnter == 1 && allData.isAuthInfo == 0" hover-class="none" class="ruzhu"url="">去认证</navigator>
  43. <navigator v-if="allData.isEnter == 1 && allData.isAuthInfo == 1 && allData.isPay == 0" url="" class="ruzhu" hover-class="none">去认证</navigator>
  44. <view v-if="allData.isEnter == 1 && allData.isAuthInfo == 1 && allData.isPay == 1 && allData.isAuthStatus == 0" class="ruzhu" @tap="audit">审核中</view>
  45. <navigator v-if="allData.isEnter == 1 && allData.isAuthInfo == 1 && allData.isPay == 1 && allData.isAuthStatus == 1" url="" class="ruzhu" hover-class="none">未通过</navigator>
  46. <navigator v-if="allData.isEnter == 1 && allData.isAuthInfo == 1 && allData.isPay == 1 && allData.isAuthStatus == 2 && allData.roleType == 1" url="" class="ruzhu" hover-class="none">店铺管理</navigator>
  47. <navigator v-if="allData.isEnter == 1 && allData.isAuthInfo == 1 && allData.isPay == 1 && allData.isAuthStatus == 2 && allData.roleType == 2" url="" class="ruzhu" hover-class="none">店铺管理</navigator>
  48. </view>
  49. <!-- 蒙版 删除按钮点击触发 -->
  50. <view :class="['masking',isMask === 1?'showMask':'']">
  51. <view class="delete_wrap">
  52. <view class="wrap_top">{{message}}</view>
  53. <view class="wrap_bom">
  54. <view class="wrap_bom_lf" @tap="cancel">取消</view>
  55. <view class="confirm" @tap="confirmDelete">{{confirm}}</view>
  56. </view>
  57. </view>
  58. </view>
  59. </view>
  60. </template>
  61. <script>
  62. let app = getApp();
  63. import api from "../../../../../api.js";
  64. export default {
  65. data() {
  66. return {
  67. url:app.globalData.url,
  68. token:app.globalData.token,
  69. id:'',//服务项目id
  70. allData:null,//页面数据
  71. isMask:0,//蒙版是否显示
  72. message:'',//蒙版显示信息
  73. confirm:'',//按钮内容
  74. }
  75. },
  76. onLoad(options) {
  77. this.id = options.id;
  78. this.getData();
  79. },
  80. methods: {
  81. // 加载数据
  82. getData(){
  83. let data = {
  84. id:this.id,
  85. token:app.globalData.token
  86. }
  87. api.getShopProjectDetail(data).then((res)=>{
  88. console.log(res);
  89. this.allData = res.data.data;
  90. })
  91. },
  92. //审核中
  93. audit(){
  94. this.message = '认证审核中,请耐心等待。';
  95. this.confirm = '关闭',
  96. this.isMask = 1
  97. },
  98. //取消按钮
  99. cancel() {
  100. this.isMask = 0
  101. },
  102. //确认删除按钮
  103. confirmDelete() {
  104. let value = this.confirm;
  105. if(value == '去完善'){
  106. }else{
  107. this.isMask = 0
  108. }
  109. }
  110. }
  111. }
  112. </script>
  113. <style>
  114. page{
  115. width:100%;
  116. height:100%;
  117. }
  118. .fuwu_list_detail{
  119. width:100%;
  120. overflow: hidden;
  121. margin-top:14rpx;
  122. }
  123. .company{
  124. color:#666666;
  125. font-size: 26rpx;
  126. margin-left: 32rpx;
  127. }
  128. .company_icon{
  129. display: inline-block;
  130. font-size: 28rpx;
  131. color:#979797;
  132. }
  133. .fuwu_jianjie{
  134. width:100%;
  135. overflow: hidden;
  136. padding:0 30rpx;
  137. box-sizing: border-box;
  138. margin-top:10rpx;
  139. display: flex;
  140. justify-content: space-between;
  141. }
  142. .fuwu_title{
  143. color:#2A2A2A;
  144. font-size:32rpx;
  145. font-weight: bold;
  146. line-height: 36rpx;
  147. margin-top:10rpx;
  148. text-indent: 30rpx;
  149. }
  150. .fuwu_title2{
  151. font-size: 28rpx;
  152. color:#2A2A2A;
  153. line-height: 36rpx;
  154. }
  155. .fuwu_title3{
  156. line-height: 36rpx;
  157. }
  158. .dis{
  159. font-size: 36rpx;
  160. color:#E11521;
  161. font-weight: bold;
  162. }
  163. .price{
  164. font-size: 24rpx;
  165. color: #999999;
  166. text-decoration: line-through;
  167. display: inline-block;
  168. margin-left: 14rpx;
  169. }
  170. .fuwu_banner{
  171. width:100%;
  172. padding:0 30rpx 42rpx;
  173. margin-top:30rpx;
  174. box-sizing: border-box;
  175. }
  176. .fuwu_banner_img{
  177. display: block;
  178. width:100%;
  179. height:100%;
  180. }
  181. .back{
  182. width:100%;
  183. height:20rpx;
  184. background-color: #F7F7F7;
  185. }
  186. .detail{
  187. width:100%;
  188. min-height:600rpx;
  189. overflow: hidden;
  190. padding:0 30rpx 100rpx;
  191. box-sizing: border-box;
  192. position: relative;
  193. }
  194. .detail_line{
  195. width:320rpx;
  196. height:2rpx;
  197. background-color:#f2f2f2;
  198. position: relative;
  199. margin:54rpx auto 0;
  200. }
  201. .detail_title{
  202. font-size: 30rpx;
  203. color:#222222;
  204. padding:0 20rpx;
  205. background-color: #ffffff;
  206. position: absolute;
  207. top:-20rpx;
  208. left:50%;
  209. transform: translateX(-50%);
  210. }
  211. .detail_content{
  212. width:100%;
  213. overflow: hidden;
  214. margin-top:54rpx;
  215. min-height: 100rpx;
  216. }
  217. .detail_content view{
  218. font-size: 28rpx;
  219. color:#666666;
  220. line-height: 48rpx;
  221. }
  222. .detail_content image{
  223. display: block;
  224. width:100%;
  225. margin:40rpx 0 30rpx 0;
  226. }
  227. .footer{
  228. width:100%;
  229. height:100rpx;
  230. background:rgba(255,255,255,1);
  231. box-shadow:0px 4rpx 8rpx 0px rgba(0,0,0,0.5);
  232. position: fixed;
  233. left:0;
  234. bottom:0;
  235. padding:0 30rpx;
  236. box-sizing: border-box;
  237. overflow: hidden;
  238. }
  239. .to_index{
  240. width:calc(100% - 284rpx);
  241. height:100%;
  242. line-height: 100rpx;
  243. text-align: center;
  244. float:left;
  245. }
  246. .back_index{
  247. font-size: 40rpx;
  248. color:#222222;
  249. }
  250. .ruzhu{
  251. width:284rpx;
  252. height:72rpx;
  253. background:rgba(231,120,23,1);
  254. border-radius:6rpx;
  255. color:#ffffff;
  256. text-align: center;
  257. line-height: 72rpx;
  258. font-size: 30rpx;
  259. float:right;
  260. margin-top:14rpx;
  261. }
  262. .masking{
  263. width:100%;
  264. height:100%;
  265. background:rgba(0,0,0,0.5);
  266. position: absolute;
  267. top:0;
  268. left:0;
  269. z-index:100;
  270. display: none;
  271. }
  272. .showMask{
  273. display: block;
  274. }
  275. .delete_wrap{
  276. width:600rpx;
  277. height:260rpx;
  278. background:rgba(255,255,255,1);
  279. border-radius:10rpx;
  280. position: fixed;
  281. top:50%;
  282. left:50%;
  283. transform: translate(-50%,-50%);
  284. }
  285. .wrap_top{
  286. font-size: 32rpx;
  287. color:#000000;
  288. font-weight: bold;
  289. text-align: center;
  290. height:152rpx;
  291. line-height: 152rpx;
  292. border-bottom:1px solid #F2F2F2;
  293. box-sizing: border-box;
  294. }
  295. .wrap_bom_lf{
  296. width:50%;
  297. border-right: 1px solid #f2f2f2;
  298. box-sizing: border-box;
  299. font-size: 32rpx;
  300. color:#222222;
  301. font-weight: bold;
  302. text-align: center;
  303. line-height: 106rpx;
  304. display: inline-block;
  305. }
  306. .confirm{
  307. width:50%;
  308. display: inline-block;
  309. text-align: center;
  310. line-height: 106rpx;
  311. font-size: 32rpx;
  312. color:#E77817;
  313. font-weight: bold;
  314. }
  315. .wrap{
  316. width:100%;
  317. height:100%;
  318. position: relative;
  319. }
  320. .add{
  321. width: 100%;
  322. overflow: hidden;
  323. padding: 0 30rpx;
  324. box-sizing: border-box;
  325. margin-top: 10rpx;
  326. display: flex;
  327. justify-content: space-between;
  328. }
  329. .add_lf{
  330. font-size: 28rpx;
  331. color: #2A2A2A;
  332. }
  333. </style>