contact ui, create ticket

This commit is contained in:
jayesh
2024-03-22 17:21:40 +05:30
parent f0b1e1737d
commit be39551790
16 changed files with 846 additions and 37 deletions

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,7 @@
<svg width="11" height="11" viewBox="0 0 11 11" fill="none" xmlns="http://www.w3.org/2000/svg">
<mask id="path-1-inside-1_462_1817" fill="white">
<path d="M6.99725 3.22021L6.53516 2.7581L2.74618 6.54698C2.2756 7.01755 2.2756 7.78325 2.74618 8.25385C3.21675 8.72444 3.98245 8.72444 4.45305 8.25385L9.54166 3.16508C9.89186 2.81488 10.0847 2.34929 10.0847 1.85406C10.0847 1.35882 9.89186 0.893234 9.54166 0.543039C9.19149 0.192865 8.72588 0 8.23064 0C7.73538 0 7.2698 0.192865 6.91962 0.543061L0.732617 6.73007C0.260176 7.20251 0 7.83063 0 8.49872C0 9.16685 0.260176 9.79494 0.732617 10.2674C1.20506 10.7398 1.83318 11 2.50128 11C3.16937 11 3.79749 10.7398 4.26993 10.2674L9.15718 5.38012L8.69509 4.91803L3.80785 9.8053C3.45883 10.1543 2.99484 10.3465 2.50128 10.3465C2.00771 10.3465 1.54372 10.1543 1.1947 9.8053C0.845689 9.45628 0.653512 8.99229 0.653512 8.49872C0.653512 8.00516 0.845732 7.54114 1.1947 7.19215L7.38173 1.00515C7.84983 0.537066 8.6115 0.537066 9.0796 1.00515C9.5477 1.47325 9.5477 2.23491 9.0796 2.70301L3.99098 7.79174C3.77519 8.00753 3.42407 8.00753 3.20828 7.79174C2.99249 7.57595 2.99249 7.22483 3.20828 7.00904L6.99725 3.22021Z"/>
</mask>
<path d="M6.99725 3.22021L6.53516 2.7581L2.74618 6.54698C2.2756 7.01755 2.2756 7.78325 2.74618 8.25385C3.21675 8.72444 3.98245 8.72444 4.45305 8.25385L9.54166 3.16508C9.89186 2.81488 10.0847 2.34929 10.0847 1.85406C10.0847 1.35882 9.89186 0.893234 9.54166 0.543039C9.19149 0.192865 8.72588 0 8.23064 0C7.73538 0 7.2698 0.192865 6.91962 0.543061L0.732617 6.73007C0.260176 7.20251 0 7.83063 0 8.49872C0 9.16685 0.260176 9.79494 0.732617 10.2674C1.20506 10.7398 1.83318 11 2.50128 11C3.16937 11 3.79749 10.7398 4.26993 10.2674L9.15718 5.38012L8.69509 4.91803L3.80785 9.8053C3.45883 10.1543 2.99484 10.3465 2.50128 10.3465C2.00771 10.3465 1.54372 10.1543 1.1947 9.8053C0.845689 9.45628 0.653512 8.99229 0.653512 8.49872C0.653512 8.00516 0.845732 7.54114 1.1947 7.19215L7.38173 1.00515C7.84983 0.537066 8.6115 0.537066 9.0796 1.00515C9.5477 1.47325 9.5477 2.23491 9.0796 2.70301L3.99098 7.79174C3.77519 8.00753 3.42407 8.00753 3.20828 7.79174C2.99249 7.57595 2.99249 7.22483 3.20828 7.00904L6.99725 3.22021Z" fill="white"/>
<path d="M6.99725 3.22021L7.70434 3.92733L8.41146 3.22024L7.70437 2.51312L6.99725 3.22021ZM6.53516 2.7581L7.24228 2.05101L6.53519 1.34388L5.82806 2.05098L6.53516 2.7581ZM2.74618 6.54698L2.03908 5.83986L2.03907 5.83987L2.74618 6.54698ZM4.45305 8.25385L5.16015 8.96095L5.16016 8.96094L4.45305 8.25385ZM9.54166 3.16508L8.83456 2.45797L8.83454 2.45798L9.54166 3.16508ZM6.91962 0.543061L7.62673 1.25017L7.62675 1.25015L6.91962 0.543061ZM4.26993 10.2674L4.97704 10.9745L4.97704 10.9745L4.26993 10.2674ZM9.15718 5.38012L9.86429 6.08722L10.5714 5.38012L9.86428 4.67301L9.15718 5.38012ZM8.69509 4.91803L9.4022 4.21092L8.69509 3.50382L7.98798 4.21093L8.69509 4.91803ZM3.80785 9.8053L4.51495 10.5124L4.51496 10.5124L3.80785 9.8053ZM1.1947 9.8053L0.487596 10.5124L0.487618 10.5124L1.1947 9.8053ZM1.1947 7.19215L0.487597 6.48504L0.487574 6.48507L1.1947 7.19215ZM7.38173 1.00515L6.67464 0.298024L6.67463 0.298038L7.38173 1.00515ZM9.0796 1.00515L9.7867 0.29804L9.78669 0.298024L9.0796 1.00515ZM9.0796 2.70301L8.37249 1.99591L8.37248 1.99591L9.0796 2.70301ZM3.99098 7.79174L4.69809 8.49885L4.69809 8.49884L3.99098 7.79174ZM3.20828 7.00904L2.50119 6.30192L2.50118 6.30193L3.20828 7.00904ZM7.70437 2.51312L7.24228 2.05101L5.82804 3.46519L6.29012 3.9273L7.70437 2.51312ZM5.82806 2.05098L2.03908 5.83986L3.45327 7.25409L7.24226 3.46522L5.82806 2.05098ZM2.03907 5.83987C1.17796 6.70098 1.17799 8.09983 2.03905 8.96094L3.4533 7.54675C3.37322 7.46667 3.37324 7.33412 3.45328 7.25408L2.03907 5.83987ZM2.03905 8.96094C2.90016 9.82208 4.29904 9.82206 5.16015 8.96095L3.74594 7.54674C3.66586 7.62682 3.53333 7.62679 3.4533 7.54675L2.03905 8.96094ZM5.16016 8.96094L10.2488 3.87217L8.83454 2.45798L3.74593 7.54675L5.16016 8.96094ZM10.2488 3.87218C10.7865 3.33447 11.0847 2.61453 11.0847 1.85406H9.08472C9.08472 2.08406 8.99723 2.2953 8.83456 2.45797L10.2488 3.87218ZM11.0847 1.85406C11.0847 1.09358 10.7865 0.373649 10.2488 -0.164068L8.83456 1.25015C8.99723 1.41282 9.08472 1.62406 9.08472 1.85406H11.0847ZM10.2488 -0.164068C9.71106 -0.701778 8.9911 -1 8.23064 -1V1C8.46066 1 8.67192 1.08751 8.83456 1.25015L10.2488 -0.164068ZM8.23064 -1C7.47016 -1 6.75021 -0.70177 6.21249 -0.164025L7.62675 1.25015C7.78939 1.0875 8.00061 1 8.23064 1V-1ZM6.21252 -0.164046L0.0255104 6.02296L1.43972 7.43717L7.62673 1.25017L6.21252 -0.164046ZM0.0255104 6.02296C-0.634462 6.68293 -1 7.5654 -1 8.49872H1C1 8.09585 1.15481 7.72208 1.43972 7.43717L0.0255104 6.02296ZM-1 8.49872C-1 9.43208 -0.634458 10.3145 0.0255104 10.9745L1.43972 9.56028C1.15481 9.27536 1 8.90162 1 8.49872H-1ZM0.0255104 10.9745C0.685482 11.6345 1.56795 12 2.50128 12V10C2.0984 10 1.72463 9.84519 1.43972 9.56028L0.0255104 10.9745ZM2.50128 12C3.4346 12 4.31707 11.6345 4.97704 10.9745L3.56283 9.56028C3.27792 9.84519 2.90415 10 2.50128 10V12ZM4.97704 10.9745L9.86429 6.08722L8.45007 4.67301L3.56283 9.56028L4.97704 10.9745ZM9.86428 4.67301L9.4022 4.21092L7.98799 5.62514L8.45007 6.08722L9.86428 4.67301ZM7.98798 4.21093L3.10074 9.09819L4.51496 10.5124L9.4022 5.62514L7.98798 4.21093ZM3.10074 9.09819C2.93928 9.25965 2.72964 9.34649 2.50128 9.34649V11.3465C3.26003 11.3465 3.97839 11.049 4.51495 10.5124L3.10074 9.09819ZM2.50128 9.34649C2.27294 9.34649 2.06328 9.25965 1.90179 9.09817L0.487618 10.5124C1.02415 11.0489 1.74249 11.3465 2.50128 11.3465V9.34649ZM1.90181 9.09819C1.74034 8.93673 1.65351 8.72709 1.65351 8.49872H-0.346488C-0.346488 9.25748 -0.0489663 9.97584 0.487596 10.5124L1.90181 9.09819ZM1.65351 8.49872C1.65351 8.2704 1.74036 8.06071 1.90183 7.89924L0.487574 6.48507C-0.0488997 7.02157 -0.346488 7.73993 -0.346488 8.49872H1.65351ZM1.90181 7.89926L8.08884 1.71225L6.67463 0.298038L0.487597 6.48504L1.90181 7.89926ZM8.08882 1.71227C8.1664 1.63469 8.29493 1.63469 8.37251 1.71227L9.78669 0.298024C8.92807 -0.560559 7.53326 -0.560559 6.67464 0.298024L8.08882 1.71227ZM8.37249 1.71225C8.45007 1.78983 8.45007 1.91833 8.37249 1.99591L9.7867 3.41012C10.6453 2.55149 10.6453 1.15667 9.7867 0.29804L8.37249 1.71225ZM8.37248 1.99591L3.28387 7.08464L4.69809 8.49884L9.78671 3.41011L8.37248 1.99591ZM3.28387 7.08463C3.45861 6.9099 3.74065 6.9099 3.91539 7.08463L2.50118 8.49885C3.10749 9.10516 4.09177 9.10516 4.69809 8.49885L3.28387 7.08463ZM3.91539 7.08463C4.09013 7.25937 4.09013 7.54141 3.91539 7.71615L2.50118 6.30193C1.89486 6.90825 1.89486 7.89253 2.50118 8.49885L3.91539 7.08463ZM3.91538 7.71616L7.70434 3.92733L6.29015 2.51309L2.50119 6.30192L3.91538 7.71616Z" fill="white" mask="url(#path-1-inside-1_462_1817)"/>
</svg>

After

Width:  |  Height:  |  Size: 6.5 KiB

View File

@@ -0,0 +1,3 @@
<svg width="15" height="15" viewBox="0 0 15 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M14 14L1 1M14 1L1 14" stroke="white" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
</svg>

After

Width:  |  Height:  |  Size: 217 B

View File

@@ -1,4 +1,5 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:glassmorphism/glassmorphism.dart'; import 'package:glassmorphism/glassmorphism.dart';
class CustomTextFormField extends StatefulWidget { class CustomTextFormField extends StatefulWidget {
@@ -65,8 +66,8 @@ class _CustomTextFormFieldState extends State<CustomTextFormField> {
begin: Alignment.topLeft, begin: Alignment.topLeft,
end: Alignment.bottomRight, end: Alignment.bottomRight,
colors: [ colors: [
Color(0xFFffffff).withOpacity(0.1), const Color(0xFFffffff).withOpacity(0.1),
Color(0xFFFFFFFF).withOpacity(0.05), const Color(0xFFFFFFFF).withOpacity(0.05),
], ],
stops: [ stops: [
0.1, 0.1,
@@ -76,8 +77,8 @@ class _CustomTextFormFieldState extends State<CustomTextFormField> {
begin: Alignment.topLeft, begin: Alignment.topLeft,
end: Alignment.bottomRight, end: Alignment.bottomRight,
colors: [ colors: [
Color(0xff9A0000).withOpacity(0.5), const Color(0xff9A0000).withOpacity(0.5),
Color(0xFFffffff).withOpacity(0.5), const Color(0xFFffffff).withOpacity(0.5),
], ],
), ),
child: TextFormField( child: TextFormField(
@@ -126,9 +127,9 @@ class _CustomTextFormFieldState extends State<CustomTextFormField> {
? null ? null
: widget.suffixIcon!, : widget.suffixIcon!,
border: InputBorder.none, border: InputBorder.none,
contentPadding: EdgeInsets.symmetric(horizontal: 10), contentPadding: const EdgeInsets.symmetric(horizontal: 10),
), ),
style: TextStyle(color: Colors.white), style: const TextStyle(color: Colors.white),
keyboardType: widget.texttype, keyboardType: widget.texttype,
// validator: widget.validator ?? // validator: widget.validator ??
// (value) { // (value) {
@@ -145,3 +146,145 @@ class _CustomTextFormFieldState extends State<CustomTextFormField> {
); );
} }
} }
class CustomTextFormField1 extends StatefulWidget {
const CustomTextFormField1({
Key? key,
this.validator,
this.textEditingController,
this.hintText,
this.leadingIcon,
this.prefixIconColor = const Color(0xFF737373),
this.isInputPassword = false,
this.validatorText,
this.value,
this.readonly = false,
this.enabled = true,
this.maxlines = 1,
this.texttype,
this.inputFormatters,
this.onInput,
this.onTap,
this.suffixIcon,
}) : super(key: key);
final dynamic validator;
final TextEditingController? textEditingController;
final String? hintText;
final Widget? leadingIcon;
final Color prefixIconColor;
final bool isInputPassword;
final String? validatorText;
final String? value;
final bool readonly;
final bool enabled;
final int maxlines;
final TextInputType? texttype;
final dynamic inputFormatters;
final Function(String)? onInput;
final VoidCallback? onTap;
final Widget? suffixIcon;
@override
State<CustomTextFormField1> createState() => _CustomTextFormField1State();
}
class _CustomTextFormField1State extends State<CustomTextFormField1> {
late bool obscureText;
@override
void initState() {
super.initState();
obscureText = widget.isInputPassword;
}
@override
Widget build(BuildContext context) {
return TextFormField(
cursorColor: Colors.red,
initialValue: widget.value,
readOnly: widget.readonly,
onTap: widget.onTap,
enabled: widget.enabled,
enableInteractiveSelection: false,
maxLines: widget.maxlines,
autovalidateMode: AutovalidateMode.onUserInteraction,
obscureText: obscureText,
controller: widget.textEditingController,
decoration: InputDecoration(
contentPadding: const EdgeInsets.symmetric(
vertical: 15,
horizontal: 14,
),
hintText: widget.hintText,
border: OutlineInputBorder(
borderRadius: BorderRadius.circular(8.r),
borderSide: const BorderSide(color: Color(0XFF3A3A3A), width: 1),
),
enabledBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(8.r),
borderSide: const BorderSide(color: Color(0XFF3A3A3A), width: 1),
),
focusedBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(8.r),
borderSide: const BorderSide(color: Color(0XFF3A3A3A), width: 1),
),
errorBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(8),
borderSide: const BorderSide(color: Colors.red, width: 1),
),
focusedErrorBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(8),
borderSide: const BorderSide(color: Colors.red, width: 1),
),
hintStyle: TextStyle(
fontSize: 16.sp, fontFamily: "manrope", color: Colors.white),
prefixIconColor: widget.prefixIconColor,
// ignore: prefer_null_aware_operators
prefixIcon: widget.leadingIcon == null ? null : widget.leadingIcon!,
suffixIcon: widget.isInputPassword
? GestureDetector(
onTap: () => setState(() => obscureText = !obscureText),
child: obscureText
? const Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Padding(
padding: EdgeInsets.only(right: 20.0),
child: Icon(Icons.remove_red_eye),
),
],
)
: const Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Padding(
padding: EdgeInsets.only(right: 20.0),
child: Icon(
Icons.remove_red_eye_outlined,
color: Color(0xFF959595),
),
),
],
),
)
: widget.suffixIcon == null
? null
: widget.suffixIcon!,
),
style: const TextStyle(color: Colors.white),
keyboardType: widget.texttype,
validator: widget.validator ??
(value) {
if (value == null || value.isEmpty) {
return "Empty value";
}
return null;
},
inputFormatters: widget.inputFormatters,
onChanged: (value) {
widget.onInput?.call(value);
},
);
}
}

View File

@@ -0,0 +1,40 @@
import 'dart:io';
import 'package:file_picker/file_picker.dart';
import 'package:get/get.dart';
import 'package:traderscircuit/Utils/Dialogs.dart';
import 'package:path/path.dart' as path;
import 'package:traderscircuit/controller/contact_us_controller.dart';
class FilePickerMethod {
ContactUsController contactUsController = Get.put(ContactUsController());
String extractFileName(String filePath) {
return path.basename(filePath);
}
Future<List<File?>?> pickFile() async {
FilePickerResult? result = await FilePicker.platform.pickFiles(
allowMultiple: true,
allowCompression: true, compressionQuality: 50,
type: FileType.custom,
allowedExtensions: [
'jpg',
'jpeg',
'png',
'pdf'
], // Define the allowed file types
);
if (result != null) {
if (contactUsController.attachmentFileList.length + result.count > 3) {
utils.showToast("Can Select Max 3 Files");
return null;
} else {
return result.paths.map((path) => File(path!)).toList();
}
} else {
return null;
}
}
}

View File

@@ -45,13 +45,16 @@ Widget text18W500(String text) {
); );
} }
Widget text18W400(String text) { Widget text18W400(String text,
{TextAlign texAl = TextAlign.start, double heightV = 1.5}) {
return Text( return Text(
text, text,
textAlign: texAl,
style: TextStyle( style: TextStyle(
fontSize: 18.sp, fontSize: 18.sp,
color: Colors.white, color: Colors.white,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
height: heightV,
fontFamily: 'manrope'), fontFamily: 'manrope'),
); );
} }
@@ -69,12 +72,14 @@ Widget text24W500(String text) {
); );
} }
Widget text16W400(String text) { Widget text16W400(String text,
{Color clr = Colors.white, TextOverflow textOver = TextOverflow.clip}) {
return Text( return Text(
text, text,
overflow: textOver,
style: TextStyle( style: TextStyle(
fontSize: 16.sp, fontSize: 16.sp,
color: Colors.white, color: clr,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
fontFamily: 'manrope'), fontFamily: 'manrope'),
); );
@@ -124,12 +129,12 @@ Widget text16W600(String text) {
); );
} }
Widget text16W500(String text) { Widget text16W500(String text, {Color clr = Colors.white}) {
return Text( return Text(
text, text,
style: TextStyle( style: TextStyle(
fontSize: 16.sp, fontSize: 16.sp,
color: Colors.white, color: clr,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
fontFamily: 'manrope'), fontFamily: 'manrope'),
); );
@@ -167,6 +172,7 @@ Widget text12W400(String text) {
fontFamily: 'manrope'), fontFamily: 'manrope'),
); );
} }
Widget text12W500(String text) { Widget text12W500(String text) {
return Text( return Text(
text, text,

View File

@@ -0,0 +1,8 @@
import 'dart:io';
import 'package:get/get.dart';
class ContactUsController extends GetxController {
RxList<File?> attachmentFileList = [File("")].obs;
RxList<String> attachmentPathNameList = [""].obs;
}

View File

@@ -16,8 +16,6 @@ class RouteName {
static const String notification = '/notification'; static const String notification = '/notification';
static const String exploreUnseen = '/exploreUnseen'; static const String exploreUnseen = '/exploreUnseen';
static const String verifyotp = '/verifyotp'; static const String verifyotp = '/verifyotp';
//secureaccess //secureaccess
@@ -40,4 +38,7 @@ class RouteName {
static const String termsandcondition = '/termsandcondition'; static const String termsandcondition = '/termsandcondition';
static const String privacypolicy = '/privacypolicy'; static const String privacypolicy = '/privacypolicy';
static const String aboutus = '/aboutus'; static const String aboutus = '/aboutus';
//contact us
static const String contactUsMain = '/contactUsMain';
} }

View File

@@ -5,6 +5,7 @@ import 'package:traderscircuit/view/MainScreen/ExploreUnseen.dart';
import 'package:traderscircuit/view/Sidemenu/AboutUs.dart'; import 'package:traderscircuit/view/Sidemenu/AboutUs.dart';
import 'package:traderscircuit/view/Sidemenu/PrivacyPolicy.dart'; import 'package:traderscircuit/view/Sidemenu/PrivacyPolicy.dart';
import 'package:traderscircuit/view/Sidemenu/TermsAndCondition.dart'; import 'package:traderscircuit/view/Sidemenu/TermsAndCondition.dart';
import 'package:traderscircuit/view/Sidemenu/contactUs/contact_us_main.dart';
import 'package:traderscircuit/view/login/AddDetails.dart'; import 'package:traderscircuit/view/login/AddDetails.dart';
import 'package:traderscircuit/view/login/Kyc.dart'; import 'package:traderscircuit/view/login/Kyc.dart';
@@ -140,5 +141,11 @@ class AppRoutes {
name: RouteName.aboutus, name: RouteName.aboutus,
page: () => const AboutUs(), page: () => const AboutUs(),
), ),
//contact us
GetPage(
name: RouteName.contactUsMain,
page: () => const ContactUsMainScreen(),
)
]; ];
} }

View File

@@ -5,7 +5,6 @@ import 'package:get/get.dart';
import 'package:traderscircuit/Utils/Common/sized_box.dart'; import 'package:traderscircuit/Utils/Common/sized_box.dart';
import 'package:traderscircuit/Utils/text.dart'; import 'package:traderscircuit/Utils/text.dart';
import 'package:traderscircuit/resources/routes/route_name.dart'; import 'package:traderscircuit/resources/routes/route_name.dart';
import 'package:traderscircuit/view/onBoarding/splashScreen1.dart';
class SideMenu extends StatefulWidget { class SideMenu extends StatefulWidget {
const SideMenu({super.key}); const SideMenu({super.key});
@@ -16,7 +15,10 @@ class SideMenu extends StatefulWidget {
class _SideMenuState extends State<SideMenu> { class _SideMenuState extends State<SideMenu> {
List sideBarData = [ List sideBarData = [
{"imagePath": "assets/images/svg/sidemenu/Faq.svg", "text": "FAQs"}, {
"imagePath": "assets/images/svg/sidemenu/Faq.svg",
"text": "FAQs",
},
{ {
"imagePath": "assets/images/svg/sidemenu/contact.svg", "imagePath": "assets/images/svg/sidemenu/contact.svg",
"text": "Contact Us" "text": "Contact Us"
@@ -62,9 +64,9 @@ class _SideMenuState extends State<SideMenu> {
child: Container( child: Container(
width: 25.w, width: 25.w,
height: 25.h, height: 25.h,
decoration: ShapeDecoration( decoration: const ShapeDecoration(
color: Colors.black, color: Colors.black,
shape: const OvalBorder(), shape: OvalBorder(),
), ),
child: Align( child: Align(
alignment: Alignment.center, alignment: Alignment.center,
@@ -105,13 +107,13 @@ class _SideMenuState extends State<SideMenu> {
Container( Container(
width: 80.w, width: 80.w,
height: 80.h, height: 80.h,
decoration: ShapeDecoration( decoration: const ShapeDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
"assets/images/png/Ellipse 560.png"), "assets/images/png/Ellipse 560.png"),
fit: BoxFit.fill, fit: BoxFit.fill,
), ),
shape: const OvalBorder(), shape: OvalBorder(),
), ),
), ),
sizedBoxWidth(20.w), sizedBoxWidth(20.w),
@@ -131,7 +133,7 @@ class _SideMenuState extends State<SideMenu> {
Container( Container(
height: 1, height: 1,
margin: EdgeInsets.symmetric(vertical: 10.h), margin: EdgeInsets.symmetric(vertical: 10.h),
decoration: BoxDecoration( decoration: const BoxDecoration(
border: Border( border: Border(
bottom: BorderSide( bottom: BorderSide(
color: Color.fromRGBO(176, 176, 176, 0.5), color: Color.fromRGBO(176, 176, 176, 0.5),
@@ -152,7 +154,7 @@ class _SideMenuState extends State<SideMenu> {
width: 122.w, width: 122.w,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(6.r), borderRadius: BorderRadius.circular(6.r),
color: Color(0xFF34C759), color: const Color(0xFF34C759),
), ),
child: Center(child: text14W500_black('Upgrade')), child: Center(child: text14W500_black('Upgrade')),
), ),
@@ -166,7 +168,7 @@ class _SideMenuState extends State<SideMenu> {
Container( Container(
height: 1, height: 1,
margin: EdgeInsets.symmetric(vertical: 10.h), margin: EdgeInsets.symmetric(vertical: 10.h),
decoration: BoxDecoration( decoration: const BoxDecoration(
border: Border( border: Border(
bottom: BorderSide( bottom: BorderSide(
color: Color.fromRGBO(176, 176, 176, 0.5), color: Color.fromRGBO(176, 176, 176, 0.5),
@@ -192,7 +194,7 @@ class _SideMenuState extends State<SideMenu> {
Container( Container(
height: 1, height: 1,
margin: EdgeInsets.symmetric(vertical: 10.h), margin: EdgeInsets.symmetric(vertical: 10.h),
decoration: BoxDecoration( decoration: const BoxDecoration(
border: Border( border: Border(
bottom: BorderSide( bottom: BorderSide(
color: Color.fromRGBO(176, 176, 176, 0.5), color: Color.fromRGBO(176, 176, 176, 0.5),
@@ -213,8 +215,8 @@ class _SideMenuState extends State<SideMenu> {
width: 122.w, width: 122.w,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(6.r), borderRadius: BorderRadius.circular(6.r),
color: Color(0xFF3A3A3A).withOpacity(0.6), color: const Color(0xFF3A3A3A).withOpacity(0.6),
border: Border.all(color: Color(0xFF9A0000))), border: Border.all(color: const Color(0xFF9A0000))),
child: Padding( child: Padding(
padding: EdgeInsets.symmetric(horizontal: 10.w), padding: EdgeInsets.symmetric(horizontal: 10.w),
child: Row( child: Row(
@@ -224,7 +226,7 @@ class _SideMenuState extends State<SideMenu> {
Container( Container(
height: 30.h, height: 30.h,
width: 30.h, width: 30.h,
decoration: BoxDecoration( decoration: const BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
'assets/images/png/Ellipse 1498.png', 'assets/images/png/Ellipse 1498.png',
@@ -238,15 +240,13 @@ class _SideMenuState extends State<SideMenu> {
), ),
selected: true, selected: true,
onTap: () { onTap: () {
setState(() { Get.toNamed(RouteName.kyc);
// Get.toNamed(RouteName.privacypolicy);
});
}, },
), ),
Container( Container(
height: 1, height: 1,
margin: EdgeInsets.symmetric(vertical: 10.h), margin: EdgeInsets.symmetric(vertical: 10.h),
decoration: BoxDecoration( decoration: const BoxDecoration(
border: Border( border: Border(
bottom: BorderSide( bottom: BorderSide(
color: Color.fromRGBO(176, 176, 176, 0.5), color: Color.fromRGBO(176, 176, 176, 0.5),
@@ -267,7 +267,7 @@ class _SideMenuState extends State<SideMenu> {
width: 122.w, width: 122.w,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(6.r), borderRadius: BorderRadius.circular(6.r),
color: Color(0xFF0093FF), color: const Color(0xFF0093FF),
), ),
child: Center(child: text14W500('Conservative')), child: Center(child: text14W500('Conservative')),
), ),
@@ -284,6 +284,7 @@ class _SideMenuState extends State<SideMenu> {
image: sideBarData[index]["imagePath"], image: sideBarData[index]["imagePath"],
text: sideBarData[index]["text"], text: sideBarData[index]["text"],
onTap: () { onTap: () {
print(index);
navigateTo(index, context); navigateTo(index, context);
}, },
); );
@@ -367,7 +368,7 @@ LogOutdialog(context) {
color: const Color(0xFFFFFFFF)), color: const Color(0xFFFFFFFF)),
), ),
sizedBoxHeight(40.h), sizedBoxHeight(40.h),
Row( const Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ children: [
// SizedBox( // SizedBox(
@@ -408,7 +409,7 @@ void navigateTo(int index, BuildContext context) {
case 1: case 1:
{ {
// Get.toNamed(RouteName.feedback); Get.toNamed(RouteName.contactUsMain);
} }
break; break;
@@ -420,7 +421,7 @@ void navigateTo(int index, BuildContext context) {
case 3: case 3:
{ {
// Get.toNamed(RouteName.contactUs); // Get.toNamed(RouteName.contactUsMain);
} }
break; break;
@@ -517,7 +518,7 @@ void navigateTo(int index, BuildContext context) {
child: Container( child: Container(
width: 150.w, width: 150.w,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Color(0xFF3192D8), color: const Color(0xFF3192D8),
borderRadius: BorderRadius.circular(5.r), borderRadius: BorderRadius.circular(5.r),
), ),
child: Padding( child: Padding(
@@ -568,7 +569,7 @@ class sideBarTile extends StatelessWidget {
Container( Container(
height: 1, height: 1,
margin: EdgeInsets.symmetric(vertical: 10.h), margin: EdgeInsets.symmetric(vertical: 10.h),
decoration: BoxDecoration( decoration: const BoxDecoration(
border: Border( border: Border(
bottom: BorderSide( bottom: BorderSide(
color: Color.fromRGBO(176, 176, 176, 0.5), color: Color.fromRGBO(176, 176, 176, 0.5),

View File

@@ -0,0 +1,241 @@
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:gap/gap.dart';
import 'package:get/get.dart';
import 'package:traderscircuit/controller/contact_us_controller.dart';
import '../../../Utils/Common/CommonAppbar.dart';
import '../../../Utils/Common/commonBotton.dart';
import '../../../Utils/text.dart';
import '../../onBoarding/splashScreen1.dart';
import 'create_ticket_bottom_sheet.dart';
class ContactUsMainScreen extends StatefulWidget {
const ContactUsMainScreen({super.key});
@override
State<ContactUsMainScreen> createState() => _ContactUsMainScreenState();
}
class _ContactUsMainScreenState extends State<ContactUsMainScreen> {
ContactUsController contactUsController = Get.put(ContactUsController());
@override
Widget build(BuildContext context) {
return DefaultTabController(
length: 4,
child: Scaffold(
appBar: CommonAppbar(
height: 75,
titleTxt: "",
customActionWidget: text16W400(""),
),
backgroundColor: Colors.black,
extendBody: true,
bottomNavigationBar: Padding(
padding: const EdgeInsets.symmetric(horizontal: 17, vertical: 40),
child: SizedBox(
width: Get.width,
child: kycBtn(
text: "Create Ticket",
onTap: () {
contactUsController.attachmentFileList.clear();
contactUsController.attachmentPathNameList.clear();
CreateTicketBottomSheet().bottomSheet(context);
},
bgClr: const Color(0xFF6C0000),
borderClr: const Color(0xFF990000),
),
),
),
body: Stack(
children: [
const CommonBlurLeft(),
const CommonBlurRight(),
Stack(children: [
Padding(
padding:
const EdgeInsets.symmetric(horizontal: 16, vertical: 16),
child: ListView(
physics: const NeverScrollableScrollPhysics(),
children: [
text25W600("Contact Us"),
const Gap(20),
text16W400("Hi Afrid,"),
text16W400("We are here to help you Us"),
const Gap(12),
TabBar(
labelStyle: TextStyle(
fontSize: 18.sp,
fontWeight: FontWeight.w400,
fontFamily: "manrope",
),
isScrollable: true,
labelColor: Colors.white,
unselectedLabelColor: const Color(0xFF464646),
indicatorColor: const Color(0xFF6C0000),
indicatorSize: TabBarIndicatorSize.label,
unselectedLabelStyle: TextStyle(
fontSize: 18.sp,
fontWeight: FontWeight.w500,
fontFamily: "manrope",
),
tabs: const [
Tab(text: "All Tickets (2)"),
Tab(text: "Open Tickets (2)"),
Tab(text: "Closed (1)"),
Tab(text: "Resolved (1)"),
],
),
SizedBox(
height: 0.5.sh,
child: TabBarView(children: [
ListView.builder(
itemCount: dataL.length,
itemBuilder: (ctx, index) {
return ticketCardWidget(index, "ALL");
}),
ListView.builder(
itemCount: dataL.length,
itemBuilder: (ctx, index) {
return ticketCardWidget(index, "OPEN");
}),
ListView.builder(
itemCount: dataL.length,
itemBuilder: (ctx, index) {
return ticketCardWidget(index, "CLOSED");
}),
ListView.builder(
itemCount: dataL.length,
itemBuilder: (ctx, index) {
return ticketCardWidget(index, "RESOLVED");
}),
]),
)
],
)),
]),
],
),
),
);
}
}
Widget ticketCardWidget(index, type) {
return dataL[index]["type"] != type && type != "ALL"
? SizedBox()
: Container(
width: Get.width,
height: 190,
margin: EdgeInsets.only(bottom: 18, top: index == 0 ? 15 : 0),
decoration: ShapeDecoration(
gradient: LinearGradient(
begin: const Alignment(0.98, -0.21),
end: const Alignment(-0.98, 0.21),
colors: [
Colors.white.withOpacity(0.03999999910593033),
Colors.white.withOpacity(0.05999999865889549)
],
),
shape: RoundedRectangleBorder(
side: const BorderSide(width: 1, color: Color(0xFF393939)),
borderRadius: BorderRadius.circular(8),
),
),
child: Padding(
padding: const EdgeInsets.symmetric(
vertical: 15,
horizontal: 10,
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
text16W600(dataL[index]["id"]),
Row(
children: [
text16W500(dataL[index]["type"],
clr: dataL[index]["type"] == "OPEN"
? const Color(0xFFFFAD31)
: dataL[index]["type"] == "CLOSED"
? const Color(0xFF95CCFF)
: const Color(0xFF34C759)),
const Gap(8),
CircleAvatar(
radius: 10,
backgroundColor: dataL[index]["type"] == "OPEN"
? const Color(0xFFFFAD31)
: dataL[index]["type"] == "CLOSED"
? const Color(0xFF95CCFF)
: const Color(0xFF34C759),
child: const Center(
child: Icon(
Icons.check_rounded,
size: 15,
color: Colors.white,
),
),
)
],
),
],
),
const Gap(10),
text16W600(dataL[index]["date"]),
const Gap(5),
text16W400(dataL[index]["category"]),
const Gap(22),
Container(
padding: const EdgeInsets.symmetric(
horizontal: 12,
),
width: Get.width,
height: 50,
decoration: ShapeDecoration(
color: Colors.black.withOpacity(0.03999999910593033),
shape: RoundedRectangleBorder(
side:
const BorderSide(width: 1, color: Color(0xFF393939)),
borderRadius: BorderRadius.circular(8),
),
),
child: Center(
child: text16W400(dataL[index]["desc"],
clr: const Color(0xFF9E9E9E),
textOver: TextOverflow.ellipsis),
),
)
],
),
),
);
}
List<dynamic> dataL = [
{
"id": "#13569412",
"date": "16 Feb 2024, 11 : 35PM",
"category": "Account Management",
"desc":
"Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500. Lorem Ipsum has been the industry's standard dummy text ever since the 1500",
"type": "OPEN"
},
{
"id": "#13569412",
"date": "16 Feb 2024, 11 : 35PM",
"category": "Technical Support",
"desc":
"Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500. Lorem Ipsum has been the industry's standard dummy text ever since the 1500",
"type": "CLOSED"
},
{
"id": "#13569412",
"date": "16 Feb 2024, 11 : 35PM",
"category": "Feedback and Suggestions",
"desc":
"Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500. Lorem Ipsum has been the industry's standard dummy text ever since the 1500",
"type": "RESOLVED"
}
];

View File

@@ -0,0 +1,219 @@
import 'dart:developer';
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:flutter_svg/svg.dart';
import 'package:gap/gap.dart';
import 'package:get/get.dart';
import 'package:traderscircuit/Utils/text.dart';
import '../../../Utils/Common/CustomTextFormField.dart';
import '../../../Utils/Common/FilePicker.dart';
import '../../../Utils/Common/commonBotton.dart';
import '../../../Utils/Common/custom_drop_down.dart';
import '../../../controller/contact_us_controller.dart';
import 'ticket_confirmed_bottom_sheet.dart';
class CreateTicketBottomSheet {
TextEditingController descriptionController = TextEditingController();
ContactUsController contactUsController = Get.put(ContactUsController());
bottomSheet(
BuildContext context,
) {
return showModalBottomSheet(
useSafeArea: true,
isScrollControlled: true,
context: context,
backgroundColor: const Color(0xFF101111),
isDismissible: false,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.only(
topLeft: Radius.circular(8.r),
topRight: Radius.circular(8.r),
),
),
builder: (BuildContext context) {
return Obx(
() => Container(
padding: const EdgeInsets.symmetric(vertical: 8, horizontal: 20),
child: Wrap(
children: [
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
crossAxisAlignment: CrossAxisAlignment.end,
mainAxisAlignment: MainAxisAlignment.end,
children: [
GestureDetector(
onTap: () {
Get.back();
},
child: SvgPicture.asset(
"assets/images/svg/cross_cancel.svg")),
],
),
const Gap(16),
text18W600("Raise a Ticket"),
const Gap(20),
const CustomDropDownWidget(
header: "Choose your query",
listData: [
"Account Management",
"Technical Support",
"Billing and Payments",
"Feedback and Suggestions",
"Complaints and Disputes",
"Subscriptions",
"Portfolio",
"Content Buytes",
"Market Insights"
],
),
const Gap(14),
Stack(
children: [
CustomTextFormField1(
texttype: TextInputType.multiline,
hintText: "Description (min 30 characters)",
textEditingController: descriptionController,
maxlines: 8,
validator: (value) {
if (value.isEmpty) {
return 'Enter your description';
} else if (value.toString().length < 30) {
return 'Description should be minimum 30 characters';
}
return null;
},
inputFormatters: [
LengthLimitingTextInputFormatter(150),
],
),
contactUsController.attachmentPathNameList.isEmpty
? const SizedBox()
: Positioned(
bottom: 8,
left: 9,
right: 9,
child: SizedBox(
width: 1.sw,
height: 37.h,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: contactUsController
.attachmentPathNameList.length,
itemBuilder: (ctx, index) {
return Container(
width: 210.w,
height: 37.h,
margin:
const EdgeInsets.only(right: 5),
decoration: BoxDecoration(
borderRadius:
BorderRadius.circular(8),
border: Border.all(
width: 1,
color:
const Color(0xFF3A3A3A))),
child: Row(
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
const Gap(6),
SvgPicture.asset(
"assets/images/svg/attachment_pin.svg"),
const Gap(6),
SizedBox(
width: 120,
child: FittedBox(
child: text12W400(
contactUsController
.attachmentPathNameList[
index]))),
const Gap(15),
GestureDetector(
onTap: () {
contactUsController
.attachmentPathNameList
.removeAt(index);
contactUsController
.attachmentFileList
.removeAt(index);
},
child: SvgPicture.asset(
"assets/images/svg/cross_cancel.svg",
color:
const Color(0xFF818181),
width: 8,
height: 8,
)),
],
),
);
}),
))
],
),
contactUsController.attachmentPathNameList.length >= 3
? const SizedBox()
: const Gap(10),
contactUsController.attachmentPathNameList.length >= 3
? const SizedBox()
: InkWell(
onTap: () async {
var result = await FilePickerMethod().pickFile();
if (result != null) {
contactUsController.attachmentPathNameList
.clear();
for (var a in result) {
contactUsController.attachmentFileList.add(a);
}
for (var a
in contactUsController.attachmentFileList) {
contactUsController.attachmentPathNameList
.add(FilePickerMethod()
.extractFileName(a?.path ?? ''));
}
}
},
child: Row(
children: [
SvgPicture.asset(
"assets/images/svg/attachment_pin.svg"),
const Gap(6),
text12W400(
"Add Attachment (Max 3 files of 2MB each / Optional)"),
],
),
),
const Gap(20),
SizedBox(
width: Get.width,
child: kycBtn(
text: "Create Ticket",
onTap: () {
Get.back();
TicketConfirmedBottomSheet().bottomSheet(context);
},
bgClr: const Color(0xFF6C0000),
borderClr: const Color(0xFF990000),
),
),
const Gap(30),
],
)
],
),
),
);
},
);
}
}

View File

@@ -0,0 +1,83 @@
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:flutter_svg/svg.dart';
import 'package:gap/gap.dart';
import 'package:get/get.dart';
import 'package:lottie/lottie.dart';
import 'package:traderscircuit/Utils/text.dart';
import '../../../Utils/Common/commonBotton.dart';
class TicketConfirmedBottomSheet {
bottomSheet(
BuildContext context,
) {
return showModalBottomSheet(
useSafeArea: true,
isScrollControlled: true,
context: context,
backgroundColor: const Color(0xFF101111),
isDismissible: false,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.only(
topLeft: Radius.circular(8.r),
topRight: Radius.circular(8.r),
),
),
builder: (BuildContext context) {
return Container(
padding: const EdgeInsets.symmetric(vertical: 8, horizontal: 20),
child: Wrap(
children: [
Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Row(
crossAxisAlignment: CrossAxisAlignment.end,
mainAxisAlignment: MainAxisAlignment.end,
children: [
GestureDetector(
onTap: () {
Get.back();
},
child: SvgPicture.asset(
"assets/images/svg/cross_cancel.svg")),
],
),
const Gap(22),
Lottie.asset(
'assets/images/png/check_lottie.json',
width: 140,
height: 140,
),
const Gap(10),
text18W600("#18663765"),
const Gap(8),
text18W400(
"Your ticket has been created successfully. our support team will get back to you in 24-48 business hours.",
texAl: TextAlign.center,
heightV: 2,
),
const Gap(35),
SizedBox(
width: Get.width,
child: kycBtn(
text: "Done",
onTap: () {
Get.back();
},
bgClr: const Color(0xFF6C0000),
borderClr: const Color(0xFF990000),
),
),
const Gap(30),
],
)
],
),
);
},
);
}
}

View File

@@ -7,7 +7,6 @@ import 'package:flutter_svg/flutter_svg.dart';
import 'package:get/get.dart'; import 'package:get/get.dart';
import 'package:glassmorphism/glassmorphism.dart'; import 'package:glassmorphism/glassmorphism.dart';
import 'package:traderscircuit/Utils/Common/CommonAppbar.dart'; import 'package:traderscircuit/Utils/Common/CommonAppbar.dart';
import 'package:traderscircuit/Utils/Common/CommonDropdown.dart';
import 'package:traderscircuit/Utils/Common/CustomTextFormField.dart'; import 'package:traderscircuit/Utils/Common/CustomTextFormField.dart';
import 'package:traderscircuit/Utils/Common/commonBotton.dart'; import 'package:traderscircuit/Utils/Common/commonBotton.dart';
import 'package:traderscircuit/Utils/text.dart'; import 'package:traderscircuit/Utils/text.dart';

View File

@@ -1,6 +1,14 @@
# Generated by pub # Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile # See https://dart.dev/tools/pub/glossary#lockfile
packages: packages:
archive:
dependency: transitive
description:
name: archive
sha256: "22600aa1e926be775fa5fe7e6894e7fb3df9efda8891c73f70fb3262399a432d"
url: "https://pub.dev"
source: hosted
version: "3.4.10"
args: args:
dependency: transitive dependency: transitive
description: description:
@@ -65,6 +73,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.2.4" version: "1.2.4"
convert:
dependency: transitive
description:
name: convert
sha256: "0f08b14755d163f6e2134cb58222dd25ea2a2ee8a195e53983d57c075324d592"
url: "https://pub.dev"
source: hosted
version: "3.1.1"
cross_file: cross_file:
dependency: transitive dependency: transitive
description: description:
@@ -73,6 +89,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "0.3.3+7" version: "0.3.3+7"
crypto:
dependency: transitive
description:
name: crypto
sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab
url: "https://pub.dev"
source: hosted
version: "3.0.3"
cupertino_icons: cupertino_icons:
dependency: "direct main" dependency: "direct main"
description: description:
@@ -129,6 +153,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "7.0.0" version: "7.0.0"
file_picker:
dependency: "direct main"
description:
name: file_picker
sha256: d1d0ac3966b36dc3e66eeefb40280c17feb87fa2099c6e22e6a1fc959327bd03
url: "https://pub.dev"
source: hosted
version: "8.0.0+1"
file_selector_linux: file_selector_linux:
dependency: transitive dependency: transitive
description: description:
@@ -360,6 +392,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.1" version: "2.1.1"
lottie:
dependency: "direct main"
description:
name: lottie
sha256: a93542cc2d60a7057255405f62252533f8e8956e7e06754955669fd32fb4b216
url: "https://pub.dev"
source: hosted
version: "2.7.0"
matcher: matcher:
dependency: transitive dependency: transitive
description: description:
@@ -480,6 +520,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.8" version: "2.1.8"
pointycastle:
dependency: transitive
description:
name: pointycastle
sha256: "43ac87de6e10afabc85c445745a7b799e04de84cebaa4fd7bf55a5e1e9604d29"
url: "https://pub.dev"
source: hosted
version: "3.7.4"
shared_preferences: shared_preferences:
dependency: "direct main" dependency: "direct main"
description: description:

View File

@@ -26,6 +26,8 @@ dependencies:
image_picker: ^1.0.7 image_picker: ^1.0.7
dotted_border: ^2.1.0 dotted_border: ^2.1.0
image_cropper: ^4.0.1 image_cropper: ^4.0.1
file_picker: ^8.0.0+1
lottie: ^2.7.0
dev_dependencies: dev_dependencies:
flutter_test: flutter_test: