-
Notifications
You must be signed in to change notification settings - Fork 12
REC - Implementa ID unico de receta #2110
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
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.
funcionamiento ok!
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.
Se solicitan cambios que quedan en la tarea https://proyectos.andes.gob.ar/browse/REC-146
a9ed630 to
f0c7a82
Compare
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.
Esta funcionando bien!!
modules/recetas/recetasController.ts
Outdated
| for (let i = 0;i < cantRecetas;i++) { | ||
| try { | ||
| receta = new Receta(); | ||
| receta.idReceta = generarIdDesdeFecha(); |
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.
Mati el funcionamiento lo veo ok. Pero falta considerar que la creación del idReceta debería realizarse con el dato del campo createdAt, para evitar que alguna vez pudieran generarse dos recetas al mismo tiempo desde distintas instancias de la api. En la tarea https://proyectos.andes.gob.ar/browse/REC-146 se lo aclara como:
El id generado debe coincidir con los datos de la fecha crearse con la fecha de creación), si esto no pasa ver si no es conveniente aplicar otra estrategia de creación para que se haga luego de crear la receta (ver api recetar de ejemplo).
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.
Listos los cambios @MCele! Ahora se comporta igual que en recetar la generación del ID, a partir de un post-save en el esquema de BD.
Requerimiento
https://proyectos.andes.gob.ar/browse/REC-134
Funcionalidad desarrollada
UserStories llegó a completarse
Requiere actualizaciones en la base de datos