Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sai Srinivas
GEN_ERP_2025
Commits
55280429
Commit
55280429
authored
Aug 20, 2025
by
Sai Srinivas
Browse files
20-08-2025 By Sai Srinivas
Test Cases CRM
parent
6ace5c45
Changes
31
Show whitespace changes
Inline
Side-by-side
lib/screens/crm/generateQuotationScreen.dart
View file @
55280429
...
...
@@ -26,6 +26,7 @@ class Generatequotationscreen extends StatefulWidget {
class
_GeneratequotationscreenState
extends
State
<
Generatequotationscreen
>
{
Dropdowntheme
ddtheme
=
Dropdowntheme
();
List
<
FocusNode
>
focusNodes
=
List
.
generate
(
12
,
(
index
)
=>
FocusNode
());
@override
void
initState
()
{
...
...
@@ -45,6 +46,13 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
});
}
@override
void
dispose
()
{
focusNodes
.
map
((
e
)
=>
e
.
dispose
());
super
.
dispose
();
}
@override
Widget
build
(
BuildContext
context
)
{
return
Consumer
<
Crmgeneratequotationprovider
>(
...
...
@@ -95,6 +103,10 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
TextInputType
.
emailAddress
,
false
,
null
,
focusNodes
[
0
],
focusNodes
[
1
],
TextInputAction
.
done
,
null
,
),
errorWidget
(
context
,
provider
.
mailIdError
),
...
...
@@ -107,6 +119,10 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
TextInputType
.
phone
,
false
,
FilteringTextInputFormatter
.
digitsOnly
,
focusNodes
[
1
],
focusNodes
[
2
],
TextInputAction
.
done
,
null
,
),
errorWidget
(
context
,
provider
.
mobileError
),
...
...
@@ -119,6 +135,10 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
TextInputType
.
text
,
false
,
null
,
focusNodes
[
2
],
focusNodes
[
3
],
TextInputAction
.
done
,
null
,
),
errorWidget
(
context
,
provider
.
subjectsError
),
],
...
...
@@ -623,6 +643,10 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
TextInputType
.
text
,
false
,
null
,
focusNodes
[
3
],
focusNodes
[
4
],
TextInputAction
.
done
,
null
,
),
errorWidget
(
context
,
provider
.
SpecialNoteError
),
...
...
@@ -635,6 +659,10 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
TextInputType
.
text
,
false
,
null
,
focusNodes
[
4
],
focusNodes
[
5
],
TextInputAction
.
done
,
null
,
),
errorWidget
(
context
,
provider
.
forError
),
...
...
@@ -647,6 +675,10 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
TextInputType
.
text
,
false
,
null
,
focusNodes
[
5
],
focusNodes
[
6
],
TextInputAction
.
done
,
null
,
),
errorWidget
(
context
,
provider
.
paymentTermsError
),
],
...
...
@@ -675,22 +707,29 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
),
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
provider
.
buttonsLoading
?[
SizedBox
(
width:
25
),
children:
provider
.
buttonsLoading
?
[
SizedBox
(
width:
25
),
CircularProgressIndicator
.
adaptive
(
valueColor:
AlwaysStoppedAnimation
(
AppColors
.
app_blue
),
valueColor:
AlwaysStoppedAnimation
(
AppColors
.
app_blue
,
),
SizedBox
(
width:
25
),
]:
[
),
SizedBox
(
width:
25
),
]
:
[
Expanded
(
child:
InkResponse
(
onTap:
provider
.
buttonsLoading
?
null
:
()
{
HapticFeedback
.
mediumImpact
();
provider
.
buttonsLoading
=
true
;
//genquotedown
final
insertedData
=
provider
.
productRows
;
final
insertedData
=
provider
.
productRows
;
print
(
insertedData
);
provider
.
crmLeadDetailsGenerateQuoteSubmitAPIFunction
(
...
...
@@ -711,22 +750,25 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
child:
provider
.
submitLoading
?
CircularProgressIndicator
.
adaptive
(
valueColor:
AlwaysStoppedAnimation
<
Color
>(
valueColor:
AlwaysStoppedAnimation
<
Color
>(
AppColors
.
app_blue
,
),
)
:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
SvgPicture
.
asset
(
"assets/svg/crm/download_quote_ic.svg"
,
),
SizedBox
(
width:
10
,
),
SizedBox
(
width:
10
),
Text
(
"Download"
,
style:
TextStyle
(
fontSize:
14
,
fontFamily:
"JakartaRegular"
,
fontFamily:
"JakartaRegular"
,
),
),
],
...
...
@@ -734,16 +776,21 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
),
),
),
SvgPicture
.
asset
(
"assets/svg/crm/vertical_line_ic.svg"
),
SvgPicture
.
asset
(
"assets/svg/crm/vertical_line_ic.svg"
,
),
Expanded
(
child:
InkResponse
(
onTap:
provider
.
buttonsLoading
?
null
:
()
{
HapticFeedback
.
mediumImpact
();
provider
.
buttonsLoading
=
true
;
//genquotemail,
final
insertedData
=
provider
.
getFormData
();
final
insertedData
=
provider
.
productRows
;
print
(
insertedData
);
provider
.
crmLeadDetailsGenerateQuoteSubmitAPIFunction
(
context
,
...
...
@@ -763,22 +810,25 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
child:
provider
.
submitLoading
?
CircularProgressIndicator
.
adaptive
(
valueColor:
AlwaysStoppedAnimation
<
Color
>(
valueColor:
AlwaysStoppedAnimation
<
Color
>(
AppColors
.
app_blue
,
),
)
:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
SvgPicture
.
asset
(
"assets/svg/crm/email_quote_ic.svg"
,
),
SizedBox
(
width:
10
,
),
SizedBox
(
width:
10
),
Text
(
"Email"
,
style:
TextStyle
(
fontSize:
14
,
fontFamily:
"JakartaRegular"
,
fontFamily:
"JakartaRegular"
,
),
),
],
...
...
@@ -786,16 +836,21 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
),
),
),
SvgPicture
.
asset
(
"assets/svg/crm/vertical_line_ic.svg"
),
SvgPicture
.
asset
(
"assets/svg/crm/vertical_line_ic.svg"
,
),
Expanded
(
child:
InkResponse
(
onTap:
provider
.
buttonsLoading
?
null
:
()
{
HapticFeedback
.
mediumImpact
();
provider
.
buttonsLoading
=
true
;
//genquotewhatsapp,
final
insertedData
=
provider
.
getFormData
();
final
insertedData
=
provider
.
productRows
;
print
(
insertedData
);
provider
.
crmLeadDetailsGenerateQuoteSubmitAPIFunction
(
context
,
...
...
@@ -815,22 +870,25 @@ class _GeneratequotationscreenState extends State<Generatequotationscreen> {
child:
provider
.
submitLoading
?
CircularProgressIndicator
.
adaptive
(
valueColor:
AlwaysStoppedAnimation
<
Color
>(
valueColor:
AlwaysStoppedAnimation
<
Color
>(
AppColors
.
app_blue
,
),
)
:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
SvgPicture
.
asset
(
"assets/svg/crm/whatsapp_quote_ic.svg"
,
),
SizedBox
(
width:
10
,
),
SizedBox
(
width:
10
),
Text
(
"Whatsapp"
,
style:
TextStyle
(
fontSize:
14
,
fontFamily:
"JakartaRegular"
,
fontFamily:
"JakartaRegular"
,
),
),
],
...
...
lib/screens/crm/pendingTasksDetails.dart
View file @
55280429
...
...
@@ -3,6 +3,7 @@ import 'dart:io';
import
'package:connectivity_plus/connectivity_plus.dart'
;
import
'package:dotted_line/dotted_line.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_svg/svg.dart'
;
import
'package:generp/Notifiers/crmProvider/crmDashboardProvider.dart'
;
import
'package:generp/Utils/app_colors.dart'
;
...
...
@@ -96,7 +97,10 @@ class _PendingtasksdetailsState extends State<Pendingtasksdetails> {
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
InkResponse
(
onTap:
()
=>
Navigator
.
pop
(
context
,
true
),
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
pop
(
context
,
true
);
},
child:
SvgPicture
.
asset
(
"assets/svg/appbar_back_button.svg"
,
height:
25
,
...
...
@@ -104,7 +108,10 @@ class _PendingtasksdetailsState extends State<Pendingtasksdetails> {
),
SizedBox
(
width:
10
),
InkResponse
(
onTap:
()
=>
Navigator
.
pop
(
context
,
true
),
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
pop
(
context
,
true
);
},
child:
Text
(
"Pending Tasks"
,
style:
TextStyle
(
...
...
@@ -236,6 +243,7 @@ class _PendingtasksdetailsState extends State<Pendingtasksdetails> {
Expanded
(
child:
InkResponse
(
onTap:
belowHeads
[
i
]==
"Mobile Number"
?(){
HapticFeedback
.
selectionClick
();
launch
(
'tel://
${belowSubHeads[i]}
'
,
);
...
...
@@ -278,6 +286,7 @@ class _PendingtasksdetailsState extends State<Pendingtasksdetails> {
FloatingActionButtonLocation
.
centerFloat
,
floatingActionButton:
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
await
Navigator
.
push
(
context
,
MaterialPageRoute
(
builder:
(
context
)
=>
Followupupdatescreen
(
...
...
lib/screens/crm/pendingTasksList.dart
View file @
55280429
...
...
@@ -3,6 +3,7 @@ import 'dart:io';
import
'package:connectivity_plus/connectivity_plus.dart'
;
import
'package:dotted_line/dotted_line.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_svg/flutter_svg.dart'
;
import
'package:generp/Notifiers/crmProvider/crmDashboardProvider.dart'
;
import
'package:generp/Utils/app_colors.dart'
;
...
...
@@ -140,6 +141,7 @@ class _PendingTasksListState extends State<PendingTasksList> {
];
return
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
await
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -236,7 +238,8 @@ class _PendingTasksListState extends State<PendingTasksList> {
child:
Text
(
"
${provider.pendingTasksLists[index].anote}
"
,
textAlign:
TextAlign
.
right
,
maxLines:
1
,
maxLines:
2
,
overflow:
TextOverflow
.
ellipsis
,
style:
TextStyle
(
color:
AppColors
.
semi_black
,
fontFamily:
"JakartaRegular"
,
...
...
lib/screens/crm/universalSearchScreen.dart
View file @
55280429
import
'dart:io'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_svg/svg.dart'
;
import
'package:generp/screens/crm/ProspectDetailsByMode.dart'
;
import
'package:provider/provider.dart'
;
...
...
@@ -73,7 +74,10 @@ class _UniversalsearchscreenState extends State<Universalsearchscreen> {
Expanded
(
flex:
1
,
child:
InkResponse
(
onTap:
()
=>
Navigator
.
pop
(
context
,
true
),
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
pop
(
context
,
true
);
},
child:
Container
(
child:
SvgPicture
.
asset
(
"assets/svg/appbar_back_button.svg"
,
height:
25
)),
...
...
@@ -127,6 +131,7 @@ class _UniversalsearchscreenState extends State<Universalsearchscreen> {
child:
provider
.
searchController
.
text
.
isNotEmpty
?
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
provider
.
searchController
.
clear
();
provider
.
crmUniversalSearchFunction
(
context
,
...
...
@@ -260,6 +265,7 @@ class _UniversalsearchscreenState extends State<Universalsearchscreen> {
}
return
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
pushAndRemoveUntil
(
context
,
MaterialPageRoute
(
...
...
@@ -395,6 +401,7 @@ class _UniversalsearchscreenState extends State<Universalsearchscreen> {
}
return
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
pushAndRemoveUntil
(
context
,
MaterialPageRoute
(
...
...
lib/screens/finance/AllPaymentRequesitionListsByModes.dart
View file @
55280429
...
...
@@ -92,7 +92,7 @@ class _AllpaymentrequesitionlistsbymodesState
Color
getDecorationColor
(
value
)
{
var
color
=
AppColors
.
approved_bg_color
;
switch
(
value
){
switch
(
value
)
{
case
'Requested'
:
return
AppColors
.
requested_bg_color
;
case
'Level 1 Approved'
:
...
...
@@ -107,14 +107,13 @@ class _AllpaymentrequesitionlistsbymodesState
return
AppColors
.
processed_bg_color
;
case
'Payment Rejected'
:
return
AppColors
.
rejected_bg_color
;
}
return
color
;
}
Color
getTextColor
(
value
)
{
var
color
=
AppColors
.
approved_text_color
;
switch
(
value
){
switch
(
value
)
{
case
'Requested'
:
return
AppColors
.
requested_text_color
;
case
'Level 1 Approved'
:
...
...
@@ -129,14 +128,13 @@ class _AllpaymentrequesitionlistsbymodesState
return
AppColors
.
processed_text_color
;
case
'Payment Rejected'
:
return
AppColors
.
rejected_text_color
;
}
return
color
;
}
getText
(
value
){
getText
(
value
)
{
var
text
=
"A"
;
switch
(
value
){
switch
(
value
)
{
case
'Requested'
:
return
"R"
;
case
'Level 1 Approved'
:
...
...
@@ -151,14 +149,13 @@ class _AllpaymentrequesitionlistsbymodesState
return
"P"
;
case
'Payment Rejected'
:
return
"R"
;
}
return
text
;
}
double
getSize
(
value
){
double
getSize
(
value
)
{
var
text
=
"A"
;
switch
(
value
){
switch
(
value
)
{
case
'Requested'
:
return
16.0
;
case
'Level 1 Approved'
:
...
...
@@ -173,7 +170,6 @@ class _AllpaymentrequesitionlistsbymodesState
return
16.0
;
case
'Payment Rejected'
:
return
16.0
;
}
return
18.0
;
}
...
...
@@ -214,7 +210,7 @@ class _AllpaymentrequesitionlistsbymodesState
:
NoNetwork
(
context
);
}
bool
shouldShowSwipeButtons
(
status
){
bool
shouldShowSwipeButtons
(
status
)
{
isLevel1Finalized
=
[
"Level 1 Approved"
,
"Level 1 Rejected"
,
...
...
@@ -265,8 +261,8 @@ class _AllpaymentrequesitionlistsbymodesState
// "Level 2 rejected",
// ].contains(req_det.status);
return
Consumer2
<
Requestionlistprovider
,
Requesitionlidtdetailsprovider
>(
builder:
(
context
,
provider
,
detailsProvider
,
child
)
{
return
Consumer2
<
Requestionlistprovider
,
Requesitionlidtdetailsprovider
>(
builder:
(
context
,
provider
,
detailsProvider
,
child
)
{
final
requestLists
=
provider
.
requisitionList
;
return
Scaffold
(
resizeToAvoidBottomInset:
true
,
...
...
@@ -284,6 +280,7 @@ class _AllpaymentrequesitionlistsbymodesState
// ),
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
cf
=
Commondaterangefilter
();
var
result
=
await
cf
.
showFilterBottomSheet
(
context
);
if
(
result
!=
null
)
{
...
...
@@ -320,7 +317,7 @@ class _AllpaymentrequesitionlistsbymodesState
),
],
),
0xFFFFFFFF
0xFFFFFFFF
,
),
backgroundColor:
AppColors
.
scaffold_bg_color
,
body:
...
...
@@ -349,6 +346,7 @@ class _AllpaymentrequesitionlistsbymodesState
}
return
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
res
=
await
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -376,7 +374,6 @@ class _AllpaymentrequesitionlistsbymodesState
}
},
child:
Container
(
margin:
EdgeInsets
.
symmetric
(
horizontal:
10
,
vertical:
5
,
...
...
@@ -388,35 +385,45 @@ class _AllpaymentrequesitionlistsbymodesState
child:
ClipRRect
(
borderRadius:
BorderRadius
.
circular
(
20
),
child:
Slidable
(
startActionPane:
shouldShowButtons
?
ActionPane
(
startActionPane:
shouldShowButtons
?
ActionPane
(
motion:
const
ScrollMotion
(),
dragDismissible:
false
,
// dismissible: DismissiblePane(onDismissed: () {}),
// dismissible: DismissiblePane(onDismissed: () {}),
children:
[
if
(
shouldShowButtons
&&
![
"admin"
,
"self"
].
contains
(
widget
.
mode
))...[
if
(
shouldShowButtons
&&
![
"admin"
,
"self"
,
].
contains
(
widget
.
mode
))
...[
SlidableAction
(
onPressed:
(
context
)
{
_showLevelRejectionSheet
(
context
,
requestLists
[
index
].
id
,
);
},
backgroundColor:
Color
(
0xFFFFE5E5
),
foregroundColor:
Color
(
0xFFEF3739
),
backgroundColor:
Color
(
0xFFFFE5E5
,
),
foregroundColor:
Color
(
0xFFEF3739
,
),
icon:
Icons
.
clear
,
label:
'Reject'
,
),
],
if
(
widget
.
mode
==
"process"
)...[
if
(
widget
.
mode
==
"process"
)
...[
SlidableAction
(
onPressed:
(
context
)
{
detailsProvider
.
approveRejectPaymentRequestAPIFunction
(
context
,
requestLists
[
index
].
id
,
requestLists
[
index
]
.
id
,
);
detailsProvider
.
preValues
();
_showAddPaymentSheet
(
...
...
@@ -424,55 +431,72 @@ class _AllpaymentrequesitionlistsbymodesState
requestLists
[
index
].
id
,
);
},
backgroundColor:
Color
(
0xFFFFF8E5
),
foregroundColor:
Color
(
0xFFFFB600
),
backgroundColor:
Color
(
0xFFFFF8E5
,
),
foregroundColor:
Color
(
0xFFFFB600
,
),
icon:
Icons
.
add
,
label:
'Add Payment'
,
),
],
],
):
null
,
endActionPane:
shouldShowButtons
?
ActionPane
(
)
:
null
,
endActionPane:
shouldShowButtons
?
ActionPane
(
motion:
const
ScrollMotion
(),
key:
ValueKey
(
requestLists
[
index
].
id
),
key:
ValueKey
(
requestLists
[
index
].
id
,
),
dragDismissible:
false
,
// dismissible: DismissiblePane(
//
// onDismissed: () {},
// closeOnCancel: true,
// resizeDuration: Duration(milliseconds: 300),),
children:
[
if
([
"apr_lvl1"
,
"apr_lvl2"
,
"self_apr_lvl2"
,
].
contains
(
widget
.
mode
))...[
].
contains
(
widget
.
mode
))
...[
SlidableAction
(
onPressed:
(
context
)
{
detailsProvider
.
paymentRequesitionDetails
(
context
,
requestLists
[
index
].
id
);
detailsProvider
.
paymentRequesitionDetails
(
context
,
requestLists
[
index
]
.
id
,
);
detailsProvider
.
preValues
();
detailsProvider
.
approveRejectPaymentRequestAPIFunction
(
context
,
requestLists
[
index
].
id
,
requestLists
[
index
]
.
id
,
);
_showLevelApprovalSheet
(
context
,
requestLists
[
index
].
id
,
);
},
backgroundColor:
Color
(
0xFFE9FFE8
),
foregroundColor:
Color
(
0xFF4CB443
),
backgroundColor:
Color
(
0xFFE9FFE8
,
),
foregroundColor:
Color
(
0xFF4CB443
,
),
icon:
Icons
.
check
,
label:
'Approve'
,
),
],
],
):
null
,
)
:
null
,
child:
Container
(
padding:
EdgeInsets
.
symmetric
(
...
...
@@ -490,16 +514,27 @@ class _AllpaymentrequesitionlistsbymodesState
width:
50
,
padding:
EdgeInsets
.
all
(
8.0
),
decoration:
BoxDecoration
(
color:
getDecorationColor
(
requestLists
[
index
].
status
),
shape:
BoxShape
.
circle
color:
getDecorationColor
(
requestLists
[
index
].
status
,
),
shape:
BoxShape
.
circle
,
),
child:
Center
(
child:
Text
(
getText
(
requestLists
[
index
].
status
),
getText
(
requestLists
[
index
]
.
status
,
),
style:
TextStyle
(
color:
getTextColor
(
requestLists
[
index
].
status
),
fontSize:
getSize
(
requestLists
[
index
].
status
),
fontFamily:
"JakartaBold"
color:
getTextColor
(
requestLists
[
index
]
.
status
,
),
fontSize:
getSize
(
requestLists
[
index
]
.
status
,
),
fontFamily:
"JakartaBold"
,
),
),
),
...
...
@@ -517,19 +552,25 @@ class _AllpaymentrequesitionlistsbymodesState
requestLists
[
index
]
.
accountName
!,
maxLines:
1
,
overflow:
TextOverflow
.
ellipsis
,
overflow:
TextOverflow
.
ellipsis
,
style:
TextStyle
(
fontFamily:
"JakartaRegular"
,
fontFamily:
"JakartaRegular"
,
fontSize:
14
,
color:
AppColors
.
semi_black
,
color:
AppColors
.
semi_black
,
),
),
Text
(
"
${requestLists[index].date}
"
,
style:
TextStyle
(
fontFamily:
"JakartaRegular"
,
fontFamily:
"JakartaRegular"
,
fontSize:
14
,
color:
AppColors
.
app_blue
,
color:
AppColors
.
app_blue
,
),
),
],
...
...
@@ -616,6 +657,7 @@ class _AllpaymentrequesitionlistsbymodesState
];
return
ListTile
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
switch
(
index
)
{
case
0
:
provider
.
copyToClipboard
(
context
);
...
...
@@ -742,7 +784,7 @@ class _AllpaymentrequesitionlistsbymodesState
focusNodes
[
1
],
TextInputAction
.
next
,
),
if
(
provider
.
ApprovedAmountError
!=
null
)...[
if
(
provider
.
ApprovedAmountError
!=
null
)
...[
errorWidget
(
context
,
provider
.
ApprovedAmountError
),
],
textControllerWidget
(
...
...
@@ -865,6 +907,7 @@ class _AllpaymentrequesitionlistsbymodesState
),
InkWell
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
provider
.
paymentrequisitionApproveSubmitAPIFunction
(
context
,
...
...
@@ -916,13 +959,22 @@ class _AllpaymentrequesitionlistsbymodesState
context
,
listen:
false
,
);
final
detailsprov
=
Provider
.
of
<
Requesitionlidtdetailsprovider
>(
context
,
listen:
false
);
final
detailsprov
=
Provider
.
of
<
Requesitionlidtdetailsprovider
>(
context
,
listen:
false
,
);
detailsprov
.
resetAll
();
provider
.
paymentRequestionListsAPIFunction
(
context
,
widget
.
mode
,
""
,
""
);
provider
.
paymentRequestionListsAPIFunction
(
context
,
widget
.
mode
,
""
,
""
,
);
});
});
},);
}
Future
<
void
>
_showLevelRejectionSheet
(
BuildContext
context
,
paymentID
)
{
return
showModalBottomSheet
(
useSafeArea:
true
,
...
...
@@ -999,6 +1051,7 @@ class _AllpaymentrequesitionlistsbymodesState
errorWidget
(
context
,
provider
.
remarksError
),
InkWell
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
provider
.
paymentrequisitionRejectSubmitAPIFunction
(
context
,
...
...
@@ -1044,18 +1097,26 @@ class _AllpaymentrequesitionlistsbymodesState
).
whenComplete
(()
{
print
(
"closing Sheet"
);
WidgetsBinding
.
instance
.
addPostFrameCallback
((
timeStamp
)
{
var
provider
=
Provider
.
of
<
Requestionlistprovider
>(
context
,
listen:
false
,
);
final
detailsprov
=
Provider
.
of
<
Requesitionlidtdetailsprovider
>(
context
,
listen:
false
);
final
detailsprov
=
Provider
.
of
<
Requesitionlidtdetailsprovider
>(
context
,
listen:
false
,
);
detailsprov
.
resetAll
();
provider
.
paymentRequestionListsAPIFunction
(
context
,
widget
.
mode
,
""
,
""
);
provider
.
paymentRequestionListsAPIFunction
(
context
,
widget
.
mode
,
""
,
""
,
);
});
});
},);
}
Future
<
void
>
_showAddPaymentSheet
(
BuildContext
context
,
paymentID
)
{
return
showModalBottomSheet
(
useSafeArea:
true
,
...
...
@@ -1333,6 +1394,7 @@ class _AllpaymentrequesitionlistsbymodesState
),
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
_showAttachmentSheet
(
context
);
},
child:
Container
(
...
...
@@ -1390,6 +1452,7 @@ class _AllpaymentrequesitionlistsbymodesState
),
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
setState
(()
{
provider
.
imagePicked
=
0
;
...
...
@@ -1501,6 +1564,7 @@ class _AllpaymentrequesitionlistsbymodesState
),
child:
InkWell
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
provider
.
paymentrequisitionProcessSubmitAPIFunction
(
context
,
...
...
@@ -1541,18 +1605,26 @@ class _AllpaymentrequesitionlistsbymodesState
).
whenComplete
(()
{
print
(
"closing Sheet"
);
WidgetsBinding
.
instance
.
addPostFrameCallback
((
timeStamp
)
{
var
provider
=
Provider
.
of
<
Requestionlistprovider
>(
context
,
listen:
false
,
);
final
detailsprov
=
Provider
.
of
<
Requesitionlidtdetailsprovider
>(
context
,
listen:
false
);
final
detailsprov
=
Provider
.
of
<
Requesitionlidtdetailsprovider
>(
context
,
listen:
false
,
);
detailsprov
.
resetAll
();
provider
.
paymentRequestionListsAPIFunction
(
context
,
widget
.
mode
,
""
,
""
);
provider
.
paymentRequestionListsAPIFunction
(
context
,
widget
.
mode
,
""
,
""
,
);
});
});
},);
}
Future
<
void
>
_showAttachmentSheet
(
BuildContext
context
)
{
return
showModalBottomSheet
(
useSafeArea:
true
,
...
...
@@ -1601,6 +1673,7 @@ class _AllpaymentrequesitionlistsbymodesState
SizedBox
(
height:
15
),
InkWell
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
of
(
context
).
pop
(
false
);
provider
.
imgFromGallery
(
context
);
},
...
...
@@ -1612,6 +1685,7 @@ class _AllpaymentrequesitionlistsbymodesState
SizedBox
(
height:
10
),
InkWell
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
Navigator
.
of
(
context
).
pop
(
false
);
provider
.
imgFromCamera
(
context
);
},
...
...
lib/screens/finance/PaymentRequestionListDetails.dart
View file @
55280429
...
...
@@ -335,7 +335,9 @@ class _PaymentrequestionlistdetailsState
Expanded
(
child:
InkResponse
(
onTap:
()
{
if
(
provider
.
Headings
[
j
]
==
"Attachment"
)
{
HapticFeedback
.
selectionClick
();
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -354,6 +356,7 @@ class _PaymentrequestionlistdetailsState
);
}
else
if
(
provider
.
Headings
[
j
]
==
"Requested Account"
)
{
HapticFeedback
.
selectionClick
();
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -428,6 +431,7 @@ class _PaymentrequestionlistdetailsState
Expanded
(
child:
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
print
(
provider
.
requestsDetails
.
id
);
_showLevelRejectionSheet
(
context
,
...
...
@@ -461,6 +465,7 @@ class _PaymentrequestionlistdetailsState
Expanded
(
child:
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
provider
.
approveRejectPaymentRequestAPIFunction
(
context
,
...
...
@@ -495,6 +500,7 @@ class _PaymentrequestionlistdetailsState
Expanded
(
child:
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
provider
.
approveRejectPaymentRequestAPIFunction
(
context
,
...
...
lib/screens/finance/financeDashboard.dart
View file @
55280429
...
...
@@ -2,6 +2,7 @@ import 'dart:io';
import
'package:connectivity_plus/connectivity_plus.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_staggered_grid_view/flutter_staggered_grid_view.dart'
;
import
'package:flutter_svg/svg.dart'
;
import
'package:generp/Notifiers/commonProvider/accountsListProvider.dart'
;
...
...
@@ -94,7 +95,10 @@ class _FinancedashboardState extends State<Financedashboard> {
"assets/svg/finance/fin_accounts_ic.svg"
,
//"
];
final
paymentInitiationNames
=
[
"Self"
,
"Account List"
];
final
paymentInitiationSubtitles
=
[
"Payment Requests"
,
"Transactions Details"
];
final
paymentInitiationSubtitles
=
[
"Payment Requests"
,
"Transactions Details"
,
];
final
paymentInitiationRoles
=
[
668
,
293
];
final
paymentAdministrationIcons
=
[
...
...
@@ -118,9 +122,11 @@ class _FinancedashboardState extends State<Financedashboard> {
// "Ledgers, transactions, finance",
"Payment Requests"
,
];
final
paymentAdministrationRoles
=
[
666
,
678
,
673
,
final
paymentAdministrationRoles
=
[
666
,
678
,
673
,
// 675,
667
];
667
,
];
// Extract role IDs from accessible pages
final
roles
=
provider
.
accessiblePagesList
.
map
((
e
)
=>
e
.
id
).
toList
();
...
...
@@ -163,7 +169,7 @@ class _FinancedashboardState extends State<Financedashboard> {
return
Scaffold
(
resizeToAvoidBottomInset:
true
,
backgroundColor:
AppColors
.
scaffold_bg_color
,
appBar:
appbarNew
(
context
,
"Finance"
,
0xFFCEEDFF
),
appBar:
appbarNew
(
context
,
"Finance"
,
0xFFCEEDFF
),
body:
SizedBox
(
child:
SingleChildScrollView
(
child:
Column
(
...
...
@@ -171,15 +177,21 @@ class _FinancedashboardState extends State<Financedashboard> {
Container
(
height:
200
,
decoration:
BoxDecoration
(
image:
DecorationImage
(
image:
AssetImage
(
image:
DecorationImage
(
image:
AssetImage
(
"assets/svg/finance/main_dashboard.png"
,
),
fit:
BoxFit
.
contain
,),
gradient:
LinearGradient
(
colors:
[
),
fit:
BoxFit
.
contain
,
),
gradient:
LinearGradient
(
colors:
[
Color
(
0xFFCEEDFF
),
AppColors
.
scaffold_bg_color
],
begin:
Alignment
.
topCenter
,
end:
Alignment
.
bottomCenter
)
AppColors
.
scaffold_bg_color
,
],
begin:
Alignment
.
topCenter
,
end:
Alignment
.
bottomCenter
,
),
),
),
Container
(
padding:
EdgeInsets
.
symmetric
(
horizontal:
10
),
...
...
@@ -215,6 +227,7 @@ class _FinancedashboardState extends State<Financedashboard> {
return
Expanded
(
child:
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
navigate
;
navigate
=
Allpaymentrequesitionlistsbymodes
(
mode:
approvalModes
[
co
],
...
...
@@ -293,6 +306,7 @@ class _FinancedashboardState extends State<Financedashboard> {
itemBuilder:
(
context
,
ini
)
{
return
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
navigate
;
if
(
ini
==
0
)
{
navigate
=
await
Navigator
.
push
(
...
...
@@ -406,6 +420,7 @@ class _FinancedashboardState extends State<Financedashboard> {
itemBuilder:
(
context
,
ad
)
{
return
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
navigate
;
if
(
ad
==
0
)
{
navigate
=
await
Navigator
.
push
(
...
...
@@ -483,8 +498,7 @@ class _FinancedashboardState extends State<Financedashboard> {
borderRadius:
BorderRadius
.
circular
(
14
),
),
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
mainAxisAlignment:
MainAxisAlignment
.
center
,
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
...
...
@@ -535,7 +549,8 @@ class _FinancedashboardState extends State<Financedashboard> {
},
),
],
SizedBox
(
height:
100
,),
SizedBox
(
height:
100
),
// ListView.builder(
// itemCount: pages.length,
// shrinkWrap: true,
...
...
@@ -653,7 +668,6 @@ class _FinancedashboardState extends State<Financedashboard> {
// );
// },
// ),
],
),
),
...
...
@@ -665,6 +679,7 @@ class _FinancedashboardState extends State<Financedashboard> {
FloatingActionButtonLocation
.
centerFloat
,
floatingActionButton:
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
_showPaymentOptionsSheet
(
context
);
},
child:
Container
(
...
...
@@ -752,6 +767,7 @@ class _FinancedashboardState extends State<Financedashboard> {
];
return
ListTile
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
res
;
if
(
provider
.
accessiblePagesList2
[
index
]
...
...
@@ -856,9 +872,7 @@ class _FinancedashboardState extends State<Financedashboard> {
}
Navigator
.
pop
(
context
);
},
leading:
SvgPicture
.
asset
(
icons
[
index
],
),
leading:
SvgPicture
.
asset
(
icons
[
index
]),
title:
Text
(
"
${pages2[index].pageName}
"
,
style:
TextStyle
(
...
...
lib/screens/finance/paymentListPaymentRequisition.dart
View file @
55280429
...
...
@@ -3,6 +3,7 @@ import 'dart:io';
import
'package:connectivity_plus/connectivity_plus.dart'
;
import
'package:flutter/cupertino.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_svg/svg.dart'
;
import
'package:generp/Utils/GlobalConstants.dart'
;
import
'package:generp/screens/finance/paymentDetailsPaymentRequisition.dart'
;
...
...
@@ -109,6 +110,7 @@ class _PaymentlistpaymentrequisitionState
// ),
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
cf
=
Commondaterangefilter
();
var
result
=
await
cf
.
showFilterBottomSheet
(
context
);
if
(
result
!=
null
)
{
...
...
@@ -164,6 +166,7 @@ class _PaymentlistpaymentrequisitionState
itemBuilder:
(
context
,
index
)
{
return
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
res
=
await
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -334,6 +337,7 @@ class _PaymentlistpaymentrequisitionState
];
return
ListTile
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
switch
(
index
)
{
case
0
:
provider
.
copyToClipboard
(
context
);
...
...
lib/screens/finance/paymentreceiptList.dart
View file @
55280429
...
...
@@ -3,6 +3,7 @@ import 'dart:io';
import
'package:connectivity_plus/connectivity_plus.dart'
;
import
'package:flutter/cupertino.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_svg/svg.dart'
;
import
'package:generp/Utils/GlobalConstants.dart'
;
import
'package:generp/screens/finance/paymentReceiptDetails.dart'
;
...
...
@@ -93,6 +94,7 @@ class _PaymentreceiptlistState extends State<Paymentreceiptlist> {
// ),
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
cf
=
Commondaterangefilter
();
var
result
=
await
cf
.
showFilterBottomSheet
(
context
);
if
(
result
!=
null
)
{
...
...
@@ -124,7 +126,7 @@ class _PaymentreceiptlistState extends State<Paymentreceiptlist> {
),
],
),
0xFFFFFFFF
0xFFFFFFFF
,
),
backgroundColor:
AppColors
.
scaffold_bg_color
,
body:
...
...
@@ -146,6 +148,7 @@ class _PaymentreceiptlistState extends State<Paymentreceiptlist> {
itemBuilder:
(
context
,
index
)
{
return
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
res
=
await
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -160,8 +163,7 @@ class _PaymentreceiptlistState extends State<Paymentreceiptlist> {
),
),
);
if
(
routeSettingName
==
"Paymentreceiptdetails"
)
{
if
(
routeSettingName
==
"Paymentreceiptdetails"
)
{
debugPrint
(
"prd"
);
provider
.
paymentsListAPI
(
context
,
''
,
''
);
}
...
...
@@ -194,7 +196,7 @@ class _PaymentreceiptlistState extends State<Paymentreceiptlist> {
padding:
EdgeInsets
.
all
(
3.0
),
decoration:
BoxDecoration
(
color:
AppColors
.
requested_bg_color
,
shape:
BoxShape
.
circle
shape:
BoxShape
.
circle
,
),
child:
SvgPicture
.
asset
(
"assets/svg/finance/rupee_ic.svg"
,
...
...
@@ -311,6 +313,7 @@ class _PaymentreceiptlistState extends State<Paymentreceiptlist> {
];
return
ListTile
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
switch
(
index
)
{
case
0
:
provider
.
copyToClipboard
(
context
);
...
...
lib/screens/finance/submitPaymentRequestionListsByMode.dart
View file @
55280429
...
...
@@ -293,6 +293,7 @@ class _SubmitpaymentrequestionlistsbymodeState
flex:
1
,
child:
InkResponse
(
onTap:
()
async
{
HapticFeedback
.
selectionClick
();
var
res
=
await
Navigator
.
push
(
context
,
MaterialPageRoute
(
...
...
@@ -574,6 +575,7 @@ class _SubmitpaymentrequestionlistsbymodeState
InkResponse
(
onTap:
()
{
HapticFeedback
.
selectionClick
();
_showAttachmentSheet
(
context
);
},
child:
Container
(
...
...
@@ -759,6 +761,7 @@ class _SubmitpaymentrequestionlistsbymodeState
provider
.
submitClicked
?
null
:
()
{
HapticFeedback
.
selectionClick
();
provider
.
submitClicked
=
true
;
provider
.
addPaymentRequestionSubmitAPI
(
...
...
pubspec.yaml
View file @
55280429
...
...
@@ -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.9
8
+10
6
version
:
1.0.9
9
+10
7
environment
:
sdk
:
^3.7.2
...
...
Prev
1
2
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment