From e713d858d6ee701d755f94a9d671e40f50da3764 Mon Sep 17 00:00:00 2001 From: SRUTHY R <117913189+Sruthy1810@users.noreply.github.com> Date: Sat, 19 Oct 2024 00:29:00 +0530 Subject: [PATCH] Updated index.js added customer details --- .../app/components/Manager/OrderList/index.js | 69 ++++++++++--------- 1 file changed, 37 insertions(+), 32 deletions(-) diff --git a/client/app/components/Manager/OrderList/index.js b/client/app/components/Manager/OrderList/index.js index 59a28a82..b1eac6b6 100644 --- a/client/app/components/Manager/OrderList/index.js +++ b/client/app/components/Manager/OrderList/index.js @@ -1,71 +1,76 @@ -/** - * - * OrderList - * - */ - import React from 'react'; - import { Link } from 'react-router-dom'; - import { formatDate } from '../../../utils/date'; -const OrderList = props => { +const OrderList = (props) => { const { orders } = props; - const renderFirstItem = order => { + const renderFirstItem = (order) => { if (order.products) { const product = order.products[0].product; return ( ); } else { - return ; + return ; + } + }; + + const renderAddress = (order) => { + const { address } = order.customer; + if (address) { + return ( +