-
Notifications
You must be signed in to change notification settings - Fork 6
IN - Separar visualización camas censables y no censables #3225
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
silviroa
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
La idea no era cambiar el filtro existente, si no que por defecto muestra solo camas censables y el slide para incluir censable se debe agregar en el Titulo del sidebar donde se ven los totales de camas
| camasFiltradas = camasFiltradas.filter((snap: ISnapshot) => !snap.esCensable); | ||
| } else if (esCensable.id === 1) { | ||
| camasFiltradas = camasFiltradas.filter((snap: ISnapshot) => snap.esCensable); | ||
| if (esCensable != null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No hace falta poner explicitamente el != null
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Corregido
| if (this.filtro.censable !== undefined && this.filtro.censable !== null) { | ||
| this.mapaCamasService.esCensable.next(this.filtro.censable.id); | ||
| } else { | ||
| this.mapaCamasService.esCensable.next(this.mostrarTodasCamas ? null : 1); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Estas dos condiciones las podemos remplazar por una ternaria para que quede mas legible a la hora de interpretarlo.
this.mapaCamasService.esCensable.next(this.filtro.censable?.id ?? (this.mostrarTodasCamas ? null : 1));
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Corregido
|
|
||
| onCensableChange() { | ||
| if (this.filtro.censable) { | ||
| this.mostrarTodasCamas = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Me queda la duda en que momento la variable this.mostrarTodasCamas se puede convertir en true ya que en la declaración esta como falsa y si la condición del if se cumple o no, sigue siendo falsa.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
El plex-bool (switch) solo aparece cuando no hay nada elegido en el select de censable (*ngIf="!filtro.censable").
Si la persona elige “Censable” o “No Censable”, el switch desaparece y onCensableChange() se encarga de resetear su valor.
Esto evita que quede un valor del switch activo al mismo tiempo que una opción en el select, lo cual aplicaría mal el filtro.
|
Si aplican filtro por censable, modificar titulo en el sidebar y ocultar slide |
(Ya se corrigió lo recomendado) |
|
Nico, por lo general esta correcta la tarea y sus correcciones... por otro lado, con lo que estuvimos viendo recien en conjunto con @AgosLizzi, dejo comentado que: en capa profesional, hay un caso que no se ven todas las camas no censables, dejo imagen... Compa, efectivamente hay q hacer la correccion por este caso. |
Se corrigió el bug de profesional con camas censables |
AgosLizzi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nico, un detalle super pequeño. Cuando aplicamos el filtro por censable o no censable cambia el plex title del sidebar y queda una linea abajo solo la hora, siempre mirando la pantalla desde una notebook. En estos casos se podría achicar a md el título para que no quede esa diferencia?
Solo cambiaría de tamaño cuando se aplica el filtro




Requerimiento
IN-644
Funcionalidad desarrollada
UserStory llegó a completarse
Requiere actualizaciones en la base de datos
Requiere actualizaciones en la API
Requiere actualizaciones en andes-test-integracion