๐Ÿ“ฆ Inventory Management
Total Products
0
In inventory
In Stock
0
Available
Low Stock
0
Need reorder
Out of Stock
0
Unavailable

Product List

0 products
ProductCategoryPriceStockBarcodeStatusActions
โณ
Loading products...
`); w.document.close();w.print(); }; window.exportCSV = () => { const rows=[['Name','Category','Price','Stock','Barcode','Status']]; products.forEach(p=>{ const st=(p.stock||0)===0?'Out':(p.stock||0)<=(p.lowAt||10)?'Low':'OK'; rows.push([p.name,p.category||'',p.price||0,p.stock||0,p.barcode||'',st]); }); const csv=rows.map(r=>r.join(',')).join('\n'); const a=document.createElement('a'); a.href='data:text/csv;charset=utf-8,'+encodeURIComponent(csv); a.download=`inventory-${new Date().toISOString().split('T')[0]}.csv`; a.click(); showToast('โœ… CSV exported!'); }; window.openSuggest = () => document.getElementById('suggestModal').classList.add('show'); window.sendSuggest = () => { const text=document.getElementById('suggestText').value.trim(); if(!text){showToast('โŒ Please write a suggestion');return;} window.location.href=`mailto:support@aiposai.com?subject=Suggestion from ${userData.businessName||'User'}&body=${encodeURIComponent(text)}`; document.getElementById('suggestModal').classList.remove('show'); showToast('โœ… Opening email...'); }; window.closeModal = () => document.getElementById('productModal').classList.remove('show'); window.doLogout = async () => { await signOut(auth); window.location.href='login.html'; }; function showToast(msg) { const t=document.getElementById('toast'); t.textContent=msg;t.classList.add('show'); setTimeout(()=>t.classList.remove('show'),2500); } window.showToast=showToast;