Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Hiding fields depending on category does not work

Abierto
#847 6 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
35/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
php
Área
frontend

Línea de trabajo

Reproduce ticket creation in the simplified interface using a block with fields and a hiding condition based on ticket category, then inspect the plugin code handling conditional block visibility and form layout updates. Compare the category condition with the working title condition; done means the block hides when the specified category is selected without layout or CSS breakage.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

bug
Code of Conduct
  • I agree to follow this project's Code of Conduct
Is there an existing issue for this?
  • I have searched the existing issues
GLPI Version

10.0.15

Plugin version

1.21.15

Bug description

When I setup a block to be hidden depending on ticket category, block is not hidden in simplified interface. Haven't tried in standard interface since it does not meet our requirements.

Block configuration:

Block config 1

Block fields:

Block fields

Block hiding condition:

Block condition
Block condition 2

When a user begins to create a ticket, block is shown (which is expected to happen)

Ticket creation before setting category

But when the user sets the category by which the block has to be hidden, some erratic movement happens and the field is still shown with broken CSS, a.k.a. moved rightwards and wider.

Ticket creation after setting category

I've tried setting the condition to the ticket's title and this works correctly, block is successfully hidden and works like a charm.

Relevant log output

No response

Page URL

No response

Steps To reproduce
  1. Create a block and set it's type to "Insertion in the form (before save button)".
  2. Configure some fields in the block.
  3. Set a hiding conditional rule that depends on ticket's category.
  4. Test a ticket creation by setting the category specified on step 3 and block is still present.
Your GLPI setup information

No response

Anything else?

No response

Lenguaje dominante
PHP
Estrellas
115
Forks
82
Merge medio
3 d 5 h
PR fusionados (30 d)
12

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de pluginsGLPI/fields

Todos los issues de pluginsGLPI/fields

Issues similares

Más issues de PHP

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.