mirror of
https://github.com/inventree/inventree-app.git
synced 2025-04-28 05:26:47 +00:00
Add view for list of manufacturers
This commit is contained in:
parent
83ac6041cb
commit
7a7fc84ffe
@ -25,6 +25,12 @@ class SupplierListWidget extends CompanyListWidget {
|
||||
}
|
||||
|
||||
|
||||
class ManufacturerListWidget extends CompanyListWidget {
|
||||
@override
|
||||
_CompanyListState createState() => _CompanyListState("Manufacturers", {"is_manufacturer": "true"});
|
||||
}
|
||||
|
||||
|
||||
class CustomerListWidget extends CompanyListWidget {
|
||||
@override
|
||||
_CompanyListState createState() => _CompanyListState("Customers", {"is_customer": "true"});
|
||||
|
@ -75,6 +75,13 @@ class InvenTreeDrawer extends StatelessWidget {
|
||||
Navigator.push(context, MaterialPageRoute(builder: (context) => SupplierListWidget()));
|
||||
}
|
||||
|
||||
void _showManufacturers() {
|
||||
if (!InvenTreeAPI().checkConnection(context)) return;
|
||||
_closeDrawer();
|
||||
|
||||
Navigator.push(context, MaterialPageRoute(builder: (context) => ManufacturerListWidget()));
|
||||
}
|
||||
|
||||
void _showCustomers() {
|
||||
if (!InvenTreeAPI().checkConnection(context)) return;
|
||||
_closeDrawer();
|
||||
@ -128,9 +135,14 @@ class InvenTreeDrawer extends StatelessWidget {
|
||||
),
|
||||
new ListTile(
|
||||
title: new Text("Suppliers"),
|
||||
leading: new FaIcon(FontAwesomeIcons.industry),
|
||||
leading: new FaIcon(FontAwesomeIcons.building),
|
||||
onTap: _showSuppliers,
|
||||
),
|
||||
new ListTile(
|
||||
title: Text("Manufacturers"),
|
||||
leading: new FaIcon(FontAwesomeIcons.industry),
|
||||
onTap: _showManufacturers,
|
||||
),
|
||||
new ListTile(
|
||||
title: new Text("Customers"),
|
||||
leading: new FaIcon(FontAwesomeIcons.users),
|
||||
|
Loading…
x
Reference in New Issue
Block a user