|
|
|
@ -520,7 +520,7 @@
|
|
|
|
|
<img class="dataIcon mr5px" src="@/static/icon_money_day.png" alt="" /> |
|
|
|
|
<span>总数</span> |
|
|
|
|
</div> |
|
|
|
|
<!-- <div |
|
|
|
|
<div |
|
|
|
|
class="mt10" |
|
|
|
|
@click=" |
|
|
|
|
() => |
|
|
|
@ -534,12 +534,12 @@
|
|
|
|
|
details.allocationDataInfo.totalNum || 0 |
|
|
|
|
}}</span> |
|
|
|
|
<span class="">个</span> |
|
|
|
|
</div> --> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="mt10"> |
|
|
|
|
<!-- <div class="mt10"> |
|
|
|
|
<span class="data mr5px">{{ details.allocationDataInfo.totalNum || 0 }}</span> |
|
|
|
|
<span class="">个</span> |
|
|
|
|
</div> |
|
|
|
|
</div> --> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<!-- 已上架 --> |
|
|
|
@ -831,7 +831,7 @@
|
|
|
|
|
|
|
|
|
|
<div class="abnormal_item red"> |
|
|
|
|
<div class="align_center"> |
|
|
|
|
<img class="dataIcon mr5px " src="@/static/icon_money_day.png" alt="" /> |
|
|
|
|
<img class="dataIcon mr5px" src="@/static/icon_money_day.png" alt="" /> |
|
|
|
|
<span>处理率</span> |
|
|
|
|
</div> |
|
|
|
|
<div class="mt10"> |
|
|
|
@ -839,10 +839,15 @@
|
|
|
|
|
class="data mr5px underline" |
|
|
|
|
@click=" |
|
|
|
|
() => |
|
|
|
|
handleShowAbnormalData('异常数据-处理率-%', abnormal_status, { |
|
|
|
|
tip: '处理率', |
|
|
|
|
prop: 'processingRate', |
|
|
|
|
},'bar') |
|
|
|
|
handleShowAbnormalData( |
|
|
|
|
'异常数据-处理率-%', |
|
|
|
|
abnormal_status, |
|
|
|
|
{ |
|
|
|
|
tip: '处理率', |
|
|
|
|
prop: 'processingRate', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
>{{ abnormal_Info.abnormalRate }}</span |
|
|
|
|
> |
|
|
|
@ -1028,7 +1033,7 @@
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="border pd10 flex-c-sb"> |
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1046,7 +1051,7 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box orange mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1064,14 +1069,19 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center" v-if="signforData_status !== 'daySignData'"> |
|
|
|
|
<div class="text_center flex1 mr10" v-if="signforData_status !== 'daySignData'"> |
|
|
|
|
<div |
|
|
|
|
class="data_box blue mb10" |
|
|
|
|
@click=" |
|
|
|
|
handleShowSignDetail('签收数据 - 签收率 - %', signforData_status, { |
|
|
|
|
tip: '签收率', |
|
|
|
|
prop: 'signScale', |
|
|
|
|
},'bar') |
|
|
|
|
handleShowSignDetail( |
|
|
|
|
'签收数据 - 签收率 - %', |
|
|
|
|
signforData_status, |
|
|
|
|
{ |
|
|
|
|
tip: '签收率', |
|
|
|
|
prop: 'signScale', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<div class="data mr5px underline"> |
|
|
|
@ -1084,7 +1094,7 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box purple mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1102,27 +1112,32 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10" v-if="signforData_status !== 'daySignData'"> |
|
|
|
|
<div |
|
|
|
|
class="data_box purple mb10" |
|
|
|
|
@click=" |
|
|
|
|
handleShowSignDetail('签收数据 - 文员签收数 - 件', signforData_status, { |
|
|
|
|
tip: '文员签收数', |
|
|
|
|
prop: 'clerkSignforScale', |
|
|
|
|
}) |
|
|
|
|
handleShowSignDetail( |
|
|
|
|
'签收数据 - 文员签收率 - %', |
|
|
|
|
signforData_status, |
|
|
|
|
{ |
|
|
|
|
tip: '文员签收率', |
|
|
|
|
prop: 'clerkSignforScale', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<div class="data mr5px underline"> |
|
|
|
|
{{ signforData.clerkSignforScale || 0 }} |
|
|
|
|
</div> |
|
|
|
|
<div class="">件</div> |
|
|
|
|
<div class="">%</div> |
|
|
|
|
</div> |
|
|
|
|
<div class=""> |
|
|
|
|
<span>文员签收件</span> |
|
|
|
|
<span>文员签收率</span> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box red mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1142,17 +1157,22 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center" v-if="signforData_status !== 'daySignData'"> |
|
|
|
|
<div class="text_center flex1" v-if="signforData_status !== 'daySignData'"> |
|
|
|
|
<div |
|
|
|
|
class="data_box red mb10" |
|
|
|
|
@click=" |
|
|
|
|
handleShowSignDetail('签收数据 - 签收超时率 - %', signforData_status, { |
|
|
|
|
tip: '签收超时率', |
|
|
|
|
prop: 'clerkOverTimeScale', |
|
|
|
|
},'bar') |
|
|
|
|
handleShowSignDetail( |
|
|
|
|
'签收数据 - 签收超时率 - %', |
|
|
|
|
signforData_status, |
|
|
|
|
{ |
|
|
|
|
tip: '签收超时率', |
|
|
|
|
prop: 'clerkOverTimeScale', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<div class="data mr5px"> |
|
|
|
|
<div class="data mr5px underline"> |
|
|
|
|
{{ signforData.clerkOverTimeScale ? signforData.clerkOverTimeScale : 0 }} |
|
|
|
|
</div> |
|
|
|
|
<div class="">%</div> |
|
|
|
@ -1311,7 +1331,7 @@
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="border pd10 flex-c-sb"> |
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1329,7 +1349,7 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box orange mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1347,14 +1367,22 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center" v-if="billSignforData_status !== 'dayBillLadingSignData'"> |
|
|
|
|
<div |
|
|
|
|
class="text_center flex1 mr10" |
|
|
|
|
v-if="billSignforData_status !== 'dayBillLadingSignData'" |
|
|
|
|
> |
|
|
|
|
<div |
|
|
|
|
class="data_box blue mb10" |
|
|
|
|
@click=" |
|
|
|
|
handleShowSignDetail('自提签收数据 - 签收率 - %', billSignforData_status, { |
|
|
|
|
tip: '签收率', |
|
|
|
|
prop: 'signScale', |
|
|
|
|
},'bar') |
|
|
|
|
handleShowSignDetail( |
|
|
|
|
'自提签收数据 - 签收率 - %', |
|
|
|
|
billSignforData_status, |
|
|
|
|
{ |
|
|
|
|
tip: '签收率', |
|
|
|
|
prop: 'signScale', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<div class="data mr5px underline"> |
|
|
|
@ -1367,7 +1395,7 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box purple mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1385,27 +1413,35 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div |
|
|
|
|
class="text_center flex1 mr10" |
|
|
|
|
v-if="billSignforData_status !== 'dayBillLadingSignData'" |
|
|
|
|
> |
|
|
|
|
<div |
|
|
|
|
class="data_box purple mb10" |
|
|
|
|
@click=" |
|
|
|
|
handleShowSignDetail('自提签收数据 - 文员签收数 - 件', billSignforData_status, { |
|
|
|
|
tip: '文员签收率', |
|
|
|
|
prop: 'clerkSignforScale', |
|
|
|
|
}) |
|
|
|
|
handleShowSignDetail( |
|
|
|
|
'自提签收数据 - 文员签收数 - %', |
|
|
|
|
billSignforData_status, |
|
|
|
|
{ |
|
|
|
|
tip: '文员签收率', |
|
|
|
|
prop: 'clerkSignforScale', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<div class="data mr5px underline"> |
|
|
|
|
{{ billSignforData.clerkSignforScale ? billSignforData.clerkSignforScale : 0 }} |
|
|
|
|
</div> |
|
|
|
|
<div class="">件</div> |
|
|
|
|
<div class="">%</div> |
|
|
|
|
</div> |
|
|
|
|
<div class=""> |
|
|
|
|
<span>文员签收数</span> |
|
|
|
|
<span>文员签收率</span> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center"> |
|
|
|
|
<div class="text_center flex1 mr10"> |
|
|
|
|
<div |
|
|
|
|
class="data_box red mb10" |
|
|
|
|
@click=" |
|
|
|
@ -1425,14 +1461,22 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="text_center" v-if="billSignforData_status !== 'dayBillLadingSignData'"> |
|
|
|
|
<div |
|
|
|
|
class="text_center flex1 mr10" |
|
|
|
|
v-if="billSignforData_status !== 'dayBillLadingSignData'" |
|
|
|
|
> |
|
|
|
|
<div |
|
|
|
|
class="data_box red mb10" |
|
|
|
|
@click=" |
|
|
|
|
handleShowSignDetail('自提签收数据 - 超时签收任务 - %', billSignforData_status, { |
|
|
|
|
tip: '超时签收任务', |
|
|
|
|
prop: 'clerkOverTimeScale', |
|
|
|
|
},'bar') |
|
|
|
|
handleShowSignDetail( |
|
|
|
|
'自提签收数据 - 超时签收任务 - %', |
|
|
|
|
billSignforData_status, |
|
|
|
|
{ |
|
|
|
|
tip: '超时签收任务', |
|
|
|
|
prop: 'clerkOverTimeScale', |
|
|
|
|
}, |
|
|
|
|
'bar' |
|
|
|
|
) |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<div class="data mr5px underline"> |
|
|
|
@ -1628,13 +1672,53 @@ const details = reactive({
|
|
|
|
|
/** 签收数据 */ |
|
|
|
|
signforDataInfo: { |
|
|
|
|
/** 当日签收数据 */ |
|
|
|
|
daySignData: {}, |
|
|
|
|
daySignData: { |
|
|
|
|
signNum: 0, |
|
|
|
|
clerkOverTimeSignfoNum: 0, |
|
|
|
|
clerkOverTimeScale: 0, |
|
|
|
|
signScale: 0, |
|
|
|
|
clerkSignNum: 0, |
|
|
|
|
planNum: 0, |
|
|
|
|
unSignNum: 0, |
|
|
|
|
clerkSignforScale: 0, |
|
|
|
|
data: [], |
|
|
|
|
}, |
|
|
|
|
/** 当月签收数据 */ |
|
|
|
|
monthSignData: {}, |
|
|
|
|
monthSignData: { |
|
|
|
|
signNum: 0, |
|
|
|
|
clerkOverTimeSignfoNum: 0, |
|
|
|
|
clerkOverTimeScale: 0, |
|
|
|
|
signScale: 0, |
|
|
|
|
clerkSignNum: 0, |
|
|
|
|
planNum: 0, |
|
|
|
|
unSignNum: 0, |
|
|
|
|
clerkSignforScale: 0, |
|
|
|
|
data: [], |
|
|
|
|
}, |
|
|
|
|
/** 当日自提签收数据 */ |
|
|
|
|
dayBillLadingSignData: {}, |
|
|
|
|
dayBillLadingSignData: { |
|
|
|
|
signNum: 0, |
|
|
|
|
clerkOverTimeSignfoNum: 0, |
|
|
|
|
clerkOverTimeScale: 0, |
|
|
|
|
signScale: 0, |
|
|
|
|
clerkSignNum: 0, |
|
|
|
|
planNum: 0, |
|
|
|
|
unSignNum: 0, |
|
|
|
|
clerkSignforScale: 0, |
|
|
|
|
data: [], |
|
|
|
|
}, |
|
|
|
|
/** 当月自提签收数据 */ |
|
|
|
|
monthBillLadingSignData: {}, |
|
|
|
|
monthBillLadingSignData: { |
|
|
|
|
signNum: 0, |
|
|
|
|
clerkOverTimeSignfoNum: 0, |
|
|
|
|
clerkOverTimeScale: 0, |
|
|
|
|
signScale: 0, |
|
|
|
|
clerkSignNum: 0, |
|
|
|
|
planNum: 0, |
|
|
|
|
unSignNum: 0, |
|
|
|
|
clerkSignforScale: 0, |
|
|
|
|
data: [], |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
loadingObj: { |
|
|
|
|
/** 开单数据 */ |
|
|
|
@ -1996,15 +2080,7 @@ const initDeliveryData = async () => {
|
|
|
|
|
|
|
|
|
|
/** 签收数据 */ |
|
|
|
|
const initSignforData = async () => { |
|
|
|
|
const _keyArr = [ |
|
|
|
|
'signNum', |
|
|
|
|
'unSignNum', |
|
|
|
|
'signScale', |
|
|
|
|
'clerkSignNum', |
|
|
|
|
'clerkSignforScale', |
|
|
|
|
'clerkOverTimeSignfoNum', |
|
|
|
|
'clerkOverTimeScale', |
|
|
|
|
]; |
|
|
|
|
const _keyArr = ['signNum', 'unSignNum', 'clerkSignNum', 'planNum', 'clerkOverTimeSignfoNum']; |
|
|
|
|
|
|
|
|
|
const _obj = { |
|
|
|
|
daySignData: { data: [] }, |
|
|
|
@ -2030,6 +2106,8 @@ const initSignforData = async () => {
|
|
|
|
|
const item = _obj[key]; |
|
|
|
|
|
|
|
|
|
item[value] = 0; |
|
|
|
|
|
|
|
|
|
console.log('item :>> ', item); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -2042,6 +2120,7 @@ const initSignforData = async () => {
|
|
|
|
|
const key = _keyArr[j]; |
|
|
|
|
|
|
|
|
|
const _val = isNumber(value[key]) ? Number(value[key]) : 0; |
|
|
|
|
value[key] = _val; |
|
|
|
|
|
|
|
|
|
// 签收数据 |
|
|
|
|
if (Number(value.type) === 1) { |
|
|
|
@ -2063,6 +2142,106 @@ const initSignforData = async () => {
|
|
|
|
|
: // 自提签收数据 |
|
|
|
|
_obj.monthBillLadingSignData.data.push(value); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
_obj.monthBillLadingSignData.totalSinNum = computeNumber( |
|
|
|
|
_obj.monthBillLadingSignData.signNum, |
|
|
|
|
'+', |
|
|
|
|
_obj.monthBillLadingSignData.unSignNum |
|
|
|
|
).result; |
|
|
|
|
_obj.monthSignData.totalSinNum = computeNumber( |
|
|
|
|
_obj.monthSignData.signNum, |
|
|
|
|
'+', |
|
|
|
|
_obj.monthSignData.unSignNum |
|
|
|
|
).result; |
|
|
|
|
|
|
|
|
|
console.log('_obj :>> ', _obj); |
|
|
|
|
|
|
|
|
|
// 签收率 |
|
|
|
|
if ( |
|
|
|
|
!isNumber(_obj.monthBillLadingSignData.signNum) || |
|
|
|
|
!isNumber(_obj.monthBillLadingSignData.totalSinNum) || |
|
|
|
|
Number(_obj.monthBillLadingSignData.totalSinNum) === 0 |
|
|
|
|
) { |
|
|
|
|
_obj.monthBillLadingSignData.signScale = 0; |
|
|
|
|
} else { |
|
|
|
|
_obj.monthBillLadingSignData.signScale = computeNumber( |
|
|
|
|
_obj.monthBillLadingSignData.signNum, |
|
|
|
|
'/', |
|
|
|
|
_obj.monthBillLadingSignData.totalSinNum |
|
|
|
|
).result; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ( |
|
|
|
|
!isNumber(_obj.monthSignData.signNum) || |
|
|
|
|
!isNumber(_obj.monthSignData.totalSinNum) || |
|
|
|
|
Number(_obj.monthSignData.totalSinNum) === 0 |
|
|
|
|
) { |
|
|
|
|
_obj.monthSignData.signScale = 0; |
|
|
|
|
} else { |
|
|
|
|
_obj.monthSignData.signScale = computeNumber( |
|
|
|
|
_obj.monthSignData.signNum, |
|
|
|
|
'/', |
|
|
|
|
_obj.monthSignData.totalSinNum |
|
|
|
|
).result; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// 文员签收率 |
|
|
|
|
if ( |
|
|
|
|
!isNumber(_obj.monthBillLadingSignData.clerkSignNum) || |
|
|
|
|
!isNumber(_obj.monthBillLadingSignData.planNum) || |
|
|
|
|
Number(_obj.monthBillLadingSignData.planNum) === 0 |
|
|
|
|
) { |
|
|
|
|
_obj.monthBillLadingSignData.clerkSignforScale = 0; |
|
|
|
|
} else { |
|
|
|
|
_obj.monthBillLadingSignData.clerkSignforScale = computeNumber( |
|
|
|
|
Number(_obj.monthBillLadingSignData.clerkSignNum), |
|
|
|
|
'/', |
|
|
|
|
Number(_obj.monthBillLadingSignData.planNum) |
|
|
|
|
).result; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ( |
|
|
|
|
!isNumber(_obj.monthSignData.clerkSignNum) || |
|
|
|
|
!isNumber(_obj.monthSignData.planNum) || |
|
|
|
|
Number(_obj.monthSignData.planNum) === 0 |
|
|
|
|
) { |
|
|
|
|
_obj.monthSignData.clerkSignforScale = 0; |
|
|
|
|
} else { |
|
|
|
|
_obj.monthSignData.clerkSignforScale = computeNumber( |
|
|
|
|
Number(_obj.monthSignData.clerkSignNum), |
|
|
|
|
'/', |
|
|
|
|
Number(_obj.monthSignData.planNum) |
|
|
|
|
).result; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// 异常签收率 |
|
|
|
|
if ( |
|
|
|
|
!isNumber(_obj.monthBillLadingSignData.clerkOverTimeSignfoNum) || |
|
|
|
|
!isNumber(_obj.monthBillLadingSignData.planNum) || |
|
|
|
|
Number(_obj.monthBillLadingSignData.planNum) === 0 |
|
|
|
|
) { |
|
|
|
|
_obj.monthBillLadingSignData.clerkOverTimeScale = 0; |
|
|
|
|
} else { |
|
|
|
|
_obj.monthBillLadingSignData.clerkOverTimeScale = computeNumber( |
|
|
|
|
_obj.monthBillLadingSignData.clerkOverTimeSignfoNum, |
|
|
|
|
'/', |
|
|
|
|
_obj.monthBillLadingSignData.planNum |
|
|
|
|
).result; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ( |
|
|
|
|
!isNumber(_obj.monthSignData.clerkOverTimeSignfoNum) || |
|
|
|
|
!isNumber(_obj.monthSignData.planNum) || |
|
|
|
|
Number(_obj.monthSignData.planNum) === 0 |
|
|
|
|
) { |
|
|
|
|
_obj.monthSignData.clerkOverTimeScale = 0; |
|
|
|
|
} else { |
|
|
|
|
_obj.monthSignData.clerkOverTimeScale = computeNumber( |
|
|
|
|
_obj.monthSignData.clerkOverTimeSignfoNum, |
|
|
|
|
'/', |
|
|
|
|
_obj.monthSignData.planNum |
|
|
|
|
).result; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// 当日数据 |
|
|
|
@ -2097,11 +2276,12 @@ const initSignforData = async () => {
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
details.signforDataInfo = data || []; |
|
|
|
|
// details.signforDataInfo = data || []; |
|
|
|
|
} catch (error) { |
|
|
|
|
console.log('error :>> ', error); |
|
|
|
|
} finally { |
|
|
|
|
details.signforDataInfo = _obj; |
|
|
|
|
console.log('details.signforDataInfo :>> ', details.signforDataInfo); |
|
|
|
|
details.loadingObj.signforData = false; |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
@ -2156,7 +2336,7 @@ const delivery_bill_info = computed(() => {
|
|
|
|
|
/** 签收数据 */ |
|
|
|
|
const signforData = computed<any>(() => { |
|
|
|
|
const _obj: any = details.signforDataInfo[signforData_status.value] || {}; |
|
|
|
|
console.log('_obj :>> ', _obj); |
|
|
|
|
// console.log('_obj :>> ', _obj); |
|
|
|
|
|
|
|
|
|
_obj.signScaleNum ? _obj.signScaleNum : (_obj.signScaleNum = _obj.signScale || 0); |
|
|
|
|
_obj.clerkSignforScaleNum |
|
|
|
@ -2202,7 +2382,6 @@ const billSignforData = computed<any>(() => {
|
|
|
|
|
|
|
|
|
|
type OptionObjType = { prop: string; tip: string }; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 定义两种颜色 |
|
|
|
|
const colors = ['#008CBA', '#808080']; // 蓝色和灰色 |
|
|
|
|
// /** 获取百分比 */ |
|
|
|
@ -2317,10 +2496,15 @@ const getProportion = (value: number) => {
|
|
|
|
|
// }); |
|
|
|
|
// }; |
|
|
|
|
// 定义显示图表的函数,接受数据、标题、选项对象和图表类型(默认为饼图) |
|
|
|
|
const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType, chartType: string = 'pie') => { |
|
|
|
|
console.log('data :>> ', data); |
|
|
|
|
console.log('title :>> ', title); |
|
|
|
|
console.log('optionObj :>> ', optionObj); |
|
|
|
|
const handleShowEcharts = ( |
|
|
|
|
data: any[], |
|
|
|
|
title: string, |
|
|
|
|
optionObj: OptionObjType, |
|
|
|
|
chartType: string = 'pie' |
|
|
|
|
) => { |
|
|
|
|
console.log('data :>> ', data); |
|
|
|
|
console.log('title :>> ', title); |
|
|
|
|
console.log('optionObj :>> ', optionObj); |
|
|
|
|
|
|
|
|
|
if (getObjType(data) !== 'array') return; // 检查传入的数据是否为数组,如果不是则返回 |
|
|
|
|
|
|
|
|
@ -2344,7 +2528,8 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
const item = _arr[j]; // 获取当前 _arr 中的数据项 |
|
|
|
|
if (item.value > value[optionObj.prop]) continue; // 如果当前 _arr 中的数据项值大于当前数据项的值,继续下一个循环 |
|
|
|
|
|
|
|
|
|
_arr.splice(j, 0, { // 在当前位置插入当前数据项 |
|
|
|
|
_arr.splice(j, 0, { |
|
|
|
|
// 在当前位置插入当前数据项 |
|
|
|
|
name: value.warehouseName, // 数据项的名称 |
|
|
|
|
value: value[optionObj.prop], // 数据项的值 |
|
|
|
|
}); |
|
|
|
@ -2353,13 +2538,15 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
} |
|
|
|
|
if (isContinue) continue; // 如果已插入当前数据项,跳过插入到数组末尾的操作 |
|
|
|
|
|
|
|
|
|
_arr.push({ // 如果未插入,将当前数据项添加到数组末尾 |
|
|
|
|
_arr.push({ |
|
|
|
|
// 如果未插入,将当前数据项添加到数组末尾 |
|
|
|
|
name: value.warehouseName, // 数据项的名称 |
|
|
|
|
value: value[optionObj.prop], // 数据项的值 |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
nextTick(() => { // 确保 DOM 更新完成后再进行图表初始化 |
|
|
|
|
nextTick(() => { |
|
|
|
|
// 确保 DOM 更新完成后再进行图表初始化 |
|
|
|
|
// 获取图表容器元素 |
|
|
|
|
const chartDom = document.getElementById('echartBox'); |
|
|
|
|
if (!chartDom) return; // 如果未找到图表容器元素,则返回 |
|
|
|
@ -2373,7 +2560,7 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
}, |
|
|
|
|
tooltip: { |
|
|
|
|
trigger: 'item', // 设置提示框触发方式为数据项 |
|
|
|
|
formatter: (params) => { |
|
|
|
|
formatter: params => { |
|
|
|
|
if (chartType === 'pie') { |
|
|
|
|
return `${params.name}: ${params.value} (${params.percent}%)`; // 如果是饼图,格式化提示信息为名称、值和百分比 |
|
|
|
|
} else { |
|
|
|
@ -2385,7 +2572,8 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
orient: 'vertical', // 图例布局方向 |
|
|
|
|
left: 'left', // 图例位置 |
|
|
|
|
}, |
|
|
|
|
...(chartType === 'bar' && { // 如果是柱状图,添加柱状图的配置 |
|
|
|
|
...(chartType === 'bar' && { |
|
|
|
|
// 如果是柱状图,添加柱状图的配置 |
|
|
|
|
xAxis: { |
|
|
|
|
type: 'category', // x 轴类型为类别 |
|
|
|
|
data: _arr.map(item => item.name), // x 轴数据为类别名称 |
|
|
|
@ -2397,24 +2585,25 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
yAxis: { |
|
|
|
|
type: 'value', // y 轴类型为数值 |
|
|
|
|
axisLabel: { |
|
|
|
|
formatter: (value) => { |
|
|
|
|
formatter: value => { |
|
|
|
|
return getProportion(value); // 将 y 轴标签格式化为百分比形式 |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
series: [ |
|
|
|
|
{ |
|
|
|
|
name: optionObj.tip, // 系列名称 |
|
|
|
|
type: 'bar', // 系列类型为柱状图 |
|
|
|
|
data: _arr.map(item => ({ // 系列数据 |
|
|
|
|
data: _arr.map(item => ({ |
|
|
|
|
// 系列数据 |
|
|
|
|
name: item.name, // 数据项名称 |
|
|
|
|
value: item.value, // 数据项值 |
|
|
|
|
})), |
|
|
|
|
itemStyle: { |
|
|
|
|
color: (params) => { |
|
|
|
|
color: params => { |
|
|
|
|
// 根据数据项的索引选择颜色 |
|
|
|
|
return colors[params.dataIndex % 2]; |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
emphasis: { |
|
|
|
|
itemStyle: { |
|
|
|
@ -2426,9 +2615,9 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
show: true, // 显示高亮标签 |
|
|
|
|
fontSize: 20, // 高亮标签字体大小 |
|
|
|
|
fontWeight: 'bold', // 高亮标签字体粗细 |
|
|
|
|
formatter: (params) => { |
|
|
|
|
formatter: params => { |
|
|
|
|
return getProportion(params.value); // 高亮标签格式化为百分比形式 |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
barGap: '30%', // 柱子之间的间隔 |
|
|
|
@ -2437,12 +2626,14 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}), |
|
|
|
|
...(chartType === 'pie' && { // 如果是饼图,添加饼图的配置 |
|
|
|
|
...(chartType === 'pie' && { |
|
|
|
|
// 如果是饼图,添加饼图的配置 |
|
|
|
|
series: [ |
|
|
|
|
{ |
|
|
|
|
name: optionObj.tip, // 系列名称 |
|
|
|
|
type: 'pie', // 系列类型为饼图 |
|
|
|
|
data: _arr.map((item) => ({ // 系列数据 |
|
|
|
|
data: _arr.map(item => ({ |
|
|
|
|
// 系列数据 |
|
|
|
|
name: item.name + ' - ' + getProportion(item.value / _total), // 数据项名称,附加百分比 |
|
|
|
|
value: item.value, // 数据项值 |
|
|
|
|
})), |
|
|
|
@ -2469,8 +2660,6 @@ const handleShowEcharts = (data: any[], title: string, optionObj: OptionObjType,
|
|
|
|
|
}); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** 请求详情 */ |
|
|
|
|
const handleDetails = async (type, title, optionObj: OptionObjType) => { |
|
|
|
|
details.popUpShow.isShow = true; |
|
|
|
@ -2534,7 +2723,12 @@ const handleShowDeliveryDetail = (
|
|
|
|
|
handleShowEcharts(data, title, optionObj); |
|
|
|
|
}; |
|
|
|
|
/** 显示售后异常数据 */ |
|
|
|
|
const handleShowAbnormalData = (title, type: 'dayData' | 'monthData', optionObj: any = {},chartType) => { |
|
|
|
|
const handleShowAbnormalData = ( |
|
|
|
|
title, |
|
|
|
|
type: 'dayData' | 'monthData', |
|
|
|
|
optionObj: any = {}, |
|
|
|
|
chartType |
|
|
|
|
) => { |
|
|
|
|
details.popUpShow.isShow = true; |
|
|
|
|
details.title = title; |
|
|
|
|
console.log(optionObj, 'optionObj'); |
|
|
|
@ -2544,7 +2738,7 @@ const handleShowAbnormalData = (title, type: 'dayData' | 'monthData', optionObj:
|
|
|
|
|
if (getObjType(details.unloadAbnormalDataInfo[type]) !== 'object') return; |
|
|
|
|
|
|
|
|
|
const { data } = details.unloadAbnormalDataInfo[type]; |
|
|
|
|
handleShowEcharts(data, title, optionObj,chartType); |
|
|
|
|
handleShowEcharts(data, title, optionObj, chartType); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
/** 显示签收详情 */ |
|
|
|
@ -2567,7 +2761,7 @@ const handleShowSignDetail = (
|
|
|
|
|
|
|
|
|
|
console.log('data :>> ', data); |
|
|
|
|
|
|
|
|
|
handleShowEcharts(data, title, optionObj,chartType); |
|
|
|
|
handleShowEcharts(data, title, optionObj, chartType); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
/** 导出 */ |
|
|
|
|