BUGFIX: missing labels
This commit is contained in:
parent
09024ab65d
commit
0aa87504e4
|
@ -32,8 +32,8 @@ function initCronType()
|
|||
document.querySelectorAll('.crontype-inputs:not(.d-none)').forEach(elem => elem.classList.add('d-none'));
|
||||
document.querySelector('.crontype-' + type).classList.remove('d-none');
|
||||
|
||||
document.querySelector('.crontype-inputs:not(.d-none) input').disabled = false;
|
||||
document.querySelector('.crontype-inputs.d-none input').disabled = true;
|
||||
document.querySelectorAll('.crontype-inputs:not(.d-none) input').forEach(elem => elem.disabled = false);
|
||||
document.querySelectorAll('.crontype-inputs.d-none input').forEach(elem => elem.disabled = true);
|
||||
|
||||
if (type == 'http') {
|
||||
document.querySelectorAll('.croncategory-group:not(.crontype-group) button').forEach(elem => elem.innerText = elem.dataset.defaultText)
|
||||
|
@ -42,8 +42,8 @@ function initCronType()
|
|||
document.querySelectorAll('.croncategory-group:not(.crontype-group)').forEach(elem => elem.classList.add('d-none'));
|
||||
document.querySelectorAll('.croncategory-inputs:not(.crontype-inputs)').forEach(elem => elem.classList.add('d-none'));
|
||||
|
||||
document.querySelector('.croncategory-inputs:not(.d-none) input').disabled = false;
|
||||
document.querySelector('.croncategory-inputs.d-none input').disabled = true;
|
||||
document.querySelectorAll('.croncategory-inputs:not(.d-none) input').forEach(elem => elem.disabled = false);
|
||||
document.querySelectorAll('.croncategory-inputs.d-none input').forEach(elem => elem.disabled = true);
|
||||
}
|
||||
if (type == 'reboot') {
|
||||
if (document.querySelector('#btn-group-discriminator') === null) {
|
||||
|
|
|
@ -67,6 +67,8 @@
|
|||
Reboot
|
||||
{% elseif data.crontype == 'http' %}
|
||||
Http request
|
||||
{% else %}
|
||||
Job type
|
||||
{% endif %}
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="crontypeButton">
|
||||
|
@ -82,6 +84,8 @@
|
|||
Local
|
||||
{% elseif data.hosttype == 'ssh' %}
|
||||
SSH
|
||||
{% else %}
|
||||
Host type
|
||||
{% endif %}
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="hosttypeButton">
|
||||
|
@ -95,11 +99,13 @@
|
|||
<div id="btn-group-discriminator" class="d-none">
|
||||
{% endif %}
|
||||
<div class="dropdown croncategory-group containertype-group{% if data.crontype != 'http' %} btn-group{% else %} d-none{% endif %}">
|
||||
<button class="btn btn-outline-primary dropdown-toggle" type="button" id="containertypeButton" data-default-text="" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<button class="btn btn-outline-primary dropdown-toggle" type="button" id="containertypeButton" data-default-text="Container" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
{% if data.containertype == 'none' or data.containertype == '' %}
|
||||
None
|
||||
{% elseif data.containertype == 'docker' %}
|
||||
Docker
|
||||
{% else %}
|
||||
Container
|
||||
{% endif %}
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="containertypeButton">
|
||||
|
|
Loading…
Reference in New Issue