Started conversion to bootstrap for the frontend framework

This commit is contained in:
2025-07-01 14:12:59 -04:00
parent 604025179c
commit 03dab84224
5 changed files with 76 additions and 60 deletions

View File

@ -1,19 +1,17 @@
const testId = $("#results-table").data("test-id");
$(function () {
$("#test-result-form").on("submit", function (e) {
e.preventDefault();
$("#test-result-form").on("submit", function (e) {
e.preventDefault();
const form = $(this);
const formData = form.serialize();
const benchmarkId = form.find('[name="result_benchmark"]').val();
const form = $(this);
const formData = form.serialize();
const benchmarkId = form.find('[name="result_benchmark"]').val();
$.post("/api/v1/result/add", formData, function (response) {
if (response === "success") {
fetchTestBenchmarkResults(testId, benchmarkId);
form[0].reset();
}
});
$.post("/api/v1/result/add", formData, function (response) {
if (response === "success") {
fetchTestBenchmarkResults(testId, benchmarkId);
form[0].reset();
}
});
});
@ -75,8 +73,10 @@ async function fetchTestBenchmarkResults(testId, benchmarkId) {
}
}
$("#results-table tbody tr").each(function (index, tr) {
const benchmarkId = $(tr).data("benchmark-id");
console.log("Fetching results for benchmark id: " + benchmarkId);
fetchTestBenchmarkResults(testId, benchmarkId);
$(document).ready(function() {
$("#results-table tbody tr").each(function (index, tr) {
const benchmarkId = $(tr).data("benchmark-id");
console.log("Fetching results for benchmark id: " + benchmarkId);
fetchTestBenchmarkResults(testId, benchmarkId);
});
});

View File

@ -1,5 +1,5 @@
$primary-color: teal;
body {
background: #eee;
background: white;
}