added nevigation for project teams
This commit is contained in:
parent
c96aa42e81
commit
307b3ceb96
@ -14,6 +14,7 @@ import 'package:on_field_work/model/employees/employee_model.dart';
|
|||||||
import 'package:on_field_work/view/service_project/jobs_tab.dart';
|
import 'package:on_field_work/view/service_project/jobs_tab.dart';
|
||||||
import 'package:on_field_work/helpers/widgets/my_refresh_indicator.dart';
|
import 'package:on_field_work/helpers/widgets/my_refresh_indicator.dart';
|
||||||
import 'package:on_field_work/helpers/widgets/pill_tab_bar.dart';
|
import 'package:on_field_work/helpers/widgets/pill_tab_bar.dart';
|
||||||
|
import 'package:on_field_work/view/employees/employee_profile_screen.dart';
|
||||||
|
|
||||||
class ServiceProjectDetailsScreen extends StatefulWidget {
|
class ServiceProjectDetailsScreen extends StatefulWidget {
|
||||||
final String projectId;
|
final String projectId;
|
||||||
@ -385,36 +386,44 @@ class _ServiceProjectDetailsScreenState
|
|||||||
const Divider(height: 20, thickness: 1),
|
const Divider(height: 20, thickness: 1),
|
||||||
// List of team members inside this role card
|
// List of team members inside this role card
|
||||||
...teamMembers.map((team) {
|
...teamMembers.map((team) {
|
||||||
return Padding(
|
return InkWell(
|
||||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
onTap: () {
|
||||||
child: Row(
|
// NAVIGATION TO EMPLOYEE DETAILS SCREEN
|
||||||
children: [
|
Get.to(() => EmployeeProfilePage(
|
||||||
Avatar(
|
employeeId: team.employee.id,
|
||||||
firstName: team.employee.firstName,
|
));
|
||||||
lastName: team.employee.lastName,
|
},
|
||||||
size: 32,
|
child: Padding(
|
||||||
imageUrl:
|
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||||
(team.employee.photo?.isNotEmpty ?? false)
|
child: Row(
|
||||||
? team.employee.photo
|
children: [
|
||||||
: null,
|
Avatar(
|
||||||
),
|
firstName: team.employee.firstName,
|
||||||
MySpacing.width(12),
|
lastName: team.employee.lastName,
|
||||||
Expanded(
|
size: 32,
|
||||||
child: Column(
|
imageUrl:
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
(team.employee.photo?.isNotEmpty ?? false)
|
||||||
children: [
|
? team.employee.photo
|
||||||
MyText.titleMedium(
|
: null,
|
||||||
"${team.employee.firstName} ${team.employee.lastName}",
|
|
||||||
fontWeight: 600,
|
|
||||||
),
|
|
||||||
MyText.bodySmall(
|
|
||||||
"Status: ${team.isActive ? 'Active' : 'Inactive'}",
|
|
||||||
color: Colors.grey[700],
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
MySpacing.width(12),
|
||||||
],
|
Expanded(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
MyText.titleMedium(
|
||||||
|
"${team.employee.firstName} ${team.employee.lastName}",
|
||||||
|
fontWeight: 600,
|
||||||
|
),
|
||||||
|
MyText.bodySmall(
|
||||||
|
"Status: ${team.isActive ? 'Active' : 'Inactive'}",
|
||||||
|
color: Colors.grey[700],
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}).toList(),
|
}).toList(),
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user