import React, { useState } from 'react'
import ImageWithBasePath from '../../core/img/imagewithbasebath'
import { Link } from 'react-router-dom'
import { OverlayTrigger, Tooltip } from 'react-bootstrap';
import { setToogleHeader } from '../../core/redux/action';
import { useDispatch, useSelector } from 'react-redux';
import { ChevronUp, PlusCircle, RotateCcw, Sliders, StopCircle } from 'feather-icons-react/build/IconComponents';
import { Filter } from 'react-feather';
import Select from 'react-select';
import { DatePicker } from 'antd';
import AddPurchaseReturn from '../../core/modals/purchases/addpurchasereturn';
import EditPurchaseReturns from '../../core/modals/purchases/editpurchasereturns';
import Swal from 'sweetalert2';
import withReactContent from 'sweetalert2-react-content';
const PurchaseReturns = () => {
const oldandlatestvalue = [
{ value: 'date', label: 'Sort by Date' },
{ value: 'newest', label: 'Newest' },
{ value: 'oldest', label: 'Oldest' },
];
const supplier = [
{ value: 'chooseSupplier', label: 'Choose Supplier' },
{ value: 'apexComputers', label: 'Apex Computers' },
{ value: 'modernAutomobile', label: 'Modern Automobile' },
{ value: 'aimInfotech', label: 'AIM Infotech' },
];
const supplierlist = [
{ value: 'chooseSupplier', label: 'Choose Supplier' },
{ value: 'apexComputers', label: 'Apex Computers' },
{ value: 'modernAutomobile', label: 'Modern Automobile' },
{ value: 'aimInfotech', label: 'AIM Infotech' },
];
const [selectedDate, setSelectedDate] = useState(new Date());
const handleDateChange = (date) => {
setSelectedDate(date);
};
const dispatch = useDispatch();
const data = useSelector((state) => state.toggle_header);
const [isFilterVisible, setIsFilterVisible] = useState(false);
const toggleFilterVisibility = () => {
setIsFilterVisible((prevVisibility) => !prevVisibility);
};
const renderTooltip = (props) => (
| Image | Date | Supplier | Reference | Status | Grand Total ($) | Paid ($) | Due ($) | Payment Status | Action | |
|---|---|---|---|---|---|---|---|---|---|---|
|
|
2/27/2022 | Apex Computers | PT001 | Received | 550 | 120 | 550 | Paid |
|
|
|
|
1/15/2022 | Modern Automobile | PT002 | Ordered | 550 | 120 | 550 | Partial |
|
|
|
|
3/24/2022 | AIM Infotech | PT003 | Pending | 210 | 120 | 210 | Unpaid |
|
|
|
|
1/15/2022 | Best Power Tools | PT004 | Received | 210 | 120 | 210 | Paid |
|
|
|
|
1/15/2022 | AIM Infotech | PT005 | Pending | 210 | 120 | 210 | UnPaid |
|
|
|
|
3/24/2022 | Best Power Tools | PT006 | Received | 210 | 120 | 210 | paid |
|
|
|
|
1/15/2022 | Apex Computers | PT007 | Ordered | 1000 | 500 | 1000 | Partial |
|
|
|
|
3/24/2022 | Best Power Tools | PT008 | Received | 210 | 120 | 210 | paid |
|
|
|
|
3/24/2022 | Hatimi Hardware & Tools | PT009 | Pending | 5500 | 550 | 5500 | Unpaid |
|
|
|
|
3/24/2022 | Best Power Tools | PT0010 | Pending | 2580 | 1250 | 2580 | Unpaid |
|
|
|
|
3/24/2022 | Best Power Tools | PT0011 | Pending | 2580 | 1250 | 2580 | Unpaid |
|