DONE: use full name for date in letter, include password in email after membership is done, block ic_number to exclude - (#9)
Co-authored-by: ISMAIL MASSERAN <topaz@ISMAILs-Macbook.local> Reviewed-on: #9
This commit was merged in pull request #9.
This commit is contained in:
@@ -100,6 +100,8 @@ const props = withDefaults(defineProps<{
|
||||
currentSort?: SortConfig[];
|
||||
exportable?: boolean;
|
||||
exportFileName?: string;
|
||||
/** Title shown at the top of exported PDF documents. */
|
||||
exportPdfTitle?: string;
|
||||
/** When true, table body scrolls inside a max-height box instead of growing the page. */
|
||||
scrollable?: boolean;
|
||||
/** Max height of the scrollable table area (CSS value). */
|
||||
@@ -622,12 +624,22 @@ const exportToPDF = () => {
|
||||
else if (colCount > 8) fontSize = 7;
|
||||
const cellPadding = colCount > 8 ? 4 : 8;
|
||||
|
||||
let tableStartY = 20;
|
||||
if (props.exportPdfTitle?.trim()) {
|
||||
doc.setFontSize(14);
|
||||
doc.text(props.exportPdfTitle.trim(), doc.internal.pageSize.getWidth() / 2, 28, {
|
||||
align: 'center',
|
||||
});
|
||||
tableStartY = 48;
|
||||
}
|
||||
|
||||
const tableOptions: Parameters<typeof autoTable>[1] = {
|
||||
head: [headers],
|
||||
body: data,
|
||||
startY: tableStartY,
|
||||
styles: { fontSize, cellPadding },
|
||||
headStyles: { fillColor: [66, 139, 202] },
|
||||
margin: { top: 20 },
|
||||
margin: { top: tableStartY },
|
||||
};
|
||||
|
||||
// For wide tables: let table use natural column widths and split across pages
|
||||
|
||||
Reference in New Issue
Block a user