Summary
In this chapter, we learned how to implement inventory management, using the acquired knowledge from the previous chapter about registration creation. In sequence, we learned how to refactor the customer home page with Placeholder
and PartialLoop
view helpers. We changed the home page route of the whatstore application for the Store
module because the default user must be the customer.
Then, we learned how to implement a product basket, using Laminas\Session\Container
to store the products in the session. Finally, we learned how to make a purchase order for an authenticated customer.
Finally, we saw how to decouple the generic behavior of authentication for each module so that it implements only specific behavior.
In the next chapter, we will review implemented features, and we will refactor code when it is appropriate. We will also create a product search box, generate API documentation, and encapsulate identity management.