Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
The error happened when I create a boolean field with checkbox/radio button, the value of the field is not selectable. Only one value is selectable. Here is the screenshot of the error/invisible checkbox field on order edit page:
Defective HTML Code:
<div class="form-item form-type-radios form-item-field-flag-include-ppn-und">
<div class="field-label"> <label for="edit-field-flag-include-ppn-und">Include PPN <span class="form-required" title="This field is required.">*</span></label>
</div>
<div id="edit-field-flag-include-ppn-und" class="form-radios">
<div class="form-item form-type-radio form-item-field-flag-include-ppn-und tooltip-onfocus">
<div class="field-wrap-0"><input id="edit-field-flag-include-ppn-und-0" name="field_flag_include_ppn[und]" value="0" checked="checked" class="form-radio" type="radio"></div>
</div>
<div class="form-item form-type-radio form-item-field-flag-include-ppn-und">
<input id="edit-field-flag-include-ppn-und-1" name="field_flag_include_ppn[und]" value="1" class="form-radio" type="radio">
<div class="field-label"> <label class="option" for="edit-field-flag-include-ppn-und-1">Termasuk PPN </label>
</div>
</div>
</div>
</div>
And here after I do some HTML modification from Firefox Inspector, this is the expected result:
The HTML Code become:
<div class="form-item form-type-radios form-item-field-flag-include-ppn-und">
<div class="field-label">
<label for="edit-field-flag-include-ppn-und">Include PPN <span class="form-required" title="This field is required.">*</span></label>
</div>
<div id="edit-field-flag-include-ppn-und" class="form-radios">
<div class="form-item form-type-radio form-item-field-flag-include-ppn-und">
<input id="edit-field-flag-include-ppn-und-0" name="field_flag_include_ppn[und]" value="0" checked="checked" class="form-radio" type="radio">
<div class="field-label">
<label class="option" for="edit-field-flag-include-ppn-und-0">Belum Termasuk PPN </label>
</div>
</div>
<div class="form-item form-type-radio form-item-field-flag-include-ppn-und">
<input id="edit-field-flag-include-ppn-und-1" name="field_flag_include_ppn[und]" value="1" class="form-radio" type="radio">
<div class="field-label">
<label class="option" for="edit-field-flag-include-ppn-und-1">Termasuk PPN </label>
</div>
</div>
</div>
</div>
So, how can I apply a fix for this theme issue?
Comment | File | Size | Author |
---|---|---|---|
#2 | Radio OK.PNG | 2.52 KB | Harsikesa |
#2 | Radio Error.PNG | 1.4 KB | Harsikesa |
Comments
Comment #2
Harsikesa CreditAttribution: Harsikesa commentedComment #3
Harsikesa CreditAttribution: Harsikesa commentedI found temporary solution, just change file \profiles\erpal_platform\themes\erpal_theme\theme\form-element.theme.inc
from:
to:
and add:
so the final file would become:
hope this help urgent people