harmonia form: a boolean (checkbox) field is marked required with *, though unchecked is a valid answer
Los mantenedores suelen responder en 1 día
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 82/100
Línea de trabajo
Empieza por la rama de las casillas de verificación en ui/perspective/manage/form-view.html.template, alrededor de la línea 383, y luego revisa las ramas correspondientes en las otras cinco plantillas de formularios y documentos enumeradas en el issue. Elimina el asterisco de campo obligatorio solo para los campos de casilla de verificación y consérvalo para los demás widgets; confirma que los formularios generados no muestran ningún asterisco para las casillas de verificación y que los demás campos obligatorios siguen mostrando uno.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Problem
In a generated Harmonia form, a boolean field (CHECKBOX) is marked required with a red *, although an unchecked box is a valid answer (false). The user cannot "skip" a checkbox, so the asterisk only suggests that the box must be ticked.
Steps to reproduce
- Open Tax Rates (
tax-ratesmodule), e.g./services/web/tax-rates/gen/tax-rates/index.html#/TaxRate. - Press + New (or open an existing row for edit).
- The Base checkbox ("Базова" in Bulgarian) shows a red
*. - Leave it unticked, fill in the other fields, save → the record is saved with
Base = false.
Expected: no * on a checkbox.
Cause
The Base column is NOT NULL, so the model marks the property required (isRequiredProperty == "true"). The CHECKBOX branch of the form templates adds the asterisk exactly as the other widgets do, e.g. template-application-ui-harmonia-java/ui/perspective/manage/form-view.html.template:383:
<label x-h-label for="f_${property.name}">...#if($property.isRequiredProperty == "true") <span class="text-negative">*</span>#end</label>
A checkbox always submits a value (the form initialises it to false), so for a boolean the NOT NULL is always satisfied.
Suggested fix
Drop the asterisk from the CHECKBOX branch in every form template that has it:
ui/perspective/manage/form-view.html.template(383)ui/perspective/document/document-view.html.template(321)ui/my/my-form-view.html.template,ui/my/my-document-view.html.templateui/partner/partner-form-view.html.template,ui/partner/partner-document-view.html.template
The non-checkbox branches keep it.
- Lenguaje dominante
- Java
- Estrellas
- 278
- Forks
- 97
- Merge medio
- 12 h 43 min
- PR fusionados (30 d)
- 296
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de eclipse-dirigible/dirigible
-
harmonia list: the record sheet's title collapses to 0 height when the record's properties overflow the sheetPosiblemente ocupada @NicoleNG18 la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
eclipse-dirigible/dirigible#8570 ·
Los mantenedores suelen responder en 1 día
-
intent checks: a soft duplicate warning is asked again on every update, even when its fields did not changePosiblemente ocupada @NicoleNG18 la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
eclipse-dirigible/dirigible#8568 ·
Los mantenedores suelen responder en 1 día
-
harmonia list: search ignores what relation columns show - matches the key, not the labelPosiblemente ocupada @NicoleNG18 la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
eclipse-dirigible/dirigible#8561 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
eclipse-dirigible/dirigible#8548 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
eclipse-dirigible/dirigible#8354 ·
Los mantenedores suelen responder en 1 día
Todos los issues de eclipse-dirigible/dirigible
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
wultra/powerauth-tests#980 ·
-
account bug communication lecture
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
line/centraldogma#1397 ·
Los mantenedores suelen responder en 2 días
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 78/100
cryptomator/hub#515 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
vert-x3/vertx-mail-client#268 ·