Sfoglia il codice sorgente

Merge branch 'develop' of http://192.168.0.253:3000/bozzysadmb/ISCS-Client-V1.0 into develop

wyn 3 mesi fa
parent
commit
0053ab092a

+ 0 - 28
src/components/WorkJobArchiveReport.css

@@ -123,34 +123,6 @@
   }
 }
 
-/* 打印时仅保留报告区域,避免根节点占高产生空白页(需在点击打印时给 html/body 加 class print-archive-only) */
-@media print {
-  html.print-archive-only,
-  html.print-archive-only body,
-  html.print-archive-only #root,
-  html.print-archive-only #root > * {
-    height: 0 !important;
-    min-height: 0 !important;
-    max-height: 0 !important;
-    overflow: hidden !important;
-    padding: 0 !important;
-    margin: 0 !important;
-  }
-  html.print-archive-only .work-job-archive-report {
-    position: fixed !important;
-    top: 0 !important;
-    left: 0 !important;
-    right: 0 !important;
-    width: 100% !important;
-    height: auto !important;
-    min-height: auto !important;
-    max-height: none !important;
-    overflow: visible !important;
-    z-index: 99999 !important;
-    background: #fff !important;
-  }
-}
-
 /* 水印 - 与 test1 .watermark-bg 完全一致 */
 .work-job-archive-report .watermark-bg {
   background-image: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Ctext x='50%25' y='50%25' font-size='20' fill='%23f3f4f6' transform='rotate(-45 200 200)' text-anchor='middle'%3E内部归档 INTERNAL ONLY%3C/text%3E%3C/svg%3E");

+ 1 - 9
src/components/WorkJobArchiveReport.tsx

@@ -446,15 +446,7 @@ export default function WorkJobArchiveReport() {
     }
   }, [jobDetail, flowNodes.length, setFlowNodes, setFlowEdges]);
 
-  const handlePrint = () => {
-    document.documentElement.classList.add('print-archive-only');
-    document.body.classList.add('print-archive-only');
-    window.print();
-    window.onafterprint = () => {
-      document.documentElement.classList.remove('print-archive-only');
-      document.body.classList.remove('print-archive-only');
-    };
-  };
+  const handlePrint = () => window.print();
 
   const handleExportPdf = async () => {
     if (exportingPdf) return;