Ramin-RX7 / CafeMenu

Café management website with custom dashboard panel for staff
MIT License
2 stars 4 forks source link

Implement orders view #91

Closed Ramin-RX7 closed 1 year ago

Ramin-RX7 commented 1 year ago

The order view needs to give out only the orders of the current session

(The view is called index in the orders app

This means you need to take the orders from the session. It is a list (parsed in string because of session format) that contains the order id.

So you have to convert those ids to the actual Order objects using .objects.get() method. and send them to the template using this context structure: context = { "orders": <CURRENT_SESSION_ORDERS> }

Ramin-RX7 commented 1 year ago

completed in #96