Initial commit for driver_tripz
This commit is contained in:
@@ -29,249 +29,6 @@ import 'package:flutter/cupertino.dart';
|
||||
|
||||
import 'device_compatibility_page.dart';
|
||||
|
||||
// class CupertinoDrawerCaptain extends StatelessWidget {
|
||||
// final ImageController imageController = Get.put(ImageController());
|
||||
|
||||
// @override
|
||||
// Widget build(BuildContext context) {
|
||||
// return CupertinoPageScaffold(
|
||||
// navigationBar: CupertinoNavigationBar(
|
||||
// middle: Text('Menu'.tr),
|
||||
// ),
|
||||
// child: SafeArea(
|
||||
// child: CustomScrollView(
|
||||
// slivers: [
|
||||
// const SliverToBoxAdapter(child: const UserAccountHeader()),
|
||||
// SliverList(
|
||||
// delegate: SliverChildListDelegate([
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.money_dollar,
|
||||
// text: 'Wallet'.tr,
|
||||
// onTap: () => Get.to(() => WalletCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.person,
|
||||
// text: 'Profile'.tr,
|
||||
// onTap: () => Get.to(() => ProfileCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.clock,
|
||||
// text: 'History of Trip'.tr,
|
||||
// onTap: () => Get.to(() => const HistoryCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.car_detailed,
|
||||
// text: 'Available for rides'.tr,
|
||||
// onTap: () => Get.to(() => const AvailableRidesPage()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.bell,
|
||||
// text: 'Notifications'.tr,
|
||||
// onTap: () => Get.to(() => const NotificationCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.question_circle,
|
||||
// text: 'Helping Center'.tr,
|
||||
// onTap: () => Get.to(() => HelpCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.share,
|
||||
// text: 'Share App'.tr,
|
||||
// onTap: () => Get.to(() => InviteScreen()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.wrench,
|
||||
// text: "Maintenance Center".tr,
|
||||
// onTap: () => Get.to(() => MaintainCenterPage()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon:
|
||||
// CupertinoIcons.heart, // Updated icon to represent health
|
||||
// text: "Health Insurance".tr, // Updated English text
|
||||
// onTap: () => Get.to(() => AssuranceHealthPage()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.mail,
|
||||
// text: "Contact Us".tr,
|
||||
// onTap: () => Get.to(() => ContactUsPage()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon:
|
||||
// Icons.play_circle_filled, // Icon representing video play
|
||||
// text: 'Videos Tutorials'.tr,
|
||||
// onTap: () => Get.to(() => VideoListPage()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: Icons.star, // Another option with a filled star icon
|
||||
// text: "Rate Our App".tr,
|
||||
// onTap: () => Get.to(() => RatingScreen()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.settings,
|
||||
// text: 'Settings'.tr,
|
||||
// onTap: () => Get.to(() => const SettingsCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// _buildDrawerItem(
|
||||
// icon: CupertinoIcons.square_arrow_right,
|
||||
// text: 'Sign Out'.tr,
|
||||
// onTap: () => Get.to(() => const LogoutCaptain()),
|
||||
// ),
|
||||
// _buildDivider(),
|
||||
// ]),
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// ),
|
||||
// );
|
||||
// }
|
||||
|
||||
// Widget _buildDivider() {
|
||||
// return const Divider(
|
||||
// thickness: 1,
|
||||
// height: 1,
|
||||
// color: CupertinoColors.systemGrey4,
|
||||
// );
|
||||
// }
|
||||
|
||||
// Widget _buildDrawerItem({
|
||||
// required IconData icon,
|
||||
// required String text,
|
||||
// required VoidCallback onTap,
|
||||
// }) {
|
||||
// return CupertinoButton(
|
||||
// onPressed: onTap,
|
||||
// child: Row(
|
||||
// children: [
|
||||
// Icon(icon, color: CupertinoColors.activeBlue),
|
||||
// const SizedBox(width: 10),
|
||||
// Text(text, style: const TextStyle(color: CupertinoColors.label)),
|
||||
// const Spacer(),
|
||||
// const Icon(CupertinoIcons.right_chevron,
|
||||
// color: CupertinoColors.systemGrey),
|
||||
// ],
|
||||
// ),
|
||||
// );
|
||||
// }
|
||||
// }
|
||||
|
||||
// class UserAccountHeader extends StatelessWidget {
|
||||
// const UserAccountHeader({super.key});
|
||||
|
||||
// @override
|
||||
// Widget build(BuildContext context) {
|
||||
// return Container(
|
||||
// padding: const EdgeInsets.all(16),
|
||||
// decoration: const BoxDecoration(
|
||||
// gradient: LinearGradient(
|
||||
// colors: [AppColor.blueColor, AppColor.twitterColor],
|
||||
// begin: Alignment.topLeft,
|
||||
// end: Alignment.bottomRight,
|
||||
// ),
|
||||
// ),
|
||||
// child: Column(
|
||||
// crossAxisAlignment: CrossAxisAlignment.start,
|
||||
// children: [
|
||||
// GetBuilder<ImageController>(
|
||||
// builder: (imageController) {
|
||||
// return Stack(
|
||||
// children: [
|
||||
// imageController.isloading
|
||||
// ? const CupertinoActivityIndicator()
|
||||
// : Container(
|
||||
// width: 100,
|
||||
// height: 100,
|
||||
// decoration: BoxDecoration(
|
||||
// shape: BoxShape.circle,
|
||||
// image: DecorationImage(
|
||||
// fit: BoxFit.cover,
|
||||
// image: NetworkImage(
|
||||
// '${AppLink.seferCairoServer}/portrate_captain_image/${box.read(BoxName.driverID)}.jpg',
|
||||
// ),
|
||||
// ),
|
||||
// ),
|
||||
// ),
|
||||
// Positioned(
|
||||
// right: 0,
|
||||
// top: 0,
|
||||
// child: CupertinoButton(
|
||||
// onPressed: () {
|
||||
// imageController.choosImagePicture(
|
||||
// AppLink.uploadImage1, 'portrait');
|
||||
// },
|
||||
// child: const Icon(CupertinoIcons.pencil_circle_fill,
|
||||
// color: CupertinoColors.white),
|
||||
// ),
|
||||
// ),
|
||||
// ],
|
||||
// );
|
||||
// },
|
||||
// ),
|
||||
// const SizedBox(height: 10),
|
||||
// Text(
|
||||
// '${box.read(BoxName.nameDriver).toString().split(' ')[0]} ${box.read(BoxName.nameDriver).toString().split(' ')[1]}',
|
||||
// style: const TextStyle(
|
||||
// color: CupertinoColors.white,
|
||||
// fontSize: 18,
|
||||
// fontWeight: FontWeight.bold),
|
||||
// ),
|
||||
// const SizedBox(height: 5),
|
||||
// Text(
|
||||
// box.read(BoxName.emailDriver),
|
||||
// style: const TextStyle(color: CupertinoColors.white, fontSize: 14),
|
||||
// ),
|
||||
// const SizedBox(height: 10),
|
||||
// Row(
|
||||
// children: [
|
||||
// Text(
|
||||
// Get.find<HomeCaptainController>().rating.toString(),
|
||||
// style: const TextStyle(
|
||||
// color: CupertinoColors.systemYellow, fontSize: 16),
|
||||
// ),
|
||||
// const SizedBox(width: 5),
|
||||
// // You might want to replace this with a Cupertino-style rating widget
|
||||
// // For now, we'll use text to represent stars
|
||||
// // const Text('★★★★★',
|
||||
// // style: TextStyle(color: CupertinoColors.systemYellow)),
|
||||
|
||||
// Container(
|
||||
// padding: const EdgeInsets.symmetric(horizontal: 4, vertical: 1),
|
||||
// color: AppColor.greenColor,
|
||||
// child: RatingBar.builder(
|
||||
// initialRating: double.parse(
|
||||
// Get.find<HomeCaptainController>().rating.toString()),
|
||||
// minRating: 1,
|
||||
// direction: Axis.horizontal,
|
||||
// itemCount: 5,
|
||||
// itemSize: 20,
|
||||
// itemPadding: const EdgeInsets.symmetric(horizontal: 2),
|
||||
// itemBuilder: (context, _) => const Icon(
|
||||
// Icons.star,
|
||||
// color: Colors.amber,
|
||||
// ),
|
||||
// onRatingUpdate: (rating) {},
|
||||
// ),
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// );
|
||||
// }
|
||||
// }
|
||||
class CupertinoDrawerCaptain extends StatelessWidget {
|
||||
final ImageController imageController = Get.put(ImageController());
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user