Skip to content

Commit

Permalink
add missing id's
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnRDOrazio committed Apr 29, 2024
1 parent e998d22 commit 135fcea
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions assets/js/FormControls.js
Original file line number Diff line number Diff line change
Expand Up @@ -251,15 +251,15 @@ class FormControls {
if(FormControls.settings.decreeURLField) {
formRow += `<div class="form-group col-sm-6">
<label for="onTheFly${FormControls.uniqid}DecreeURL">${messages[ "Decree URL" ]}<i class="ms-2 fas fa-info-circle" title="Use %s in place of the language code if using a language mapping"></i></label>
<input type="text" class="form-control litEvent litEventDecreeURL" value="${festivity !== null && typeof festivity.decreeURL !== 'undefined' ? festivity.decreeURL : ''}" />
<input type="text" class="form-control litEvent litEventDecreeURL" value="${festivity !== null && typeof festivity.decreeURL !== 'undefined' ? festivity.decreeURL : ''}" id="onTheFly${FormControls.uniqid}DecreeURL" />
</div>`;
}

if(FormControls.settings.decreeLangMapField) {
let decreeLangs = festivity !== null && typeof festivity.decreeLangs !== 'undefined' ? Object.keys(festivity.decreeLangs).map(key => key+'='+festivity.decreeLangs[key] ) : null;
formRow += `<div class="form-group col-sm-6">
<label for="onTheFly${FormControls.uniqid}DecreeLangs">${messages[ "Decree Langs" ]}<i class="ms-2 fas fa-info-circle" title="Use a comma separated list of key=value pairings, e.g. DE=ge,EN=en. Key is uppercased two letter ISO code, value is (generally lowercased) two letter representation used within the actual URL"></i></label>
<input type="text" class="form-control litEvent litEventDecreeLangs" value="${festivity !== null && typeof festivity.decreeLangs !== 'undefined' ? decreeLangs.join(',') : ''}" />
<input type="text" class="form-control litEvent litEventDecreeLangs" value="${festivity !== null && typeof festivity.decreeLangs !== 'undefined' ? decreeLangs.join(',') : ''}" id="onTheFly${FormControls.uniqid}DecreeLangs" />
</div>`;
}

Expand Down
2 changes: 1 addition & 1 deletion assets/js/extending.js
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ jQuery.ajax({
});

$(document).on('click', '.strtotime-toggle-btn', ev => {
let uniqid = parseInt( $(ev.currentTarget).attr('data-row-uniqid') );
const uniqid = parseInt( $(ev.currentTarget).attr('data-row-uniqid') );
if( $(ev.currentTarget).attr('aria-pressed') === 'true' ) {
$(ev.currentTarget).find('i').removeClass('fa-comment-slash').addClass('fa-comment');
$(`#onTheFly${uniqid}Month`).closest('.form-group').remove();
Expand Down

0 comments on commit 135fcea

Please sign in to comment.