1
0
الملفات
RestaurantDash/src/components/Home/Inventory/InventoryTablePage.js
2025-06-16 23:18:32 +03:00

42 أسطر
864 B
JavaScript

import React, { useState } from 'react';
import TableView from './TableView';
const initialProducts = [
{
product: 'Apple Watch',
sales: 150,
amount: 45000,
price: 299,
status: 'Published',
expiration: '30 Days Left',
},
{
product: 'Samsung Galaxy',
sales: 90,
amount: 36000,
price: 400,
status: 'Low Stock',
expiration: '12 Days Left',
},
{
product: 'Sony Headphones',
sales: 60,
amount: 18000,
price: 299,
status: 'Draft',
expiration: '5 Days Left',
},
];
const InventoryTablePage = () => {
const [products, setProducts] = useState(initialProducts);
const handleAddNewProduct = () => {
alert('Navigate to Add Product page or open form here');
};
return <TableView data={products} onAddNewProduct={handleAddNewProduct} />;
};
export default InventoryTablePage;