123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483 |
- <template>
- <view class="orderDetail">
- <view class="orderHeader">
- <!-- 手机状态栏占位 -->
- <view class="statusBar" :style="{height:statusBarHeight+'rpx'}"></view>
- <!-- 导航栏 -->
- <view class="navigationBar" :style="{height:navigationBarHeight,paddingTop:statusBarHeight+'rpx'}">
- <view @tap="goBack">
- <image :src="require('../../../../static/backw.png')" alt="">
- </view>
- <view class="navigationTitle">
- 订单详情
- </view>
- </view>
- <view class="headerBody" @click="toPath">
- <view>
- <view class="serveBody">
- <image :src="require('../../../../static/che.png')" alt="">
- <view class="serveTitle">
- {{orderData.status==1?'待服务':orderData.status==2?'提车中':orderData.status==3?'作业中':orderData.status==4?'作业完成待支付':orderData.status==5?'作业完成已支付':orderData.status==6?'已完成':'已取消'}}
- </view>
- </view>
- <view class="reserve">
- 预约时间:{{orderData.time}}
- </view>
- </view>
- <image class="more" :src="require('../../../../static/more-w.png')" alt="">
- </view>
- </view>
- <view class="orderBody">
- <view class="orderDetail">
- <view class="carHeader">
- 预约信息
- </view>
- <view class="carView">
- <image :src="baseImagePath+orderData.carLogo" alt="">
- <view class="carBody">
- <view class="carTitle">
- <image :src="require('../../../../static/car.png')" alt="">
- <span>{{orderData.carNumber}}</span>
- <view class="border"></view>
- <span>{{orderData.carMadelLevel}}</span>
- </view>
- <view class="content">
- {{orderData.carTypeName}}
- </view>
- </view>
- </view>
- <view class="shop">
- <view>
- 服务门店:{{orderData.shopName}}
- </view>
- </view>
- <view class="times">
- <view>
- 服务方式:{{orderData.serviceType==1?'在店下单':'上门提车'}}
- </view>
- </view>
- <view class="times" v-if="orderData.remarks">
- <view>
- 预约备注:{{orderData.remarks}}
- </view>
- </view>
- </view>
- <view class="explain">
- <view class="serveHeader">
- 服务项目
- </view>
- <view class="serveBodys" v-for="(item, index) in orderData.repairOrderServicesVO" :key="index">
- <view class="leftView">
- <view class="dian"></view>
- <view class="title">
- {{item.goodsName}}
- </view>
- </view>
- <view class="rightView" v-if="item.oneName !== null">
- {{item.oneName}}
- </view>
- </view>
- </view>
- <view style="height: 240rpx;"></view>
- </view>
- <view class="buttomBtn" v-if="orderData.status==4 || orderData.status==5 || orderData.status==6">
- <view class="inventory" @click="toRouter(orderData.id)">
- 费用清单
- </view>
- </view>
- </view>
- </template>
- <script>
- import {
- orderDetail
- } from "@/api/maintain.js"
- export default {
- components: {},
- data: function() {
- return {
- baseImagePath:this.baseImagePath,
- serveList: [{
- name: "常规检查",
- subTitle: "全车48项检测",
- },
- {
- name: "机械维修",
- subTitle: "机械维修",
- },
- {
- name: "常规检查",
- subTitle: "全车48项检测",
- },
- {
- name: "常规检查",
- subTitle: "机械维修",
- },
- ],
- orderData: {},
- statusBarHeight: "",
- navigationBarHeight: "",
- navHeight: ""
- }
- },
- onLoad(options) {
- console.log(options);
- this.orderData = JSON.parse(decodeURIComponent(options.data));
- orderDetail({id:this.orderData.id}).then((res)=>{
- this.orderData= res.data;
- console.log(this.orderData);
- })
- // 状态栏高度
- this.statusBarHeight = uni.getSystemInfoSync().statusBarHeight
- // #ifdef MP-WEIXIN
- // 获取微信胶囊的位置信息 width,height,top,right,left,bottom
- const custom = wx.getMenuButtonBoundingClientRect()
- // console.log(custom)
- // 导航栏高度(标题栏高度) = 胶囊高度 + (顶部距离 - 状态栏高度) * 2
- this.navigationBarHeight = custom.height + (custom.top - this.statusBarHeight) * 2
- // console.log("导航栏高度:"+this.globalData.navigationBarHeight)
- // 总体高度 = 状态栏高度 + 导航栏高度
- this.navHeight = (this.navigationBarHeight + this.statusBarHeight)
- this.navigationBarHeight = this.navigationBarHeight + 'px'
- this.statusBarHeight = this.statusBarHeight + 'px'
- this.navHeight = this.navHeight + 'px'
- // #endif
- },
- methods: {
-
- goBack() {
- uni.navigateBack({
- delta: 1
- })
- },
- toPath() {
- this.$yrouter.push({
- path: "/pages/maintenance/maintainOrder/flow/index?data=" + encodeURIComponent(JSON.stringify(this.orderData))
- });
- },
- toRouter(id){
- console.log(id);
- this.$yrouter.push({
- path:"/pages/maintenance/expensesList/expensesList?id="+id
- })
- }
- },
- }
- </script>
- <style lang="less">
- page {
- background: #F5F5F5;
- }
- .buttomBtn {
- position: fixed;
- bottom: 0;
- width: 750rpx;
- height: 144rpx;
- background: #FFFFFF;
- display: flex;
- align-items: center;
- justify-content: flex-end;
- .deliveryOfVehicle {
- width: 200rpx;
- height: 70rpx;
- background: #FFFFFF;
- border: 1px solid #005EFF;
- border-radius: 35rpx;
- font-size: 28rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #005EFF;
- line-height: 70rpx;
- text-align: center;
- margin-right: 20rpx;
- }
- .liveStreaming {
- width: 200rpx;
- height: 70rpx;
- background: #FFFFFF;
- border: 1px solid #005EFF;
- border-radius: 35rpx;
- font-size: 28rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #005EFF;
- line-height: 70rpx;
- text-align: center;
- margin-right: 20rpx;
- }
- .inventory {
- width: 200rpx;
- height: 70rpx;
- background: linear-gradient(0deg, #008EFF 0%, #0036FF 100%);
- border-radius: 35rpx;
- font-size: 28rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #FFFFFF;
- line-height: 70rpx;
- text-align: center;
- margin-right: 20rpx;
- }
- }
- .more {
- width: 14rpx;
- height: 23rpx;
- }
- .serveBodys {
- display: flex;
- align-items: center;
- justify-content: space-between;
- padding: 34rpx 30rpx 0 36rpx;
- .leftView {
- display: flex;
- align-items: center;
- .dian {
- width: 6rpx;
- height: 6rpx;
- background: #005EFF;
- border-radius: 50%;
- }
- .title {
- padding-left: 10rpx;
- font-size: 28rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #333333;
- line-height: 36rpx;
- }
- }
- .rightView {
- text-align: center;
- min-width: 94rpx;
- height: 32rpx;
- background: #FFFFFF;
- border: 1px solid #DBDBDB;
- border-radius: 3rpx;
- font-size: 18rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- line-height: 32rpx;
- }
- }
- .headerBody {
- display: flex;
- align-items: center;
- margin-top: 73rpx;
- margin-left: 44rpx;
- justify-content: space-between;
- margin-right: 41rpx;
- }
- .orderBody {
- position: absolute;
- top: 358rpx;
- //
- .orderDetail {
- width: 710rpx;
- background: #FFFFFF;
- border-radius: 10rpx;
- margin: 20rpx;
- .carHeader {
- padding: 38rpx 0 13rpx 31rpx;
- font-size: 32rpx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #333333;
- line-height: 36rpx;
- }
- .carView {
- display: flex;
- padding: 26rpx;
- image {
- width: 120rpx;
- height: 120rpx;
- background: #FFFFFF;
- border: 2rpx solid #F4F4F4;
- border-radius: 8rpx;
- padding-top: 14rpx;
- }
- .carBody {
- padding: 14rpx 29rpx 14rpx 29rpx;
- .carTitle {
- display: flex;
- image {
- width: 33rpx;
- height: 27rpx;
- padding-top: 0rpx;
- }
- .border {
- width: 1px;
- height: 20rpx;
- background: #DBDBDB;
- }
- span {
- font-size: 30rpx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #333333;
- line-height: 31rpx;
- padding: 0 15rpx 0 15rpx;
- }
- }
- .content {
- font-size: 26rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #666666;
- line-height: 34rpx;
- padding: 20rpx 60rpx 20rpx 0;
- }
- }
- }
- .shop {
- display: flex;
- align-items: center;
- font-size: 26rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #333333;
- line-height: 34rpx;
- padding: 15rpx 30rpx 15rpx 30rpx;
- image {
- width: 30rpx;
- height: 26rpx;
- }
- }
- .times {
- display: flex;
- align-items: center;
- font-size: 26rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #333333;
- line-height: 34rpx;
- margin-top: 16rpx;
- padding-bottom: 30rpx;
- padding: 0rpx 30rpx 15rpx 30rpx;
- image {
- width: 30rpx;
- height: 26rpx;
- }
- }
- .buttomBtn {
- height: 33rpx;
- font-size: 26rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #333333;
- line-height: 34rpx;
- text-align: center;
- margin: 26rpx 31rpx 0 74%;
- }
- }
- .explain {
- width: 710rpx;
- background: #FFFFFF;
- border-radius: 10rpx;
- margin: 20rpx;
- padding-top: 11rpx;
- padding-bottom: 40rpx;
- .serveHeader {
- padding: 38rpx 0 13rpx 31rpx;
- font-size: 32rpx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #333333;
- line-height: 36rpx;
- }
- }
- }
- .orderHeader {
- width: 100%;
- height: 454rpx;
- background: linear-gradient(90deg, #005AFF 0%, #0078FF 100%);
- .navigationBar {
- display: flex;
- align-items: center;
- text-align: center;
- image {
- padding-left: 17rpx;
- width: 44rpx;
- height: 44rpx;
- }
- .navigationTitle {
- padding-left: 242rpx;
- font-size: 36rpx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FFFFFF;
- line-height: 75rpx;
- }
- }
- .serveBody {
- display: flex;
- align-items: center;
- image {
- width: 77rpx;
- height: 38rpx;
- }
- .serveTitle {
- font-size: 36rpx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FFFFFF;
- line-height: 75rpx;
- padding-left: 20rpx;
- }
- }
- .reserve {
- margin-top: 27rpx;
- font-size: 24rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #FFFFFF;
- line-height: 31rpx;
- }
- }
- </style>
|