add shipments
This commit is contained in:
@@ -12,6 +12,7 @@ import 'package:fcs/pages/profile/profile_currency_edit.dart';
|
||||
import 'package:fcs/pages/profile/profile_edit.dart';
|
||||
import 'package:fcs/pages/staff/model/staff_model.dart';
|
||||
import 'package:fcs/pages/widgets/bottom_up_page_route.dart';
|
||||
import 'package:fcs/pages/widgets/defalut_delivery_address.dart';
|
||||
import 'package:fcs/pages/widgets/display_text.dart';
|
||||
import 'package:fcs/pages/widgets/fcs_id_icon.dart';
|
||||
import 'package:fcs/pages/widgets/local_text.dart';
|
||||
@@ -176,8 +177,14 @@ class _ProfileState extends State<Profile> {
|
||||
)
|
||||
],
|
||||
),
|
||||
defalutDeliveryAddress(
|
||||
context, deliveryAddressModel.defalutAddress),
|
||||
DefaultDeliveryAddress(
|
||||
labelKey: "profile.default.delivery.address",
|
||||
deliveryAddress: deliveryAddressModel.defalutAddress,
|
||||
onTap: () {
|
||||
Navigator.push(
|
||||
context, BottomUpPageRoute(DeliveryAddressList()));
|
||||
},
|
||||
),
|
||||
getPrivilegeBox(context),
|
||||
SizedBox(height: 15),
|
||||
logoutbutton,
|
||||
@@ -189,42 +196,6 @@ class _ProfileState extends State<Profile> {
|
||||
);
|
||||
}
|
||||
|
||||
Widget defalutDeliveryAddress(
|
||||
BuildContext context, DeliveryAddress deliveryAddress) {
|
||||
return Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
children: [
|
||||
Expanded(
|
||||
child: DisplayText(
|
||||
labelTextKey: "delivery_address",
|
||||
iconData: MaterialCommunityIcons.truck_fast,
|
||||
),
|
||||
),
|
||||
Chip(
|
||||
label: InkWell(
|
||||
onTap: () => Navigator.push(
|
||||
context,
|
||||
BottomUpPageRoute(DeliveryAddressList()),
|
||||
),
|
||||
child: LocalText(context, "delivery_address.change_address",
|
||||
color: primaryColor),
|
||||
))
|
||||
],
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.only(left: 28.0),
|
||||
child: deliveryAddress == null
|
||||
? Container()
|
||||
: DeliveryAddressRow(
|
||||
key: ValueKey(deliveryAddress.id),
|
||||
deliveryAddress: deliveryAddress),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
Widget getPrivilegeBox(BuildContext context) {
|
||||
User user = Provider.of<MainModel>(context, listen: false).user;
|
||||
List<Privilege> _privileges =
|
||||
|
||||
Reference in New Issue
Block a user