style: Fix formatting issues

This commit is contained in:
Suraj Shetty
2021-02-01 20:34:21 +05:30
parent 62442d1c52
commit 723bd9676d
2 changed files with 30 additions and 29 deletions

View File

@@ -19,18 +19,22 @@ frappe.ui.form.on('Course Scheduling Tool', {
}
const { course_schedules } = r.message;
if (course_schedules) {
/* eslint-disable indent */
const html = `<table class="table table-bordered">
<caption>${__('Following course schedules were created')}</caption>
<thead><tr><th>${__("Course")}</th><th>${__("Date")}</th></tr></thead>
<tbody>
${course_schedules.map(c =>
`<tr><td><a href="/app/course-schedule/${c.name}">${c.name}</a></td>
<td>${c.schedule_date}</td></tr>`
).join('')}
</tbody>
</table>`;
/* eslint-disable indent */
const course_schedules_html = course_schedules.map(c => `
<tr>
<td><a href="/app/course-schedule/${c.name}">${c.name}</a></td>
<td>${c.schedule_date}</td>
</tr>
`).join('');
const html = `
<table class="table table-bordered">
<caption>${__('Following course schedules were created')}</caption>
<thead><tr><th>${__("Course")}</th><th>${__("Date")}</th></tr></thead>
<tbody>
${course_schedules_html}
</tbody>
</table>
`;
frappe.msgprint(html);
}