Commit ecd8fcd1 authored by Sai Srinivas's avatar Sai Srinivas
Browse files

07-07-2025 By Sai Srinivas

Pubspec and Safe Area.
parent 67ab0f3e
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
import 'package:generp/Notifiers/PCWalletProvider.dart';
......@@ -32,70 +34,72 @@ class _PcwalletState extends State<Pcwallet> {
final groupedData = provider.groupByDate(provider.historyList);
return WillPopScope(
onWillPop: () => onBackPressed(context),
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: AppBar(
automaticallyImplyLeading: false,
elevation: 2.0,
title: SizedBox(
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
InkResponse(
onTap: () => Navigator.pop(context, true),
child: SvgPicture.asset(
"assets/svg/app_bar_back.svg",
height: 25,
),
),
InkResponse(
onTap: () => Navigator.pop(context,true),
child: Text(
"P.C. Wallet",
style: TextStyle(
fontSize: 16,
height: 1.1,
fontFamily: "JakartaSemiBold",
color: AppColors.semi_black,
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: AppBar(
automaticallyImplyLeading: false,
elevation: 2.0,
title: SizedBox(
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
InkResponse(
onTap: () => Navigator.pop(context, true),
child: SvgPicture.asset(
"assets/svg/app_bar_back.svg",
height: 25,
),
),
),
Spacer(),
Container(
padding: EdgeInsets.symmetric(horizontal: 10),
height: 40,
decoration: BoxDecoration(
color: Color(0xFFF2FAFF),
borderRadius: BorderRadius.circular(16),
),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
SvgPicture.asset(
'assets/svg/pc_wallet.svg',
height: 30,
InkResponse(
onTap: () => Navigator.pop(context,true),
child: Text(
"P.C. Wallet",
style: TextStyle(
fontSize: 16,
height: 1.1,
fontFamily: "JakartaSemiBold",
color: AppColors.semi_black,
),
SizedBox(width: 5),
Text(
"${provider.totlDetails.balanceAmount??"0.00"}",
style: TextStyle(fontSize: 14),
),
],
),
),
),
],
Spacer(),
Container(
padding: EdgeInsets.symmetric(horizontal: 10),
height: 40,
decoration: BoxDecoration(
color: Color(0xFFF2FAFF),
borderRadius: BorderRadius.circular(16),
),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
SvgPicture.asset(
'assets/svg/pc_wallet.svg',
height: 30,
),
SizedBox(width: 5),
Text(
"${provider.totlDetails.balanceAmount??"0.00"}",
style: TextStyle(fontSize: 14),
),
],
),
),
],
),
),
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.vertical(
bottom: Radius.circular(30), // Adjust the radius as needed
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.vertical(
bottom: Radius.circular(30), // Adjust the radius as needed
),
),
),
),
backgroundColor: AppColors.scaffold_bg_color,
body: SafeArea(
child: Container(
backgroundColor: AppColors.scaffold_bg_color,
body: Container(
child: SingleChildScrollView(
child: Column(
children: [
......@@ -198,7 +202,7 @@ class _PcwalletState extends State<Pcwallet> {
itemBuilder: (context, index) {
String date = groupedData.keys.elementAt(index);
List<HistoryList> items = groupedData[date]!;
return Container(
padding: EdgeInsets.symmetric(vertical: 5),
margin: EdgeInsets.symmetric(horizontal: 10),
......@@ -219,12 +223,12 @@ class _PcwalletState extends State<Pcwallet> {
...items.map((item) {
String part1 =
item.description!.split(' (').first;
RegExp regExp = RegExp(r'\(([^)]+)\)');
String? part2 = regExp
.firstMatch(item.description!)
?.group(1);
return Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
......
import 'dart:io';
import 'package:dropdown_button2/dropdown_button2.dart';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
......@@ -66,12 +68,14 @@ class _PaymentdetailsState extends State<Paymentdetails> {
widget.genId,
);
},
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: appbar(context, "Payment Details"),
backgroundColor: AppColors.scaffold_bg_color,
body: SafeArea(
child: SingleChildScrollView(
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: appbar(context, "Payment Details"),
backgroundColor: AppColors.scaffold_bg_color,
body: SingleChildScrollView(
child: RefreshIndicator.adaptive(
color: AppColors.app_blue,
onRefresh: () async {
......@@ -425,54 +429,54 @@ class _PaymentdetailsState extends State<Paymentdetails> {
),
),
),
),
floatingActionButtonLocation:
FloatingActionButtonLocation.centerFloat,
floatingActionButton: InkWell(
onTap: () {
print("clicked");
if(provider.contactID==null){
toast(context, "Please Select Contact");
return;
}
if(provider.paymentModeID==null){
toast(context, "Please Select Payment Type");
return;
}
if(provider.image_picked==0){
toast(context, "Please add attachment");
return;
}
provider.PaymentUpdateAPI(
context,
provider.Referencecontroller.text,
provider.Amountcontroller.text,
);
if (provider.CollectionId != 0) {
showOTPSheetSheet(context);
}
},
child: Container(
alignment: Alignment.center,
height: 45,
margin: EdgeInsets.only(
left: 5.0,
right: 5.0,
top: 5.0,
bottom: 5.0,
),
decoration: BoxDecoration(
color: AppColors.app_blue, //1487C9
borderRadius: BorderRadius.circular(15.0),
),
child: Center(
child: Text(
"Send OTP",
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 15,
fontFamily: "JakartaMedium",
color: Colors.white,
floatingActionButtonLocation:
FloatingActionButtonLocation.centerFloat,
floatingActionButton: InkWell(
onTap: () {
print("clicked");
if(provider.contactID==null){
toast(context, "Please Select Contact");
return;
}
if(provider.paymentModeID==null){
toast(context, "Please Select Payment Type");
return;
}
if(provider.image_picked==0){
toast(context, "Please add attachment");
return;
}
provider.PaymentUpdateAPI(
context,
provider.Referencecontroller.text,
provider.Amountcontroller.text,
);
if (provider.CollectionId != 0) {
showOTPSheetSheet(context);
}
},
child: Container(
alignment: Alignment.center,
height: 45,
margin: EdgeInsets.only(
left: 5.0,
right: 5.0,
top: 5.0,
bottom: 5.0,
),
decoration: BoxDecoration(
color: AppColors.app_blue, //1487C9
borderRadius: BorderRadius.circular(15.0),
),
child: Center(
child: Text(
"Send OTP",
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 15,
fontFamily: "JakartaMedium",
color: Colors.white,
),
),
),
),
......
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
import 'package:generp/Notifiers/PendingComplaintsProvider.dart';
......@@ -36,232 +38,233 @@ class _PendingcomplaintsState extends State<Pendingcomplaints> {
builder: (context, provider, child) {
return WillPopScope(
onWillPop: () => onBackPressed(context),
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: appbar2(
context,
"Pending Complaints",
provider.resetAll,
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => Scancomplaintdetails(),
),
);
},
child: SvgPicture.asset("assets/svg/scanner.svg"),
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: appbar2(
context,
"Pending Complaints",
provider.resetAll,
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => Scancomplaintdetails(),
),
);
},
child: SvgPicture.asset("assets/svg/scanner.svg"),
),
),
),
body: SafeArea(
child:
provider.technician_complaint_list.isNotEmpty
? Container(
child: ListView.builder(
scrollDirection: Axis.vertical,
shrinkWrap: true,
itemCount: provider.technician_complaint_list.length,
body: provider.technician_complaint_list.isNotEmpty
? Container(
child: ListView.builder(
scrollDirection: Axis.vertical,
shrinkWrap: true,
itemCount: provider.technician_complaint_list.length,
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
itemBuilder: (context, index) {
return Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
itemBuilder: (context, index) {
return Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
margin: EdgeInsets.symmetric(vertical: 5),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(20),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
margin: EdgeInsets.symmetric(vertical: 5),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(20),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
crossAxisAlignment:
CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Row(
crossAxisAlignment:
CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Expanded(
flex: 1,
child: SvgPicture.asset(
"assets/svg/se_block_head.svg",
Expanded(
flex: 1,
child: SvgPicture.asset(
"assets/svg/se_block_head.svg",
),
),
SizedBox(width: 5),
Expanded(
flex: 4,
child: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text(
"${provider.technician_complaint_list[index].contactName}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
Text(
"${provider.technician_complaint_list[index].companyName}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: Color(0xFF818181),
fontSize: 14,
),
),
],
),
),
Spacer(),
Expanded(
flex: 1,
child: InkResponse(
onTap: () {
launch(
'tel://${provider.technician_complaint_list[index].mobileNo}',
);
},
child: SvgPicture.asset(
"assets/svg/se_call_customer.svg",
color: Color(0xFF0D9C00),
height: 20,
width: 20,
),
SizedBox(width: 5),
),
),
Expanded(
flex: 1,
child: InkResponse(
onTap: () {
_showOptionsSheet(
context,
provider
.technician_complaint_list[index]
.companyName,
Expanded(
flex: 4,
child: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text(
"${provider.technician_complaint_list[index].contactName}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
Text(
"${provider.technician_complaint_list[index].companyName}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: Color(0xFF818181),
fontSize: 14,
),
),
],
),
provider
.technician_complaint_list[index]
.genId,
provider
.technician_complaint_list[index]
.complaintId,
);
},
child: SvgPicture.asset(
"assets/svg/ic_more.svg",
height: 30,
),
Spacer(),
),
),
],
),
Divider(
thickness: 0.5,
color: Color(0xFFD7D7D7),
),
...List.generate(4, (j) {
final textheads = [
"Complaint ID",
"Product Name",
"Engine Number",
"Address",
];
final textSubheads = [
provider
.technician_complaint_list[index]
.complaintId,
provider
.technician_complaint_list[index]
.productName,
provider
.technician_complaint_list[index]
.engineNo,
provider
.technician_complaint_list[index]
.address,
];
return Container(
padding: EdgeInsets.symmetric(
vertical: 3,
),
child: Row(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Expanded(
flex: 1,
child: InkResponse(
onTap: () {
launch(
'tel://${provider.technician_complaint_list[index].mobileNo}',
);
},
child: SvgPicture.asset(
"assets/svg/se_call_customer.svg",
color: Color(0xFF0D9C00),
height: 20,
width: 20,
child: Text(
textheads[j].toString(),
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
),
Expanded(
flex: 1,
child: InkResponse(
onTap: () {
_showOptionsSheet(
context,
provider
.technician_complaint_list[index]
.companyName,
provider
.technician_complaint_list[index]
.genId,
provider
.technician_complaint_list[index]
.complaintId,
);
},
child: SvgPicture.asset(
"assets/svg/ic_more.svg",
height: 30,
flex: 2,
child: Text(
textSubheads[j].toString(),
style: TextStyle(
color: Color(0xFF818181),
),
),
),
],
),
Divider(
thickness: 0.5,
color: Color(0xFFD7D7D7),
),
...List.generate(4, (j) {
final textheads = [
"Complaint ID",
"Product Name",
"Engine Number",
"Address",
];
final textSubheads = [
provider
.technician_complaint_list[index]
.complaintId,
provider
.technician_complaint_list[index]
.productName,
provider
.technician_complaint_list[index]
.engineNo,
provider
.technician_complaint_list[index]
.address,
];
return Container(
padding: EdgeInsets.symmetric(
vertical: 3,
),
child: Row(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Expanded(
flex: 1,
child: Text(
textheads[j].toString(),
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
);
}),
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) => Visitdetails(
complaintID:
provider
.technician_complaint_list[index]
.complaintId,
),
Expanded(
flex: 2,
child: Text(
textSubheads[j].toString(),
style: TextStyle(
color: Color(0xFF818181),
),
),
),
],
),
);
},
child: Row(
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Text(
"View Details",
style: TextStyle(
color: AppColors.app_blue,
fontFamily: "JakartaMedium",
),
);
}),
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) => Visitdetails(
complaintID:
provider
.technician_complaint_list[index]
.complaintId,
),
),
);
},
child: Row(
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Text(
"View Details",
style: TextStyle(
color: AppColors.app_blue,
fontFamily: "JakartaMedium",
),
),
SizedBox(width: 5),
SvgPicture.asset(
"assets/svg/next_button.svg",
),
],
),
),
],
SizedBox(width: 5),
SvgPicture.asset(
"assets/svg/next_button.svg",
),
],
),
),
);
},
),
)
: Emptywidget(context),
],
),
);
},
),
)
: Emptywidget(context),
),
),
);
......
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
import 'package:generp/Utils/commonWidgets.dart';
......@@ -46,242 +48,245 @@ class _TodaymontlyvisistsState extends State<Todaymontlyvisists> {
builder: (context, provider, child) {
return WillPopScope(
onWillPop: () => onBackPressed(context),
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: appbar(context, provider.title),
body:SafeArea(child:
provider.visitsList.isNotEmpty
? Container(
child: ListView.builder(
scrollDirection: Axis.vertical,
shrinkWrap: true,
itemCount: provider.visitsList.length,
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: appbar(context, provider.title),
body:provider.visitsList.isNotEmpty
? Container(
child: ListView.builder(
scrollDirection: Axis.vertical,
shrinkWrap: true,
itemCount: provider.visitsList.length,
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
itemBuilder: (context, index) {
return Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
margin: EdgeInsets.symmetric(vertical: 5),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(20),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Expanded(
flex: 1,
child: Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
itemBuilder: (context, index) {
return Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
margin: EdgeInsets.symmetric(vertical: 5),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(20),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Expanded(
flex: 1,
child: Container(
padding: EdgeInsets.symmetric(
horizontal: 10,
vertical: 10,
),
decoration: BoxDecoration(
color: Color(0xFFE6F6FF),
borderRadius: BorderRadius.circular(
8,
),
),
child: SvgPicture.asset(
width: 30,
height: 30,
"assets/svg/se_block_head.svg",
),
),
decoration: BoxDecoration(
color: Color(0xFFE6F6FF),
borderRadius: BorderRadius.circular(
8,
),
SizedBox(width: 5),
Expanded(
flex: 4,
child: SizedBox(
child: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text(
"${provider.visitsList[index].contactName ?? "-"}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
Text(
"${provider.visitsList[index].companyName}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: Color(0xFF818181),
),
),
],
),
),
child: SvgPicture.asset(
width: 30,
height: 30,
"assets/svg/se_block_head.svg",
),
Spacer(),
Expanded(
flex: 1,
child: InkResponse(
onTap: () {
launch(
'tel://${provider.visitsList[index].mobileNo}',
);
},
child: SvgPicture.asset(
"assets/svg/se_call_customer.svg",
color: Color(0xFF0D9C00),
height: 20,
width: 20,
),
),
),
// Expanded(
// flex: 1,
// child: InkResponse(
// onTap: () {
// _showOptionsSheet(context);
// },
// child: Icon(Icons.more_vert),
// ),
// ),
],
),
Padding(
padding: const EdgeInsets.all(8.0),
child: Divider(
thickness: 0.5,
color: Color(0xFFD7D7D7),
),
SizedBox(width: 5),
Expanded(
flex: 4,
child: SizedBox(
child: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text(
"${provider.visitsList[index].contactName ?? "-"}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
),
...List.generate(3, (j) {
final textheads = [
"ID",
"Generator Type",
"Address",
];
final textSubheads = [
provider.visitsList[index].genId,
provider.visitsList[index].productName,
provider.visitsList[index].address,
];
return Container(
padding: EdgeInsets.symmetric(vertical: 3),
child: Row(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Expanded(
flex: 1,
child: Text(
textheads[j].toString(),
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
Text(
"${provider.visitsList[index].companyName}",
maxLines: 1,
overflow: TextOverflow.ellipsis,
),
Expanded(
flex: 2,
child: Text(
textSubheads[j].toString(),
style: TextStyle(
color: Color(0xFF818181),
),
),
],
),
),
),
Spacer(),
Expanded(
flex: 1,
child: InkResponse(
onTap: () {
launch(
'tel://${provider.visitsList[index].mobileNo}',
);
},
child: SvgPicture.asset(
"assets/svg/se_call_customer.svg",
color: Color(0xFF0D9C00),
height: 20,
width: 20,
),
),
],
),
),
// Expanded(
// flex: 1,
// child: InkResponse(
// onTap: () {
// _showOptionsSheet(context);
// },
// child: Icon(Icons.more_vert),
// ),
// ),
],
),
Padding(
padding: const EdgeInsets.all(8.0),
child: Divider(
thickness: 0.5,
color: Color(0xFFD7D7D7),
),
),
...List.generate(3, (j) {
final textheads = [
"ID",
"Generator Type",
"Address",
];
final textSubheads = [
provider.visitsList[index].genId,
provider.visitsList[index].productName,
provider.visitsList[index].address,
];
return Container(
padding: EdgeInsets.symmetric(vertical: 3),
);
}),
SizedBox(
child: Row(
crossAxisAlignment:
CrossAxisAlignment.start,
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
children: [
Expanded(
flex: 1,
child: Text(
textheads[j].toString(),
style: TextStyle(
fontFamily: "JakartaMedium",
),
),
),
Expanded(
flex: 2,
child: Text(
textSubheads[j].toString(),
style: TextStyle(
color: Color(0xFF818181),
),
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) => Paymentdetails(
accountName: "Generator",
name:
provider
.visitsList[index]
.companyName,
genId:
provider
.visitsList[index]
.genId,
referenceID:
provider
.visitsList[index]
.complaintId,
),
),
);
},
child: SvgPicture.asset(
"assets/svg/se_payment_details.svg",
),
),
],
),
);
}),
SizedBox(
child: Row(
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
children: [
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) => Paymentdetails(
accountName: "Generator",
name:
provider
.visitsList[index]
.companyName,
genId:
provider
.visitsList[index]
.genId,
referenceID:
provider
.visitsList[index]
.complaintId,
Spacer(),
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) => Visitdetails(
complaintID:
provider
.visitsList[index]
.complaintId,
),
),
),
);
},
child: SvgPicture.asset(
"assets/svg/se_payment_details.svg",
),
),
Spacer(),
InkResponse(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) => Visitdetails(
complaintID:
provider
.visitsList[index]
.complaintId,
);
},
child: Row(
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Text(
"View Details",
style: TextStyle(
fontFamily: "JakartaMedium",
color: AppColors.app_blue,
),
),
),
);
},
child: Row(
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Text(
"View Details",
style: TextStyle(
fontFamily: "JakartaMedium",
color: AppColors.app_blue,
SizedBox(width: 5),
SvgPicture.asset(
"assets/svg/next_button.svg",
),
),
SizedBox(width: 5),
SvgPicture.asset(
"assets/svg/next_button.svg",
),
],
],
),
),
),
],
],
),
),
),
],
),
);
},
),
)
: Emptywidget(context),)
],
),
);
},
),
)
: Emptywidget(context)
),
),
);
},
......
import 'dart:io';
import 'package:dropdown_button2/dropdown_button2.dart';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
......@@ -41,17 +43,19 @@ class _UpdatecomplaintsState extends State<Updatecomplaints> {
provider.resetAll();
return onBackPressed(context);
},
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: appbar2(
context,
"Update Complaint",
provider.resetAll,
SizedBox(width: 0),
),
backgroundColor: AppColors.scaffold_bg_color,
body: SafeArea(
child: Container(
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: appbar2(
context,
"Update Complaint",
provider.resetAll,
SizedBox(width: 0),
),
backgroundColor: AppColors.scaffold_bg_color,
body: Container(
padding: EdgeInsets.symmetric(horizontal: 10, vertical: 10),
decoration: BoxDecoration(
color: Colors.white,
......@@ -389,54 +393,54 @@ class _UpdatecomplaintsState extends State<Updatecomplaints> {
),
),
),
),
floatingActionButtonLocation:
FloatingActionButtonLocation.centerFloat,
floatingActionButton: InkResponse(
onTap:
provider.submitLoading
? null
: () {
provider.submitLoading = true;
provider.UpdateComplaintAPIFunction(
context,
widget.ComplaintID,
provider.feedbackController.text,
provider.fsrNumberController.text,
provider.runningHoursController.text,
provider.statusID,
);
},
child: Container(
alignment: Alignment.center,
height: 45,
margin: EdgeInsets.only(
left: 5.0,
right: 5.0,
top: 5.0,
bottom: 5.0,
),
decoration: BoxDecoration(
color: AppColors.app_blue, //1487C9
borderRadius: BorderRadius.circular(15.0),
),
child: Center(
child:
provider.submitLoading
? CircularProgressIndicator.adaptive(
valueColor: AlwaysStoppedAnimation<Color>(
AppColors.white,
),
)
: Text(
"Submit",
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 15,
fontFamily: "JakartaMedium",
color: Colors.white,
floatingActionButtonLocation:
FloatingActionButtonLocation.centerFloat,
floatingActionButton: InkResponse(
onTap:
provider.submitLoading
? null
: () {
provider.submitLoading = true;
provider.UpdateComplaintAPIFunction(
context,
widget.ComplaintID,
provider.feedbackController.text,
provider.fsrNumberController.text,
provider.runningHoursController.text,
provider.statusID,
);
},
child: Container(
alignment: Alignment.center,
height: 45,
margin: EdgeInsets.only(
left: 5.0,
right: 5.0,
top: 5.0,
bottom: 5.0,
),
decoration: BoxDecoration(
color: AppColors.app_blue, //1487C9
borderRadius: BorderRadius.circular(15.0),
),
child: Center(
child:
provider.submitLoading
? CircularProgressIndicator.adaptive(
valueColor: AlwaysStoppedAnimation<Color>(
AppColors.white,
),
)
: Text(
"Submit",
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 15,
fontFamily: "JakartaMedium",
color: Colors.white,
),
),
),
),
),
),
),
......
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
import 'package:generp/Notifiers/VisitDetailsProvider.dart';
......@@ -39,12 +41,14 @@ class _VisitdetailsState extends State<Visitdetails> {
var complaintDetails = provider.complaintDetailsNew;
return WillPopScope(
onWillPop: () => onBackPressed(context),
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: appbar(context, "Visit Details"),
backgroundColor: AppColors.scaffold_bg_color,
body: SafeArea(
child: SizedBox(
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
appBar: appbar(context, "Visit Details"),
backgroundColor: AppColors.scaffold_bg_color,
body: SizedBox(
child: SingleChildScrollView(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
......@@ -313,44 +317,44 @@ class _VisitdetailsState extends State<Visitdetails> {
),
),
),
),
floatingActionButton: Align(
alignment: Alignment.bottomCenter,
child: InkWell(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) =>
Followupdetails(complaintID: widget.complaintID),
floatingActionButton: Align(
alignment: Alignment.bottomCenter,
child: InkWell(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder:
(context) =>
Followupdetails(complaintID: widget.complaintID),
),
);
},
child: Container(
alignment: Alignment.bottomCenter,
height: 45,
width: MediaQuery.of(context).size.width,
margin: EdgeInsets.symmetric(horizontal: 10),
decoration: BoxDecoration(
color: AppColors.app_blue,
borderRadius: BorderRadius.circular(14.0),
),
);
},
child: Container(
alignment: Alignment.bottomCenter,
height: 45,
width: MediaQuery.of(context).size.width,
margin: EdgeInsets.symmetric(horizontal: 10),
decoration: BoxDecoration(
color: AppColors.app_blue,
borderRadius: BorderRadius.circular(14.0),
),
child: Center(
child: Text(
"Followup Details",
textAlign: TextAlign.center,
style: TextStyle(
color: Colors.white,
fontFamily: "JakartaMedium",
child: Center(
child: Text(
"Followup Details",
textAlign: TextAlign.center,
style: TextStyle(
color: Colors.white,
fontFamily: "JakartaMedium",
),
),
),
),
),
),
floatingActionButtonLocation:
FloatingActionButtonLocation.centerFloat,
),
floatingActionButtonLocation:
FloatingActionButtonLocation.centerFloat,
),
);
},
......
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:generp/screens/notifierExports.dart';
import 'package:generp/Utils/commonWidgets.dart';
......@@ -37,30 +39,32 @@ class _ScancomplaintdetailsState extends State<Scancomplaintdetails> {
builder: (context, provider, child) {
return WillPopScope(
onWillPop: () => onBackPressed(context),
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: appbar(context, "Pending Complaints"),
body: SafeArea(
child: Container(
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: appbar(context, "Pending Complaints"),
body: Container(
decoration: BoxDecoration(color: Colors.black),
child: Column(
children: [
Spacer(),
Container(
height: 250,
child: QRView(
key: provider.scannerKey,
onQRViewCreated: (p0) {
provider.onQRViewCreated(p0, "pendingComplaints", context);
},
formatsAllowed: [BarcodeFormat.qrcode],
cameraFacing: CameraFacing.back,
overlay: QrScannerOverlayShape(
borderColor: AppColors.app_blue,
borderRadius: 20,
borderLength: 60,
......
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
import 'package:generp/Notifiers/ServiceEngineerDashboardProvider.dart';
......@@ -32,70 +34,72 @@ class _ServiceengineerdashboardState extends State<Serviceengineerdashboard> {
builder: (context, provider, child) {
return WillPopScope(
onWillPop: () => onBackPressed(context),
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: AppBar(
automaticallyImplyLeading: false,
elevation: 2.0,
title: SizedBox(
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
InkResponse(
onTap: () => Navigator.pop(context, true),
child: SvgPicture.asset(
"assets/svg/app_bar_back.svg",
height: 25,
),
),
InkResponse(
onTap: () => Navigator.pop(context,true),
child: Text(
"Service Engineer",
style: TextStyle(
fontSize: 16,
height: 1.1,
fontFamily: "JakartaSemiBold",
color: AppColors.semi_black,
child: SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
backgroundColor: AppColors.scaffold_bg_color,
appBar: AppBar(
automaticallyImplyLeading: false,
elevation: 2.0,
title: SizedBox(
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
InkResponse(
onTap: () => Navigator.pop(context, true),
child: SvgPicture.asset(
"assets/svg/app_bar_back.svg",
height: 25,
),
),
),
Spacer(),
Container(
height: 25,
width: 45,
decoration: BoxDecoration(
color: Color(0xFFFFF6E2),
borderRadius: BorderRadius.circular(20),
),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
SvgPicture.asset(
'assets/svg/engineer_rating.svg',
height: 15,
),
SizedBox(width: 5),
Text(
provider.avgRating.toString(),
style: TextStyle(fontSize: 14),
InkResponse(
onTap: () => Navigator.pop(context,true),
child: Text(
"Service Engineer",
style: TextStyle(
fontSize: 16,
height: 1.1,
fontFamily: "JakartaSemiBold",
color: AppColors.semi_black,
),
],
),
),
),
],
Spacer(),
Container(
height: 25,
width: 45,
decoration: BoxDecoration(
color: Color(0xFFFFF6E2),
borderRadius: BorderRadius.circular(20),
),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
SvgPicture.asset(
'assets/svg/engineer_rating.svg',
height: 15,
),
SizedBox(width: 5),
Text(
provider.avgRating.toString(),
style: TextStyle(fontSize: 14),
),
],
),
),
],
),
),
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.vertical(
bottom: Radius.circular(30), // Adjust the radius as needed
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.vertical(
bottom: Radius.circular(30), // Adjust the radius as needed
),
),
),
),
body: SafeArea(
child: Container(
body: Container(
child: SingleChildScrollView(
child: Column(
children: [
......@@ -175,7 +179,7 @@ class _ServiceengineerdashboardState extends State<Serviceengineerdashboard> {
color: Colors.white,
borderRadius: BorderRadius.circular(16),
),
child: GridView.builder(
padding: EdgeInsets.symmetric(
vertical: 15,
......@@ -232,7 +236,7 @@ class _ServiceengineerdashboardState extends State<Serviceengineerdashboard> {
route = Todaymontlyvisists(visitType: "Today");
break;
}
Navigator.push(
context,
MaterialPageRoute(builder: (context) => route),
......@@ -253,7 +257,7 @@ class _ServiceengineerdashboardState extends State<Serviceengineerdashboard> {
mainAxisAlignment: MainAxisAlignment.center,
children: [
Row(
children: [
if([0,1].contains(index))...[
Text("₹",style: TextStyle(
......@@ -294,7 +298,7 @@ class _ServiceengineerdashboardState extends State<Serviceengineerdashboard> {
color: Colors.white,
borderRadius: BorderRadius.circular(20),
),
child: Row(
children: [
Expanded(
......
......@@ -139,10 +139,12 @@ class _SplashState extends State<Splash> {
@override
Widget build(BuildContext context) {
return Scaffold(
resizeToAvoidBottomInset: true,
body: SafeArea(
child: Consumer<SplashVersionNotifier>(
return SafeArea(
top: false,
bottom: Platform.isIOS?false:true,
child: Scaffold(
resizeToAvoidBottomInset: true,
body: Consumer<SplashVersionNotifier>(
builder: (context, value, child) {
return Container(
alignment: Alignment.center,
......
......@@ -1730,6 +1730,7 @@ print("send otp:${data}");
'approved_amount': approved_amount,
'proposed_payment_account_id': proposed_payment_account_id,
};
// print(data);
final res = await post(data, approveRejectPaymentRequestSubmitUrl, {});
if (res != null) {
print(data);
......
......@@ -37,10 +37,10 @@ packages:
dependency: transitive
description:
name: async
sha256: "758e6d74e971c3e5aceb4110bfd6698efc7f501675bcfe0c775459a8140750eb"
sha256: d2872f9c19731c2e5f10444b14686eb7cc85c76274bd6c16e1816bff9a3bab63
url: "https://pub.dev"
source: hosted
version: "2.13.0"
version: "2.12.0"
auto_size_text:
dependency: "direct main"
description:
......@@ -293,10 +293,10 @@ packages:
dependency: transitive
description:
name: fake_async
sha256: "5368f224a74523e8d2e7399ea1638b37aecfca824a3cc4dfdf77bf1fa905ac44"
sha256: "6a95e56b2449df2273fd8c45a662d6947ce1ebb7aafe80e550a3f68297f3cacc"
url: "https://pub.dev"
source: hosted
version: "1.3.3"
version: "1.3.2"
ffi:
dependency: transitive
description:
......@@ -940,26 +940,26 @@ packages:
dependency: transitive
description:
name: leak_tracker
sha256: "8dcda04c3fc16c14f48a7bb586d4be1f0d1572731b6d81d51772ef47c02081e0"
sha256: c35baad643ba394b40aac41080300150a4f08fd0fd6a10378f8f7c6bc161acec
url: "https://pub.dev"
source: hosted
version: "11.0.1"
version: "10.0.8"
leak_tracker_flutter_testing:
dependency: transitive
description:
name: leak_tracker_flutter_testing
sha256: "1dbc140bb5a23c75ea9c4811222756104fbcd1a27173f0c34ca01e16bea473c1"
sha256: f8b613e7e6a13ec79cfdc0e97638fddb3ab848452eff057653abd3edba760573
url: "https://pub.dev"
source: hosted
version: "3.0.10"
version: "3.0.9"
leak_tracker_testing:
dependency: transitive
description:
name: leak_tracker_testing
sha256: "8d5a2d49f4a66b49744b23b018848400d23e54caf9463f4eb20df3eb8acb2eb1"
sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3"
url: "https://pub.dev"
source: hosted
version: "3.0.2"
version: "3.0.1"
lints:
dependency: transitive
description:
......@@ -1665,10 +1665,10 @@ packages:
dependency: transitive
description:
name: vm_service
sha256: ddfa8d30d89985b96407efce8acbdd124701f96741f2d981ca860662f1c0dc02
sha256: "0968250880a6c5fe7edc067ed0a13d4bae1577fe2771dcf3010d52c4a9d3ca14"
url: "https://pub.dev"
source: hosted
version: "15.0.0"
version: "14.3.1"
web:
dependency: transitive
description:
......
......@@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 1.0.91+95
version: 1.0.92+96
environment:
sdk: ^3.7.2
......@@ -124,18 +124,6 @@ flutter:
# "family" key with the font family name, and a "fonts" key with a
# list giving the asset and other descriptors for the font. For
# example:
# fonts:
# - family: Schyler
# fonts:
# - asset: fonts/Schyler-Regular.ttf
# - asset: fonts/Schyler-Italic.ttf
# style: italic
# - family: Trajan Pro
# fonts:
# - asset: fonts/TrajanPro.ttf
# - asset: fonts/TrajanPro_Bold.ttf
# weight: 700
#
fonts:
- family: Nexa
fonts:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment