Commit 8c18cd40 authored by 涂伟's avatar 涂伟

fix: '维保卡片预览优化'

parent 37aa7570
...@@ -73,7 +73,8 @@ const OptionEditModal = props => { ...@@ -73,7 +73,8 @@ const OptionEditModal = props => {
const [previewVisible, setPreviewVisible] = useState(false); // 预览文件弹窗 const [previewVisible, setPreviewVisible] = useState(false); // 预览文件弹窗
const [fileType, setFileType] = useState('pdf'); // 预览文件类型 const [fileType, setFileType] = useState('pdf'); // 预览文件类型
const [fileUrl, setFileUrl] = useState( const [fileUrl, setFileUrl] = useState(
'http://192.168.10.167:8088/PandaWorkFlow/WorkFlow/AccountManage/DownloadFiles?filePath=520d9de3-b69b-42c0-bb65-f198a30d0cd4\\%E5%B7%A5%E5%8D%95%E6%97%B6%E9%99%90%E9%85%8D%E7%BD%AE.pdf', '',
// 'http://192.168.10.167:8088/PandaWorkFlow/WorkFlow/AccountManage/DownloadFiles?filePath=520d9de3-b69b-42c0-bb65-f198a30d0cd4\\%E5%B7%A5%E5%8D%95%E6%97%B6%E9%99%90%E9%85%8D%E7%BD%AE.pdf',
); // 预览文件路径 ); // 预览文件路径
const [form] = Form.useForm(); const [form] = Form.useForm();
...@@ -298,6 +299,7 @@ const OptionEditModal = props => { ...@@ -298,6 +299,7 @@ const OptionEditModal = props => {
const uprops = { const uprops = {
// action: `${window.location.origin}/PandaWorkFlow/WorkFlow/AccountManage/UploaderFiles`, // action: `${window.location.origin}/PandaWorkFlow/WorkFlow/AccountManage/UploaderFiles`,
action: `${window.origin}/PandaWorkFlow/WorkFlow/AccountManage/UploaderFiles`, action: `${window.origin}/PandaWorkFlow/WorkFlow/AccountManage/UploaderFiles`,
// action: `http://192.168.10.167:8088/PandaWorkFlow/WorkFlow/AccountManage/UploaderFiles`,
multiple: true, multiple: true,
}; };
...@@ -316,10 +318,18 @@ const OptionEditModal = props => { ...@@ -316,10 +318,18 @@ const OptionEditModal = props => {
const preview = item => { const preview = item => {
setFileType(item.type); setFileType(item.type);
// setFileUrl(
// `${`${window.origin}/PandaWorkFlow/WorkFlow/AccountManage/DownloadFiles?filePath=`}${
// item.pdfUrl
// }`,
// );
setFileUrl( setFileUrl(
`${`${window.origin}/PandaWorkFlow/WorkFlow/AccountManage/DownloadFiles?filePath=`}${ `${`${window.origin}/PandaWorkFlow/WorkFlow/AccountManage/DownloadFiles?filePath=`}${
item.pdfUrl item.pdfUrl
}`, }`,
// `http://192.168.10.167:8088/PandaWorkFlow/WorkFlow/AccountManage/DownloadFiles?filePath=${
// item.pdfUrl
// }`,
); );
setPreviewVisible(true); setPreviewVisible(true);
}; };
......
...@@ -248,6 +248,7 @@ const maintenance = () => { ...@@ -248,6 +248,7 @@ const maintenance = () => {
useEffect(() => { useEffect(() => {
setTreeLoading(true); setTreeLoading(true);
console.log(activeName, 'activeNameactiveNameactiveName');
if (activeName === 'template') { if (activeName === 'template') {
CM_XWBPlan_DataList().then(res => { CM_XWBPlan_DataList().then(res => {
setTreeLoading(false); setTreeLoading(false);
...@@ -686,7 +687,6 @@ const maintenance = () => { ...@@ -686,7 +687,6 @@ const maintenance = () => {
}; };
const sort = () => { const sort = () => {
console.log('触发咯6666');
setSortVisible(true); setSortVisible(true);
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment