Compare commits
7
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6119c44394 | ||
|
|
9dab7f7495 | ||
|
|
f5697e111a | ||
|
|
775307f5c0 | ||
|
|
4502881063 | ||
|
|
358add743e | ||
|
|
f67a4036ed |
@@ -1,4 +1,5 @@
|
|||||||
import { createCrudApi } from './common';
|
import { createCrudApi } from './common';
|
||||||
|
import { APPROVE_TIMEOUT } from '@/api/common';
|
||||||
import request from '@/axios';
|
import request from '@/axios';
|
||||||
|
|
||||||
const baseUrl = '/blade-transport/contract-change';
|
const baseUrl = '/blade-transport/contract-change';
|
||||||
@@ -35,8 +36,7 @@ export const approve = id =>
|
|||||||
url: `${baseUrl}/approve`,
|
url: `${baseUrl}/approve`,
|
||||||
method: 'post',
|
method: 'post',
|
||||||
params: { id },
|
params: { id },
|
||||||
// 审批通过后同步推送合规(附件转传可达 20s+),覆盖全局 10s 超时
|
timeout: APPROVE_TIMEOUT,
|
||||||
timeout: 120000,
|
|
||||||
});
|
});
|
||||||
|
|
||||||
export const reject = id =>
|
export const reject = id =>
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import { createCrudApi } from './common';
|
import { createCrudApi } from './common';
|
||||||
|
import { APPROVE_TIMEOUT } from '@/api/common';
|
||||||
import request from '@/axios';
|
import request from '@/axios';
|
||||||
|
|
||||||
const baseUrl = '/blade-transport/contract-manage';
|
const baseUrl = '/blade-transport/contract-manage';
|
||||||
@@ -36,8 +37,7 @@ export const approve = id =>
|
|||||||
url: `${baseUrl}/approve`,
|
url: `${baseUrl}/approve`,
|
||||||
method: 'post',
|
method: 'post',
|
||||||
params: { id },
|
params: { id },
|
||||||
// 审批通过后同步推送合规(附件转传可达 20s+),覆盖全局 10s 超时
|
timeout: APPROVE_TIMEOUT,
|
||||||
timeout: 120000,
|
|
||||||
});
|
});
|
||||||
|
|
||||||
export const reject = id =>
|
export const reject = id =>
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import { createCrudApi } from './common';
|
import { createCrudApi } from './common';
|
||||||
|
import { APPROVE_TIMEOUT } from '@/api/common';
|
||||||
import request from '@/axios';
|
import request from '@/axios';
|
||||||
|
|
||||||
const baseUrl = '/blade-transport/project-change';
|
const baseUrl = '/blade-transport/project-change';
|
||||||
@@ -35,6 +36,7 @@ export const approve = id =>
|
|||||||
url: `${baseUrl}/approve`,
|
url: `${baseUrl}/approve`,
|
||||||
method: 'post',
|
method: 'post',
|
||||||
params: { id },
|
params: { id },
|
||||||
|
timeout: APPROVE_TIMEOUT,
|
||||||
});
|
});
|
||||||
|
|
||||||
export const reject = id =>
|
export const reject = id =>
|
||||||
|
|||||||
@@ -169,7 +169,7 @@ export const paymentApplicationOption = ({
|
|||||||
{ label: '当前节点', prop: 'currentNode', minWidth: 120, formatter: textFormatter },
|
{ label: '当前节点', prop: 'currentNode', minWidth: 120, formatter: textFormatter },
|
||||||
{ label: '当前处理人', prop: 'currentProcessor', minWidth: 120, formatter: textFormatter },
|
{ label: '当前处理人', prop: 'currentProcessor', minWidth: 120, formatter: textFormatter },
|
||||||
{ label: '金蝶单据号', prop: 'kingdeeBillNo', minWidth: 130, formatter: textFormatter },
|
{ label: '金蝶单据号', prop: 'kingdeeBillNo', minWidth: 130, formatter: textFormatter },
|
||||||
{ label: '金蝶单据状态', prop: 'kingdeeStatusName', minWidth: 130, formatter: textFormatter },
|
{ label: '金蝶单据状态', prop: 'kingdeeStatusName', slot: true, minWidth: 130 },
|
||||||
{ label: '金蝶锁状态', prop: 'kingdeeLockStatus', slot: true, minWidth: 150 },
|
{ label: '金蝶锁状态', prop: 'kingdeeLockStatus', slot: true, minWidth: 150 },
|
||||||
{ label: '附件同步', prop: 'attachmentSyncStatusName', minWidth: 100, formatter: textFormatter },
|
{ label: '附件同步', prop: 'attachmentSyncStatusName', minWidth: 100, formatter: textFormatter },
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -99,7 +99,8 @@ const buildTableColumns = () =>
|
|||||||
}
|
}
|
||||||
// link / status 标记的列统一走单元格插槽
|
// link / status 标记的列统一走单元格插槽
|
||||||
if (column.link || column.status) extra.slot = true;
|
if (column.link || column.status) extra.slot = true;
|
||||||
if (!extra.formatter) extra.formatter = textFormatter;
|
// 插槽列不挂兜底 formatter:avue 中 formatter 会覆盖单元格插槽渲染
|
||||||
|
if (!extra.slot && !extra.formatter) extra.formatter = textFormatter;
|
||||||
return { ...column, ...extra };
|
return { ...column, ...extra };
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,15 @@
|
|||||||
|
/**
|
||||||
|
* 金蝶单据状态公共映射
|
||||||
|
*/
|
||||||
|
|
||||||
|
/** 金蝶单据状态 → el-tag 颜色类型(failed 状态列表页悬浮展示失败原因) */
|
||||||
|
export const KINGDEE_STATUS_TAG_TYPES = {
|
||||||
|
synced: 'success',
|
||||||
|
paid: 'success',
|
||||||
|
invoiced: 'success',
|
||||||
|
paying: 'warning',
|
||||||
|
failed: 'danger',
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 金蝶单据状态 → el-tag 颜色类型,未映射状态返回 info */
|
||||||
|
export const kingdeeStatusType = status => KINGDEE_STATUS_TAG_TYPES[status] || 'info';
|
||||||
@@ -125,6 +125,17 @@
|
|||||||
{{ displayValue(row[column.prop]) }}
|
{{ displayValue(row[column.prop]) }}
|
||||||
</el-tag>
|
</el-tag>
|
||||||
<span v-else-if="column.money">{{ formatMoney(row[column.prop]) }}</span>
|
<span v-else-if="column.money">{{ formatMoney(row[column.prop]) }}</span>
|
||||||
|
<template v-else-if="column.prop === 'kingdeeStatusName'">
|
||||||
|
<el-tooltip
|
||||||
|
:disabled="row.kingdeeStatus !== 'failed'"
|
||||||
|
:content="row.kingdeeFailReason || '推送金蝶失败,可点击「同步金蝶」重试'"
|
||||||
|
placement="top"
|
||||||
|
>
|
||||||
|
<el-tag :type="kingdeeStatusType(row.kingdeeStatus)">{{
|
||||||
|
row.kingdeeStatusName || '-'
|
||||||
|
}}</el-tag>
|
||||||
|
</el-tooltip>
|
||||||
|
</template>
|
||||||
<template v-else-if="column.prop === 'kingdeeLockStatus'">
|
<template v-else-if="column.prop === 'kingdeeLockStatus'">
|
||||||
<el-tooltip v-if="lockTag(row).show" :content="lockTag(row).tip" placement="top">
|
<el-tooltip v-if="lockTag(row).show" :content="lockTag(row).tip" placement="top">
|
||||||
<el-tag :type="lockTag(row).type" class="status-text">{{ lockTag(row).label }}</el-tag>
|
<el-tag :type="lockTag(row).type" class="status-text">{{ lockTag(row).label }}</el-tag>
|
||||||
@@ -238,6 +249,7 @@ import TableHeaderTools from '@/components/table-header-tools/main.vue';
|
|||||||
import organizationSearch from '@/mixins/organization-search';
|
import organizationSearch from '@/mixins/organization-search';
|
||||||
import { getMKApprovalUrl } from '@/api/system/business-process';
|
import { getMKApprovalUrl } from '@/api/system/business-process';
|
||||||
import { loadMkEnabled, submitMkApprovalFlow } from '@/utils/mk-approval';
|
import { loadMkEnabled, submitMkApprovalFlow } from '@/utils/mk-approval';
|
||||||
|
import { kingdeeStatusType } from '@/utils/kingdee';
|
||||||
|
|
||||||
const emptyQuery = () => ({
|
const emptyQuery = () => ({
|
||||||
applicationNo: '',
|
applicationNo: '',
|
||||||
@@ -500,6 +512,7 @@ export default {
|
|||||||
''
|
''
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
kingdeeStatusType,
|
||||||
lockTag(row) {
|
lockTag(row) {
|
||||||
if (row.kingdeeLockStatus === 'locked') {
|
if (row.kingdeeLockStatus === 'locked') {
|
||||||
return { show: true, type: 'danger', label: '金蝶锁定中', tip: '该单据已被金蝶锁定,不可编辑/作废' };
|
return { show: true, type: 'danger', label: '金蝶锁定中', tip: '该单据已被金蝶锁定,不可编辑/作废' };
|
||||||
|
|||||||
@@ -68,6 +68,18 @@
|
|||||||
<span v-else>-</span>
|
<span v-else>-</span>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<template #kingdeeStatusName="{ row }">
|
||||||
|
<el-tooltip
|
||||||
|
:disabled="row.kingdeeStatus !== 'failed'"
|
||||||
|
:content="row.kingdeeFailReason || '推送金蝶失败,可点击「同步金蝶」重试'"
|
||||||
|
placement="top"
|
||||||
|
>
|
||||||
|
<el-tag :type="kingdeeStatusType(row.kingdeeStatus)">{{
|
||||||
|
row.kingdeeStatusName || '-'
|
||||||
|
}}</el-tag>
|
||||||
|
</el-tooltip>
|
||||||
|
</template>
|
||||||
|
|
||||||
<template #menu="{ row }">
|
<template #menu="{ row }">
|
||||||
<el-link
|
<el-link
|
||||||
v-if="hasPermission('payment_application_view')"
|
v-if="hasPermission('payment_application_view')"
|
||||||
@@ -151,6 +163,7 @@ import { paymentApplicationOption } from '@/option/payment/paymentApplication';
|
|||||||
import organizationSearch from '@/mixins/organization-search';
|
import organizationSearch from '@/mixins/organization-search';
|
||||||
import { getMKApprovalUrl } from '@/api/system/business-process';
|
import { getMKApprovalUrl } from '@/api/system/business-process';
|
||||||
import { loadMkEnabled, submitMkApprovalFlow } from '@/utils/mk-approval';
|
import { loadMkEnabled, submitMkApprovalFlow } from '@/utils/mk-approval';
|
||||||
|
import { kingdeeStatusType } from '@/utils/kingdee';
|
||||||
|
|
||||||
const paymentApplicationListRoute = '/payment/payment-application';
|
const paymentApplicationListRoute = '/payment/payment-application';
|
||||||
const paymentApplicationListRefreshKey = 'payment-application-list-refresh';
|
const paymentApplicationListRefreshKey = 'payment-application-list-refresh';
|
||||||
@@ -328,15 +341,17 @@ export default {
|
|||||||
this.refreshChange();
|
this.refreshChange();
|
||||||
},
|
},
|
||||||
async handleApprove(row) {
|
async handleApprove(row) {
|
||||||
// 防止重复点击:请求进行中忽略后续点击
|
// 防止重复点击:请求进行中忽略后续点击,避免重复审批和重复提示
|
||||||
if (this.approveLoading) return;
|
if (this.approveLoading) return;
|
||||||
this.approveLoading = true;
|
this.approveLoading = true;
|
||||||
const loading = this.$loading({
|
let loading = null;
|
||||||
lock: true,
|
|
||||||
text: '审批处理中,请稍候…',
|
|
||||||
background: 'rgba(255, 255, 255, 0.6)',
|
|
||||||
});
|
|
||||||
try {
|
try {
|
||||||
|
await this.$confirm('确认审批通过该付款申请?', '提示', { type: 'warning' });
|
||||||
|
loading = this.$loading({
|
||||||
|
lock: true,
|
||||||
|
text: '审批处理中,请稍候…',
|
||||||
|
background: 'rgba(255, 255, 255, 0.6)',
|
||||||
|
});
|
||||||
const res = await api.approve({ id: row.id });
|
const res = await api.approve({ id: row.id });
|
||||||
// data=false 表示审批已通过但自动同步金蝶失败,msg 带具体原因
|
// data=false 表示审批已通过但自动同步金蝶失败,msg 带具体原因
|
||||||
if (res.data.data === false) {
|
if (res.data.data === false) {
|
||||||
@@ -346,7 +361,7 @@ export default {
|
|||||||
}
|
}
|
||||||
this.refreshChange();
|
this.refreshChange();
|
||||||
} finally {
|
} finally {
|
||||||
loading.close();
|
loading?.close();
|
||||||
this.approveLoading = false;
|
this.approveLoading = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -461,6 +476,7 @@ export default {
|
|||||||
''
|
''
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
kingdeeStatusType,
|
||||||
lockTag(row) {
|
lockTag(row) {
|
||||||
if (row.kingdeeLockStatus === 'locked') {
|
if (row.kingdeeLockStatus === 'locked') {
|
||||||
return { show: true, type: 'danger', label: '金蝶锁定中', tip: '该单据已被金蝶锁定,不可编辑/作废' };
|
return { show: true, type: 'danger', label: '金蝶锁定中', tip: '该单据已被金蝶锁定,不可编辑/作废' };
|
||||||
|
|||||||
@@ -60,7 +60,17 @@
|
|||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template #kingdeeSyncStatus="{ row }">{{ kingdeeSyncName(row.kingdeeSyncStatus) }}</template>
|
<template #kingdeeSyncStatus="{ row }">
|
||||||
|
<el-tooltip
|
||||||
|
:disabled="row.kingdeeSyncStatus !== 'failed'"
|
||||||
|
:content="row.kingdeeFailReason || '推送金蝶失败,可点击「同步金蝶」重试'"
|
||||||
|
placement="top"
|
||||||
|
>
|
||||||
|
<el-tag :type="kingdeeStatusType(row.kingdeeSyncStatus)">{{
|
||||||
|
kingdeeSyncName(row.kingdeeSyncStatus)
|
||||||
|
}}</el-tag>
|
||||||
|
</el-tooltip>
|
||||||
|
</template>
|
||||||
|
|
||||||
<template #kingdeeLockStatus="{ row }">
|
<template #kingdeeLockStatus="{ row }">
|
||||||
<el-tooltip v-if="lockTag(row).show" :content="lockTag(row).tip" placement="top">
|
<el-tooltip v-if="lockTag(row).show" :content="lockTag(row).tip" placement="top">
|
||||||
@@ -84,6 +94,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import { invoiceStatusName } from '@/option/settlement/formalSettlementSearch';
|
import { invoiceStatusName } from '@/option/settlement/formalSettlementSearch';
|
||||||
import { kingdeeSyncName, paymentStatusName } from '@/option/settlement/formalSettlement';
|
import { kingdeeSyncName, paymentStatusName } from '@/option/settlement/formalSettlement';
|
||||||
|
import { kingdeeStatusType } from '@/utils/kingdee';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'FormalSettlementTablePanel',
|
name: 'FormalSettlementTablePanel',
|
||||||
@@ -186,6 +197,7 @@ export default {
|
|||||||
''
|
''
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
kingdeeStatusType,
|
||||||
invoiceName(value, settlementType) {
|
invoiceName(value, settlementType) {
|
||||||
return invoiceStatusName(value, settlementType);
|
return invoiceStatusName(value, settlementType);
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -93,11 +93,15 @@
|
|||||||
><el-tag v-else-if="column.status" :type="statusType(row.approvalStatus)" class="status-text">{{
|
><el-tag v-else-if="column.status" :type="statusType(row.approvalStatus)" class="status-text">{{
|
||||||
row[column.prop] || '-'
|
row[column.prop] || '-'
|
||||||
}}</el-tag
|
}}</el-tag
|
||||||
><el-tag
|
><el-tooltip
|
||||||
v-else-if="column.kingdee"
|
v-else-if="column.kingdee"
|
||||||
|
:disabled="row.kingdeeSyncStatus !== 'failed'"
|
||||||
|
:content="row.kingdeeFailReason || '推送金蝶失败,请重试'"
|
||||||
|
placement="top"
|
||||||
|
><el-tag
|
||||||
:type="kingdeeStatusType(row.kingdeeSyncStatus)"
|
:type="kingdeeStatusType(row.kingdeeSyncStatus)"
|
||||||
class="status-text"
|
|
||||||
>{{ kingdeeSyncName(row.kingdeeSyncStatus) }}</el-tag
|
>{{ kingdeeSyncName(row.kingdeeSyncStatus) }}</el-tag
|
||||||
|
></el-tooltip
|
||||||
><span v-else-if="column.money">{{ formatMoney(row[column.prop]) }}</span
|
><span v-else-if="column.money">{{ formatMoney(row[column.prop]) }}</span
|
||||||
><span v-else>{{ displayValue(row[column.prop]) }}</span></template
|
><span v-else>{{ displayValue(row[column.prop]) }}</span></template
|
||||||
></el-table-column
|
></el-table-column
|
||||||
@@ -182,6 +186,7 @@ import { settlementAdjustmentSearchFields } from '@/option/settlement/settlement
|
|||||||
import organizationSearch from '@/mixins/organization-search';
|
import organizationSearch from '@/mixins/organization-search';
|
||||||
import { settlementAdjustmentTableColumns } from '@/option/settlement/settlementAdjustmentTable';
|
import { settlementAdjustmentTableColumns } from '@/option/settlement/settlementAdjustmentTable';
|
||||||
import { kingdeeSyncStatusOptions } from '@/option/settlement/formalSettlementSearch';
|
import { kingdeeSyncStatusOptions } from '@/option/settlement/formalSettlementSearch';
|
||||||
|
import { kingdeeStatusType } from '@/utils/kingdee';
|
||||||
import SettlementAdjustmentEditor from './components/settlement-adjustment-editor.vue';
|
import SettlementAdjustmentEditor from './components/settlement-adjustment-editor.vue';
|
||||||
import SettlementTableTools from './components/settlement-table-tools.vue';
|
import SettlementTableTools from './components/settlement-table-tools.vue';
|
||||||
import { isAdministrator } from '@/utils/auth';
|
import { isAdministrator } from '@/utils/auth';
|
||||||
@@ -365,9 +370,7 @@ export default {
|
|||||||
'info'
|
'info'
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
kingdeeStatusType(status) {
|
kingdeeStatusType,
|
||||||
return { synced: 'success', failed: 'danger' }[status] || 'info';
|
|
||||||
},
|
|
||||||
kingdeeSyncName(value) {
|
kingdeeSyncName(value) {
|
||||||
return kingdeeSyncStatusOptions.find(item => item.value === value)?.label || value || '-';
|
return kingdeeSyncStatusOptions.find(item => item.value === value)?.label || value || '-';
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -135,7 +135,13 @@
|
|||||||
<template #kingdeeStatus="{ row }">
|
<template #kingdeeStatus="{ row }">
|
||||||
<el-tag v-if="row.kingdeeStatus === 'synced'" type="success">已推送</el-tag>
|
<el-tag v-if="row.kingdeeStatus === 'synced'" type="success">已推送</el-tag>
|
||||||
<el-tag v-else-if="row.kingdeeStatus === 'exist'" type="primary">金蝶已有</el-tag>
|
<el-tag v-else-if="row.kingdeeStatus === 'exist'" type="primary">金蝶已有</el-tag>
|
||||||
<el-tag v-else-if="row.kingdeeStatus === 'failed'" type="danger">推送失败</el-tag>
|
<el-tooltip
|
||||||
|
v-else-if="row.kingdeeStatus === 'failed'"
|
||||||
|
:content="row.kingdeeFailReason || '推送金蝶失败,请重试'"
|
||||||
|
placement="top"
|
||||||
|
>
|
||||||
|
<el-tag type="danger">推送失败</el-tag>
|
||||||
|
</el-tooltip>
|
||||||
<el-tag v-else type="info">未推送</el-tag>
|
<el-tag v-else type="info">未推送</el-tag>
|
||||||
</template>
|
</template>
|
||||||
<template #menu="{ row }">
|
<template #menu="{ row }">
|
||||||
|
|||||||
Reference in New Issue
Block a user