bit fix filter date

dev
Aji Kamaludin 1 year ago
parent 88850628ba
commit 2a1e802ab2
No known key found for this signature in database
GPG Key ID: 19058F67F0083AD3

@ -88,7 +88,7 @@ export default function HeaderTrx({ enable = 'deposit', dates, setDates }) {
<div className="flex flex-row gap-2 "> <div className="flex flex-row gap-2 ">
<Link <Link
href={route('transactions.deposit.index')} href={route('transactions.deposit.index')}
className={`px-3 py-1 rounded-full border hover:bg-blue-500 ${ className={`px-3 py-1 rounded-full border hover:bg-blue-500 hover:text-white ${
enable === 'deposit' enable === 'deposit'
? 'bg-blue-700 text-white' ? 'bg-blue-700 text-white'
: 'bg-blue-100' : 'bg-blue-100'
@ -98,7 +98,7 @@ export default function HeaderTrx({ enable = 'deposit', dates, setDates }) {
</Link> </Link>
<Link <Link
href={route('transactions.sale.index')} href={route('transactions.sale.index')}
className={`px-3 py-1 rounded-full border hover:bg-blue-500 ${ className={`px-3 py-1 rounded-full border hover:bg-blue-500 hover:text-white ${
enable === 'trx' enable === 'trx'
? 'bg-blue-700 text-white' ? 'bg-blue-700 text-white'
: 'bg-blue-100' : 'bg-blue-100'
@ -108,7 +108,7 @@ export default function HeaderTrx({ enable = 'deposit', dates, setDates }) {
</Link> </Link>
<Link <Link
href={route('transactions.poin.index')} href={route('transactions.poin.index')}
className={`px-3 py-1 rounded-full border hover:bg-blue-500 ${ className={`px-3 py-1 rounded-full border hover:bg-blue-500 hover:text-white ${
enable === 'poin' enable === 'poin'
? 'bg-blue-700 text-white' ? 'bg-blue-700 text-white'
: 'bg-blue-100' : 'bg-blue-100'

@ -5,6 +5,7 @@ import { usePrevious } from 'react-use'
import CustomerLayout from '@/Layouts/CustomerLayout' import CustomerLayout from '@/Layouts/CustomerLayout'
import HeaderTrx from '../Components/HeaderTrx' import HeaderTrx from '../Components/HeaderTrx'
import { formatIDDate } from '@/utils' import { formatIDDate } from '@/utils'
import { isEmpty } from 'lodash'
const EmptyHere = () => { const EmptyHere = () => {
return ( return (
@ -49,6 +50,9 @@ export default function Index(props) {
useEffect(() => { useEffect(() => {
if (preValue) { if (preValue) {
if (isEmpty(dates.endDate)) {
return
}
router.get( router.get(
route(route().current()), route(route().current()),
{ {

@ -49,6 +49,9 @@ export default function Index(props) {
useEffect(() => { useEffect(() => {
if (preValue) { if (preValue) {
if (isEmpty(dates.endDate)) {
return
}
router.get( router.get(
route(route().current()), route(route().current()),
{ {

@ -52,6 +52,9 @@ export default function Index(props) {
useEffect(() => { useEffect(() => {
if (preValue) { if (preValue) {
if (isEmpty(dates.endDate)) {
return
}
router.get( router.get(
route(route().current()), route(route().current()),
{ {

Loading…
Cancel
Save