This pull request includes several changes to the MiFarma project, focusing on refactoring sorting functions and modifying methods to handle product counts in the shopping cart. The most important changes include removing redundant sorting functions, updating sorting logic in VistaEmpleado, and enhancing the VistaUsuario class to manage product counts more effectively.
Refactoring sorting functions:
Removed the ordenarUsuarioxEdad function, which called mergeSort, from Funciones.h as it was redundant.
Removed the ordenarXPrecio function, which called quickSort, from Funciones.h for the same reason.
Updating sorting logic:
Updated the VistaEmpleado class to use quickSort directly instead of the ordShellProductoMenorAMayor function for sorting products.
Enhancing product count management:
Modified the VistaUsuario class to include the cont_productos_comprados parameter in the verCarrito and eliminarTodoCarrito methods to keep track of the number of products in the cart. [1][2][3]
This pull request includes several changes to the
MiFarma
project, focusing on refactoring sorting functions and modifying methods to handle product counts in the shopping cart. The most important changes include removing redundant sorting functions, updating sorting logic inVistaEmpleado
, and enhancing theVistaUsuario
class to manage product counts more effectively.Refactoring sorting functions:
ordenarUsuarioxEdad
function, which calledmergeSort
, fromFunciones.h
as it was redundant.ordenarXPrecio
function, which calledquickSort
, fromFunciones.h
for the same reason.Updating sorting logic:
VistaEmpleado
class to usequickSort
directly instead of theordShellProductoMenorAMayor
function for sorting products.Enhancing product count management:
VistaUsuario
class to include thecont_productos_comprados
parameter in theverCarrito
andeliminarTodoCarrito
methods to keep track of the number of products in the cart. [1] [2] [3]