|
@@ -1,22 +1,23 @@
|
|
|
<template>
|
|
|
<view class='container uni-column'>
|
|
|
<view class='nav uni-row'>
|
|
|
- <text :class='pendingClass' @click='selectPending'>{{pendingTitle}}</text>
|
|
|
- <text :class='turnoverClass' @click='selectTurnover'>{{turnoverTitle}}</text>
|
|
|
+ <text :class='pendingClass' @click='selectPending'>带周转</text>
|
|
|
+ <text :class='turnoverClass' @click='selectTurnover'>周转中</text>
|
|
|
<!-- <image class='img' src="../../static/screen.png"></image> -->
|
|
|
</view>
|
|
|
<!-- 待周转页面 -->
|
|
|
<view class="padding-container" v-if='pendingShow'>
|
|
|
- <view class="scroll-container" scroll-y>
|
|
|
+ <view class="scroll-container" >
|
|
|
<view v-if="listData.length == 0" style="color: #999;margin: 50% auto;">
|
|
|
<text>暂无待周转批次</text>
|
|
|
</view>
|
|
|
- <view v-else v-for="(item, index) in listData" :key="index"
|
|
|
- :class="{'list-item':true,'selected':isSelected(item)}">
|
|
|
+ <view v-else v-for="(item, index) in listData" :key="index"
|
|
|
+ :class="{'list-item':true,'selected':isSelected(item)}">
|
|
|
<!-- @click="handleSelection(item)" -->
|
|
|
- <view class="title-container uni-row">
|
|
|
+ <view class="title-container uni-row">
|
|
|
<view class="title uni-row">
|
|
|
- <text class="label" style="max-width: 200rpx; overflow: auto;">{{ item['turnoverArea'] }}</text>
|
|
|
+ <text class="label" style="max-width: 180rpx;height: 32rpx;overflow: hidden;text-overflow: ellipsis;
|
|
|
+ white-space: nowrap;">{{ item['turnoverArea'] }}</text>
|
|
|
<text class="label code">{{ item['preDeptName'] }}</text>
|
|
|
<text class="label code" style="margin-left: 16rpx;">→</text>
|
|
|
<text class="label code" style="margin-left: 16rpx;">{{ item['deptName'] }}</text>
|
|
@@ -56,7 +57,7 @@
|
|
|
</view>
|
|
|
<!-- 周转中页面 -->
|
|
|
<view class='turnover-container' v-if='turnoverShow'>
|
|
|
- <view class="scroll-container" scroll-y>
|
|
|
+ <view class="scroll-container" >
|
|
|
<view v-if="lotList.length == 0" style="color: #999;margin: 50% auto;">
|
|
|
<text>暂无周转中批次</text>
|
|
|
</view>
|
|
@@ -72,12 +73,13 @@
|
|
|
<view :class="{'list-container':true,'selected':isSelected(item)}" v-for="(item,index) in lotList"
|
|
|
@click="handleSelection(item)" :key='index'>
|
|
|
<view class="turnover-title uni-row">
|
|
|
- <view class="uni-row" style="align-items: center;">
|
|
|
+ <view class="uni-row" style="align-items: center;">
|
|
|
<view><text class='title-color'>{{ item[0]['totalCarrier'] }}箱</text></view>
|
|
|
- <view><text class="second-info">{{item[0].preDeptName + '→' + item[0].deptName }}</text></view>
|
|
|
- </view>
|
|
|
+ <view><text class="second-info">{{item[0].preDeptName + '→' + item[0].deptName }}</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
- <view v-for="(lot,index) in item" :key="index" style="margin-bottom: 10rpx;">
|
|
|
+ <view v-for="(lot,index) in item" :key="index" style="margin-bottom: 10rpx;">
|
|
|
<view class="list-container-item product-description uni-row">
|
|
|
<text class="label left-value">产品描述</text>
|
|
|
<text class="label right-value">{{lot['productDescription']}}</text>
|
|
@@ -117,7 +119,8 @@
|
|
|
// import pending from './pending';
|
|
|
// import turnover from './turnover';
|
|
|
import {
|
|
|
- getDayWorkItemList,getItemList
|
|
|
+ getDayWorkItemList,
|
|
|
+ getItemList
|
|
|
} from '@/api/business/dayWorkItem.js'
|
|
|
import {
|
|
|
updateDayWorkItem,
|
|
@@ -128,8 +131,6 @@
|
|
|
} from '@/api/dict/dict.js'
|
|
|
|
|
|
|
|
|
- const pendingTitle = ref('待周转')
|
|
|
- const turnoverTitle = ref('周转中')
|
|
|
const sum = ref(0)
|
|
|
const pendingClass = ref({
|
|
|
selecter: true
|
|
@@ -251,19 +252,19 @@
|
|
|
function isSelected(item) {
|
|
|
//单选
|
|
|
return selection.value == item;
|
|
|
-
|
|
|
+
|
|
|
//多选
|
|
|
// return selection.value.includes(item);
|
|
|
}
|
|
|
|
|
|
function handleSelection(item) {
|
|
|
// 单选
|
|
|
- if(selection.value == item){
|
|
|
+ if (selection.value == item) {
|
|
|
selection.value = []
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
selection.value = item;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
// 多选
|
|
|
// const buttonIndex = selection.value.findIndex(selectedItem => selectedItem === item);
|
|
|
// if (buttonIndex > -1) {
|
|
@@ -372,7 +373,9 @@
|
|
|
}
|
|
|
|
|
|
.padding-container {
|
|
|
- .scroll-container {
|
|
|
+ .scroll-container {
|
|
|
+ max-height: 90%;
|
|
|
+ overflow: auto;
|
|
|
.list-item {
|
|
|
background-color: #fff;
|
|
|
padding: 0 24rpx;
|
|
@@ -434,6 +437,8 @@
|
|
|
/* 周转中样式 */
|
|
|
.turnover-container {
|
|
|
.scroll-container {
|
|
|
+ height: 90%;
|
|
|
+ overflow: scroll;
|
|
|
.item-container {
|
|
|
// height: 90%;
|
|
|
// padding: 8rpx 0 32rpx 0;
|