enquiry-screen

This commit is contained in:
Trina Bakshi 2025-05-20 12:09:13 +05:30
parent d67808e07f
commit 0a69a9a09f
5 changed files with 176 additions and 14 deletions

View File

@ -1,5 +1,5 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:intl/intl.dart'; import 'package:kmobile/features/enquiry/screens/enquiry_screen.dart';
import 'package:material_symbols_icons/material_symbols_icons.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart';
class ChequeManagementScreen extends StatefulWidget { class ChequeManagementScreen extends StatefulWidget {
@ -50,8 +50,8 @@ class _ChequeManagementScreen extends State<ChequeManagementScreen>{
icon: Symbols.data_alert, icon: Symbols.data_alert,
label: 'Enquiry', label: 'Enquiry',
onTap: () { onTap: () {
// Navigator.push(context, MaterialPageRoute( Navigator.push(context, MaterialPageRoute(
// builder: (context) => const BlockCardScreen())); builder: (context) => const EnquiryScreen()));
}, },
), ),

View File

@ -4,6 +4,7 @@ import 'package:kmobile/features/accounts/screens/account_statement_screen.dart'
import 'package:kmobile/features/cheque/screens/cheque_management_screen.dart'; import 'package:kmobile/features/cheque/screens/cheque_management_screen.dart';
import 'package:kmobile/features/customer_info/screens/customer_info_screen.dart'; import 'package:kmobile/features/customer_info/screens/customer_info_screen.dart';
import 'package:kmobile/features/beneficiaries/screens/manage_beneficiaries_screen.dart'; import 'package:kmobile/features/beneficiaries/screens/manage_beneficiaries_screen.dart';
import 'package:kmobile/features/enquiry/screens/enquiry_screen.dart';
import 'package:material_symbols_icons/material_symbols_icons.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart';
class DashboardScreen extends StatefulWidget { class DashboardScreen extends StatefulWidget {
@ -136,7 +137,10 @@ class _DashboardScreenState extends State<DashboardScreen> {
builder: (context) => const ManageBeneficiariesScreen())); builder: (context) => const ManageBeneficiariesScreen()));
}), }),
_buildQuickLink(Symbols.support_agent, "Contact \n Us", _buildQuickLink(Symbols.support_agent, "Contact \n Us",
() => print("")), () {
Navigator.push(context, MaterialPageRoute(
builder: (context) => const EnquiryScreen()));
}),
], ],
), ),
const SizedBox(height: 10), const SizedBox(height: 10),

View File

@ -0,0 +1,93 @@
import 'package:flutter/material.dart';
import 'package:material_symbols_icons/material_symbols_icons.dart';
import 'package:url_launcher/url_launcher.dart';
class EnquiryScreen extends StatefulWidget {
const EnquiryScreen({super.key});
@override
State<EnquiryScreen> createState() => _EnquiryScreen();
}
class _EnquiryScreen extends State<EnquiryScreen>{
Future<void> _launchEmail() async {
final Uri emailUri = Uri(
scheme: 'mailto',
path: 'helpdesk@kccb.in',
);
if (await canLaunchUrl(emailUri)) {
await launchUrl(emailUri);
} else {
debugPrint('Could not launch email client');
}
}
Future<void> _launchPhone() async {
final Uri phoneUri = Uri(scheme: 'tel', path: '0651-312861');
if (await canLaunchUrl(phoneUri)) {
await launchUrl(phoneUri);
} else {
debugPrint('Could not launch phone dialer');
}
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new),
onPressed: () {
Navigator.pop(context);
},),
title: const Text('Enquiry', style: TextStyle(color: Colors.black,
fontWeight: FontWeight.w500),),
centerTitle: false,
actions: const [
Padding(
padding: EdgeInsets.only(right: 10.0),
child: CircleAvatar(
backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image
radius: 20,
),
),
],
),
body: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const Text("Mail us at", style: TextStyle(color: Colors.grey)),
const SizedBox(height: 4),
GestureDetector(
onTap: _launchEmail,
child: const Text(
"helpdesk@kccb.in",
style: TextStyle(color: Colors.blue),
),
),
const SizedBox(height: 20),
const Text("Call us at", style: TextStyle(color: Colors.grey)),
const SizedBox(height: 4),
GestureDetector(
onTap: _launchPhone,
child: const Text(
"0651-312861",
style: TextStyle(color: Colors.blue),
),
),
const SizedBox(height: 20),
const Text("Write to us", style: TextStyle(color: Colors.grey)),
const SizedBox(height: 4),
const Text(
"101 Street, Some Street, Some Address\nSome Address",
style: TextStyle(color: Colors.blue),
),
],
),
),
);
}
}

View File

@ -130,10 +130,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: flutter_bloc name: flutter_bloc
sha256: "1046d719fbdf230330d3443187cc33cc11963d15c9089f6cc56faa42a4c5f0cc" sha256: cf51747952201a455a1c840f8171d273be009b932c75093020f9af64f2123e38
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "9.1.0" version: "9.1.1"
flutter_lints: flutter_lints:
dependency: "direct dev" dependency: "direct dev"
description: description:
@ -162,10 +162,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: flutter_secure_storage_linux name: flutter_secure_storage_linux
sha256: bf7404619d7ab5c0a1151d7c4e802edad8f33535abfbeff2f9e1fe1274e2d705 sha256: be76c1d24a97d0b98f8b54bce6b481a380a6590df992d0098f868ad54dc8f688
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.2.2" version: "1.2.3"
flutter_secure_storage_macos: flutter_secure_storage_macos:
dependency: transitive dependency: transitive
description: description:
@ -236,10 +236,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: http name: http
sha256: fe7ab022b76f3034adc518fb6ea04a82387620e19977665ea18d30a1cf43442f sha256: "2c11f3f94c687ee9bad77c171151672986360b2b001d109814ee7140b2cf261b"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.3.0" version: "1.4.0"
http_parser: http_parser:
dependency: transitive dependency: transitive
description: description:
@ -468,10 +468,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: provider name: provider
sha256: "489024f942069c2920c844ee18bb3d467c69e48955a4f32d1677f71be103e310" sha256: "4abbd070a04e9ddc287673bf5a030c7ca8b685ff70218720abab8b092f53dd84"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "6.1.4" version: "6.1.5"
shared_preferences: shared_preferences:
dependency: "direct main" dependency: "direct main"
description: description:
@ -589,6 +589,70 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.4.0" version: "1.4.0"
url_launcher:
dependency: "direct main"
description:
name: url_launcher
sha256: "9d06212b1362abc2f0f0d78e6f09f726608c74e3b9462e8368bb03314aa8d603"
url: "https://pub.dev"
source: hosted
version: "6.3.1"
url_launcher_android:
dependency: transitive
description:
name: url_launcher_android
sha256: "8582d7f6fe14d2652b4c45c9b6c14c0b678c2af2d083a11b604caeba51930d79"
url: "https://pub.dev"
source: hosted
version: "6.3.16"
url_launcher_ios:
dependency: transitive
description:
name: url_launcher_ios
sha256: "7f2022359d4c099eea7df3fdf739f7d3d3b9faf3166fb1dd390775176e0b76cb"
url: "https://pub.dev"
source: hosted
version: "6.3.3"
url_launcher_linux:
dependency: transitive
description:
name: url_launcher_linux
sha256: "4e9ba368772369e3e08f231d2301b4ef72b9ff87c31192ef471b380ef29a4935"
url: "https://pub.dev"
source: hosted
version: "3.2.1"
url_launcher_macos:
dependency: transitive
description:
name: url_launcher_macos
sha256: "17ba2000b847f334f16626a574c702b196723af2a289e7a93ffcb79acff855c2"
url: "https://pub.dev"
source: hosted
version: "3.2.2"
url_launcher_platform_interface:
dependency: transitive
description:
name: url_launcher_platform_interface
sha256: "552f8a1e663569be95a8190206a38187b531910283c3e982193e4f2733f01029"
url: "https://pub.dev"
source: hosted
version: "2.3.2"
url_launcher_web:
dependency: transitive
description:
name: url_launcher_web
sha256: "4bd2b7b4dc4d4d0b94e5babfffbca8eac1a126c7f3d6ecbc1a11013faa3abba2"
url: "https://pub.dev"
source: hosted
version: "2.4.1"
url_launcher_windows:
dependency: transitive
description:
name: url_launcher_windows
sha256: "3284b6d2ac454cf34f114e1d3319866fdd1e19cdc329999057e44ffe936cfa77"
url: "https://pub.dev"
source: hosted
version: "3.1.4"
vector_graphics: vector_graphics:
dependency: transitive dependency: transitive
description: description:
@ -641,10 +705,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: win32 name: win32
sha256: dc6ecaa00a7c708e5b4d10ee7bec8c270e9276dfcab1783f57e9962d7884305f sha256: "329edf97fdd893e0f1e3b9e88d6a0e627128cc17cc316a8d67fda8f1451178ba"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "5.12.0" version: "5.13.0"
xdg_directories: xdg_directories:
dependency: transitive dependency: transitive
description: description:

View File

@ -46,6 +46,7 @@ dependencies:
local_auth: ^2.3.0 local_auth: ^2.3.0
material_symbols_icons: ^4.2815.0 material_symbols_icons: ^4.2815.0
shared_preferences: ^2.5.3 shared_preferences: ^2.5.3
url_launcher: ^6.3.1
dev_dependencies: dev_dependencies:
flutter_test: flutter_test: