add product updated

This commit is contained in:
kratikpal 2024-08-14 10:12:26 +05:30
parent 96aa3e8549
commit 7e86e93c8e

View File

@ -23,6 +23,8 @@ class _AddProductsScreenState extends State<AddProductsScreen> {
@override @override
void initState() { void initState() {
super.initState(); super.initState();
final provider = Provider.of<ProductProvider>(context, listen: false);
filteredProducts = provider.productList;
} }
void filterProducts(String query) { void filterProducts(String query) {
@ -70,8 +72,6 @@ class _AddProductsScreenState extends State<AddProductsScreen> {
return const Center(child: CircularProgressIndicator()); return const Center(child: CircularProgressIndicator());
} }
filteredProducts = provider.productList;
return Stack( return Stack(
children: [ children: [
Column( Column(