add pagination for invoice and update ui for material 3
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import 'package:fcs/domain/entities/fcs_shipment.dart';
|
||||
import 'package:fcs/helpers/theme.dart';
|
||||
import 'package:fcs/pages/fcs_shipment/model/fcs_shipment_model.dart';
|
||||
import 'package:fcs/pages/widgets/local_text.dart';
|
||||
import 'package:fcs/pages/widgets/local_app_bar.dart';
|
||||
import 'package:fcs/pages/widgets/progress.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -42,39 +41,26 @@ class _InvoiceShipmentListState extends State<InvoiceShipmentList> {
|
||||
Widget build(BuildContext context) {
|
||||
return LocalProgress(
|
||||
inAsyncCall: _isLoading,
|
||||
child: DefaultTabController(
|
||||
length: 3,
|
||||
child: Scaffold(
|
||||
appBar: AppBar(
|
||||
centerTitle: true,
|
||||
leading: new IconButton(
|
||||
icon: new Icon(CupertinoIcons.back),
|
||||
onPressed: () => Navigator.of(context).pop(),
|
||||
),
|
||||
backgroundColor: primaryColor,
|
||||
title: LocalText(context, "invoice.shipment.title",
|
||||
fontSize: 18, color: Colors.white),
|
||||
),
|
||||
body: new ListView.separated(
|
||||
separatorBuilder: (context, index) => Divider(
|
||||
color: Colors.black,
|
||||
),
|
||||
scrollDirection: Axis.vertical,
|
||||
padding: EdgeInsets.only(top: 15),
|
||||
shrinkWrap: true,
|
||||
itemCount: _fcsShipments.length,
|
||||
itemBuilder: (BuildContext context, int index) {
|
||||
return InvoiceShipmentListRow(
|
||||
fcsShipment: _fcsShipments[index],
|
||||
onSelect: (f) {
|
||||
Navigator.of(context).push(CupertinoPageRoute(
|
||||
builder: (context) => InvoiceCustomerList(
|
||||
fcsShipment: f,
|
||||
)));
|
||||
},
|
||||
);
|
||||
}),
|
||||
),
|
||||
child: Scaffold(
|
||||
appBar: LocalAppBar(labelKey: "invoice.shipment.title"),
|
||||
body: new ListView.separated(
|
||||
separatorBuilder: (context, index) => Divider(
|
||||
color: Colors.black,
|
||||
),
|
||||
scrollDirection: Axis.vertical,
|
||||
padding: EdgeInsets.only(top: 15),
|
||||
shrinkWrap: true,
|
||||
itemCount: _fcsShipments.length,
|
||||
itemBuilder: (BuildContext context, int index) {
|
||||
return InvoiceShipmentListRow(
|
||||
fcsShipment: _fcsShipments[index],
|
||||
onSelect: (f) {
|
||||
Navigator.of(context).push(CupertinoPageRoute(
|
||||
builder: (context) =>
|
||||
InvoiceCustomerList(fcsShipment: f)));
|
||||
},
|
||||
);
|
||||
}),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user