4.1 同步发版内容到天梯
This commit is contained in:
@ -117,6 +117,7 @@ const Evaluationocuments: React.FC<{}> = (props) => {
|
||||
<Button
|
||||
key="save"
|
||||
type="primary"
|
||||
disabled={editType}
|
||||
loading={spinning}
|
||||
onClick={() => {
|
||||
form.submit();
|
||||
|
@ -161,7 +161,7 @@ const Index: React.FC<upload> = (props) => {
|
||||
{
|
||||
title: '操作',
|
||||
render: (text: any, record: any, index: any) => (
|
||||
<FileDown apiUrl={`/api/core-service-ebtp-updownload/v1/attachment/download/oid/${record.fileId}`} fileName={'回执记录表' + (index + 1)} type='pdf' method='GET' btnName='回执导出' />
|
||||
<FileDown fileId={record.fileId} fileName={'回执记录表' + (index + 1)} type='pdf' method='GET' btnName='回执导出' />
|
||||
),
|
||||
},
|
||||
];
|
||||
|
@ -161,7 +161,7 @@ const Index: React.FC<upload> = (props) => {
|
||||
{
|
||||
title: '操作',
|
||||
render: (text: any, record: any, index: any) => (
|
||||
<FileDown apiUrl={`/api/core-service-ebtp-updownload/v1/attachment/download/oid/${record.fileId}`} fileName={'回执记录表' + (index + 1)} type='pdf' method='GET' btnName='回执导出' />
|
||||
<FileDown fileId={record.fileId} fileName={'回执记录表' + (index + 1)} type='pdf' method='GET' btnName='回执导出' />
|
||||
),
|
||||
},
|
||||
];
|
||||
|
@ -4,8 +4,9 @@ import '@/utils/lq.style.less';
|
||||
import ProTable from '@ant-design/pro-table';
|
||||
import { downMainQuery, updateStatus } from '../service';
|
||||
import { getURLInformation } from '@/utils/CommonUtils';
|
||||
import { downloadAttachmentPath, getDownloadToken } from '@/utils/DownloadUtils';
|
||||
import { downloadFileObjectId } from '@/utils/DownloadUtils';
|
||||
import { nowExceedSpecifiedTime } from '@/utils/DateUtils';
|
||||
import ReviewReportUpload from '@/utils/ReviewReportUpload';
|
||||
|
||||
|
||||
const DownloadPurchasingDocuments: React.FC = () => {
|
||||
@ -13,7 +14,10 @@ const DownloadPurchasingDocuments: React.FC = () => {
|
||||
|
||||
const [tableData, setTableData] = useState<any[]>([]);
|
||||
const [spinningLoading, setSpinningLoading] = useState<boolean>(false);
|
||||
|
||||
//下载附件弹窗
|
||||
const [downloadVisible, setDownloadVisible] = useState<boolean>(false);
|
||||
//下载附件objectId
|
||||
const [downloadObjectId, setDownloadObjectId] = useState<string>('');
|
||||
//表头数据
|
||||
const columns: any[] = [
|
||||
{
|
||||
@ -63,7 +67,7 @@ const DownloadPurchasingDocuments: React.FC = () => {
|
||||
*/
|
||||
const downloadBody = (data: any) => {
|
||||
setSpinningLoading(true);
|
||||
window.location.href = downloadAttachmentPath + data.contentFileId + getDownloadToken();
|
||||
downloadFileObjectId(data.contentFileId);
|
||||
updateDownloadStatus(data.registerId, data.reviewTurnId);
|
||||
}
|
||||
/**
|
||||
@ -71,7 +75,8 @@ const DownloadPurchasingDocuments: React.FC = () => {
|
||||
* @param data
|
||||
*/
|
||||
const downloadAttachment = (data: any) => {
|
||||
window.location.href = downloadAttachmentPath + data.documentSetId + getDownloadToken();
|
||||
setDownloadObjectId(data.documentSetId);
|
||||
setDownloadVisible(true);
|
||||
}
|
||||
/**
|
||||
* 更新状态
|
||||
@ -108,9 +113,15 @@ const DownloadPurchasingDocuments: React.FC = () => {
|
||||
pagination={{ defaultPageSize: 10 }}
|
||||
/>
|
||||
</Spin>
|
||||
{/* <div style={{ textAlign: 'center' }}>
|
||||
<Button onClick={() => window.history.go(-1)}>返回</Button>
|
||||
</div> */}
|
||||
{downloadVisible && <ReviewReportUpload
|
||||
modalVisible={downloadVisible}
|
||||
onCancel={() => {
|
||||
setDownloadVisible(false);
|
||||
setDownloadObjectId('');
|
||||
}}
|
||||
fileId={downloadObjectId}
|
||||
readOnly={true}
|
||||
/>}
|
||||
</Card>
|
||||
</>
|
||||
)
|
||||
|
Reference in New Issue
Block a user