add pickups

This commit is contained in:
Sai Naw Wun
2020-05-31 15:00:11 +06:30
parent d5847722d8
commit 3f6a66b887
57 changed files with 1368 additions and 1236 deletions

View File

@@ -41,75 +41,78 @@ class _PickupListRowState extends State<PickupListRow> {
print('_pickup $_pickUp');
return Container(
padding: EdgeInsets.only(left: 15, right: 15),
child: Card(
elevation: 10,
color: Colors.white,
child: InkWell(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => PickUpEditor(pickUp: _pickUp)),
);
},
child: Row(
children: <Widget>[
Expanded(
child: new Padding(
padding: const EdgeInsets.symmetric(vertical: 16.0),
child: new Row(
child: InkWell(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => PickUpEditor(pickUp: _pickUp)),
);
},
child: Row(
children: <Widget>[
Expanded(
child: new Padding(
padding: const EdgeInsets.symmetric(vertical: 16.0),
child: new Row(
children: <Widget>[
new Expanded(
child: new Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Padding(
padding: const EdgeInsets.only(left: 8.0),
child: new Text(
_pickUp.id == null ? '' : _pickUp.id,
style: new TextStyle(
fontSize: 15.0, color: Colors.black),
),
),
Padding(
padding: const EdgeInsets.only(left: 10.0, top: 10),
child: new Text(
_pickUp.id == null ? '' : "Last ${_pickUp.last} days" ,
style: new TextStyle(
fontSize: 15.0, color: Colors.grey),
),
)
],
),
),
],
),
),
),
Column(
children: <Widget>[
Padding(
padding: const EdgeInsets.all(0),
child: getStatus(_pickUp.status),
),
Padding(
padding: const EdgeInsets.only(left: 8.0,top:5,bottom: 5),
child: Row(
children: <Widget>[
new Expanded(
child: new Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Padding(
padding: const EdgeInsets.only(left: 8.0),
child: new Text(
_pickUp.id == null ? '' : _pickUp.id,
style: new TextStyle(
fontSize: 15.0, color: Colors.black),
),
),
Padding(
padding: const EdgeInsets.only(left: 8.0),
child: Row(
children: <Widget>[
new Text(
_pickUp.weight == null
? ''
: _pickUp.weight.toString() + 'lb - ',
style: new TextStyle(
fontSize: 15.0, color: Colors.grey),
),
new Text(
_pickUp.numberOfPackage == null
? ""
: _pickUp.numberOfPackage.toString() +
' packages',
style: new TextStyle(
fontSize: 15.0, color: Colors.grey),
),
],
),
),
],
),
new Text(
_pickUp.weight == null
? ''
: _pickUp.weight.toString() + 'lb - ',
style:
new TextStyle(fontSize: 15.0, color: Colors.grey),
),
new Text(
_pickUp.numberOfPackage == null
? ""
: _pickUp.numberOfPackage.toString() + ' packages',
style:
new TextStyle(fontSize: 15.0, color: Colors.grey),
),
],
),
),
),
Row(
children: <Widget>[
Padding(
padding: const EdgeInsets.all(8.0),
child: getStatus(_pickUp.status),
),
],
)
],
),
],
)
],
),
),
);