Fix JavaScript syntax error in nested ternary operators
This commit is contained in:
1 parent
168052ed0c
commit
90ed775883
1 file changed
+21
-24
+21
-24
@@ -1300,31 +1300,28 @@ def jobs():
|
|||||||
</div>
|
</div>
|
||||||
`).join('')}
|
`).join('')}
|
||||||
` : ''}
|
` : ''}
|
||||||
${job.status === 'completed' ? `
|
${job.status === 'completed' ? (job.zip_name ? `
|
||||||
${job.zip_name ? `
|
<p><a href="/download/${job.zip_name}" class="download-btn">Download ZIP</a>
|
||||||
<p><a href="/download/${job.zip_name}" class="download-btn">Download ZIP</a>
|
<form method="post" action="/delete/${jobId}" style="display: inline;">
|
||||||
<form method="post" action="/delete/${jobId}" style="display: inline;">
|
<button type="submit" class="delete-btn" onclick="return confirm('Are you sure you want to delete this job?')">Delete Job</button>
|
||||||
<button type="submit" class="delete-btn" onclick="return confirm('Are you sure you want to delete this job?')">Delete Job</button>
|
</form></p>
|
||||||
</form></p>
|
` : `
|
||||||
` : `
|
<p><em>No files were successfully processed to create a ZIP archive.</em>
|
||||||
<p><em>No files were successfully processed to create a ZIP archive.</em>
|
<form method="post" action="/delete/${jobId}" style="display: inline;">
|
||||||
<form method="post" action="/delete/${jobId}" style="display: inline;">
|
<button type="submit" class="delete-btn" onclick="return confirm('Are you sure you want to delete this job?')">Delete Job</button>
|
||||||
<button type="submit" class="delete-btn" onclick="return confirm('Are you sure you want to delete this job?')">Delete Job</button>
|
</form></p>
|
||||||
</form></p>
|
|
||||||
`}
|
|
||||||
${job.skipped ? `
|
|
||||||
<div class="skipped-section">
|
|
||||||
<div class="skipped-toggle" onclick="toggleSkippedDetails(this)">
|
|
||||||
⚠️ Skipped Files (${job.skipped.length}) ▶
|
|
||||||
</div>
|
|
||||||
<div class="skipped-details">
|
|
||||||
<ul>
|
|
||||||
${job.skipped.map(skipInfo => `<li><strong>${skipInfo[0]}</strong>: ${skipInfo[1]}</li>`).join('')}
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
` : ''}
|
|
||||||
` : ''}
|
` : ''}
|
||||||
|
${job.skipped ? `
|
||||||
|
<div class="skipped-section">
|
||||||
|
<div class="skipped-toggle" onclick="toggleSkippedDetails(this)">
|
||||||
|
⚠️ Skipped Files (${job.skipped.length}) ▶
|
||||||
|
</div>
|
||||||
|
<div class="skipped-details">
|
||||||
|
<ul>
|
||||||
|
${job.skipped.map(skipInfo => `<li><strong>${skipInfo[0]}</strong>: ${skipInfo[1]}</li>`).join('')}
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
` : ''}
|
` : ''}
|
||||||
`;
|
`;
|
||||||
jobsContainer.insertBefore(jobDiv, jobsContainer.querySelector('script') || jobsContainer.lastElementChild);
|
jobsContainer.insertBefore(jobDiv, jobsContainer.querySelector('script') || jobsContainer.lastElementChild);
|
||||||
|
|||||||
Reference in new issue
Block a user