Commit 4406a0cd authored by Deep Dey's avatar Deep Dey

chore: add page-breaks after each admission form data

parent a262bc46
...@@ -9,9 +9,11 @@ ...@@ -9,9 +9,11 @@
margin: 0; margin: 0;
padding: 0; padding: 0;
} }
body { body {
width: 100%; width: 100%;
} }
.container { .container {
display: flex; display: flex;
justify-content: center; justify-content: center;
...@@ -19,6 +21,7 @@ ...@@ -19,6 +21,7 @@
flex-direction: column; flex-direction: column;
width: 100%; width: 100%;
} }
.table-container { .table-container {
width: 100%; width: 100%;
padding: 20px; padding: 20px;
...@@ -28,37 +31,46 @@ ...@@ -28,37 +31,46 @@
justify-content: center; justify-content: center;
} }
table { table {
width: 100%; width: 100%;
border-collapse: collapse; border-collapse: collapse;
} }
th, th,
td { td {
padding: 10px; padding: 10px;
text-align: left; text-align: left;
} }
th { th {
background-color: #4CAF50; background-color: #4CAF50;
color: white; color: white;
font-size: 14px; font-size: 14px;
} }
td { td {
background-color: #f9f9f9; background-color: #f9f9f9;
border-bottom: 1px solid #ddd; border-bottom: 1px solid #ddd;
font-size: 12px; font-size: 12px;
} }
tr:hover td { tr:hover td {
background-color: #f1f1f1; background-color: #f1f1f1;
} }
tr:nth-child(even) td { tr:nth-child(even) td {
background-color: #f2f2f2; background-color: #f2f2f2;
} }
th:first-child, td:first-child { th:first-child, td:first-child {
width: 30%; width: 30%;
} }
th:nth-child(2), td:nth-child(2) { th:nth-child(2), td:nth-child(2) {
width: 70%; width: 70%;
} }
.title { .title {
/*text-align: center;*/ /*text-align: center;*/
font-size: 18px; font-size: 18px;
...@@ -66,12 +78,14 @@ ...@@ -66,12 +78,14 @@
color: #333; color: #333;
font-weight: bold; font-weight: bold;
} }
.page-break { page-break-after: always; }
</style> </style>
</head> </head>
<body> <body>
<div class="container" th:each="admissionForm : ${admissionFormList}"> <div class="container" th:each="admissionForm : ${admissionFormList}">
<div class="table-container"> <div class="table-container page-break">
<div class="title">Candidate Information (<span th:text="${admissionForm.fullName}"></span>)</div> <div class="title">Candidate Information (<span th:text="${admissionForm.fullName}"></span>)</div>
<table> <table>
<tr> <tr>
......
...@@ -201,6 +201,16 @@ $(document).ready(function () { ...@@ -201,6 +201,16 @@ $(document).ready(function () {
checkedValues.push($(this).data('id')); checkedValues.push($(this).data('id'));
}); });
if (checkedValues.length == 0) {
$('#messageModal .modal-title').text('Error');
$('#messageModal .modal-body').text(
'Please select at least one form to download admission data.'
);
$('#messageModal').modal('show');
return;
}
window window
.open( .open(
BASE_URL_LAMARTIN + BASE_URL_LAMARTIN +
......
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