import React, { useEffect, useState } from "react"; import { useStore } from "../../utils/useStore"; import { Button, Card, Col, Input, Row, Tabs } from "antd"; import { FilterOutlined, } from "@ant-design/icons"; import { BreadcumbComponent } from "../../component/BreadcumbComponent"; import { Pulsa } from "./Pulsa"; import { LINKS } from "../../routes/app"; const { TabPane } = Tabs; const { Search } = Input; export const Transaction = () => { const store = useStore(); const [isLoading, setIsLoading] = useState(false); // Init useEffect(() => { const init = async () => { try { setIsLoading(true); await store.transaction.getDataCategories(); setIsLoading(false); } catch (e) { setIsLoading(false); } }; init(); }, []); // Category useEffect(() => { console.log('⚡ transaction category store', store.transaction.dataCategories) }, [store.transaction.dataCategories]) const callback = (key) => { console.log(key); }; const routeData = [ { route: LINKS.HOME, name: "Home", }, { route: LINKS.TRANSACTION, name: Transaction, }, ]; return (
{store.transaction.dataCategories.map((item, index) => ( ))}
); };