Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multiselect html p tag input fix #422

Merged
merged 1 commit into from
Dec 5, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 4 additions & 10 deletions lib/DataHarmonizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -1196,11 +1196,7 @@ class DataHarmonizer {
}

$('#field-description-text').html(
`${
fields[col].title
}<select multiple class="multiselect" rows="15">${renderContent(
content
)}</select>`
`${fields[col].title}<select multiple class="multiselect" rows="15">${content}</select>`
);
$('#field-description-modal').modal('show');
$('#field-description-text .multiselect')
Expand All @@ -1213,15 +1209,13 @@ class DataHarmonizer {
let indentation = 12 + label.search(/\S/) * 8; // pixels
return `<div style="padding-left:${indentation}px" class="option ${
value === '' ? 'selectize-dropdown-emptyoptionlabel' : ''
}">${renderContent(escape(label))}</div>`;
}">${escape(label)}</div>`;
},
},
}) // must be rendered when html is visible
.on('change', function () {
let newValCsv = renderContent(
formatMultivaluedValue(
$('#field-description-text .multiselect').val()
)
let newValCsv = formatMultivaluedValue(
$('#field-description-text .multiselect').val()
);
self.setDataAtCell(row, col, newValCsv, 'thisChange');
});
Expand Down
Loading