2020-06-14 15:05:04 +02:00
|
|
|
document.addEventListener('DOMContentLoaded', () => {
|
|
|
|
const neverExpireCheckbox = document.getElementById('field-never_expire');
|
|
|
|
const expireAfterDaysField = document.getElementById('field-expire_after_days');
|
|
|
|
|
|
|
|
neverExpireCheckbox.addEventListener('change', () => {
|
|
|
|
// noinspection RedundantConditionalExpressionJS
|
2020-06-14 15:15:15 +02:00
|
|
|
expireAfterDaysField.disabled = neverExpireCheckbox.checked ? true : false;
|
2020-06-14 15:05:04 +02:00
|
|
|
});
|
|
|
|
});
|