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_rentals
Commits
5037c228
Commit
5037c228
authored
Nov 18, 2025
by
Sai Srinivas
Browse files
Few pay fixes
parents
db93d1c9
30024bcb
Changes
13
Show whitespace changes
Inline
Side-by-side
android/app/build.gradle.kts
View file @
5037c228
...
@@ -32,7 +32,7 @@ android {
...
@@ -32,7 +32,7 @@ android {
applicationId
=
"in.webgrid.genrentals"
applicationId
=
"in.webgrid.genrentals"
// You can update the following values to match your application needs.
// You can update the following values to match your application needs.
// For more information, see: https://flutter.dev/to/review-gradle-config.
// For more information, see: https://flutter.dev/to/review-gradle-config.
minSdk
=
23
minSdk
=
flutter
.
minSdkVersion
targetSdk
=
36
targetSdk
=
36
versionCode
=
flutter
.
versionCode
versionCode
=
flutter
.
versionCode
versionName
=
flutter
.
versionName
versionName
=
flutter
.
versionName
...
...
assets/images/temp_background.jpg
deleted
100644 → 0
View file @
db93d1c9
99.3 KB
lib/Models/RentalPaymentDetailsResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
RentalPaymentDetailsResponse
{
List
<
Bill
>?
bill
;
int
?
error
;
String
?
message
;
RentalPaymentDetailsResponse
({
this
.
bill
,
this
.
error
,
this
.
message
});
RentalPaymentDetailsResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'bill'
]
!=
null
)
{
bill
=
<
Bill
>[];
json
[
'bill'
].
forEach
((
v
)
{
bill
!.
add
(
new
Bill
.
fromJson
(
v
));
});
}
error
=
json
[
'error'
];
message
=
json
[
'message'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
bill
!=
null
)
{
data
[
'bill'
]
=
this
.
bill
!.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
return
data
;
}
}
class
Bill
{
String
?
narration
;
String
?
amount
;
String
?
mode
;
String
?
ref
;
String
?
datetime
;
Bill
({
this
.
narration
,
this
.
amount
,
this
.
mode
,
this
.
ref
,
this
.
datetime
});
Bill
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
narration
=
json
[
'narration'
];
amount
=
json
[
'amount'
];
mode
=
json
[
'mode'
];
ref
=
json
[
'ref'
];
datetime
=
json
[
'datetime'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'narration'
]
=
this
.
narration
;
data
[
'amount'
]
=
this
.
amount
;
data
[
'mode'
]
=
this
.
mode
;
data
[
'ref'
]
=
this
.
ref
;
data
[
'datetime'
]
=
this
.
datetime
;
return
data
;
}
}
lib/Models/billProductResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
BillProductResponse
{
List
<
Bp
>?
bp
;
int
?
error
;
String
?
message
;
BillProductResponse
({
this
.
bp
,
this
.
error
,
this
.
message
});
BillProductResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'bp'
]
!=
null
)
{
bp
=
<
Bp
>[];
json
[
'bp'
].
forEach
((
v
)
{
bp
!.
add
(
new
Bp
.
fromJson
(
v
));
});
}
error
=
json
[
'error'
];
message
=
json
[
'message'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
bp
!=
null
)
{
data
[
'bp'
]
=
this
.
bp
!.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
return
data
;
}
}
class
Bp
{
String
?
pname
;
String
?
qty
;
String
?
totalAmount
;
Bp
({
this
.
pname
,
this
.
qty
,
this
.
totalAmount
});
Bp
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
pname
=
json
[
'pname'
];
qty
=
json
[
'qty'
];
totalAmount
=
json
[
'total_amount'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'pname'
]
=
this
.
pname
;
data
[
'qty'
]
=
this
.
qty
;
data
[
'total_amount'
]
=
this
.
totalAmount
;
return
data
;
}
}
lib/Models/orderDetailsBillResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
OrderDetailsBillResponse
{
List
<
Bill
>?
bill
;
int
?
error
;
String
?
message
;
OrderDetailsBillResponse
({
this
.
bill
,
this
.
error
,
this
.
message
});
OrderDetailsBillResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'bill'
]
!=
null
)
{
bill
=
<
Bill
>[];
json
[
'bill'
].
forEach
((
v
)
{
bill
!.
add
(
new
Bill
.
fromJson
(
v
));
});
}
error
=
json
[
'error'
];
message
=
json
[
'message'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
bill
!=
null
)
{
data
[
'bill'
]
=
this
.
bill
!.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
return
data
;
}
}
class
Bill
{
String
?
totalAmount
;
String
?
datetime
;
String
?
billNarration
;
String
?
billId
;
Bill
({
this
.
totalAmount
,
this
.
datetime
,
this
.
billNarration
,
this
.
billId
});
Bill
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
totalAmount
=
json
[
'total_amount'
];
datetime
=
json
[
'datetime'
];
billNarration
=
json
[
'bill_narration'
];
billId
=
json
[
'bill_id'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'total_amount'
]
=
this
.
totalAmount
;
data
[
'datetime'
]
=
this
.
datetime
;
data
[
'bill_narration'
]
=
this
.
billNarration
;
data
[
'bill_id'
]
=
this
.
billId
;
return
data
;
}
}
lib/Models/orderDetailsMainResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
OrderDetailsMainResponse
{
List
<
Bill
>?
bill
;
int
?
error
;
String
?
message
;
OrderDetailsMainResponse
({
this
.
bill
,
this
.
error
,
this
.
message
});
OrderDetailsMainResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'bill'
]
!=
null
)
{
bill
=
<
Bill
>[];
json
[
'bill'
].
forEach
((
v
)
{
bill
!.
add
(
new
Bill
.
fromJson
(
v
));
});
}
error
=
json
[
'error'
];
message
=
json
[
'message'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
bill
!=
null
)
{
data
[
'bill'
]
=
this
.
bill
!.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
return
data
;
}
}
class
Bill
{
String
?
dispAddress
;
String
?
tenure
;
Bill
({
this
.
dispAddress
,
this
.
tenure
});
Bill
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
dispAddress
=
json
[
'disp_address'
];
tenure
=
json
[
'tenure'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'disp_address'
]
=
this
.
dispAddress
;
data
[
'tenure'
]
=
this
.
tenure
;
return
data
;
}
}
lib/Models/orderDetailsProductResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
OrderDetailsProductResponse
{
List
<
Products
>?
products
;
int
?
error
;
String
?
message
;
OrderDetailsProductResponse
({
this
.
products
,
this
.
error
,
this
.
message
});
OrderDetailsProductResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'products'
]
!=
null
)
{
products
=
<
Products
>[];
json
[
'products'
].
forEach
((
v
)
{
products
!.
add
(
new
Products
.
fromJson
(
v
));
});
}
error
=
json
[
'error'
];
message
=
json
[
'message'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
products
!=
null
)
{
data
[
'products'
]
=
this
.
products
!.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
return
data
;
}
}
class
Products
{
String
?
pname
;
String
?
qty
;
String
?
totalAmount
;
String
?
type
;
Products
({
this
.
pname
,
this
.
qty
,
this
.
totalAmount
,
this
.
type
});
Products
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
pname
=
json
[
'pname'
];
qty
=
json
[
'qty'
];
totalAmount
=
json
[
'total_amount'
];
type
=
json
[
'type'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'pname'
]
=
this
.
pname
;
data
[
'qty'
]
=
this
.
qty
;
data
[
'total_amount'
]
=
this
.
totalAmount
;
data
[
'type'
]
=
this
.
type
;
return
data
;
}
}
lib/Models/rentalAccountResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
RentalAccountResponse
{
List
<
Account
>?
account
;
int
?
error
;
String
?
message
;
RentalAccountResponse
({
this
.
account
,
this
.
error
,
this
.
message
});
RentalAccountResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'account'
]
!=
null
)
{
account
=
<
Account
>[];
json
[
'account'
].
forEach
((
v
)
{
account
!.
add
(
new
Account
.
fromJson
(
v
));
});
}
error
=
json
[
'error'
];
message
=
json
[
'message'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
account
!=
null
)
{
data
[
'account'
]
=
this
.
account
!.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
return
data
;
}
}
class
Account
{
String
?
id
;
String
?
name
;
String
?
address
;
Account
({
this
.
id
,
this
.
name
,
this
.
address
});
Account
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
id
=
json
[
'id'
];
name
=
json
[
'name'
];
address
=
json
[
'address'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'id'
]
=
this
.
id
;
data
[
'name'
]
=
this
.
name
;
data
[
'address'
]
=
this
.
address
;
return
data
;
}
}
lib/Models/rentalContactResponse.dart
deleted
100644 → 0
View file @
db93d1c9
class
RentalContactResponse
{
int
?
error
;
String
?
message
;
int
?
exist
;
String
?
city
;
String
?
raname
;
String
?
mob
;
String
?
mail
;
String
?
address
;
String
?
state
;
String
?
accId
;
int
?
otp
;
RentalContactResponse
(
{
this
.
error
,
this
.
message
,
this
.
exist
,
this
.
city
,
this
.
raname
,
this
.
mob
,
this
.
mail
,
this
.
address
,
this
.
state
,
this
.
accId
,
this
.
otp
});
RentalContactResponse
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
error
=
json
[
'error'
];
message
=
json
[
'message'
];
exist
=
json
[
'exist'
];
city
=
json
[
'city'
];
raname
=
json
[
'raname'
];
mob
=
json
[
'mob'
];
mail
=
json
[
'mail'
];
address
=
json
[
'address'
];
state
=
json
[
'state'
];
accId
=
json
[
'acc_id'
];
otp
=
json
[
'otp'
];
}
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
data
[
'error'
]
=
this
.
error
;
data
[
'message'
]
=
this
.
message
;
data
[
'exist'
]
=
this
.
exist
;
data
[
'city'
]
=
this
.
city
;
data
[
'raname'
]
=
this
.
raname
;
data
[
'mob'
]
=
this
.
mob
;
data
[
'mail'
]
=
this
.
mail
;
data
[
'address'
]
=
this
.
address
;
data
[
'state'
]
=
this
.
state
;
data
[
'acc_id'
]
=
this
.
accId
;
data
[
'otp'
]
=
this
.
otp
;
return
data
;
}
}
lib/Screens/DashboardScreen.dart
View file @
5037c228
...
@@ -1067,7 +1067,7 @@ class _DashboardScreenState extends State<DashboardScreen> with WidgetsBindingOb
...
@@ -1067,7 +1067,7 @@ class _DashboardScreenState extends State<DashboardScreen> with WidgetsBindingOb
child:
Row
(
child:
Row
(
children:
[
children:
[
SizedBox
(
width:
screenWidth
*
0.02
),
SizedBox
(
width:
screenWidth
*
0.02
),
Icon
(
Icons
.
info
_outline
,
color:
Colors
.
red
,
size:
getResponsiveIconSize
(
context
,
15
)),
Icon
(
Icons
.
error
_outline
,
color:
Colors
.
red
,
size:
getResponsiveIconSize
(
context
,
15
)),
SizedBox
(
width:
screenWidth
*
0.01
),
SizedBox
(
width:
screenWidth
*
0.01
),
Expanded
(
Expanded
(
child:
Text
(
child:
Text
(
...
...
lib/Services/api_URLs.dart
View file @
5037c228
...
@@ -2,13 +2,9 @@
...
@@ -2,13 +2,9 @@
const
baseUrl
=
"https://erp.gengroup.in/ci/app/Rental/Rental_Home/"
;
const
baseUrl
=
"https://erp.gengroup.in/ci/app/Rental/Rental_Home/"
;
const
baseUrl2
=
"https://erp.gengroup.in/ci/app/Rental/"
;
const
baseUrl2
=
"https://erp.gengroup.in/ci/app/Rental/"
;
/// tokens url
const
addFcmTokenUrl
=
"
${baseUrl}
add_fcm_token"
;
/// payments and bills
/// payments and bills
const
addPaymentUrl
=
"
${baseUrl}
add_payment"
;
const
transactionsUrl
=
"
${baseUrl}
transactions"
;
const
transactionsUrl
=
"
${baseUrl}
transactions"
;
const
balanceUrl
=
"
${baseUrl}
balance"
;
const
billDetailsUrl
=
"
${baseUrl}
bill_details"
;
const
billDetailsUrl
=
"
${baseUrl}
bill_details"
;
const
billListUrl
=
"
${baseUrl}
bill_list"
;
const
billListUrl
=
"
${baseUrl}
bill_list"
;
const
downloadBillUrl
=
"
${baseUrl}
download_bill"
;
const
downloadBillUrl
=
"
${baseUrl}
download_bill"
;
...
@@ -17,17 +13,10 @@ const downloadReceiptUrl = "${baseUrl}download_receipt";
...
@@ -17,17 +13,10 @@ const downloadReceiptUrl = "${baseUrl}download_receipt";
const
payAmountUrl
=
"
${baseUrl}
pay_amount"
;
const
payAmountUrl
=
"
${baseUrl}
pay_amount"
;
const
getPaymentStatusUrl
=
"
${baseUrl}
get_payment_status"
;
const
getPaymentStatusUrl
=
"
${baseUrl}
get_payment_status"
;
/// info
const
checkInOutSubmitUrl
=
"
${baseUrl}
check_in_out_submit"
;
const
rentalContactUrl
=
"
${baseUrl}
rental_contact"
;
const
getRentalAccInfoUrl
=
"
${baseUrl}
get_rental_acc_info"
;
/// order
/// order
const
orderDetailsBillUrl
=
"
${baseUrl}
order_details_bill"
;
const
orderDetailsMainUrl
=
"
${baseUrl}
order_details_main"
;
const
orderDetailsProductUrl
=
"
${baseUrl}
order_details_product"
;
const
subsOrderDetails
=
"
${baseUrl}
subs_order_details"
;
const
subsOrderDetails
=
"
${baseUrl}
subs_order_details"
;
const
tagOrderUrl
=
"
${baseUrl}
tag_order"
;
/// tickets
/// tickets
const
addEnquiryUrl
=
"
${baseUrl}
add_enquiry"
;
const
addEnquiryUrl
=
"
${baseUrl}
add_enquiry"
;
...
...
lib/Services/api_calling.dart
View file @
5037c228
...
@@ -6,19 +6,14 @@ import 'package:gen_rentals/Models/HelpAndEnquiryModels/TicketChatDisplayRespons
...
@@ -6,19 +6,14 @@ import 'package:gen_rentals/Models/HelpAndEnquiryModels/TicketChatDisplayRespons
import
'package:gen_rentals/Models/BillsModels/billListResponse.dart'
;
import
'package:gen_rentals/Models/BillsModels/billListResponse.dart'
;
import
'package:gen_rentals/Models/ProfileResponse.dart'
;
import
'package:gen_rentals/Models/ProfileResponse.dart'
;
import
'package:gen_rentals/Models/TransactionModels/PaymentReceiptDetailsResponse.dart'
;
import
'package:gen_rentals/Models/TransactionModels/PaymentReceiptDetailsResponse.dart'
;
import
'package:gen_rentals/Models/billProductResponse.dart'
;
import
'package:gen_rentals/Models/orderDetailsMainResponse.dart'
;
import
'package:gen_rentals/Models/orderDetailsProductResponse.dart'
;
import
'package:gen_rentals/Models/SubscribeOrderDetailsResponse.dart'
;
import
'package:gen_rentals/Models/SubscribeOrderDetailsResponse.dart'
;
import
'package:gen_rentals/Models/HelpAndEnquiryModels/ticketListResponse.dart'
;
import
'package:gen_rentals/Models/HelpAndEnquiryModels/ticketListResponse.dart'
;
import
'../Models/BillsModels/BillDetailsResponse.dart'
;
import
'../Models/BillsModels/BillDetailsResponse.dart'
;
import
'../Models/DashboardResponse.dart'
;
import
'../Models/DashboardResponse.dart'
;
import
'../Models/RentalPaymentDetailsResponse.dart'
;
import
'../Models/TransactionModels/PayAmountResponse.dart'
;
import
'../Models/TransactionModels/PayAmountResponse.dart'
;
import
'../Models/TransactionModels/TransactionsResponse.dart'
;
import
'../Models/TransactionModels/TransactionsResponse.dart'
;
import
'../Models/orderDetailsBillResponse.dart'
;
import
'../Models/rentalAccountResponse.dart'
;
import
'../Models/rentalContactResponse.dart'
;
import
'../Notifier/PayAmountProvider.dart'
;
import
'../Notifier/PayAmountProvider.dart'
;
import
'../Notifier/RentalContactProvider .dart'
;
import
'../Notifier/RentalContactProvider .dart'
;
import
'api_URLs.dart'
;
import
'api_URLs.dart'
;
...
@@ -121,7 +116,7 @@ class ApiCalling {
...
@@ -121,7 +116,7 @@ class ApiCalling {
};
};
final
res
=
await
post
(
data
,
payAmountUrl
,
{});
final
res
=
await
post
(
data
,
payAmountUrl
,
{});
debugPrint
(
"PayAmount Response
${res?.body}
"
);
//
debugPrint("PayAmount Response ${res?.body}");
if
(
res
!=
null
)
{
if
(
res
!=
null
)
{
return
PayAmountResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
return
PayAmountResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
...
@@ -204,7 +199,7 @@ class ApiCalling {
...
@@ -204,7 +199,7 @@ class ApiCalling {
final
res
=
await
post
(
data
,
billDetailsUrl
,
{});
final
res
=
await
post
(
data
,
billDetailsUrl
,
{});
debugPrint
(
"Bill Details Response
${res?.body}
"
);
//
debugPrint("Bill Details Response ${res?.body}");
if
(
res
!=
null
)
{
if
(
res
!=
null
)
{
return
BillDetailsResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
return
BillDetailsResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
}
else
{
...
@@ -260,7 +255,7 @@ class ApiCalling {
...
@@ -260,7 +255,7 @@ class ApiCalling {
};
};
final
res
=
await
post
(
data
,
paymentReceiptDetailsUrl
,
{});
final
res
=
await
post
(
data
,
paymentReceiptDetailsUrl
,
{});
debugPrint
(
"TR Response
${res?.body}
"
);
//
debugPrint("TR Response ${res?.body}");
if
(
res
!=
null
)
{
if
(
res
!=
null
)
{
return
PaymentReceiptDetailsResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
return
PaymentReceiptDetailsResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
...
@@ -288,7 +283,7 @@ class ApiCalling {
...
@@ -288,7 +283,7 @@ class ApiCalling {
};
};
final
res
=
await
post
(
data
,
downloadReceiptUrl
,
{});
final
res
=
await
post
(
data
,
downloadReceiptUrl
,
{});
debugPrint
(
"DownloadApi Response
${res}
"
);
//
debugPrint("DownloadApi Response${res}");
if
(
res
!=
null
)
{
if
(
res
!=
null
)
{
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
...
@@ -317,7 +312,7 @@ class ApiCalling {
...
@@ -317,7 +312,7 @@ class ApiCalling {
};
};
final
res
=
await
post
(
data
,
subsOrderDetails
,
{});
final
res
=
await
post
(
data
,
subsOrderDetails
,
{});
debugPrint
(
"Subscribe order details Response:
${res?.body}
"
);
//
debugPrint("Subscribe order details Response: ${res?.body}");
if
(
res
!=
null
)
{
if
(
res
!=
null
)
{
return
SubscribeOrderDetailsResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
return
SubscribeOrderDetailsResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
...
@@ -333,34 +328,6 @@ class ApiCalling {
...
@@ -333,34 +328,6 @@ class ApiCalling {
/// Fetch Order Details Main
static
Future
<
OrderDetailsMainResponse
?>
fetchOrderDetailMainApi
(
String
sessionId
,
String
empId
,
String
orderId
,
)
async
{
try
{
Map
<
String
,
String
>
data
=
{
"session_id"
:
sessionId
,
"emp_id"
:
empId
,
"ord_id"
:
orderId
,
};
final
res
=
await
post
(
data
,
orderDetailsMainUrl
,
{});
if
(
res
!=
null
)
{
return
OrderDetailsMainResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
debugPrint
(
"Null Response"
);
return
null
;
}
}
catch
(
e
)
{
debugPrint
(
"❌ API Error (fetchOrderDetailMain):
$e
"
);
return
null
;
}
}
/// Fetch Rental Transaction
/// Fetch Rental Transaction
static
Future
<
TransactionsResponse
?>
fetchRentalsTransactionsApi
(
static
Future
<
TransactionsResponse
?>
fetchRentalsTransactionsApi
(
String
sessionId
,
String
sessionId
,
...
@@ -426,8 +393,8 @@ class ApiCalling {
...
@@ -426,8 +393,8 @@ class ApiCalling {
};
};
final
res
=
await
post
(
data
,
ticketChatDetailsUrl
,
{});
final
res
=
await
post
(
data
,
ticketChatDetailsUrl
,
{});
// debugPrint("
🟢
Raw API Response:\n${res?.body}");
// debugPrint(" Raw API Response:\n${res?.body}");
// debugPrint("
🟢
Response Type: ${res?.body.runtimeType}");
// debugPrint(" Response Type: ${res?.body.runtimeType}");
if
(
res
!=
null
)
{
if
(
res
!=
null
)
{
return
TicketChatDisplayResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
return
TicketChatDisplayResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
...
@@ -440,33 +407,6 @@ class ApiCalling {
...
@@ -440,33 +407,6 @@ class ApiCalling {
return
null
;
return
null
;
}
}
}
}
//
// static Future<addTicketResponse?> addTicketAPI(
// type, description, List<http.MultipartFile> newList) async {
// if (await CheckHeaderValidity()) {
// try {
// Map<String, String> data = {
// 'type': type.toString(),
// 'description': description.toString(),
// //ticket_image
// };
// // print("Add ticket ${data}");
// final header = await HeaderValues();
// final res = await PostMultipleImagesNew(
// data, addTicketsUrl, header, newList);
// if (res != null) {
// return addTicketResponse.fromJson(jsonDecode(res));
// } else {
// return null;
// }
// } catch (e) {
// debugPrint('hello bev=bug $e ');
// return null;
// }
// } else {
// return addTicketResponse(error: "401");
// }
// }
/// Send Message Chat Api
/// Send Message Chat Api
...
@@ -559,31 +499,6 @@ class ApiCalling {
...
@@ -559,31 +499,6 @@ class ApiCalling {
/// Fetch Tag Order
static
Future
<
CommonResponse
?>
fetchTagOrderApi
(
String
sessionId
,
String
empId
,
)
async
{
try
{
Map
<
String
,
String
>
data
=
{
"session_id"
:
sessionId
,
"emp_id"
:
empId
,
};
final
res
=
await
post
(
data
,
tagOrderUrl
,
{});
if
(
res
!=
null
)
{
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
debugPrint
(
"Null Response"
);
return
null
;
}
}
catch
(
e
)
{
debugPrint
(
"❌ API Error (fetchTagOrder):
$e
"
);
return
null
;
}
}
/// Submit Enquiry Api
/// Submit Enquiry Api
static
Future
<
CommonResponse
?>
submitEnquiryApi
(
static
Future
<
CommonResponse
?>
submitEnquiryApi
(
...
@@ -621,117 +536,8 @@ class ApiCalling {
...
@@ -621,117 +536,8 @@ class ApiCalling {
}
}
}
}
/// Fetch CheckInOut Submit
static
Future
<
CommonResponse
?>
fetchCheckInOutSubmitApi
(
String
sessionId
,
String
empId
,
)
async
{
try
{
Map
<
String
,
String
>
data
=
{
"session_id"
:
sessionId
,
"emp_id"
:
empId
,
};
final
res
=
await
post
(
data
,
checkInOutSubmitUrl
,
{});
if
(
res
!=
null
)
{
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
debugPrint
(
"Null Response"
);
return
null
;
}
}
catch
(
e
)
{
debugPrint
(
"❌ API Error (CheckInOutSubmit):
$e
"
);
return
null
;
}
}
/// Fetch Balance
static
Future
<
CommonResponse
?>
fetchBalanceApi
(
String
sessionId
,
String
empId
,
String
accId
,
)
async
{
try
{
Map
<
String
,
String
>
data
=
{
"session_id"
:
sessionId
,
"emp_id"
:
empId
,
"acc_id"
:
accId
,
};
final
res
=
await
post
(
data
,
balanceUrl
,
{});
if
(
res
!=
null
)
{
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
debugPrint
(
"Null Response"
);
return
null
;
}
}
catch
(
e
)
{
debugPrint
(
"❌ API Error (fetch Balance):
$e
"
);
return
null
;
}
}
/// Add Payment
static
Future
<
CommonResponse
?>
fetchAddPaymentApi
(
String
sessionId
,
String
empId
,
String
amount
,
String
orderId
,
)
async
{
try
{
Map
<
String
,
String
>
data
=
{
"session_id"
:
sessionId
,
"emp_id"
:
empId
,
"amount"
:
amount
,
"order_id"
:
orderId
,
};
final
res
=
await
post
(
data
,
addPaymentUrl
,
{});
if
(
res
!=
null
)
{
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
debugPrint
(
"Null Response"
);
return
null
;
}
}
catch
(
e
)
{
debugPrint
(
"❌ API Error (AddPaymentApi):
$e
"
);
return
null
;
}
}
/// Add Fcm Token
static
Future
<
CommonResponse
?>
fetchAddFcmTokenApi
(
String
sessionId
,
String
empId
,
String
amount
,
String
orderId
,
)
async
{
try
{
Map
<
String
,
String
>
data
=
{
"session_id"
:
sessionId
,
"emp_id"
:
empId
,
"amount"
:
amount
,
"order_id"
:
orderId
,
};
final
res
=
await
post
(
data
,
addFcmTokenUrl
,
{});
if
(
res
!=
null
)
{
return
CommonResponse
.
fromJson
(
jsonDecode
(
res
.
body
));
}
else
{
debugPrint
(
"Null Response"
);
return
null
;
}
}
catch
(
e
)
{
debugPrint
(
"❌ API Error (fetch Add Payment Api):
$e
"
);
return
null
;
}
}
/// Fetch Dashboard
/// Fetch Dashboard
static
Future
<
DashboardResponse
?>
fetchDashboardApi
(
static
Future
<
DashboardResponse
?>
fetchDashboardApi
(
...
...
pubspec.lock
View file @
5037c228
...
@@ -165,10 +165,10 @@ packages:
...
@@ -165,10 +165,10 @@ packages:
dependency: transitive
dependency: transitive
description:
description:
name: fake_async
name: fake_async
sha256: "
6a95e56b2449df2273fd8c45a662d6947ce1ebb7aafe80e550a3f68297f3cacc
"
sha256: "
5368f224a74523e8d2e7399ea1638b37aecfca824a3cc4dfdf77bf1fa905ac44
"
url: "https://pub.dev"
url: "https://pub.dev"
source: hosted
source: hosted
version: "1.3.
2
"
version: "1.3.
3
"
ffi:
ffi:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -412,26 +412,26 @@ packages:
...
@@ -412,26 +412,26 @@ packages:
dependency: transitive
dependency: transitive
description:
description:
name: leak_tracker
name: leak_tracker
sha256:
c35baad643ba394b40aac41080300150a4f08fd0fd6a10378f8f7c6bc161acec
sha256:
"33e2e26bdd85a0112ec15400c8cbffea70d0f9c3407491f672a2fad47915e2de"
url: "https://pub.dev"
url: "https://pub.dev"
source: hosted
source: hosted
version: "1
0
.0.
8
"
version: "1
1
.0.
2
"
leak_tracker_flutter_testing:
leak_tracker_flutter_testing:
dependency: transitive
dependency: transitive
description:
description:
name: leak_tracker_flutter_testing
name: leak_tracker_flutter_testing
sha256:
f8b613e7e6a13ec79cfdc0e97638fddb3ab848452eff057653abd3edba760573
sha256:
"1dbc140bb5a23c75ea9c4811222756104fbcd1a27173f0c34ca01e16bea473c1"
url: "https://pub.dev"
url: "https://pub.dev"
source: hosted
source: hosted
version: "3.0.
9
"
version: "3.0.
10
"
leak_tracker_testing:
leak_tracker_testing:
dependency: transitive
dependency: transitive
description:
description:
name: leak_tracker_testing
name: leak_tracker_testing
sha256: "
6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3
"
sha256: "
8d5a2d49f4a66b49744b23b018848400d23e54caf9463f4eb20df3eb8acb2eb1
"
url: "https://pub.dev"
url: "https://pub.dev"
source: hosted
source: hosted
version: "3.0.
1
"
version: "3.0.
2
"
lints:
lints:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -865,10 +865,10 @@ packages:
...
@@ -865,10 +865,10 @@ packages:
dependency: transitive
dependency: transitive
description:
description:
name: test_api
name: test_api
sha256:
fb31f383e2ee25fbbfe06b40fe21e1e458d14080e3c67e7ba0acfde4df4e0bbd
sha256:
"522f00f556e73044315fa4585ec3270f1808a4b186c936e612cab0b565ff1e00"
url: "https://pub.dev"
url: "https://pub.dev"
source: hosted
source: hosted
version: "0.7.
4
"
version: "0.7.
6
"
typed_data:
typed_data:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -913,10 +913,10 @@ packages:
...
@@ -913,10 +913,10 @@ packages:
dependency: transitive
dependency: transitive
description:
description:
name: vector_math
name: vector_math
sha256:
"80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803"
sha256:
d530bd74fea330e6e364cda7a85019c434070188383e1cd8d9777ee586914c5b
url: "https://pub.dev"
url: "https://pub.dev"
source: hosted
source: hosted
version: "2.
1.4
"
version: "2.
2.0
"
vm_service:
vm_service:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -966,5 +966,5 @@ packages:
...
@@ -966,5 +966,5 @@ packages:
source: hosted
source: hosted
version: "6.5.0"
version: "6.5.0"
sdks:
sdks:
dart: ">=3.
7.2
<4.0.0"
dart: ">=3.
8.0-0
<4.0.0"
flutter: ">=3.29.0"
flutter: ">=3.29.0"
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