Skip to content
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

Added Order Tracking Schema and Controllers with advance features #879

Merged
merged 2 commits into from
Nov 8, 2024

Conversation

IkkiOcean
Copy link
Contributor

Description:

This PR introduces the implementation of the Order Tracking System for better management of orders within the application. It includes the creation of the Order Tracking Schema along with the necessary controllers to handle various order-related operations.


Changes:

  • Order Tracking Schema:

    • Created a new Mongoose schema to represent order information including:
      • Customer details
      • Order items
      • Order status
      • Order timestamps (for creation, updates, and delivery)
  • Controllers Implemented:

    1. createOrder: Handles the creation of new orders in the system.
    2. getOrders: Fetches all orders.
    3. updateOrderStatus: Allows updating the order's current status (e.g., "pending", "shipped", "delivered").
    4. deleteOrder: Deletes a specific order from the system.
    5. getOrderById: Retrieves order details based on a specific order ID.
    6. addItemToOrder: Adds a new item to an existing order.
    7. removeItemFromOrder: Removes an item from an existing order.
    8. updateOrderItemQuantity: Updates the quantity of a specific item in an order.
    9. bulkUpdateOrderStatus: Updates the status of multiple orders in bulk.
    10. getOrderStatusHistory: Retrieves the status history of a specific order.
    11. getOrdersByStatus: Retrieves orders based on their current status.
    12. getAllOrdersForAdmin: Retrieves all orders, useful for admin users to monitor all transactions.

Why:

The addition of the order tracking system provides a structured way to handle and track orders, enabling better management and status updates. This will enhance the user experience and administrative control over the orders.

Related Issues:

Copy link

vercel bot commented Nov 8, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
agro-tech-ai ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 8, 2024 5:19pm

Copy link
Contributor

github-actions bot commented Nov 8, 2024

Thank you for submitting your pull request! 🙌 We'll review it as soon as possible. In the meantime, please ensure that your changes align with our CONTRIBUTING.md. If there are any specific instructions or feedback regarding your PR, we'll provide them here. Thanks again for your contribution! 😊

@manikumarreddyu manikumarreddyu merged commit f6b9d7f into manikumarreddyu:main Nov 8, 2024
4 checks passed
Copy link
Contributor

github-actions bot commented Nov 8, 2024

🎉 Your pull request has been successfully merged! 🎉 Thank you for your valuable contribution to our project. Your efforts are greatly appreciated. Feel free to reach out if you have any more contributions or if there's anything else we can assist you with. Keep up the fantastic work! 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Order Tracking Schema and CRUD API
2 participants