TP_Service_Changes Trip_Info_Modal
This commit is contained in:
parent
de7491cc6e
commit
f0a0eb3c1d
@ -1,5 +1,6 @@
|
|||||||
import 'dart:convert';
|
import 'dart:convert';
|
||||||
import 'dart:core';
|
import 'dart:core';
|
||||||
|
import 'package:frontend/Screens/allTrips/plan_info_mdl.dart';
|
||||||
import 'package:frontend/Screens/allTrips/remarks_list.dart';
|
import 'package:frontend/Screens/allTrips/remarks_list.dart';
|
||||||
import 'package:frontend/data/models/plan.dart';
|
import 'package:frontend/data/models/plan.dart';
|
||||||
import 'package:go_router/go_router.dart';
|
import 'package:go_router/go_router.dart';
|
||||||
@ -1196,6 +1197,34 @@ class _ListAllPlansState extends State<ListAllPlans> {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
IconButton(
|
||||||
|
icon: const Icon(
|
||||||
|
Icons
|
||||||
|
.info_outlined,
|
||||||
|
color: Color(
|
||||||
|
0xFF475569,
|
||||||
|
),
|
||||||
|
size: 18,
|
||||||
|
),
|
||||||
|
tooltip:
|
||||||
|
'Trip Info',
|
||||||
|
onPressed: () {
|
||||||
|
showDialog(
|
||||||
|
context:
|
||||||
|
context,
|
||||||
|
builder:
|
||||||
|
(
|
||||||
|
context,
|
||||||
|
) => TripInformation(
|
||||||
|
// planId: plan.planId,
|
||||||
|
planId:
|
||||||
|
plan.planId.toString(),
|
||||||
|
layoutColorForUser:
|
||||||
|
layoutColor!,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -1490,6 +1519,34 @@ class _ListAllPlansState extends State<ListAllPlans> {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
IconButton(
|
||||||
|
icon: const Icon(
|
||||||
|
Icons
|
||||||
|
.info_outline_rounded,
|
||||||
|
color: Color(
|
||||||
|
0xFF475569,
|
||||||
|
),
|
||||||
|
size: 20,
|
||||||
|
),
|
||||||
|
tooltip:
|
||||||
|
'Trip Info',
|
||||||
|
onPressed: () {
|
||||||
|
showDialog(
|
||||||
|
context:
|
||||||
|
context,
|
||||||
|
builder:
|
||||||
|
(
|
||||||
|
context,
|
||||||
|
) => TripInformation(
|
||||||
|
// planId: plan.planId,
|
||||||
|
planId:
|
||||||
|
plan.planId.toString(),
|
||||||
|
layoutColorForUser:
|
||||||
|
layoutColor!,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
208
lib/Screens/allTrips/plan_info_mdl.dart
Normal file
208
lib/Screens/allTrips/plan_info_mdl.dart
Normal file
@ -0,0 +1,208 @@
|
|||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:google_fonts/google_fonts.dart';
|
||||||
|
import 'dart:convert';
|
||||||
|
import 'package:http/http.dart' as http;
|
||||||
|
import 'package:intl/intl.dart';
|
||||||
|
|
||||||
|
import '../../config/apiUrl.dart';
|
||||||
|
import '../../utils/auth_utils.dart';
|
||||||
|
|
||||||
|
class TripInformation extends StatefulWidget {
|
||||||
|
final String planId;
|
||||||
|
final Color layoutColorForUser;
|
||||||
|
|
||||||
|
const TripInformation({
|
||||||
|
Key? key,
|
||||||
|
required this.planId,
|
||||||
|
required this.layoutColorForUser,
|
||||||
|
}) : super(key: key);
|
||||||
|
|
||||||
|
@override
|
||||||
|
_TripInformationState createState() => _TripInformationState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _TripInformationState extends State<TripInformation> {
|
||||||
|
late Future<Map<String, dynamic>> _tripInfoFuture;
|
||||||
|
|
||||||
|
Future<Map<String, dynamic>> fetchComments() async {
|
||||||
|
final String apiUrldata =
|
||||||
|
'$apiUrl/api/plans/planInfo?plan_id=${widget.planId}';
|
||||||
|
|
||||||
|
final token = await getToken();
|
||||||
|
|
||||||
|
if (token == null) {
|
||||||
|
throw Exception('Token not found. Please log in.');
|
||||||
|
}
|
||||||
|
|
||||||
|
final response = await http.get(
|
||||||
|
Uri.parse(apiUrldata),
|
||||||
|
headers: {
|
||||||
|
'Authorization': 'Bearer $token',
|
||||||
|
'app-signature': 'ts-traveltool-2025-signature-123456',
|
||||||
|
'Content-Type': 'application/json',
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
||||||
|
if (response.statusCode == 200) {
|
||||||
|
final jsonData = json.decode(response.body);
|
||||||
|
final Map<String, dynamic> dataMap =
|
||||||
|
jsonData['data'] as Map<String, dynamic>;
|
||||||
|
return dataMap;
|
||||||
|
} else {
|
||||||
|
throw Exception('Failed to load comments');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
void initState() {
|
||||||
|
super.initState();
|
||||||
|
_tripInfoFuture = fetchComments();
|
||||||
|
|
||||||
|
print('_tripInfoFuture : $_tripInfoFuture');
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return AlertDialog(
|
||||||
|
backgroundColor: Colors.white,
|
||||||
|
title: Text(
|
||||||
|
'Trip Information',
|
||||||
|
style: GoogleFonts.poppins(color: Colors.black),
|
||||||
|
),
|
||||||
|
content: ConstrainedBox(
|
||||||
|
constraints: const BoxConstraints(
|
||||||
|
maxWidth: 500, // ✅ You can adjust this width
|
||||||
|
maxHeight:
|
||||||
|
400, // ✅ Optional: limit height to make it scrollable vertically
|
||||||
|
),
|
||||||
|
child: FutureBuilder<Map<String, dynamic>>(
|
||||||
|
future: _tripInfoFuture,
|
||||||
|
builder: (context, snapshot) {
|
||||||
|
if (snapshot.connectionState == ConnectionState.waiting) {
|
||||||
|
return const Center(child: CircularProgressIndicator());
|
||||||
|
}
|
||||||
|
|
||||||
|
if (snapshot.hasError) {
|
||||||
|
return Text(
|
||||||
|
'Error: ${snapshot.error}',
|
||||||
|
style: GoogleFonts.poppins(fontSize: 12, color: Colors.black),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!snapshot.hasData) {
|
||||||
|
return Text(
|
||||||
|
'No data found.',
|
||||||
|
style: GoogleFonts.poppins(fontSize: 12, color: Colors.black),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
final data = snapshot.data!;
|
||||||
|
|
||||||
|
return SingleChildScrollView(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
keyValueColumn("Traveller", data["traveller"] ?? ""),
|
||||||
|
keyValueColumn("Group Name", data["group_name"] ?? ""),
|
||||||
|
keyValueColumn(
|
||||||
|
"Allowed Plan Type",
|
||||||
|
data["allowed_plan_type"] ?? "",
|
||||||
|
),
|
||||||
|
keyValueColumn(
|
||||||
|
"Policy Action Flow",
|
||||||
|
data["policy_action_flow"] ?? "",
|
||||||
|
),
|
||||||
|
keyValueColumn("Policy Type", data["policy_type"] ?? ""),
|
||||||
|
|
||||||
|
const SizedBox(height: 12),
|
||||||
|
Text(
|
||||||
|
"Approval Criteria:",
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontWeight: FontWeight.w600,
|
||||||
|
fontSize: 13,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
|
||||||
|
...List.generate((data["approval_criteria"] as List).length, (
|
||||||
|
index,
|
||||||
|
) {
|
||||||
|
final item = data["approval_criteria"][index];
|
||||||
|
return Card(
|
||||||
|
elevation: 1,
|
||||||
|
color: Colors.white,
|
||||||
|
margin: const EdgeInsets.symmetric(vertical: 4),
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
keyValueRow("Action", item["action"]),
|
||||||
|
keyValueRow("Approver", item["approver"]),
|
||||||
|
keyValueRow(
|
||||||
|
"Is Action Done",
|
||||||
|
item["is_action_done"],
|
||||||
|
),
|
||||||
|
keyValueRow("Action On", item["action_on"]),
|
||||||
|
keyValueRow("Email Status", item["email_status"]),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
|
),
|
||||||
|
actions: [],
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Widget keyValueColumn(String key, String value) {
|
||||||
|
return Padding(
|
||||||
|
padding: const EdgeInsets.symmetric(vertical: 2),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
"$key ",
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontWeight: FontWeight.w600,
|
||||||
|
fontSize: 13,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(height: 5),
|
||||||
|
Text(value, style: GoogleFonts.poppins(fontSize: 13)),
|
||||||
|
// Expanded(
|
||||||
|
// child: Text(value, style: GoogleFonts.poppins(fontSize: 13)),
|
||||||
|
// ),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Widget keyValueRow(String key, String value) {
|
||||||
|
return Padding(
|
||||||
|
padding: const EdgeInsets.symmetric(vertical: 2, horizontal: 4),
|
||||||
|
child: Row(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: Text(
|
||||||
|
"$key ",
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontWeight: FontWeight.w600,
|
||||||
|
fontSize: 12,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(height: 5),
|
||||||
|
Expanded(
|
||||||
|
child: Text(value, style: GoogleFonts.poppins(fontSize: 12)),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -1,5 +1,6 @@
|
|||||||
import 'dart:convert';
|
import 'dart:convert';
|
||||||
import 'dart:core';
|
import 'dart:core';
|
||||||
|
import 'package:frontend/Screens/allTrips/plan_info_mdl.dart';
|
||||||
import 'package:frontend/data/models/plan.dart';
|
import 'package:frontend/data/models/plan.dart';
|
||||||
import 'package:frontend/utils/travelAgent_remarks.dart';
|
import 'package:frontend/utils/travelAgent_remarks.dart';
|
||||||
import 'package:go_router/go_router.dart';
|
import 'package:go_router/go_router.dart';
|
||||||
@ -947,6 +948,35 @@ class _TravelAgentListPlansState extends State<TravelAgentListPlans> {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
IconButton(
|
||||||
|
icon: const Icon(
|
||||||
|
Icons
|
||||||
|
.info_outlined,
|
||||||
|
color: Color(
|
||||||
|
0xFF475569,
|
||||||
|
),
|
||||||
|
size: 18,
|
||||||
|
),
|
||||||
|
tooltip:
|
||||||
|
'Trip Info',
|
||||||
|
onPressed: () {
|
||||||
|
showDialog(
|
||||||
|
context:
|
||||||
|
context,
|
||||||
|
builder:
|
||||||
|
(
|
||||||
|
context,
|
||||||
|
) => TripInformation(
|
||||||
|
// planId: plan.planId,
|
||||||
|
planId:
|
||||||
|
plan.planId
|
||||||
|
.toString(),
|
||||||
|
layoutColorForUser:
|
||||||
|
layoutColor!,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -635,6 +635,7 @@ class _ForexScreenState extends State<ForexScreen> {
|
|||||||
|
|
||||||
if (_isForexDataComplete()) {
|
if (_isForexDataComplete()) {
|
||||||
if (tripuserId != null) {
|
if (tripuserId != null) {
|
||||||
|
print('tripuserId - $tripuserId');
|
||||||
postgetForexData(getForexData);
|
postgetForexData(getForexData);
|
||||||
} else {
|
} else {
|
||||||
print("tripuserId is null");
|
print("tripuserId is null");
|
||||||
@ -686,6 +687,7 @@ class _ForexScreenState extends State<ForexScreen> {
|
|||||||
});
|
});
|
||||||
|
|
||||||
if (_isForexDataComplete()) {
|
if (_isForexDataComplete()) {
|
||||||
|
print('_isForexDataComplete');
|
||||||
postgetForexData(getForexData);
|
postgetForexData(getForexData);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -29,10 +29,13 @@ class _AccomodationListWidgetState extends State<AccomodationListWidget> {
|
|||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -64,6 +67,22 @@ class _AccomodationListWidgetState extends State<AccomodationListWidget> {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Accomodation");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
||||||
@ -88,7 +107,7 @@ class _AccomodationListWidgetState extends State<AccomodationListWidget> {
|
|||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
if (widget.accommodationList.isNotEmpty && orgHasService)
|
||||||
MouseRegion(
|
MouseRegion(
|
||||||
cursor:
|
cursor:
|
||||||
widget.isViewMode
|
widget.isViewMode
|
||||||
@ -328,6 +347,7 @@ class _AccomodationListWidgetState extends State<AccomodationListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Accomodation"),
|
onTap: () => widget.onOpen(true, item, "Accomodation"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -336,7 +356,8 @@ class _AccomodationListWidgetState extends State<AccomodationListWidget> {
|
|||||||
'assets/images/IconsImg/edit.png',
|
'assets/images/IconsImg/edit.png',
|
||||||
width: 20,
|
width: 20,
|
||||||
height: 15,
|
height: 15,
|
||||||
color: isDesktop ? Color(0xFF114D8B) : Colors.black87,
|
color:
|
||||||
|
isDesktop ? Color(0xFF114D8B) : Colors.black87,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -354,6 +375,7 @@ class _AccomodationListWidgetState extends State<AccomodationListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
|
|||||||
@ -35,11 +35,13 @@ class _BusListWidgetState extends State<BusListWidget> {
|
|||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -71,6 +73,22 @@ class _BusListWidgetState extends State<BusListWidget> {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Bus");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
||||||
@ -95,7 +113,7 @@ class _BusListWidgetState extends State<BusListWidget> {
|
|||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
if (widget.busList.isNotEmpty && orgHasService)
|
||||||
MouseRegion(
|
MouseRegion(
|
||||||
cursor:
|
cursor:
|
||||||
widget.isViewMode
|
widget.isViewMode
|
||||||
@ -306,6 +324,8 @@ class _BusListWidgetState extends State<BusListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
|
||||||
|
if (widget.busList.isNotEmpty && orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Bus"),
|
onTap: () => widget.onOpen(true, item, "Bus"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -315,7 +335,8 @@ class _BusListWidgetState extends State<BusListWidget> {
|
|||||||
width: 20,
|
width: 20,
|
||||||
height: 15,
|
height: 15,
|
||||||
// color: Color(0xFF114D8B),
|
// color: Color(0xFF114D8B),
|
||||||
color: !isDesktop ? Colors.black : Color(0xFF575A74),
|
color:
|
||||||
|
!isDesktop ? Colors.black : Color(0xFF575A74),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -333,6 +354,7 @@ class _BusListWidgetState extends State<BusListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
|
|||||||
@ -37,6 +37,8 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
// late Map<String, String> countryMap;
|
// late Map<String, String> countryMap;
|
||||||
Map<String, String> countryMap = {};
|
Map<String, String> countryMap = {};
|
||||||
|
|
||||||
@ -45,6 +47,7 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
super.initState();
|
super.initState();
|
||||||
loadCountryList(); // Call your method here
|
loadCountryList(); // Call your method here
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -76,6 +79,22 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Flight");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
|
}
|
||||||
|
|
||||||
Future<void> loadCountryList() async {
|
Future<void> loadCountryList() async {
|
||||||
final result = await apiService.fetchFlightsCountryList(widget.tripType);
|
final result = await apiService.fetchFlightsCountryList(widget.tripType);
|
||||||
|
|
||||||
@ -225,7 +244,7 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
),
|
),
|
||||||
|
|
||||||
// Right side: either "Add" icon or nothing
|
// Right side: either "Add" icon or nothing
|
||||||
if (widget.flightList.isNotEmpty)
|
if (widget.flightList.isNotEmpty && orgHasService)
|
||||||
MouseRegion(
|
MouseRegion(
|
||||||
cursor:
|
cursor:
|
||||||
widget.isViewMode
|
widget.isViewMode
|
||||||
@ -247,23 +266,24 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
),
|
),
|
||||||
)
|
)
|
||||||
else if (!isDesktop)
|
else if (!isDesktop)
|
||||||
|
SizedBox.shrink(),
|
||||||
// Centered "No Data Found" message for mobile and empty list
|
// Centered "No Data Found" message for mobile and empty list
|
||||||
Expanded(
|
// Expanded(
|
||||||
child: Center(
|
// child: Center(
|
||||||
child: Text(
|
// child: Text(
|
||||||
"No Data Found",
|
// "No Data Found",
|
||||||
textAlign: TextAlign.center,
|
// textAlign: TextAlign.center,
|
||||||
style: GoogleFonts.poppins(
|
// style: GoogleFonts.poppins(
|
||||||
fontSize: 18,
|
// fontSize: 18,
|
||||||
fontWeight: FontWeight.w500,
|
// fontWeight: FontWeight.w500,
|
||||||
color: Colors.grey,
|
// color: Colors.grey,
|
||||||
),
|
// ),
|
||||||
),
|
// ),
|
||||||
),
|
// ),
|
||||||
),
|
// ),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
const SizedBox(height: 16),
|
isDesktop ? SizedBox(height: 16) : SizedBox(height: 5),
|
||||||
|
|
||||||
// Actual flight data UI
|
// Actual flight data UI
|
||||||
_buildData(context, isDesktop),
|
_buildData(context, isDesktop),
|
||||||
@ -430,6 +450,8 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Flight"),
|
onTap: () => widget.onOpen(true, item, "Flight"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -439,7 +461,9 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
width: 20,
|
width: 20,
|
||||||
height: 15,
|
height: 15,
|
||||||
color:
|
color:
|
||||||
isDesktop ? Color(0xFF114D8B) : Colors.black87,
|
isDesktop
|
||||||
|
? Color(0xFF114D8B)
|
||||||
|
: Colors.black87,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -457,6 +481,7 @@ class _FlightListWidgetState extends State<FlightListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
|
|||||||
@ -36,6 +36,7 @@ class _ForexListWidgetState extends State<ForexListWidget> {
|
|||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
@ -72,6 +73,22 @@ class _ForexListWidgetState extends State<ForexListWidget> {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Forex");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
||||||
@ -334,6 +351,8 @@ class _ForexListWidgetState extends State<ForexListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Forex"),
|
onTap: () => widget.onOpen(true, item, "Forex"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -343,7 +362,8 @@ class _ForexListWidgetState extends State<ForexListWidget> {
|
|||||||
width: 20,
|
width: 20,
|
||||||
height: 15,
|
height: 15,
|
||||||
// color: Color(0xFF114D8B),
|
// color: Color(0xFF114D8B),
|
||||||
color: !isDesktop ? Colors.black : Color(0xFF575A74),
|
color:
|
||||||
|
!isDesktop ? Colors.black : Color(0xFF575A74),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -360,6 +380,8 @@ class _ForexListWidgetState extends State<ForexListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
],
|
||||||
|
|
||||||
item['forex_id'] != null
|
item['forex_id'] != null
|
||||||
? IconButton(
|
? IconButton(
|
||||||
icon: Icon(
|
icon: Icon(
|
||||||
|
|||||||
@ -33,11 +33,29 @@ class _InsuranceListWidgetState extends State<InsuranceListWidget> {
|
|||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Insurance");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -267,6 +285,7 @@ class _InsuranceListWidgetState extends State<InsuranceListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Insurance"),
|
onTap: () => widget.onOpen(true, item, "Insurance"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -293,6 +312,7 @@ class _InsuranceListWidgetState extends State<InsuranceListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
|
|||||||
@ -30,11 +30,29 @@ class _MiscellaneousListWidgetState extends State<MiscellaneousListWidget> {
|
|||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Miscellaneous");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -90,6 +108,8 @@ class _MiscellaneousListWidgetState extends State<MiscellaneousListWidget> {
|
|||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
|
if (orgHasService && widget.miscellaneousList.isNotEmpty)
|
||||||
MouseRegion(
|
MouseRegion(
|
||||||
cursor:
|
cursor:
|
||||||
widget.isViewMode
|
widget.isViewMode
|
||||||
@ -244,6 +264,7 @@ class _MiscellaneousListWidgetState extends State<MiscellaneousListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Miscellaneous"),
|
onTap: () => widget.onOpen(true, item, "Miscellaneous"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -271,6 +292,7 @@ class _MiscellaneousListWidgetState extends State<MiscellaneousListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
|
|||||||
@ -31,11 +31,29 @@ class _TaxiListWidgetState extends State<TaxiListWidget> {
|
|||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Taxi");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -91,6 +109,8 @@ class _TaxiListWidgetState extends State<TaxiListWidget> {
|
|||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
|
if (orgHasService && widget.taxiList.isNotEmpty)
|
||||||
MouseRegion(
|
MouseRegion(
|
||||||
cursor:
|
cursor:
|
||||||
widget.isViewMode
|
widget.isViewMode
|
||||||
@ -315,6 +335,7 @@ class _TaxiListWidgetState extends State<TaxiListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Taxi"),
|
onTap: () => widget.onOpen(true, item, "Taxi"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -341,6 +362,7 @@ class _TaxiListWidgetState extends State<TaxiListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
|
|||||||
@ -40,12 +40,30 @@ class _TrainListWidgetState extends State<TrainListWidget> {
|
|||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
loadCountryList(); // Call your method here
|
loadCountryList(); // Call your method here
|
||||||
|
getOrgServices();
|
||||||
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Train");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -145,7 +163,7 @@ class _TrainListWidgetState extends State<TrainListWidget> {
|
|||||||
Row(
|
Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
children: [
|
children: [
|
||||||
if ((!isDesktop))
|
if ((!isDesktop) && widget.trainList.isNotEmpty)
|
||||||
Text(
|
Text(
|
||||||
" ",
|
" ",
|
||||||
style: const TextStyle(
|
style: const TextStyle(
|
||||||
@ -153,6 +171,8 @@ class _TrainListWidgetState extends State<TrainListWidget> {
|
|||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
|
if (orgHasService && widget.trainList.isNotEmpty)
|
||||||
MouseRegion(
|
MouseRegion(
|
||||||
cursor:
|
cursor:
|
||||||
widget.isViewMode
|
widget.isViewMode
|
||||||
@ -387,6 +407,8 @@ class _TrainListWidgetState extends State<TrainListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Train"),
|
onTap: () => widget.onOpen(true, item, "Train"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -413,6 +435,7 @@ class _TrainListWidgetState extends State<TrainListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
|
|||||||
@ -33,10 +33,13 @@ class _VisaListWidgetState extends State<VisaListWidget> {
|
|||||||
Color? secondColor;
|
Color? secondColor;
|
||||||
Color? thridColor;
|
Color? thridColor;
|
||||||
|
|
||||||
|
bool orgHasService = false;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
getOrgServices();
|
||||||
}
|
}
|
||||||
|
|
||||||
void loadInitialData() async {
|
void loadInitialData() async {
|
||||||
@ -68,6 +71,22 @@ class _VisaListWidgetState extends State<VisaListWidget> {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void getOrgServices() async {
|
||||||
|
final services = await getOrgServicesName();
|
||||||
|
print("getOrgServices storage: $services");
|
||||||
|
|
||||||
|
// just names
|
||||||
|
final names = services.map((s) => s['name']).toList();
|
||||||
|
print("Names only: $names");
|
||||||
|
final hasFlight = names.contains("Visa");
|
||||||
|
|
||||||
|
setState(() {
|
||||||
|
orgHasService = hasFlight;
|
||||||
|
});
|
||||||
|
|
||||||
|
print("orgHasService: $orgHasService");
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
final isDesktop = MediaQuery.of(context).size.width > 1024;
|
||||||
@ -364,6 +383,8 @@ class _VisaListWidgetState extends State<VisaListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Spacer(),
|
Spacer(),
|
||||||
|
|
||||||
|
if (orgHasService) ...[
|
||||||
GestureDetector(
|
GestureDetector(
|
||||||
onTap: () => widget.onOpen(true, item, "Visa"),
|
onTap: () => widget.onOpen(true, item, "Visa"),
|
||||||
child: Tooltip(
|
child: Tooltip(
|
||||||
@ -390,6 +411,7 @@ class _VisaListWidgetState extends State<VisaListWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
],
|
||||||
),
|
),
|
||||||
// Divider(color: Colors.blueGrey.shade50),
|
// Divider(color: Colors.blueGrey.shade50),
|
||||||
SizedBox(height: 4),
|
SizedBox(height: 4),
|
||||||
|
|||||||
@ -485,8 +485,8 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
"exceptional_plan_reason": _excepntldescriptionController.text,
|
"exceptional_plan_reason": _excepntldescriptionController.text,
|
||||||
"functional_department": selectedFuncDept,
|
"functional_department": selectedFuncDept,
|
||||||
"so_number": _soNumberController.text,
|
"so_number": _soNumberController.text,
|
||||||
"created_by": selfId,
|
// "created_by": selfId,
|
||||||
"updated_by": selfId,
|
// "updated_by": selfId,
|
||||||
"is_active": "1",
|
"is_active": "1",
|
||||||
"flight": flightList,
|
"flight": flightList,
|
||||||
"accomodation": accommodationList,
|
"accomodation": accommodationList,
|
||||||
@ -562,6 +562,7 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
print("approverStatus - ${widget.approverStatus}");
|
print("approverStatus - ${widget.approverStatus}");
|
||||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||||
loadInitialData();
|
loadInitialData();
|
||||||
|
dynamicItineraryKey.currentState?.updateSelectedServices();
|
||||||
});
|
});
|
||||||
|
|
||||||
// if (widget.selectedPlanData != null) {
|
// if (widget.selectedPlanData != null) {
|
||||||
@ -876,7 +877,7 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
var userTripId;
|
var userTripId;
|
||||||
// if (!mounted) return;
|
// if (!mounted) return;
|
||||||
print("getSelectedPlanFor");
|
print("getSelectedPlanFor");
|
||||||
setState(() {
|
setState(() async {
|
||||||
if (selectedplanUserId != null) {
|
if (selectedplanUserId != null) {
|
||||||
print("Is Not USER ID - $planUsrId ");
|
print("Is Not USER ID - $planUsrId ");
|
||||||
if (selectedIstravelUser!) {
|
if (selectedIstravelUser!) {
|
||||||
@ -904,6 +905,7 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void fetchUserDetails() async {
|
void fetchUserDetails() async {
|
||||||
|
print('FetchHandleUSe');
|
||||||
final details = await getUserDetails();
|
final details = await getUserDetails();
|
||||||
TripPlanAction = await getTripPlanAction();
|
TripPlanAction = await getTripPlanAction();
|
||||||
print("TripPlanAction- $TripPlanAction");
|
print("TripPlanAction- $TripPlanAction");
|
||||||
@ -926,6 +928,30 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
// handleUpdateData();
|
// handleUpdateData();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void fetchUsrDtlFromSelectedTripUser() async {
|
||||||
|
// final details = await getUserDetails();
|
||||||
|
|
||||||
|
TripPlanAction = await getTripPlanActionFromSelectedUsr();
|
||||||
|
print("TripPlanAction- $TripPlanAction");
|
||||||
|
// print("details- $details");
|
||||||
|
//
|
||||||
|
// if (details != null) {
|
||||||
|
// setState(() {
|
||||||
|
// userDetails = details.toString(); // Store the full Map
|
||||||
|
// userName = details['name']; // Extract the name
|
||||||
|
// selfId = details['user_id'];
|
||||||
|
// });
|
||||||
|
// }
|
||||||
|
// orgId = await getOrgId();
|
||||||
|
// print("userDetails - $selfId");
|
||||||
|
// handleSelectedUser();
|
||||||
|
// getSelectedPlanFor();
|
||||||
|
setTripPlanAction();
|
||||||
|
|
||||||
|
// handleSelectedUser();
|
||||||
|
// handleUpdateData();
|
||||||
|
}
|
||||||
|
|
||||||
Future<String?> getToken() async {
|
Future<String?> getToken() async {
|
||||||
final prefs = await SharedPreferences.getInstance();
|
final prefs = await SharedPreferences.getInstance();
|
||||||
return prefs.getString('auth_token');
|
return prefs.getString('auth_token');
|
||||||
@ -1496,6 +1522,9 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
|
|
||||||
if (selectedPlanId != null && selectedPlanId!.isNotEmpty) {
|
if (selectedPlanId != null && selectedPlanId!.isNotEmpty) {
|
||||||
planData['plan_id'] = selectedPlanId; // Add plan_id for update
|
planData['plan_id'] = selectedPlanId; // Add plan_id for update
|
||||||
|
planData['updated_by'] = selfId; // Add plan_id for update
|
||||||
|
} else {
|
||||||
|
planData['created_by'] = selfId; // Add plan_id for update
|
||||||
}
|
}
|
||||||
|
|
||||||
print("POSTPlanTesting------- $planData}");
|
print("POSTPlanTesting------- $planData}");
|
||||||
@ -3288,250 +3317,27 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
final selected = options.firstWhere(
|
final selected = options.firstWhere(
|
||||||
(opt) => opt["title"] == newTitle,
|
(opt) => opt["title"] == newTitle,
|
||||||
);
|
);
|
||||||
setState(() {
|
setState(() async {
|
||||||
_selectedOption = selected["value"]!;
|
_selectedOption = selected["value"]!;
|
||||||
if (_selectedOption == "Option 2" ||
|
if (_selectedOption == "Option 2" ||
|
||||||
_selectedOption == "Option 3") {
|
_selectedOption == "Option 3") {
|
||||||
|
_selectedTripType = null;
|
||||||
_showInputDialog(selected["title"]!);
|
_showInputDialog(selected["title"]!);
|
||||||
} else if (_selectedOption == "Option 1") {
|
} else if (_selectedOption == "Option 1") {
|
||||||
otherUserName = userName;
|
otherUserName = userName;
|
||||||
}
|
await apiService.handleTripWiseToken(selfId!);
|
||||||
});
|
fetchUserDetails();
|
||||||
},
|
_selectedTripType = null;
|
||||||
),
|
dynamicItineraryKey.currentState
|
||||||
),
|
?.loadOrgSelectedAlServices();
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
];
|
|
||||||
}
|
|
||||||
|
|
||||||
List<Widget> _buildPlanTrip1(bool isDesktop) {
|
|
||||||
List<Map<String, String>> options = [
|
|
||||||
{"title": "Self", "value": "Option 1"},
|
|
||||||
{"title": "Other Employee", "value": "Option 2"},
|
|
||||||
{"title": "Others (Non Employee)", "value": "Option 3"},
|
|
||||||
];
|
|
||||||
|
|
||||||
print(" layoutColor: ${widget.layoutColor}");
|
|
||||||
return options.map((option) {
|
|
||||||
return Padding(
|
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 2, vertical: 0),
|
|
||||||
child: CustomTextFieldWrapper(
|
|
||||||
// color: Color(0xFFF4F4FB),
|
|
||||||
color: Color(0xFFF5F5F5),
|
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 10, vertical: 4),
|
|
||||||
layoutColor: widget.layoutColor,
|
|
||||||
width:
|
|
||||||
option["value"] == "Option 2"
|
|
||||||
? 185
|
|
||||||
: 125, // Adjust width conditionally
|
|
||||||
borderRadius: BorderRadius.circular(10),
|
|
||||||
isFocused: _selectedOption == option["value"],
|
|
||||||
isDesktop: isDesktop,
|
|
||||||
child: GestureDetector(
|
|
||||||
onTap:
|
|
||||||
widget.isViewMode
|
|
||||||
? null
|
|
||||||
: () {
|
|
||||||
setState(() {
|
|
||||||
_selectedOption = option["value"]!;
|
|
||||||
if (option["value"] == 'Option 2' ||
|
|
||||||
option["value"] == 'Option 3') {
|
|
||||||
_showInputDialog(option["title"]!);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
child: Row(
|
|
||||||
mainAxisSize: MainAxisSize.min,
|
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
option["title"]!,
|
|
||||||
style: TextStyle(
|
|
||||||
fontSize: 13,
|
|
||||||
color:
|
|
||||||
_selectedOption == option["value"]
|
|
||||||
? Colors.white
|
|
||||||
: Colors.black,
|
|
||||||
fontWeight:
|
|
||||||
_selectedOption == option["value"]
|
|
||||||
? FontWeight.w500
|
|
||||||
: null,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Container(
|
|
||||||
width: 15,
|
|
||||||
height: 15,
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
shape: BoxShape.rectangle,
|
|
||||||
// color: _selectedOption == option["value"]
|
|
||||||
// ? Colors.blueAccent
|
|
||||||
// : Colors.transparent,
|
|
||||||
borderRadius: BorderRadius.circular(4), // Rounded rectangle
|
|
||||||
border: Border.all(
|
|
||||||
color:
|
|
||||||
_selectedOption == option["value"]
|
|
||||||
? Colors.white
|
|
||||||
: Colors.black,
|
|
||||||
width: _selectedOption == option["value"] ? 2 : 1,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
child:
|
|
||||||
_selectedOption == option["value"]
|
|
||||||
? Icon(Icons.rectangle, size: 8, color: Colors.white)
|
|
||||||
: null, // Add checkmark if selected
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
|
||||||
}).toList();
|
|
||||||
}
|
|
||||||
|
|
||||||
List<Widget> _buildTripType(bool isMobile) {
|
|
||||||
return [
|
|
||||||
if (showDomestic == true)
|
|
||||||
GestureDetector(
|
|
||||||
onTap:
|
|
||||||
widget.isViewMode
|
|
||||||
? null
|
|
||||||
: () {
|
|
||||||
setState(() {
|
|
||||||
_selectedTripType = "1";
|
|
||||||
fetchTrainFlightClass(1);
|
|
||||||
|
|
||||||
dynamicItineraryKey.currentState
|
dynamicItineraryKey.currentState
|
||||||
?.updateSelectedServices();
|
?.updateSelectedServices();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
child: CustomTextFieldWrapper(
|
|
||||||
color: Color(0xFFF4F4FB),
|
|
||||||
layoutColor: widget.layoutColor,
|
|
||||||
borderRadius: BorderRadius.circular(25),
|
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 10, vertical: 5),
|
|
||||||
width: 130,
|
|
||||||
isFocused: _selectedTripType == "1",
|
|
||||||
isDesktop: widget.isDesktop,
|
|
||||||
child: Row(
|
|
||||||
mainAxisSize: MainAxisSize.min,
|
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
"Domestic",
|
|
||||||
style: TextStyle(
|
|
||||||
color:
|
|
||||||
_selectedTripType == "1" ? Colors.white : Colors.black,
|
|
||||||
fontWeight:
|
|
||||||
_selectedTripType == "1" ? FontWeight.w500 : null,
|
|
||||||
fontSize: 13,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Container(
|
|
||||||
width: 15,
|
|
||||||
height: 15,
|
|
||||||
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
shape: BoxShape.rectangle,
|
|
||||||
// color: _selectedOption == option["value"]
|
|
||||||
// ? Colors.blueAccent
|
|
||||||
// : Colors.transparent,
|
|
||||||
borderRadius: BorderRadius.circular(4), // Rounded rectangle
|
|
||||||
border: Border.all(
|
|
||||||
color:
|
|
||||||
_selectedTripType == "1"
|
|
||||||
? Colors.white
|
|
||||||
: Colors.black,
|
|
||||||
width: _selectedTripType == "1" ? 2 : 1,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
child:
|
|
||||||
_selectedTripType == "1"
|
|
||||||
? Icon(Icons.rectangle, size: 8, color: Colors.white)
|
|
||||||
: null, // Add checkmark if selected
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
SizedBox(width: 20),
|
|
||||||
if (showInternational)
|
|
||||||
GestureDetector(
|
|
||||||
onTap:
|
|
||||||
widget.isViewMode
|
|
||||||
? null
|
|
||||||
: () {
|
|
||||||
setState(() {
|
|
||||||
_selectedTripType = "2";
|
|
||||||
fetchTrainFlightClass(2);
|
|
||||||
dynamicItineraryKey.currentState
|
|
||||||
?.updateSelectedServices();
|
|
||||||
});
|
|
||||||
},
|
|
||||||
child: CustomTextFieldWrapper(
|
|
||||||
color: Color(0xFFF4F4FB),
|
|
||||||
layoutColor: widget.layoutColor,
|
|
||||||
borderRadius: BorderRadius.circular(25),
|
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 10, vertical: 4),
|
|
||||||
width: 150,
|
|
||||||
// padding: EdgeInsets.symmetric(horizontal: 5, vertical: 2),
|
|
||||||
isFocused: _selectedTripType == "2",
|
|
||||||
isDesktop: widget.isDesktop,
|
|
||||||
child: Row(
|
|
||||||
mainAxisSize: MainAxisSize.min,
|
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
"International",
|
|
||||||
style: TextStyle(
|
|
||||||
fontSize: 13,
|
|
||||||
color:
|
|
||||||
_selectedTripType == "2" ? Colors.white : Colors.black,
|
|
||||||
fontWeight:
|
|
||||||
_selectedTripType == "2" ? FontWeight.w500 : null,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Container(
|
|
||||||
width: 15,
|
|
||||||
height: 15,
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
shape: BoxShape.rectangle,
|
|
||||||
// color: _selectedOption == option["value"]
|
|
||||||
// ? Colors.blueAccent
|
|
||||||
// : Colors.transparent,
|
|
||||||
borderRadius: BorderRadius.circular(4), // Rounded rectangle
|
|
||||||
border: Border.all(
|
|
||||||
color:
|
|
||||||
_selectedTripType == "2"
|
|
||||||
? Colors.white
|
|
||||||
: Colors.black,
|
|
||||||
width: _selectedTripType == "2" ? 2 : 1,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
child:
|
|
||||||
_selectedTripType == "2"
|
|
||||||
? Icon(Icons.rectangle, size: 8, color: Colors.white)
|
|
||||||
: null, // Add checkmark if selected
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
|
|
||||||
// RadioListTile<String>(
|
|
||||||
// activeColor: Colors.blueAccent,
|
|
||||||
// contentPadding: EdgeInsets.zero,
|
|
||||||
// dense: true,
|
|
||||||
// title: Text("International"),
|
|
||||||
// value: "2",
|
|
||||||
// groupValue: _selectedTripType,
|
|
||||||
// onChanged: widget.isViewMode
|
|
||||||
// ? null
|
|
||||||
// : (value) {
|
|
||||||
// setState(() {
|
|
||||||
// _selectedTripType = value!;
|
|
||||||
// });
|
|
||||||
// },
|
|
||||||
// ),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
];
|
];
|
||||||
@ -4424,7 +4230,7 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
builder: (BuildContext context) {
|
builder: (BuildContext context) {
|
||||||
return UserSelectionDialog(
|
return UserSelectionDialog(
|
||||||
title: title,
|
title: title,
|
||||||
onSubmit: (input, userId, isTraveller) {
|
onSubmit: (input, userId, isTraveller) async {
|
||||||
setState(() {
|
setState(() {
|
||||||
otherUserName = input;
|
otherUserName = input;
|
||||||
selectedplanUserId = userId;
|
selectedplanUserId = userId;
|
||||||
@ -4432,9 +4238,25 @@ class CreateNewPlansState extends State<CreateNewPlan> {
|
|||||||
});
|
});
|
||||||
print("USer entered : $otherUserName $userId $isTraveller");
|
print("USer entered : $otherUserName $userId $isTraveller");
|
||||||
getSelectedPlanFor();
|
getSelectedPlanFor();
|
||||||
|
|
||||||
|
if (isTraveller) {
|
||||||
|
await apiService.handleTripWiseToken(
|
||||||
|
selfId!,
|
||||||
|
); // since userId is for traveller
|
||||||
|
} else {
|
||||||
|
await apiService.handleTripWiseToken(
|
||||||
|
userId,
|
||||||
|
); // fallback to selfId
|
||||||
|
}
|
||||||
|
|
||||||
|
fetchUsrDtlFromSelectedTripUser();
|
||||||
|
|
||||||
|
dynamicItineraryKey.currentState?.loadOrgSelectedAlServices();
|
||||||
|
dynamicItineraryKey.currentState?.updateSelectedServices();
|
||||||
},
|
},
|
||||||
onClose: () {
|
onClose: () async {
|
||||||
print("Choosede Clsoes");
|
print("Choosede Clsoes");
|
||||||
|
await apiService.handleTripWiseToken(selfId!);
|
||||||
fetchUserDetails();
|
fetchUserDetails();
|
||||||
},
|
},
|
||||||
layoutColorForUser: widget.layoutColor!,
|
layoutColorForUser: widget.layoutColor!,
|
||||||
|
|||||||
4218
lib/Screens/plans/create_plans_token_bfr_17_Sep.dart
Normal file
4218
lib/Screens/plans/create_plans_token_bfr_17_Sep.dart
Normal file
File diff suppressed because it is too large
Load Diff
@ -11,8 +11,10 @@ import 'package:frontend/Screens/itnerary_list/train_list.dart';
|
|||||||
import 'package:frontend/utils/auth_utils.dart';
|
import 'package:frontend/utils/auth_utils.dart';
|
||||||
import 'package:google_fonts/google_fonts.dart';
|
import 'package:google_fonts/google_fonts.dart';
|
||||||
import 'package:responsive_builder/responsive_builder.dart';
|
import 'package:responsive_builder/responsive_builder.dart';
|
||||||
|
import 'package:shared_preferences/shared_preferences.dart';
|
||||||
|
|
||||||
import '../../services/apiService.dart';
|
import '../../services/apiService.dart';
|
||||||
|
import '../../utils/auth_utils.dart';
|
||||||
import '../itnerary/accomodations.dart';
|
import '../itnerary/accomodations.dart';
|
||||||
import '../itnerary/bus.dart';
|
import '../itnerary/bus.dart';
|
||||||
import '../itnerary/flights.dart';
|
import '../itnerary/flights.dart';
|
||||||
@ -84,7 +86,8 @@ class DynamicItineraryState extends State<DynamicItinerary> {
|
|||||||
int? selectedIndex;
|
int? selectedIndex;
|
||||||
|
|
||||||
List<dynamic>? selectedAllServices;
|
List<dynamic>? selectedAllServices;
|
||||||
List<Map<String, String>> selectedOrgServiceIds = [];
|
// List<Map<String, String>> selectedOrgServiceIds = [];
|
||||||
|
List<Map<String, dynamic>> selectedOrgServiceIds = [];
|
||||||
List<dynamic>? ServicesChoosed;
|
List<dynamic>? ServicesChoosed;
|
||||||
List<String> filledItineraryKeys = [];
|
List<String> filledItineraryKeys = [];
|
||||||
|
|
||||||
@ -206,7 +209,9 @@ class DynamicItineraryState extends State<DynamicItinerary> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Org token based services
|
||||||
Future<void> loadOrgSelectedAlServices() async {
|
Future<void> loadOrgSelectedAlServices() async {
|
||||||
|
print('loadOrgSelectedAlServices');
|
||||||
try {
|
try {
|
||||||
final result = await apiService.fetchOrganization();
|
final result = await apiService.fetchOrganization();
|
||||||
|
|
||||||
@ -239,6 +244,39 @@ class DynamicItineraryState extends State<DynamicItinerary> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<void> saveSelectedOrgServices(
|
||||||
|
List<Map<String, dynamic>> services,
|
||||||
|
) async {
|
||||||
|
final prefs = await SharedPreferences.getInstance();
|
||||||
|
final jsonString = jsonEncode(services);
|
||||||
|
await prefs.setString("selectedOrgServiceName", jsonString);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future<void> OrgServices() async {
|
||||||
|
print('loadOrgSelectedAlServices');
|
||||||
|
try {
|
||||||
|
List<Map<String, String>> formattedName =
|
||||||
|
selectedOrgServiceIds.map((e) {
|
||||||
|
final id = e['service_id'].toString();
|
||||||
|
|
||||||
|
// find matching service from master list
|
||||||
|
final match = selectedAllServices?.firstWhere(
|
||||||
|
(service) => service['service_id'].toString() == id,
|
||||||
|
orElse: () => {},
|
||||||
|
);
|
||||||
|
|
||||||
|
return {
|
||||||
|
"service_id": id,
|
||||||
|
"name": match.isNotEmpty ? match['name'].toString() : "",
|
||||||
|
};
|
||||||
|
}).toList();
|
||||||
|
await saveSelectedOrgServices(formattedName);
|
||||||
|
print("ServiceformattedName: $formattedName");
|
||||||
|
} catch (e) {
|
||||||
|
print('Error fetching role list: $e');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
List<String> getAllowedServiceNames() {
|
List<String> getAllowedServiceNames() {
|
||||||
print(
|
print(
|
||||||
"DID Updatee changee - $selectedOption $selectedListOption $isSelected $selectedItem $selectedIndex",
|
"DID Updatee changee - $selectedOption $selectedListOption $isSelected $selectedItem $selectedIndex",
|
||||||
@ -336,6 +374,7 @@ class DynamicItineraryState extends State<DynamicItinerary> {
|
|||||||
Future<void> updateSelectedServices() async {
|
Future<void> updateSelectedServices() async {
|
||||||
await loadAllServices();
|
await loadAllServices();
|
||||||
await loadOrgSelectedAlServices();
|
await loadOrgSelectedAlServices();
|
||||||
|
await OrgServices();
|
||||||
|
|
||||||
final allowedServiceNames = getAllowedServiceNames();
|
final allowedServiceNames = getAllowedServiceNames();
|
||||||
|
|
||||||
|
|||||||
@ -22,6 +22,7 @@ import '../../utils/pagination.dart';
|
|||||||
import '../../utils/travelAgent_remarks.dart';
|
import '../../utils/travelAgent_remarks.dart';
|
||||||
import '../../widgets/custom_popup.dart';
|
import '../../widgets/custom_popup.dart';
|
||||||
import '../../widgets/popup_listPlan_action.dart';
|
import '../../widgets/popup_listPlan_action.dart';
|
||||||
|
import '../allTrips/plan_info_mdl.dart';
|
||||||
import '../allTrips/remarks_list.dart';
|
import '../allTrips/remarks_list.dart';
|
||||||
|
|
||||||
class ListPlans extends StatefulWidget {
|
class ListPlans extends StatefulWidget {
|
||||||
@ -1315,6 +1316,34 @@ class _ListPlansState extends State<ListPlans> {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
IconButton(
|
||||||
|
icon: const Icon(
|
||||||
|
Icons
|
||||||
|
.info_outlined,
|
||||||
|
color: Color(
|
||||||
|
0xFF475569,
|
||||||
|
),
|
||||||
|
size: 18,
|
||||||
|
),
|
||||||
|
tooltip:
|
||||||
|
'Trip Info',
|
||||||
|
onPressed: () {
|
||||||
|
showDialog(
|
||||||
|
context:
|
||||||
|
context,
|
||||||
|
builder:
|
||||||
|
(
|
||||||
|
context,
|
||||||
|
) => TripInformation(
|
||||||
|
// planId: plan.planId,
|
||||||
|
planId:
|
||||||
|
plan.planId.toString(),
|
||||||
|
layoutColorForUser:
|
||||||
|
layoutColor!,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -1632,6 +1661,35 @@ class _ListPlansState extends State<ListPlans> {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|
||||||
|
IconButton(
|
||||||
|
icon: const Icon(
|
||||||
|
Icons
|
||||||
|
.info_outlined,
|
||||||
|
color: Color(
|
||||||
|
0xFF475569,
|
||||||
|
),
|
||||||
|
size: 18,
|
||||||
|
),
|
||||||
|
tooltip:
|
||||||
|
'Trip Info',
|
||||||
|
onPressed: () {
|
||||||
|
showDialog(
|
||||||
|
context:
|
||||||
|
context,
|
||||||
|
builder:
|
||||||
|
(
|
||||||
|
context,
|
||||||
|
) => TripInformation(
|
||||||
|
// planId: plan.planId,
|
||||||
|
planId:
|
||||||
|
plan.planId.toString(),
|
||||||
|
layoutColorForUser:
|
||||||
|
layoutColor!,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -44,7 +44,18 @@ class _PolicyState extends State<Policy> {
|
|||||||
|
|
||||||
final ApiService apiService = ApiService();
|
final ApiService apiService = ApiService();
|
||||||
|
|
||||||
// List<String> services = [];
|
List<String> definedServices = [
|
||||||
|
'Flight',
|
||||||
|
'Accomodation',
|
||||||
|
'Forex',
|
||||||
|
'Insurance',
|
||||||
|
'Visa',
|
||||||
|
'Miscellaneous',
|
||||||
|
'Taxi',
|
||||||
|
'Bus',
|
||||||
|
'Train',
|
||||||
|
];
|
||||||
|
|
||||||
List<Map<String, dynamic>> services = [];
|
List<Map<String, dynamic>> services = [];
|
||||||
String? servicesJson;
|
String? servicesJson;
|
||||||
Color? layoutColor;
|
Color? layoutColor;
|
||||||
@ -297,16 +308,18 @@ class _PolicyState extends State<Policy> {
|
|||||||
);
|
);
|
||||||
print("exisitingService ${exisitingService}");
|
print("exisitingService ${exisitingService}");
|
||||||
|
|
||||||
final filtered =
|
// final filtered =
|
||||||
exisitingService!
|
// exisitingService!
|
||||||
.where(
|
// .where(
|
||||||
(service) =>
|
// (service) =>
|
||||||
selectedIds.contains(service['service_id'].toString()),
|
// selectedIds.contains(service['service_id'].toString()),
|
||||||
)
|
// )
|
||||||
.toList();
|
// .toList();
|
||||||
|
|
||||||
setState(() {
|
setState(() {
|
||||||
ServicesChoosed = filtered;
|
// ServicesChoosed = exisitingService;
|
||||||
|
ServicesChoosed = selectedAllServices;
|
||||||
|
// ServicesChoosed = filtered;
|
||||||
});
|
});
|
||||||
print("298 ServicesChoosed ${ServicesChoosed}");
|
print("298 ServicesChoosed ${ServicesChoosed}");
|
||||||
|
|
||||||
@ -357,17 +370,18 @@ class _PolicyState extends State<Policy> {
|
|||||||
|
|
||||||
print("Filtered Selected Services Added to Policy: $ServicesChoosed");
|
print("Filtered Selected Services Added to Policy: $ServicesChoosed");
|
||||||
} else {
|
} else {
|
||||||
final filtered =
|
// final filtered =
|
||||||
selectedAllServices!
|
// selectedAllServices!
|
||||||
.where(
|
// .where(
|
||||||
(service) =>
|
// (service) =>
|
||||||
selectedIds.contains(service['service_id'].toString()),
|
// selectedIds.contains(service['service_id'].toString()),
|
||||||
)
|
// )
|
||||||
.toList();
|
// .toList();
|
||||||
|
|
||||||
print("ServicesChoosedYY: $ServicesChoosed");
|
print("ServicesChoosedYY: $ServicesChoosed");
|
||||||
setState(() {
|
setState(() {
|
||||||
ServicesChoosed = filtered;
|
ServicesChoosed = selectedAllServices;
|
||||||
|
// ServicesChoosed = filtered;
|
||||||
// services = ServicesChoosed!
|
// services = ServicesChoosed!
|
||||||
// .map((service) => service['name'].toString())
|
// .map((service) => service['name'].toString())
|
||||||
// .toList();
|
// .toList();
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
* File : web/index.html - change below
|
* File : web/index.html - change below
|
||||||
* <base href="/adfactor/"> (or) <base href="/adfactor/"> replaced to <base href="/tstat/">
|
* <base href="/adfactor/"> (or) <base href="/adfactor/"> replaced to <base href="/tstat/">
|
||||||
* Check File : App.dart -> line 37 need to uncomment it "SemanticsBinding" **/
|
* Check File : App.dart -> line 37 need to uncomment it "SemanticsBinding" **/
|
||||||
// const String apiUrl = 'https://apitest.tripapprovaltool.com/tstat_be';
|
const String apiUrl = 'https://apitest.tripapprovaltool.com/tstat_be';
|
||||||
|
|
||||||
/** Note : TSTAT UAT BE URL
|
/** Note : TSTAT UAT BE URL
|
||||||
* incase "adfactor" or "aujas" href means changed to "tstat"
|
* incase "adfactor" or "aujas" href means changed to "tstat"
|
||||||
@ -33,4 +33,4 @@
|
|||||||
* incase "tstat" or "adfactor" href means changed to "aujas"
|
* incase "tstat" or "adfactor" href means changed to "aujas"
|
||||||
* File : web/index.html - change below
|
* File : web/index.html - change below
|
||||||
* <base href="/tstat/"> (or) <base href="/adfactor/"> replaced to <base href="/aujas/"> **/
|
* <base href="/tstat/"> (or) <base href="/adfactor/"> replaced to <base href="/aujas/"> **/
|
||||||
const String apiUrl = 'https://tripapprovaltool.com/aujas_be';
|
// const String apiUrl = 'https://tripapprovaltool.com/aujas_be';
|
||||||
|
|||||||
@ -38,8 +38,44 @@ class ApiService {
|
|||||||
|
|
||||||
// userRole = userData['role'];
|
// userRole = userData['role'];
|
||||||
|
|
||||||
print("userData - $userData");
|
print("store1userData - $userData");
|
||||||
print("userData11 - ${userData['role']}");
|
print("store2userData11 - ${userData['role']}");
|
||||||
|
// print("userData12 - $userRole");
|
||||||
|
}
|
||||||
|
|
||||||
|
await getOrganizationData();
|
||||||
|
} catch (e) {
|
||||||
|
print('Error decoding token: $e');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Future<void> storeTripUserDetails(String token) async {
|
||||||
|
try {
|
||||||
|
final parts = token.split('.');
|
||||||
|
if (parts.length != 3) throw Exception('Invalid token format');
|
||||||
|
|
||||||
|
final payload = json.decode(
|
||||||
|
utf8.decode(base64Url.decode(base64Url.normalize(parts[1]))),
|
||||||
|
);
|
||||||
|
|
||||||
|
final userData = payload['data'];
|
||||||
|
|
||||||
|
final prefs = await SharedPreferences.getInstance();
|
||||||
|
await prefs.setString('trip_auth_token', token);
|
||||||
|
await prefs.setString(
|
||||||
|
'trip_user_data',
|
||||||
|
jsonEncode(userData),
|
||||||
|
); // Store full user data
|
||||||
|
|
||||||
|
if (userData != null) {
|
||||||
|
final pref = await SharedPreferences.getInstance();
|
||||||
|
await pref.setString('trip_auth_token', token);
|
||||||
|
await pref.setString('trip_user_data', jsonEncode(userData));
|
||||||
|
|
||||||
|
// userRole = userData['role'];
|
||||||
|
|
||||||
|
print("storetrip_userData - $userData");
|
||||||
|
print("storetrip_2userData11 - ${userData['role']}");
|
||||||
// print("userData12 - $userRole");
|
// print("userData12 - $userRole");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -677,6 +713,37 @@ class ApiService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<void> handleTripWiseToken(String userId) async {
|
||||||
|
final String apiUrldata =
|
||||||
|
'$apiUrl/api/user/refreshUserToken?user_id=$userId';
|
||||||
|
print("API URL: $userId");
|
||||||
|
// final token = await getToken();
|
||||||
|
|
||||||
|
final token = await getToken();
|
||||||
|
|
||||||
|
final response = await http.get(
|
||||||
|
Uri.parse(apiUrldata),
|
||||||
|
headers: {
|
||||||
|
'Authorization': 'Bearer $token',
|
||||||
|
'Content-Type': 'application/json',
|
||||||
|
'app-signature': 'ts-traveltool-2025-signature-123456',
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
||||||
|
if (response.statusCode == 200) {
|
||||||
|
final data = jsonDecode(response.body);
|
||||||
|
print("data- $data");
|
||||||
|
|
||||||
|
final token = data['token']; // Assuming the token is in response
|
||||||
|
// final userId = data['user_id'].toString();
|
||||||
|
|
||||||
|
print("Token - $token");
|
||||||
|
await storeTripUserDetails(token);
|
||||||
|
} else {
|
||||||
|
throw Exception('Failed to load plans');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static Future<void> viewPlan(
|
static Future<void> viewPlan(
|
||||||
BuildContext context,
|
BuildContext context,
|
||||||
String planId, {
|
String planId, {
|
||||||
|
|||||||
@ -79,6 +79,16 @@ Future<String?> getRoleUser() async {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<List<Map<String, dynamic>>> getOrgServicesName() async {
|
||||||
|
final prefs = await SharedPreferences.getInstance();
|
||||||
|
final jsonString = prefs.getString("selectedOrgServiceName");
|
||||||
|
|
||||||
|
if (jsonString != null) {
|
||||||
|
return List<Map<String, dynamic>>.from(jsonDecode(jsonString));
|
||||||
|
}
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
Future<String?> getForexCardNumber() async {
|
Future<String?> getForexCardNumber() async {
|
||||||
final prefs = await SharedPreferences.getInstance();
|
final prefs = await SharedPreferences.getInstance();
|
||||||
final String? userDataString = prefs.getString('user_data');
|
final String? userDataString = prefs.getString('user_data');
|
||||||
@ -110,6 +120,23 @@ Future<String?> getTripPlanAction() async {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<String?> getTripPlanActionFromSelectedUsr() async {
|
||||||
|
final prefs = await SharedPreferences.getInstance();
|
||||||
|
// final String? userDataString = prefs.getString('user_data');
|
||||||
|
final String? userDataString = prefs.getString('trip_user_data');
|
||||||
|
|
||||||
|
if (userDataString != null) {
|
||||||
|
try {
|
||||||
|
final Map<String, dynamic> userData = jsonDecode(userDataString);
|
||||||
|
print("TRIPUSRDATAT - $userData");
|
||||||
|
return userData["plan_action"]?.toString();
|
||||||
|
} catch (e) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
Future<List<Map<String, dynamic>>?> getUserServices() async {
|
Future<List<Map<String, dynamic>>?> getUserServices() async {
|
||||||
final prefs = await SharedPreferences.getInstance();
|
final prefs = await SharedPreferences.getInstance();
|
||||||
final String? userDataString = prefs.getString('user_data');
|
final String? userDataString = prefs.getString('user_data');
|
||||||
@ -128,3 +155,22 @@ Future<List<Map<String, dynamic>>?> getUserServices() async {
|
|||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<List<dynamic>?> fetchTripUserServices() async {
|
||||||
|
String? orgId = await getOrgId();
|
||||||
|
|
||||||
|
final prefs = await SharedPreferences.getInstance();
|
||||||
|
final String? userDataString = prefs.getString('trip_user_data');
|
||||||
|
|
||||||
|
if (userDataString != null) {
|
||||||
|
try {
|
||||||
|
final Map<String, dynamic> userData = jsonDecode(userDataString);
|
||||||
|
print("TRIPUSRSERVICE - $userData");
|
||||||
|
return userData["service"]; // this is a List<dynamic>
|
||||||
|
} catch (e) {
|
||||||
|
print("Error decoding trip_user_data: $e");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import 'package:flutter/cupertino.dart';
|
import 'package:flutter/cupertino.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
import '../Screens/allTrips/plan_info_mdl.dart';
|
||||||
import '../Screens/allTrips/remarks_list.dart';
|
import '../Screens/allTrips/remarks_list.dart';
|
||||||
import '../data/models/plan.dart';
|
import '../data/models/plan.dart';
|
||||||
import '../services/apiService.dart';
|
import '../services/apiService.dart';
|
||||||
@ -133,6 +134,26 @@ class PlanPopupMenu extends StatelessWidget {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|
||||||
|
IconButton(
|
||||||
|
icon: const Icon(
|
||||||
|
Icons.info_outlined,
|
||||||
|
color: Color(0xFF475569),
|
||||||
|
size: 18,
|
||||||
|
),
|
||||||
|
tooltip: 'Trip Info',
|
||||||
|
onPressed: () {
|
||||||
|
showDialog(
|
||||||
|
context: context,
|
||||||
|
builder:
|
||||||
|
(context) => TripInformation(
|
||||||
|
// planId: plan.planId,
|
||||||
|
planId: plan.planId.toString(),
|
||||||
|
layoutColorForUser: layoutColor!,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
232
pubspec.lock
232
pubspec.lock
@ -1,6 +1,22 @@
|
|||||||
# Generated by pub
|
# Generated by pub
|
||||||
# See https://dart.dev/tools/pub/glossary#lockfile
|
# See https://dart.dev/tools/pub/glossary#lockfile
|
||||||
packages:
|
packages:
|
||||||
|
_fe_analyzer_shared:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: _fe_analyzer_shared
|
||||||
|
sha256: da0d9209ca76bde579f2da330aeb9df62b6319c834fa7baae052021b0462401f
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "85.0.0"
|
||||||
|
analyzer:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: analyzer
|
||||||
|
sha256: "974859dc0ff5f37bc4313244b3218c791810d03ab3470a579580279ba971a48d"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "7.7.1"
|
||||||
archive:
|
archive:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -65,6 +81,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.0.4"
|
version: "2.0.4"
|
||||||
|
cli_config:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: cli_config
|
||||||
|
sha256: ac20a183a07002b700f0c25e61b7ee46b23c309d76ab7b7640a028f18e4d99ec
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "0.2.0"
|
||||||
cli_util:
|
cli_util:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -89,6 +113,22 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.19.1"
|
version: "1.19.1"
|
||||||
|
convert:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: convert
|
||||||
|
sha256: b30acd5944035672bc15c6b7a8b47d773e41e2f17de064350988c5d02adb1c68
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.1.2"
|
||||||
|
coverage:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: coverage
|
||||||
|
sha256: "5da775aa218eaf2151c721b16c01c7676fbfdd99cebba2bf64e8b807a28ff94d"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.15.0"
|
||||||
cross_file:
|
cross_file:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -355,6 +395,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "11.0.0"
|
version: "11.0.0"
|
||||||
|
flutter_riverpod:
|
||||||
|
dependency: "direct main"
|
||||||
|
description:
|
||||||
|
name: flutter_riverpod
|
||||||
|
sha256: ca2480512a8e840291325249f4857e363ffa5d1b77b132e189c9313a9d9fb9e0
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.0.0"
|
||||||
flutter_test:
|
flutter_test:
|
||||||
dependency: "direct dev"
|
dependency: "direct dev"
|
||||||
description: flutter
|
description: flutter
|
||||||
@ -373,6 +421,22 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "8.2.12"
|
version: "8.2.12"
|
||||||
|
frontend_server_client:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: frontend_server_client
|
||||||
|
sha256: f64a0333a82f30b0cca061bc3d143813a486dc086b574bfb233b7c1372427694
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "4.0.0"
|
||||||
|
glob:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: glob
|
||||||
|
sha256: c3f1ee72c96f8f78935e18aa8cecced9ab132419e8625dc187e1c2408efc20de
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "2.1.3"
|
||||||
go_router:
|
go_router:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
@ -421,6 +485,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.4.0"
|
version: "1.4.0"
|
||||||
|
http_multi_server:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: http_multi_server
|
||||||
|
sha256: aa6199f908078bb1c5efb8d8638d4ae191aac11b311132c3ef48ce352fb52ef8
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.2.2"
|
||||||
http_parser:
|
http_parser:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
@ -509,6 +581,22 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.20.2"
|
version: "0.20.2"
|
||||||
|
io:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: io
|
||||||
|
sha256: dfd5a80599cf0165756e3181807ed3e77daf6dd4137caaad72d0b7931597650b
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.0.5"
|
||||||
|
js:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: js
|
||||||
|
sha256: "53385261521cc4a0c4658fd0ad07a7d14591cf8fc33abbceae306ddb974888dc"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "0.7.2"
|
||||||
json_annotation:
|
json_annotation:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -621,6 +709,22 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.0.0"
|
version: "1.0.0"
|
||||||
|
node_preamble:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: node_preamble
|
||||||
|
sha256: "6e7eac89047ab8a8d26cf16127b5ed26de65209847630400f9aefd7cd5c730db"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "2.0.2"
|
||||||
|
package_config:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: package_config
|
||||||
|
sha256: f096c55ebb7deb7e384101542bfba8c52696c1b56fca2eb62827989ef2353bbc
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "2.2.0"
|
||||||
path:
|
path:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -709,6 +813,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.1.8"
|
version: "2.1.8"
|
||||||
|
pool:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: pool
|
||||||
|
sha256: "978783255c543aa3586a1b3c21f6e9d720eb315376a915872c61ef8b5c20177d"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.5.2"
|
||||||
posix:
|
posix:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -725,6 +837,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "6.1.5"
|
version: "6.1.5"
|
||||||
|
pub_semver:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: pub_semver
|
||||||
|
sha256: "5bfcf68ca79ef689f8990d1160781b4bad40a3bd5e5218ad4076ddb7f4081585"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "2.2.0"
|
||||||
quill_native_bridge:
|
quill_native_bridge:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -813,6 +933,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.7.1"
|
version: "0.7.1"
|
||||||
|
riverpod:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: riverpod
|
||||||
|
sha256: "135723ec44dfba141bc4696224048a408336e794228a0117439e7ad0a8be6d05"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.0.0"
|
||||||
shared_preferences:
|
shared_preferences:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
@ -869,11 +997,59 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.4.1"
|
version: "2.4.1"
|
||||||
|
shelf:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: shelf
|
||||||
|
sha256: e7dd780a7ffb623c57850b33f43309312fc863fb6aa3d276a754bb299839ef12
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.4.2"
|
||||||
|
shelf_packages_handler:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: shelf_packages_handler
|
||||||
|
sha256: "89f967eca29607c933ba9571d838be31d67f53f6e4ee15147d5dc2934fee1b1e"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.0.2"
|
||||||
|
shelf_static:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: shelf_static
|
||||||
|
sha256: c87c3875f91262785dade62d135760c2c69cb217ac759485334c5857ad89f6e3
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.1.3"
|
||||||
|
shelf_web_socket:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: shelf_web_socket
|
||||||
|
sha256: "3632775c8e90d6c9712f883e633716432a27758216dfb61bd86a8321c0580925"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.0.0"
|
||||||
sky_engine:
|
sky_engine:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description: flutter
|
description: flutter
|
||||||
source: sdk
|
source: sdk
|
||||||
version: "0.0.0"
|
version: "0.0.0"
|
||||||
|
source_map_stack_trace:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: source_map_stack_trace
|
||||||
|
sha256: c0713a43e323c3302c2abe2a1cc89aa057a387101ebd280371d6a6c9fa68516b
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "2.1.2"
|
||||||
|
source_maps:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: source_maps
|
||||||
|
sha256: "190222579a448b03896e0ca6eca5998fa810fda630c1d65e2f78b3f638f54812"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "0.10.13"
|
||||||
source_span:
|
source_span:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -890,6 +1066,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.12.1"
|
version: "1.12.1"
|
||||||
|
state_notifier:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: state_notifier
|
||||||
|
sha256: b8677376aa54f2d7c58280d5a007f9e8774f1968d1fb1c096adcb4792fba29bb
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.0.0"
|
||||||
stream_channel:
|
stream_channel:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -922,6 +1106,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.2.2"
|
version: "1.2.2"
|
||||||
|
test:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: test
|
||||||
|
sha256: "301b213cd241ca982e9ba50266bd3f5bd1ea33f1455554c5abb85d1be0e2d87e"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.25.15"
|
||||||
test_api:
|
test_api:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -930,6 +1122,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.7.4"
|
version: "0.7.4"
|
||||||
|
test_core:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: test_core
|
||||||
|
sha256: "84d17c3486c8dfdbe5e12a50c8ae176d15e2a771b96909a9442b40173649ccaa"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "0.6.8"
|
||||||
typed_data:
|
typed_data:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
@ -1082,6 +1282,14 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.0.5"
|
version: "1.0.5"
|
||||||
|
watcher:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: watcher
|
||||||
|
sha256: "5bf046f41320ac97a469d506261797f35254fa61c641741ef32dacda98b7d39c"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.1.3"
|
||||||
web:
|
web:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
@ -1090,6 +1298,30 @@ packages:
|
|||||||
url: "https://pub.dev"
|
url: "https://pub.dev"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.1.1"
|
version: "1.1.1"
|
||||||
|
web_socket:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: web_socket
|
||||||
|
sha256: "34d64019aa8e36bf9842ac014bb5d2f5586ca73df5e4d9bf5c936975cae6982c"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.0.1"
|
||||||
|
web_socket_channel:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: web_socket_channel
|
||||||
|
sha256: d645757fb0f4773d602444000a8131ff5d48c9e47adfe9772652dd1a4f2d45c8
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "3.0.3"
|
||||||
|
webkit_inspection_protocol:
|
||||||
|
dependency: transitive
|
||||||
|
description:
|
||||||
|
name: webkit_inspection_protocol
|
||||||
|
sha256: "87d3f2333bb240704cd3f1c6b5b7acd8a10e7f0bc28c28dcf14e782014f4a572"
|
||||||
|
url: "https://pub.dev"
|
||||||
|
source: hosted
|
||||||
|
version: "1.2.1"
|
||||||
win32:
|
win32:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|||||||
@ -64,6 +64,7 @@ dependencies:
|
|||||||
flutter_quill_delta_from_html: ^1.5.2
|
flutter_quill_delta_from_html: ^1.5.2
|
||||||
flutter_launcher_icons: ^0.14.4
|
flutter_launcher_icons: ^0.14.4
|
||||||
dotted_border: ^3.1.0
|
dotted_border: ^3.1.0
|
||||||
|
flutter_riverpod: ^3.0.0
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -14,7 +14,7 @@
|
|||||||
This is a placeholder for base href that will be replaced by the value of
|
This is a placeholder for base href that will be replaced by the value of
|
||||||
the `--base-href` argument provided to `flutter build`.
|
the `--base-href` argument provided to `flutter build`.
|
||||||
-->
|
-->
|
||||||
<base href="/aujas/">
|
<base href="/tstat/">
|
||||||
|
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
|
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user