fixed color and import dahboard

This commit is contained in:
2026-04-27 14:34:45 +02:00
parent fa7997c980
commit 6b0d2aa9b9
5 changed files with 426 additions and 89 deletions
+43
View File
@@ -331,6 +331,28 @@
function createCell(col, rowIndex, cellIndex) {
const div = document.createElement("div");
div.className = "grid-cell editable-cell";
// Field color classification
// Schema/customfield fields are green.
// Fixed and standard fields stay white.
if (col.type === "detail" || col.type === "main_field") {
div.classList.add("schema-field");
} else if (col.type === "fixed") {
div.classList.add("fixed-field");
} else {
div.classList.add("standard-field");
}
// Required field classification.
// This comes from template_mapping.is_required or template_fixed_mapping.is_required.
if (
col.isRequired === true ||
col.isRequired === 1 ||
col.isRequired === "1"
) {
div.classList.add("required-field");
}
div.dataset.col = col.key;
div.dataset.colType = col.type;
div.dataset.row = rowIndex;
@@ -744,6 +766,27 @@
columns.forEach((col, colIdx) => {
const cell = document.createElement("div");
cell.className = "grid-cell grid-top-cell";
// Field color classification for top propagation row
// Schema/customfield fields are green.
// Fixed and standard fields stay white.
if (col.type === "detail" || col.type === "main_field") {
cell.classList.add("schema-field");
} else if (col.type === "fixed") {
cell.classList.add("fixed-field");
} else {
cell.classList.add("standard-field");
}
// Required field classification also for the top propagation row.
if (
col.isRequired === true ||
col.isRequired === 1 ||
col.isRequired === "1"
) {
cell.classList.add("required-field");
}
cell.style.flex = `0 0 ${col.width}px`;
if (