@media print { /* 页边距 */ @page { margin: .5cm; } * { background: transparent !important; color: #333 !important; box-shadow: none !important; text-shadow: none !important; filter: 0 !important; -ms-filter: 0 !important; } thead { display: table-row-group; } /*table-header-group导致页面中出现表头与内容重叠的现象,表头只需在第一页显示即可*/ tr, td, img { page-break-inside: avoid; } h2, h3 { page-break-after: avoid; } p, h2, h3 { orphans: 3; widows: 3; } table { width: 100% !important; padding: 0 !important; margin: 0; border-color: #333 !important; } table th { width: 0px !important; border: 1px solid #333 !important; white-space: normal !important; word-break: break-all !important; } table td { width: 0px !important; white-space: normal !important; word-break: break-all; padding: 0 10px; border-color: #333 !important; } /* 打印不要出现滚动条 */ .ui-jqgrid .ui-jqgrid-bdiv, .ui-jqgrid .ui-jqgrid-bdiv > div { height: auto !important; width: 100% !important; } }