Change the private field id attribute for consistency
This commit is contained in:
parent
181afcb4b9
commit
0576e69ad5
2 changed files with 29 additions and 22 deletions
|
@ -67,7 +67,8 @@
|
||||||
<?= lang('duration_minutes') ?>
|
<?= lang('duration_minutes') ?>
|
||||||
<span class="text-danger" hidden>*</span>
|
<span class="text-danger" hidden>*</span>
|
||||||
</label>
|
</label>
|
||||||
<input id="duration" class="form-control required" type="number" min="<?= EVENT_MINIMUM_DURATION ?>" disabled>
|
<input id="duration" class="form-control required" type="number" min="<?= EVENT_MINIMUM_DURATION ?>"
|
||||||
|
disabled>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
|
@ -129,9 +130,21 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
|
<label class="form-label" for="description">
|
||||||
|
<?= lang('description') ?>
|
||||||
|
</label>
|
||||||
|
<textarea id="description" rows="4" class="form-control" disabled></textarea>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="border rounded mb-3 p-3">
|
||||||
|
<label class="form-label mb-3">
|
||||||
|
<?= lang('options') ?>
|
||||||
|
</label>
|
||||||
|
|
||||||
<div class="form-check form-switch">
|
<div class="form-check form-switch">
|
||||||
<input class="form-check-input" type="checkbox" id="private">
|
<input class="form-check-input" type="checkbox" id="is-private">
|
||||||
<label class="form-check-label" for="private">
|
|
||||||
|
<label class="form-check-label" for="is-private">
|
||||||
<?= lang('private') ?>
|
<?= lang('private') ?>
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
|
@ -142,13 +155,6 @@
|
||||||
</small>
|
</small>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
|
||||||
<label class="form-label" for="description">
|
|
||||||
<?= lang('description') ?>
|
|
||||||
</label>
|
|
||||||
<textarea id="description" rows="4" class="form-control" disabled></textarea>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -24,7 +24,7 @@ App.Pages.Services = (function () {
|
||||||
const $category = $('#category');
|
const $category = $('#category');
|
||||||
const $availabilitiesType = $('#availabilities-type');
|
const $availabilitiesType = $('#availabilities-type');
|
||||||
const $attendantsNumber = $('#attendants-number');
|
const $attendantsNumber = $('#attendants-number');
|
||||||
const $private = $('#private');
|
const $isPrivate = $('#is-private');
|
||||||
const $location = $('#location');
|
const $location = $('#location');
|
||||||
const $description = $('#description');
|
const $description = $('#description');
|
||||||
const $filterServices = $('#filter-services');
|
const $filterServices = $('#filter-services');
|
||||||
|
@ -140,7 +140,7 @@ App.Pages.Services = (function () {
|
||||||
color: App.Components.ColorSelection.getColor($color),
|
color: App.Components.ColorSelection.getColor($color),
|
||||||
availabilities_type: $availabilitiesType.val(),
|
availabilities_type: $availabilitiesType.val(),
|
||||||
attendants_number: $attendantsNumber.val(),
|
attendants_number: $attendantsNumber.val(),
|
||||||
is_private: Number($private.prop('checked')),
|
is_private: Number($isPrivate.prop('checked')),
|
||||||
id_categories: $category.val() || null
|
id_categories: $category.val() || null
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -295,7 +295,7 @@ App.Pages.Services = (function () {
|
||||||
$location.val(service.location);
|
$location.val(service.location);
|
||||||
$availabilitiesType.val(service.availabilities_type);
|
$availabilitiesType.val(service.availabilities_type);
|
||||||
$attendantsNumber.val(service.attendants_number);
|
$attendantsNumber.val(service.attendants_number);
|
||||||
$private.prop('checked', service.is_private);
|
$isPrivate.prop('checked', service.is_private);
|
||||||
App.Components.ColorSelection.setColor($color, service.color);
|
App.Components.ColorSelection.setColor($color, service.color);
|
||||||
|
|
||||||
const categoryId = service.id_categories !== null ? service.id_categories : '';
|
const categoryId = service.id_categories !== null ? service.id_categories : '';
|
||||||
|
@ -303,7 +303,7 @@ App.Pages.Services = (function () {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Filters service records depending a string keyword.
|
* Filters service records depending on a string keyword.
|
||||||
*
|
*
|
||||||
* @param {String} keyword This is used to filter the service records of the database.
|
* @param {String} keyword This is used to filter the service records of the database.
|
||||||
* @param {Number} selectId Optional, if set then after the filter operation the record with this
|
* @param {Number} selectId Optional, if set then after the filter operation the record with this
|
||||||
|
@ -339,6 +339,7 @@ App.Pages.Services = (function () {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (selectId) {
|
if (selectId) {
|
||||||
|
debugger
|
||||||
select(selectId, show);
|
select(selectId, show);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue