|
|
|
@ -143,6 +143,7 @@
|
|
|
|
|
? loadingObj.haveDataList |
|
|
|
|
: loadingObj.notHaveDataList |
|
|
|
|
" |
|
|
|
|
:tableRowClassName="handleSetRowClassName" |
|
|
|
|
@inputTxt="inputsc" |
|
|
|
|
@timeCheck="timesc" |
|
|
|
|
@btnCheck="btnsc" |
|
|
|
@ -150,7 +151,13 @@
|
|
|
|
|
@selection="selectionChange" |
|
|
|
|
> |
|
|
|
|
<template #default="slotProps"> |
|
|
|
|
<template v-if="slotProps.scope.column.label === '操作'"> |
|
|
|
|
<template v-if="slotProps.scope.column.label === '超时状态'"> |
|
|
|
|
<el-tag :class="Number(slotProps.scope.row.isTimeOut) === 0 ? 'green' : 'red'"> |
|
|
|
|
{{ slotProps.scope.row.isTimeOutName }} |
|
|
|
|
</el-tag> |
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
|
<template v-else-if="slotProps.scope.column.label === '操作'"> |
|
|
|
|
<el-text |
|
|
|
|
v-if="permissionObj.TemporaryStorageList_packageDetail" |
|
|
|
|
@click="handleShowPackageOrderList(slotProps.scope)" |
|
|
|
@ -563,6 +570,7 @@ import {
|
|
|
|
|
downloadFileBase64, |
|
|
|
|
handleClearTableQuery, |
|
|
|
|
ChecksWhetherTheWarehouseIsSelected, |
|
|
|
|
handleTranslationDataSeclect, |
|
|
|
|
} from '@/utils/util'; |
|
|
|
|
import { columnList } from '@/option/waybill/TemporaryStorageList'; |
|
|
|
|
import { useRouter } from 'vue-router'; |
|
|
|
@ -1026,6 +1034,8 @@ const onLoad = async (params = {} as any, isRefresh?: boolean) => {
|
|
|
|
|
value.legacyStatusName = Number(value.legacyStatus) ? '是' : '否'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
handleTranslationDataSeclect(data.records, details.columnList); |
|
|
|
|
|
|
|
|
|
if (status === 'haveData') details.haveDataData = data.records; |
|
|
|
|
else details.notHaveDataData = data.records; |
|
|
|
|
details.page.total = data.total; |
|
|
|
@ -1508,6 +1518,27 @@ const handleSubmitCreatePackage = async () => {
|
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
const date = new Date(); |
|
|
|
|
|
|
|
|
|
/** 设置表格行样式 */ |
|
|
|
|
const handleSetRowClassName = (row, rowIndex) => { |
|
|
|
|
if (!row.createTime) return 'timeOut'; |
|
|
|
|
|
|
|
|
|
// 设置预警 -- 以创建时间为基准, 24小时后为超期, 临近2小时为临期 |
|
|
|
|
|
|
|
|
|
// 当前时间 - 创建时间 |
|
|
|
|
const time = Date.now() - new Date(row.createTime).getTime(); |
|
|
|
|
|
|
|
|
|
// 预警时间 |
|
|
|
|
const WarningTime = 1000 * 60 * 60 * 22; |
|
|
|
|
|
|
|
|
|
// 超时 |
|
|
|
|
const timeOut = 1000 * 60 * 60 * 24; |
|
|
|
|
|
|
|
|
|
if (time > timeOut) return 'timeOut'; |
|
|
|
|
else if (time > WarningTime && time < timeOut) return 'WarningTime'; |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
onActivated(() => { |
|
|
|
|
console.log('activated'); |
|
|
|
|
console.log('this.$store :>> ', $store); |
|
|
|
@ -1689,4 +1720,25 @@ onActivated(() => {
|
|
|
|
|
text-align: left !important; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// 表格行样式 |
|
|
|
|
:deep(.el-table) { |
|
|
|
|
tr { |
|
|
|
|
&.WarningTime { |
|
|
|
|
color: #e6a23c !important; |
|
|
|
|
|
|
|
|
|
.el-text { |
|
|
|
|
color: #e6a23c !important; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
&.timeOut { |
|
|
|
|
color: #f56c6c !important; |
|
|
|
|
|
|
|
|
|
.el-text { |
|
|
|
|
color: #f56c6c !important; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
</style> |
|
|
|
|