| | |
| | | <div class="status">{{ statusMap[item.status] }}</div> |
| | | </div> |
| | | <div class="info"> |
| | | <div v-if="item.type == 4" class="ite"> |
| | | <span>合同单号:</span> |
| | | <span>{{ item.contractNum }}</span> |
| | | </div> |
| | | <div v-else class="ite"> |
| | | <div v-if="item.billCode" class="ite"> |
| | | <span>运输单号:</span> |
| | | <span>{{ item.billCode }}</span> |
| | | </div> |
| | | <div v-else class="ite"> |
| | | <span>合同单号:</span> |
| | | <span>{{ item.contractNum }}</span> |
| | | </div> |
| | | <div class="ite"> |
| | | <span>驾驶员:</span> |
| | |
| | | <span>总运输量:</span> |
| | | <span>{{ item.totalNum }}万支</span> |
| | | </div> |
| | | <div v-if="item.type != 4" class="ite" style="width: 66%"> |
| | | <div v-if="item.billCode" class="ite" style="width: 66%"> |
| | | <span>运输公司:</span> |
| | | <span>{{ item.carrierName }}</span> |
| | | </div> |
| | | </div> |
| | | <div class="footer df_sb"> |
| | | <div v-if="item.type != 4" class="detail">运单详情</div> |
| | | <div v-else></div> |
| | | <el-button type="primary" @click="handleCall(item)">叫号</el-button> |
| | | <div v-if="item.billCode" @click="handleDetail(item)" class="detail">运单详情</div> |
| | | <div v-else class="detail" @click="subDetail(item)">预约详情</div> |
| | | <el-button v-preventReClick :loading="loadingCall" type="primary" @click="handleCall(item)">叫号</el-button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <pagination @size-change="handleSizeChange" @current-change="handlePageChange" :pagination="pagination"> |
| | | </pagination> |
| | | </div> |
| | | <!-- --> |
| | | <WaybillDetail ref="WaybillDetailRef" v-if="isShowDetail" @success="getList" @close="isShowDetail = false" /> |
| | | <DriverDetail v-if="isShowDriver" ref="DriverDetailRef" /> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | |
| | | import { platformCallList, platformCallNumber, platformInPark } from '@/api' |
| | | import { statusMap } from '../config' |
| | | import { Message } from 'element-ui' |
| | | import WaybillDetail from './WaybillDetail.vue' |
| | | import DriverDetail from "@/views/task/driverDetail.vue" |
| | | export default { |
| | | components: { |
| | | GlobalWindow, |
| | | Pagination |
| | | Pagination, |
| | | WaybillDetail, |
| | | DriverDetail |
| | | }, |
| | | data() { |
| | | return { |
| | |
| | | title: '', |
| | | callType: '1', |
| | | activePlat: {}, |
| | | dataList: [] |
| | | dataList: [], |
| | | isShowDetail: false, // 运单详情 |
| | | isShowDriver: false, // 预约详情 |
| | | loadingCall: false |
| | | |
| | | } |
| | | }, |
| | | methods: { |
| | | handleCall(item) { |
| | | const { activePlat, callType } = this |
| | | this.loadingCall = true |
| | | if (callType == 1) { // 入园叫号 |
| | | platformInPark({ |
| | | jobId: item.id, |
| | | platformId: activePlat.id |
| | | }).then(() => { |
| | | Message.success('叫号成功') |
| | | this.getList() |
| | | }) |
| | | } else { |
| | | platformCallNumber({ platformId: activePlat.id, jobId: item.id }).then(res => { |
| | | this.loadingCall = false |
| | | Message.success('叫号成功') |
| | | this.$emit('success') |
| | | this.getList() |
| | | }) |
| | | },() => {this.loadingCall = false}) |
| | | } else { |
| | | this.loadingCall = true |
| | | platformCallNumber({ platformId: activePlat.id, jobId: item.id }).then(res => { |
| | | this.loadingCall = false |
| | | Message.success('叫号成功') |
| | | this.$emit('success') |
| | | this.getList() |
| | | },()=> {this.loadingCall = false}) |
| | | } |
| | | }, |
| | | subDetail(row) { |
| | | this.isShowDriver = true |
| | | this.$nextTick(() => { |
| | | this.$refs.DriverDetailRef.id = row.bookId |
| | | this.$refs.DriverDetailRef.type = row.objType |
| | | this.$refs.DriverDetailRef.getDetail() |
| | | this.$refs.DriverDetailRef.isShowModal = true |
| | | }) |
| | | }, |
| | | handleDetail(row) { |
| | | this.isShowDetail = true |
| | | this.$nextTick(() => { |
| | | this.$refs.WaybillDetailRef.isShowModal = true |
| | | this.$refs.WaybillDetailRef.id = row.id |
| | | this.$refs.WaybillDetailRef.getDetail() |
| | | }) |
| | | }, |
| | | getList() { |
| | | const { activePlat, pagination, carCodeFront, callType } = this |
| | |
| | | .footer { |
| | | .detail { |
| | | color: $primaryColor; |
| | | cursor: pointer; |
| | | } |
| | | } |
| | | } |