123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335 |
- <template>
- <view class="order-infos">
- <!-- #ifdef MP-WEIXIN -->
- <view class="topbar"
- :style="rect?'height:'+rect.height+'px;line-height:'+rect.height+'px;margin-top:'+rect.top+'px':''">
- <!-- #endif -->
- <!-- #ifndef MP-WEIXIN -->
- <view class="topbar" :style="statusBarHeight?'margin-top:'+statusBarHeight+'px':''">
- <!-- #endif -->
- <view class="back-icon" :style="rect?'padding:'+(rect.height-24)+'rpx 20rpx':''">
- <u-icon name="arrow-left" size="24" color="#ffffff" @click="pageBack"></u-icon>
- </view>
- 固定订单详情
- </view>
- <view class="after">
- <view class="order-info-card">
- <view class="order-card ">
- <view class="order-info-title">
- <image class="img" src="../../subpages/static/czzn-img/order/orderInfo-tenant.png"
- mode="scaleToFill" />
- <view class="mid">
- <view class="info">
- <span class="label">
- {{$t('spare.orderCode')}}
- </span>
- <span class="type"
- v-if="orderInfo.orderType == '1'">{{ $t('order.temp') }}</span>
- <span class="type fixed"
- v-if="orderInfo.orderType == '2'">{{ $t('order.fixed') }}</span>
- </view>
- <text class="code">{{ orderInfo.code || '' }}</text>
- </view>
- <view class="orderStatus-info" v-if="orderInfo.orderType != '4'">
- <u--image width="100rpx" height="88rpx" v-if="orderInfo.orderStatus == 0"
- src="../../subpages/static/czzn-img/state/not-factory.png"></u--image>
- <u--image width="100rpx" height="88rpx"
- v-if="orderInfo.orderStatus == 1 && orderInfo.weighingStatus == 0"
- src="../../subpages/static/czzn-img/state/in-factory.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="orderInfo.orderStatus == 2"
- src="../../subpages/static/czzn-img/state/completed.png"></u--image>
- <u--image width="100rpx" height="88rpx"
- v-if="orderInfo.orderStatus == 1 && orderInfo.weighingStatus != 0"
- src="../../subpages/static/czzn-img/state/weighed.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="orderInfo.orderStatus == 4"
- src="../../subpages/static/czzn-img/state/cancellation.png"></u--image>
- </view>
- <!-- <span class="type" v-if="orderInfo.orderType == '1'">{{ $t('order.temp') }}</span>
- <span class="type" v-if="orderInfo.orderType == '2'">{{ $t('order.orderInfo') }}</span> -->
- <view class="orderStatus-info" v-if="orderInfo.orderType == '4'">
- <u--image width="100rpx" height="88rpx" v-if="orderInfo.orderStatus == 0"
- src="/subpages/static/czzn-img/state/no-take-order.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="orderInfo.orderStatus == 1"
- src="/subpages/static/czzn-img/state/start-take-order.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="orderInfo.orderStatus == 2"
- src="/subpages/static/czzn-img/state/completed.png"></u--image>
- <u--image width="100rpx" height="88rpx"
- v-if="orderInfo.enabledMarkType == 1 || orderInfo.orderStatus == 4"
- src="/subpages/static/czzn-img/state/cancellation.png"></u--image>
- </view>
- </view>
- <view class="order-card-info">
- <view class="order-type" v-if="orderInfo.isMain==2">
- <u-tag :text="$t('order.mainOrder')" type="success"></u-tag>
- </view>
- <p class="cell">
- <text class="label">{{ $t('order.orderDate') }}</text>
- <text class="info">{{ orderInfo.setDate || '' }}</text>
- </p>
- <p class="cell">
- <text class="label">{{ $t('order.vehicleType') }}</text>
- <text class="info"
- v-if="orderInfo.vehicleType == '101'">{{ $t('order.saleOrder') }}</text>
- <text class="info"
- v-if="orderInfo.vehicleType == '102'">{{ $t('order.purchaseOrder') }}</text>
- <text class="info"
- v-if="orderInfo.vehicleType == '103'">{{ $t('order.materialsOrder') }}</text>
- <text class="info"
- v-if="orderInfo.vehicleType == '104'">{{ $t('order.transferOrder') }}</text>
- </p>
- <p class="cell">
- <text class="label">{{ $t('order.companyName') }}</text>
- <text class="info">{{ orderInfo.companyName || '' }}</text>
- </p>
- <view class="cell">
- <text class="label">{{ $t('order.materialName') }}</text>
- <text class="info">{{ orderInfo.materialName || '' }}</text>
- </view>
- <view class="cell">
- <text class="label">{{ $t('order.orderNumber') }}</text>
- <text class="info">{{ orderInfo.orderNumber || '0' }}{{ orderInfo.orderType ==
- '4' ? $t('customer_meter.unitN') : $t('customer_meter.unitT') }}</text>
- </view>
- <p class="cell">
- <text class="label">{{ $t('order.driver') }}</text>
- <text class="info">{{ orderInfo.driver || '' }}</text>
- </p>
- <p class="cell">
- <text class="label">{{ $t('order.vehicle') }}</text>
- <text class="info">{{ orderInfo.vehicle || '' }}</text>
- </p>
- <template
- v-if="orderInfo.orderStatus != 0 && orderInfo.weighingStatus != 0">
- <p class="cell">
- <text class="label">{{ $t('order.tareWeight') }}</text>
- <text class="info">{{ orderInfo.tareWeight || '0' }}</text>
- </p>
- <p class="cell">
- <text class="label">{{ $t('order.grossWeight') }}</text>
- <text class="info">{{ orderInfo.grossWeight || '0' }}</text>
- </p>
- </template>
- <template
- v-if="orderInfo.orderStatus != 0 && orderInfo.weighingStatus != 0">
- <p class="cell">
- <text class="label">{{ $t('order.netWeight') }}</text>
- <text class="info">{{ orderInfo.netWeight || '0' }}</text>
- </p>
- </template>
- <template
- v-if="orderInfo.orderStatus != 0 && orderInfo.weighingStatus == 1">
- <p class="cell">
- <text class="label">{{ $t('order.inTime') }}</text>
- <text class="info">{{ orderInfo.inTime || '' }}</text>
- </p>
- </template>
- <template
- v-if="orderInfo.orderStatus != 0 && orderInfo.weighingStatus == 2">
- <p class="cell">
- <text class="label">{{ $t('order.outTime') }}</text>
- <text class="info">{{ orderInfo.outTime || '' }}</text>
- </p>
- </template>
- <template v-if="orderInfo.orderStatus == 2">
- <p class="cell">
- <text class="label">{{ $t('order.outDate') }}</text>
- <text class="info">{{ orderInfo.outDoorTime || '' }}</text>
- </p>
- </template>
- </view>
- </view>
- <view v-for="(item, index) in orderInfos" class="order-card" :key="index">
- <!-- <view class="order-card-title">
- <span class="type" v-if="item.orderType == '1'">{{ $t('order.temp') }}</span>
- <span class="type" v-if="item.orderType == '2'">{{ $t('order.orderInfo') }}</span>
- <text class="info">{{ item.tenantName || '' }}</text>
- <!-- <text class="no">No {{ item.code || '' }}</text>
-
- <view class="orderStatus-info">
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 0"
- src="../../subpages/static/czzn-img/state/not-factory.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 1 && item.weighingStatus == 0"
- src="../../subpages/static/czzn-img/state/in-factory.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 2"
- src="../../subpages/static/czzn-img/state/completed.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 1 && item.weighingStatus != 0"
- src="../../subpages/static/czzn-img/state/weighed.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 4"
- src="../../subpages/static/czzn-img/state/cancelllation.png"></u--image>
- </view>
- </view> -->
- <view class="order-info-title">
- <image class="img" src="../../subpages/static/czzn-img/order/orderInfo-tenant.png"
- mode="scaleToFill" />
- <view class="mid">
- <view class="info">
- <span class="label">
- {{$t('spare.orderCode')}}
- </span>
- <span class="type" v-if="item.orderType == '1'">{{ $t('order.temp') }}</span>
- <span class="type fixed" v-if="item.orderType == '2'">{{ $t('order.fixed') }}</span>
- </view>
- <text class="code">{{ item.code || '' }}</text>
- </view>
- <view class="orderStatus-info" v-if="item.orderType != '4'">
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 0"
- src="../../subpages/static/czzn-img/state/not-factory.png"></u--image>
- <u--image width="100rpx" height="88rpx"
- v-if="item.orderStatus == 1 && item.weighingStatus == 0"
- src="../../subpages/static/czzn-img/state/in-factory.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 2"
- src="../../subpages/static/czzn-img/state/completed.png"></u--image>
- <u--image width="100rpx" height="88rpx"
- v-if="item.orderStatus == 1 && item.weighingStatus != 0"
- src="../../subpages/static/czzn-img/state/weighed.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 4"
- src="../../subpages/static/czzn-img/state/cancellation.png"></u--image>
- </view>
- <!-- <span class="type" v-if="orderInfo.orderType == '1'">{{ $t('order.temp') }}</span>
- <span class="type" v-if="orderInfo.orderType == '2'">{{ $t('order.fixed') }}</span> -->
- <view class="orderStatus-info" v-if="item.orderType == '4'">
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 0"
- src="/subpages/static/czzn-img/state/no-take-order.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 1"
- src="/subpages/static/czzn-img/state/start-take-order.png"></u--image>
- <u--image width="100rpx" height="88rpx" v-if="item.orderStatus == 2"
- src="/subpages/static/czzn-img/state/completed.png"></u--image>
- <u--image width="100rpx" height="88rpx"
- v-if="item.enabledMarkType == 1 || item.orderStatus == 4"
- src="/subpages/static/czzn-img/state/cancellation.png"></u--image>
- </view>
- </view>
- <view class="order-card-info">
- <!-- <view class="order-type">
- <span class="tag tag-ls" v-if="item.orderType == '1'">{{ $t('order.temp') }}</span>
- <span class="tag tag-gd" v-if="item.orderType == '2'">{{ $t('order.fixed') }}</span>
- </view> -->
- <view class="row" v-if="item.orderStatus == 1">
- <p class="cell">
- <text class="label">{{ $t('order.inDoorTime') }}</text>
- <text class="info">{{ item.enterTime }}</text>
- </p>
- </view>
- <view class="row">
- <p class="cell">
- <text class="label">{{ $t('order.tareWeight') }}</text>
- <text class="info">{{ item.tareWeight || '0' }}</text>
- </p>
- <p class="cell">
- <text class="label">{{ $t('order.grossWeight') }}</text>
- <text class="info">{{ item.grossWeight || '0' }}</text>
- </p>
- </view>
- <view class="row">
- <p class="cell">
- <text class="label">{{ $t('order.netWeight') }}</text>
- <text class="info">{{ item.netWeight || '0' }}</text>
- </p>
- <p class="cell">
- <text class="label">{{ $t('order.orderNumber') }}</text>
- <text class="info">{{ item.orderNumber || '0' }} T</text>
- </p>
- </view>
- <view class="row">
- <p class="cell">
- <text class="label">{{ $t('order.inTime') }}</text>
- <text class="info">{{ item.inTime || '' }}</text>
- </p>
- </view>
- <view class="row" v-if="item.weighingStatus == 2">
- <p class="cell">
- <text class="label">{{ $t('order.outTime') }}</text>
- <text class="info">{{ item.outTime || '' }}</text>
- </p>
- </view>
- <view class="row" v-if="item.orderStatus == 2">
- <p class="cell">
- <text class="label">{{ $t('order.outDate') }}</text>
- <text class="info">{{ item.outDoorTime || '' }}</text>
- </p>
- </view>
- </view>
- <view class="code">
- <view class="label">{{$t('spare.orderCode')}}</view>
- <view class="info">{{ item.code || '' }}</view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import {
- getFixedOrderList
- } from "../../api/order"
- export default {
- data() {
- return {
- loading: false,
- statusBarHeight: null,
- orderInfo: {},
- orderInfos: [],
- keyword: '',
- };
- },
- onLoad(options) {
- this.onGetFixedOrderList(options)
- let sysInfo = wx.getSystemInfoSync(); //状态栏的高度
- this.statusBarHeight = sysInfo.statusBarHeight;
- this.rect = wx.getMenuButtonBoundingClientRect();
- console.log(this.rect, this.statusBarHeight);
- },
- // #ifdef MP-WEIXIN
- onShareAppMessage() {
- return {
- title: '有新订单邀请您,快来看看吧!',
- path: `/subpages/order/receiving?id=${this.orderInfo.id}`,
- }
- },
- // #endif
- methods: {
- onGetFixedOrderList(data) {
- var that = this;
- getFixedOrderList(data).then(res => {
- if (res.statusCode == 200 && res.data.code==0) {
- that.orderInfo = res.data.data.orderInfo
- that.orderInfos = res.data.data.orderInfos
- }
- console.log("获取到的固定订单信息、", that.fixedInfo);
- })
- },
- pageBack() {
- uni.navigateBack({
- delta: 1
- })
- }
- },
- };
- </script>
- <style>
- /* #ifndef APP-NVUE */
- view {
- display: flex;
- box-sizing: border-box;
- flex-direction: column;
- }
- page {
- box-sizing: border-box;
- /* padding: 40rpx 40rpx 80rpx; */
- height: 100%;
- background: url('../../subpages/static/czzn-img/order/order-detail2.png') no-repeat;
- background-size: 750rpx auto;
- }
- /* #endif*/
- </style>
- <style lang="scss" scoped>
- @import '../../common/css/public.scss';
- </style>
|