|
|
|
|
@ -201,7 +201,7 @@
|
|
|
|
|
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column label="操作" align="center" width="140" fixed="right" class-name="small-padding fixed-width">
|
|
|
|
|
<el-table-column label="操作" align="center" width="180" fixed="right" class-name="small-padding fixed-width">
|
|
|
|
|
<template #default="scope">
|
|
|
|
|
<el-tooltip content="查看详情" placement="top" v-if="canViewDetail(scope.row)">
|
|
|
|
|
<el-button link type="info" icon="DocumentChecked" @click="handleView(scope.row)"></el-button>
|
|
|
|
|
@ -209,10 +209,19 @@
|
|
|
|
|
<el-tooltip content="修改" placement="top" v-if="scope.row.contractStatus === '1'">
|
|
|
|
|
<el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['oa/erp:contractInfo:edit']"></el-button>
|
|
|
|
|
</el-tooltip>
|
|
|
|
|
<el-tooltip content="修改并重提审批" placement="top" v-if="canReapproveAfterApproved(scope.row)">
|
|
|
|
|
<el-button
|
|
|
|
|
link
|
|
|
|
|
type="warning"
|
|
|
|
|
icon="RefreshRight"
|
|
|
|
|
@click="handleReapprove(scope.row)"
|
|
|
|
|
v-hasPermi="['oa/erp:contractInfo:edit']"
|
|
|
|
|
></el-button>
|
|
|
|
|
</el-tooltip>
|
|
|
|
|
<!-- <el-tooltip content="审批记录" placement="top" v-if="scope.row.contractStatus === '2' || scope.row.contractStatus === '3'">-->
|
|
|
|
|
<!-- <el-button link type="info" icon="View" @click="handleApprovalRecord(scope.row)"></el-button>-->
|
|
|
|
|
<!-- </el-tooltip>-->
|
|
|
|
|
<el-tooltip content="合同模板" placement="top" v-if="scope.row.templateId != null">
|
|
|
|
|
<el-tooltip content="合同下载" placement="top" v-if="scope.row.templateId != null">
|
|
|
|
|
<el-button link type="info" icon="Download" @click="contractView(scope.row)"></el-button>
|
|
|
|
|
</el-tooltip>
|
|
|
|
|
<el-tooltip content="审批单导出" placement="top" v-if="scope.row.contractStatus == 3">
|
|
|
|
|
@ -575,6 +584,24 @@ const handleUpdate = (row?: ContractInfoVO) => {
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
/** 合同状态为可用(审批通过,contract_status=3):可进入编辑修改并重新发起审批 */
|
|
|
|
|
const canReapproveAfterApproved = (row: ContractInfoVO) => {
|
|
|
|
|
return String(row.contractStatus) === '3';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
const handleReapprove = (row: ContractInfoVO) => {
|
|
|
|
|
const _contractId = row?.contractId;
|
|
|
|
|
if (!_contractId) return;
|
|
|
|
|
proxy.$tab.closePage(route);
|
|
|
|
|
router.push({
|
|
|
|
|
path: '/contract/contractInfo/edit',
|
|
|
|
|
query: {
|
|
|
|
|
id: _contractId,
|
|
|
|
|
type: 'reapprove'
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
const handleView = (row?: ContractInfoVO) => {
|
|
|
|
|
const _contractId = row?.contractId;
|
|
|
|
|
proxy.$tab.closePage(route);
|
|
|
|
|
|