#1242 Add aux field selector

This commit is contained in:
Cohee
2023-11-11 18:25:43 +02:00
parent 5331b5dc8a
commit 91a1cc81a0
3 changed files with 21 additions and 4 deletions

View File

@ -1038,9 +1038,10 @@ function getCharacterBlock(item, id) {
template.find('.ch_description').hide();
}
const version = item.data?.character_version || '';
if (version) {
template.find('.character_version').text(version);
const auxFieldName = power_user.aux_field || 'character_version';
const auxFieldValue = (item.data && item.data[auxFieldName]) || '';
if (auxFieldValue) {
template.find('.character_version').text(auxFieldValue);
}
else {
template.find('.character_version').hide();