feat: overview rework and customer data mosaic view

This commit is contained in:
José Oliveira 2021-09-17 11:32:43 +01:00
parent 9ec871e163
commit d27a9847bb

View file

@ -1,6 +1,7 @@
import { useQuery, useMutation } from '@apollo/react-hooks'
import { makeStyles, Breadcrumbs, Box } from '@material-ui/core'
import NavigateNextIcon from '@material-ui/icons/NavigateNext'
// import classnames from 'classnames'
import gql from 'graphql-tag'
import * as R from 'ramda'
import React, { memo, useState } from 'react'
@ -246,6 +247,38 @@ const CustomerProfile = memo(() => {
</div>
)}
</div>
<div className={classes.rightSidePanel}>
{isOverview && (
<div>
<Box
className={classes.customerDetails}
display="flex"
justifyContent="space-between">
<CustomerDetails
customer={customerData}
locale={locale}
setShowCompliance={() => setShowCompliance(!showCompliance)}
/>
</Box>
<div>
<TransactionsList
customer={customerData}
data={sortedTransactions}
locale={locale}
loading={loading}
/>
</div>
<div>
<ActionButton
className={classes.customerDiscount}
color="primary"
onClick={() => {}}>
{`Add individual discount`}
</ActionButton>
</div>
</div>
)}
</div>
<div className={classes.rightSidePanel}>
{isOverview && (
<div>