This commit is contained in:
Malai Raja
2023-12-13 18:58:52 +05:30
parent e076b8942f
commit a38ff4f960

View File

@@ -631,7 +631,7 @@ import {
<Typography variant='body2' noWrap>{row.orderid}</Typography>
<Typography noWrap
sx={{ fontSize: '11px' }}>
{dayjs(row.deliverydate).utc().format('MM/DD/YYYY')}
{dayjs(row.deliverydate).utc().format('DD/MM/YYYY')}
</Typography>
<Typography noWrap
sx={{ fontSize: '11px' }}
@@ -773,9 +773,10 @@ import {
<>
<Tooltip title='Cancel'>
<IconButton
// disabled
// disabled={(row.orderstatus != 'created')}
onClick={(e) => {
e.stopPropagation();
setOrderheaderid(row.orderheaderid)
@@ -790,7 +791,8 @@ import {
{/* <EyeTwoTone twoToneColor={theme.palette.secondary.main} /> */}
<CloseOutlined
style={{
color:theme.palette.error.main
color:theme.palette.error.main,
}}
// twoToneColor={theme.palette.primary.main}
/>
@@ -1443,7 +1445,7 @@ import {
} else if (tabstatus === 'Pending') {
if (searchword) {
let arr = orderarrcreated.filter((val) => {
let arr = orderarruncovered.filter((val) => {
return (val.orderid.toLowerCase().includes(searchword.toLowerCase())
|| val.pickupaddress.toString().toLowerCase().includes(searchword.toLowerCase())
@@ -1457,7 +1459,7 @@ import {
console.log(arr)
setRows([...arr])
} else {
setRows([...orderarrcreated])
setRows([...orderarruncovered])
}
} else if (tabstatus === 'Cancelled') {
@@ -1465,10 +1467,10 @@ import {
let arr = orderarrcancelled.filter((val) => {
return (val.orderid.toLowerCase().includes(searchword.toLowerCase())
|| val.eventname.toLowerCase().includes(searchword.toLowerCase())
|| val.customername.toLowerCase().includes(searchword.toLowerCase())
|| val.ordervalue.toString().toLowerCase().includes(searchword.toLowerCase())
|| val.pickupaddress.toString().toLowerCase().includes(searchword.toLowerCase())
|| val.ordernotes.toString().toLowerCase().includes(searchword.toLowerCase())
|| val.deliveryaddress.toLowerCase().includes(searchword.toLowerCase())
|| val.customername.toLowerCase().includes(searchword.toLowerCase())
|| val.contactno.toString().toLowerCase().includes(searchword.toLowerCase())
)
@@ -1574,6 +1576,26 @@ import {
setRows([...orderarrpicked])
}
}else if (tabstatus === 'Created') {
if (searchword) {
let arr = orderarrcreated.filter((val) => {
return (val.orderid.toLowerCase().includes(searchword.toLowerCase())
|| val.pickupaddress.toString().toLowerCase().includes(searchword.toLowerCase())
|| val.ordernotes.toString().toLowerCase().includes(searchword.toLowerCase())
|| val.deliveryaddress.toLowerCase().includes(searchword.toLowerCase())
|| val.customername.toLowerCase().includes(searchword.toLowerCase())
|| val.contactno.toString().toLowerCase().includes(searchword.toLowerCase())
)
})
console.log(arr)
setRows([...arr])
}
else {
setRows([...orderarrcreated])
}
}
}, [orderarr, searchword])