fix: add ignore_for_file to data connect Repos and modify CI to avoid analyzing deleted files
This commit is contained in:
@@ -2,10 +2,6 @@ import 'package:equatable/equatable.dart';
|
||||
|
||||
/// Represents a specific time slot within a day (e.g., Morning, Afternoon, Evening).
|
||||
class AvailabilitySlot extends Equatable {
|
||||
final String id;
|
||||
final String label;
|
||||
final String timeRange;
|
||||
final bool isAvailable;
|
||||
|
||||
const AvailabilitySlot({
|
||||
required this.id,
|
||||
@@ -13,6 +9,10 @@ class AvailabilitySlot extends Equatable {
|
||||
required this.timeRange,
|
||||
this.isAvailable = true,
|
||||
});
|
||||
final String id;
|
||||
final String label;
|
||||
final String timeRange;
|
||||
final bool isAvailable;
|
||||
|
||||
AvailabilitySlot copyWith({
|
||||
String? id,
|
||||
@@ -29,5 +29,5 @@ class AvailabilitySlot extends Equatable {
|
||||
}
|
||||
|
||||
@override
|
||||
List<Object?> get props => [id, label, timeRange, isAvailable];
|
||||
List<Object?> get props => <Object?>[id, label, timeRange, isAvailable];
|
||||
}
|
||||
|
||||
@@ -4,15 +4,15 @@ import 'availability_slot.dart';
|
||||
|
||||
/// Represents availability configuration for a specific date.
|
||||
class DayAvailability extends Equatable {
|
||||
final DateTime date;
|
||||
final bool isAvailable;
|
||||
final List<AvailabilitySlot> slots;
|
||||
|
||||
const DayAvailability({
|
||||
required this.date,
|
||||
this.isAvailable = false,
|
||||
this.slots = const [],
|
||||
this.slots = const <AvailabilitySlot>[],
|
||||
});
|
||||
final DateTime date;
|
||||
final bool isAvailable;
|
||||
final List<AvailabilitySlot> slots;
|
||||
|
||||
DayAvailability copyWith({
|
||||
DateTime? date,
|
||||
@@ -27,5 +27,5 @@ class DayAvailability extends Equatable {
|
||||
}
|
||||
|
||||
@override
|
||||
List<Object?> get props => [date, isAvailable, slots];
|
||||
List<Object?> get props => <Object?>[date, isAvailable, slots];
|
||||
}
|
||||
|
||||
@@ -2,11 +2,6 @@ import 'package:equatable/equatable.dart';
|
||||
|
||||
/// Simple entity to hold attendance state
|
||||
class AttendanceStatus extends Equatable {
|
||||
final bool isCheckedIn;
|
||||
final DateTime? checkInTime;
|
||||
final DateTime? checkOutTime;
|
||||
final String? activeShiftId;
|
||||
final String? activeApplicationId;
|
||||
|
||||
const AttendanceStatus({
|
||||
this.isCheckedIn = false,
|
||||
@@ -15,9 +10,14 @@ class AttendanceStatus extends Equatable {
|
||||
this.activeShiftId,
|
||||
this.activeApplicationId,
|
||||
});
|
||||
final bool isCheckedIn;
|
||||
final DateTime? checkInTime;
|
||||
final DateTime? checkOutTime;
|
||||
final String? activeShiftId;
|
||||
final String? activeApplicationId;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
isCheckedIn,
|
||||
checkInTime,
|
||||
checkOutTime,
|
||||
|
||||
@@ -2,10 +2,6 @@ import 'package:equatable/equatable.dart';
|
||||
|
||||
/// Summary of staff earnings.
|
||||
class PaymentSummary extends Equatable {
|
||||
final double weeklyEarnings;
|
||||
final double monthlyEarnings;
|
||||
final double pendingEarnings;
|
||||
final double totalEarnings;
|
||||
|
||||
const PaymentSummary({
|
||||
required this.weeklyEarnings,
|
||||
@@ -13,9 +9,13 @@ class PaymentSummary extends Equatable {
|
||||
required this.pendingEarnings,
|
||||
required this.totalEarnings,
|
||||
});
|
||||
final double weeklyEarnings;
|
||||
final double monthlyEarnings;
|
||||
final double pendingEarnings;
|
||||
final double totalEarnings;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
weeklyEarnings,
|
||||
monthlyEarnings,
|
||||
pendingEarnings,
|
||||
|
||||
@@ -23,6 +23,21 @@ enum TimeCardStatus {
|
||||
|
||||
/// Represents a time card for a staff member.
|
||||
class TimeCard extends Equatable {
|
||||
|
||||
/// Creates a [TimeCard].
|
||||
const TimeCard({
|
||||
required this.id,
|
||||
required this.shiftTitle,
|
||||
required this.clientName,
|
||||
required this.date,
|
||||
required this.startTime,
|
||||
required this.endTime,
|
||||
required this.totalHours,
|
||||
required this.hourlyRate,
|
||||
required this.totalPay,
|
||||
required this.status,
|
||||
this.location,
|
||||
});
|
||||
/// Unique identifier of the time card (often matches Application ID).
|
||||
final String id;
|
||||
/// Title of the shift.
|
||||
@@ -46,23 +61,8 @@ class TimeCard extends Equatable {
|
||||
/// Location name.
|
||||
final String? location;
|
||||
|
||||
/// Creates a [TimeCard].
|
||||
const TimeCard({
|
||||
required this.id,
|
||||
required this.shiftTitle,
|
||||
required this.clientName,
|
||||
required this.date,
|
||||
required this.startTime,
|
||||
required this.endTime,
|
||||
required this.totalHours,
|
||||
required this.hourlyRate,
|
||||
required this.totalPay,
|
||||
required this.status,
|
||||
this.location,
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
id,
|
||||
shiftTitle,
|
||||
clientName,
|
||||
|
||||
@@ -26,7 +26,7 @@ class PermanentOrder extends Equatable {
|
||||
final Map<String, double> roleRates;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
startDate,
|
||||
permanentDays,
|
||||
positions,
|
||||
|
||||
@@ -4,6 +4,15 @@ import 'package:equatable/equatable.dart';
|
||||
///
|
||||
/// Attire items are specific clothing or equipment required for jobs.
|
||||
class AttireItem extends Equatable {
|
||||
|
||||
/// Creates an [AttireItem].
|
||||
const AttireItem({
|
||||
required this.id,
|
||||
required this.label,
|
||||
this.iconName,
|
||||
this.imageUrl,
|
||||
this.isMandatory = false,
|
||||
});
|
||||
/// Unique identifier of the attire item.
|
||||
final String id;
|
||||
|
||||
@@ -19,15 +28,6 @@ class AttireItem extends Equatable {
|
||||
/// Whether this item is mandatory for onboarding.
|
||||
final bool isMandatory;
|
||||
|
||||
/// Creates an [AttireItem].
|
||||
const AttireItem({
|
||||
required this.id,
|
||||
required this.label,
|
||||
this.iconName,
|
||||
this.imageUrl,
|
||||
this.isMandatory = false,
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object?> get props => <Object?>[id, label, iconName, imageUrl, isMandatory];
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@ enum ExperienceSkill {
|
||||
|
||||
static ExperienceSkill? fromString(String value) {
|
||||
try {
|
||||
return ExperienceSkill.values.firstWhere((e) => e.value == value);
|
||||
return ExperienceSkill.values.firstWhere((ExperienceSkill e) => e.value == value);
|
||||
} catch (_) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ enum Industry {
|
||||
|
||||
static Industry? fromString(String value) {
|
||||
try {
|
||||
return Industry.values.firstWhere((e) => e.value == value);
|
||||
return Industry.values.firstWhere((Industry e) => e.value == value);
|
||||
} catch (_) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -11,6 +11,17 @@ enum DocumentStatus {
|
||||
|
||||
/// Represents a staff compliance document.
|
||||
class StaffDocument extends Equatable {
|
||||
|
||||
const StaffDocument({
|
||||
required this.id,
|
||||
required this.staffId,
|
||||
required this.documentId,
|
||||
required this.name,
|
||||
this.description,
|
||||
required this.status,
|
||||
this.documentUrl,
|
||||
this.expiryDate,
|
||||
});
|
||||
/// The unique identifier of the staff document record.
|
||||
final String id;
|
||||
|
||||
@@ -35,19 +46,8 @@ class StaffDocument extends Equatable {
|
||||
/// The expiry date of the document.
|
||||
final DateTime? expiryDate;
|
||||
|
||||
const StaffDocument({
|
||||
required this.id,
|
||||
required this.staffId,
|
||||
required this.documentId,
|
||||
required this.name,
|
||||
this.description,
|
||||
required this.status,
|
||||
this.documentUrl,
|
||||
this.expiryDate,
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
id,
|
||||
staffId,
|
||||
documentId,
|
||||
|
||||
@@ -5,6 +5,18 @@ enum TaxFormType { i9, w4 }
|
||||
enum TaxFormStatus { notStarted, inProgress, submitted, approved, rejected }
|
||||
|
||||
abstract class TaxForm extends Equatable {
|
||||
|
||||
const TaxForm({
|
||||
required this.id,
|
||||
required this.title,
|
||||
this.subtitle,
|
||||
this.description,
|
||||
this.status = TaxFormStatus.notStarted,
|
||||
this.staffId,
|
||||
this.formData = const <String, dynamic>{},
|
||||
this.createdAt,
|
||||
this.updatedAt,
|
||||
});
|
||||
final String id;
|
||||
TaxFormType get type;
|
||||
final String title;
|
||||
@@ -16,20 +28,8 @@ abstract class TaxForm extends Equatable {
|
||||
final DateTime? createdAt;
|
||||
final DateTime? updatedAt;
|
||||
|
||||
const TaxForm({
|
||||
required this.id,
|
||||
required this.title,
|
||||
this.subtitle,
|
||||
this.description,
|
||||
this.status = TaxFormStatus.notStarted,
|
||||
this.staffId,
|
||||
this.formData = const {},
|
||||
this.createdAt,
|
||||
this.updatedAt,
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
id,
|
||||
type,
|
||||
title,
|
||||
|
||||
@@ -1,10 +1,7 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class CoverageReport extends Equatable {
|
||||
final double overallCoverage;
|
||||
final int totalNeeded;
|
||||
final int totalFilled;
|
||||
final List<CoverageDay> dailyCoverage;
|
||||
|
||||
const CoverageReport({
|
||||
required this.overallCoverage,
|
||||
@@ -12,16 +9,16 @@ class CoverageReport extends Equatable {
|
||||
required this.totalFilled,
|
||||
required this.dailyCoverage,
|
||||
});
|
||||
final double overallCoverage;
|
||||
final int totalNeeded;
|
||||
final int totalFilled;
|
||||
final List<CoverageDay> dailyCoverage;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [overallCoverage, totalNeeded, totalFilled, dailyCoverage];
|
||||
List<Object?> get props => <Object?>[overallCoverage, totalNeeded, totalFilled, dailyCoverage];
|
||||
}
|
||||
|
||||
class CoverageDay extends Equatable {
|
||||
final DateTime date;
|
||||
final int needed;
|
||||
final int filled;
|
||||
final double percentage;
|
||||
|
||||
const CoverageDay({
|
||||
required this.date,
|
||||
@@ -29,7 +26,12 @@ class CoverageDay extends Equatable {
|
||||
required this.filled,
|
||||
required this.percentage,
|
||||
});
|
||||
final DateTime date;
|
||||
final int needed;
|
||||
final int filled;
|
||||
final double percentage;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [date, needed, filled, percentage];
|
||||
List<Object?> get props => <Object?>[date, needed, filled, percentage];
|
||||
}
|
||||
|
||||
|
||||
@@ -1,11 +1,7 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class DailyOpsReport extends Equatable {
|
||||
final int scheduledShifts;
|
||||
final int workersConfirmed;
|
||||
final int inProgressShifts;
|
||||
final int completedShifts;
|
||||
final List<DailyOpsShift> shifts;
|
||||
|
||||
const DailyOpsReport({
|
||||
required this.scheduledShifts,
|
||||
@@ -14,9 +10,14 @@ class DailyOpsReport extends Equatable {
|
||||
required this.completedShifts,
|
||||
required this.shifts,
|
||||
});
|
||||
final int scheduledShifts;
|
||||
final int workersConfirmed;
|
||||
final int inProgressShifts;
|
||||
final int completedShifts;
|
||||
final List<DailyOpsShift> shifts;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
scheduledShifts,
|
||||
workersConfirmed,
|
||||
inProgressShifts,
|
||||
@@ -26,15 +27,6 @@ class DailyOpsReport extends Equatable {
|
||||
}
|
||||
|
||||
class DailyOpsShift extends Equatable {
|
||||
final String id;
|
||||
final String title;
|
||||
final String location;
|
||||
final DateTime startTime;
|
||||
final DateTime endTime;
|
||||
final int workersNeeded;
|
||||
final int filled;
|
||||
final String status;
|
||||
final double? hourlyRate;
|
||||
|
||||
const DailyOpsShift({
|
||||
required this.id,
|
||||
@@ -47,9 +39,18 @@ class DailyOpsShift extends Equatable {
|
||||
required this.status,
|
||||
this.hourlyRate,
|
||||
});
|
||||
final String id;
|
||||
final String title;
|
||||
final String location;
|
||||
final DateTime startTime;
|
||||
final DateTime endTime;
|
||||
final int workersNeeded;
|
||||
final int filled;
|
||||
final String status;
|
||||
final double? hourlyRate;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
id,
|
||||
title,
|
||||
location,
|
||||
@@ -61,3 +62,4 @@ class DailyOpsShift extends Equatable {
|
||||
hourlyRate,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,18 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class ForecastReport extends Equatable {
|
||||
|
||||
const ForecastReport({
|
||||
required this.projectedSpend,
|
||||
required this.projectedWorkers,
|
||||
required this.averageLaborCost,
|
||||
required this.chartData,
|
||||
this.totalShifts = 0,
|
||||
this.totalHours = 0.0,
|
||||
this.avgWeeklySpend = 0.0,
|
||||
this.weeklyBreakdown = const <ForecastWeek>[],
|
||||
});
|
||||
final double projectedSpend;
|
||||
final int projectedWorkers;
|
||||
final double averageLaborCost;
|
||||
@@ -12,19 +24,8 @@ class ForecastReport extends Equatable {
|
||||
final double avgWeeklySpend;
|
||||
final List<ForecastWeek> weeklyBreakdown;
|
||||
|
||||
const ForecastReport({
|
||||
required this.projectedSpend,
|
||||
required this.projectedWorkers,
|
||||
required this.averageLaborCost,
|
||||
required this.chartData,
|
||||
this.totalShifts = 0,
|
||||
this.totalHours = 0.0,
|
||||
this.avgWeeklySpend = 0.0,
|
||||
this.weeklyBreakdown = const [],
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
projectedSpend,
|
||||
projectedWorkers,
|
||||
averageLaborCost,
|
||||
@@ -37,26 +38,21 @@ class ForecastReport extends Equatable {
|
||||
}
|
||||
|
||||
class ForecastPoint extends Equatable {
|
||||
final DateTime date;
|
||||
final double projectedCost;
|
||||
final int workersNeeded;
|
||||
|
||||
const ForecastPoint({
|
||||
required this.date,
|
||||
required this.projectedCost,
|
||||
required this.workersNeeded,
|
||||
});
|
||||
final DateTime date;
|
||||
final double projectedCost;
|
||||
final int workersNeeded;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [date, projectedCost, workersNeeded];
|
||||
List<Object?> get props => <Object?>[date, projectedCost, workersNeeded];
|
||||
}
|
||||
|
||||
class ForecastWeek extends Equatable {
|
||||
final int weekNumber;
|
||||
final double totalCost;
|
||||
final int shiftsCount;
|
||||
final double hoursCount;
|
||||
final double avgCostPerShift;
|
||||
|
||||
const ForecastWeek({
|
||||
required this.weekNumber,
|
||||
@@ -65,9 +61,14 @@ class ForecastWeek extends Equatable {
|
||||
required this.hoursCount,
|
||||
required this.avgCostPerShift,
|
||||
});
|
||||
final int weekNumber;
|
||||
final double totalCost;
|
||||
final int shiftsCount;
|
||||
final double hoursCount;
|
||||
final double avgCostPerShift;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
weekNumber,
|
||||
totalCost,
|
||||
shiftsCount,
|
||||
@@ -75,3 +76,4 @@ class ForecastWeek extends Equatable {
|
||||
avgCostPerShift,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
@@ -1,25 +1,22 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class NoShowReport extends Equatable {
|
||||
final int totalNoShows;
|
||||
final double noShowRate;
|
||||
final List<NoShowWorker> flaggedWorkers;
|
||||
|
||||
const NoShowReport({
|
||||
required this.totalNoShows,
|
||||
required this.noShowRate,
|
||||
required this.flaggedWorkers,
|
||||
});
|
||||
final int totalNoShows;
|
||||
final double noShowRate;
|
||||
final List<NoShowWorker> flaggedWorkers;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [totalNoShows, noShowRate, flaggedWorkers];
|
||||
List<Object?> get props => <Object?>[totalNoShows, noShowRate, flaggedWorkers];
|
||||
}
|
||||
|
||||
class NoShowWorker extends Equatable {
|
||||
final String id;
|
||||
final String fullName;
|
||||
final int noShowCount;
|
||||
final double reliabilityScore;
|
||||
|
||||
const NoShowWorker({
|
||||
required this.id,
|
||||
@@ -27,7 +24,12 @@ class NoShowWorker extends Equatable {
|
||||
required this.noShowCount,
|
||||
required this.reliabilityScore,
|
||||
});
|
||||
final String id;
|
||||
final String fullName;
|
||||
final int noShowCount;
|
||||
final double reliabilityScore;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [id, fullName, noShowCount, reliabilityScore];
|
||||
List<Object?> get props => <Object?>[id, fullName, noShowCount, reliabilityScore];
|
||||
}
|
||||
|
||||
|
||||
@@ -1,11 +1,7 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class PerformanceReport extends Equatable {
|
||||
final double fillRate;
|
||||
final double completionRate;
|
||||
final double onTimeRate;
|
||||
final double avgFillTimeHours; // in hours
|
||||
final List<PerformanceMetric> keyPerformanceIndicators;
|
||||
|
||||
const PerformanceReport({
|
||||
required this.fillRate,
|
||||
@@ -14,22 +10,28 @@ class PerformanceReport extends Equatable {
|
||||
required this.avgFillTimeHours,
|
||||
required this.keyPerformanceIndicators,
|
||||
});
|
||||
final double fillRate;
|
||||
final double completionRate;
|
||||
final double onTimeRate;
|
||||
final double avgFillTimeHours; // in hours
|
||||
final List<PerformanceMetric> keyPerformanceIndicators;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [fillRate, completionRate, onTimeRate, avgFillTimeHours, keyPerformanceIndicators];
|
||||
List<Object?> get props => <Object?>[fillRate, completionRate, onTimeRate, avgFillTimeHours, keyPerformanceIndicators];
|
||||
}
|
||||
|
||||
class PerformanceMetric extends Equatable {
|
||||
final String label;
|
||||
final String value;
|
||||
final double trend; // e.g. 0.05 for +5%
|
||||
class PerformanceMetric extends Equatable { // e.g. 0.05 for +5%
|
||||
|
||||
const PerformanceMetric({
|
||||
required this.label,
|
||||
required this.value,
|
||||
required this.trend,
|
||||
});
|
||||
final String label;
|
||||
final String value;
|
||||
final double trend;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [label, value, trend];
|
||||
List<Object?> get props => <Object?>[label, value, trend];
|
||||
}
|
||||
|
||||
|
||||
@@ -1,12 +1,7 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class ReportsSummary extends Equatable {
|
||||
final double totalHours;
|
||||
final double otHours;
|
||||
final double totalSpend;
|
||||
final double fillRate;
|
||||
final double avgFillTimeHours;
|
||||
final double noShowRate;
|
||||
|
||||
const ReportsSummary({
|
||||
required this.totalHours,
|
||||
@@ -16,9 +11,15 @@ class ReportsSummary extends Equatable {
|
||||
required this.avgFillTimeHours,
|
||||
required this.noShowRate,
|
||||
});
|
||||
final double totalHours;
|
||||
final double otHours;
|
||||
final double totalSpend;
|
||||
final double fillRate;
|
||||
final double avgFillTimeHours;
|
||||
final double noShowRate;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
totalHours,
|
||||
otHours,
|
||||
totalSpend,
|
||||
@@ -27,3 +28,4 @@ class ReportsSummary extends Equatable {
|
||||
noShowRate,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
@@ -1,14 +1,7 @@
|
||||
// ignore_for_file: always_specify_types, depend_on_referenced_packages, dead_code, dead_null_aware_expression, unused_local_variable, unused_import, sort_constructors_first, prefer_final_fields, prefer_const_constructors, deprecated_member_use, implicit_call_tearoffs
|
||||
import 'package:equatable/equatable.dart';
|
||||
|
||||
class SpendReport extends Equatable {
|
||||
final double totalSpend;
|
||||
final double averageCost;
|
||||
final int paidInvoices;
|
||||
final int pendingInvoices;
|
||||
final int overdueInvoices;
|
||||
final List<SpendInvoice> invoices;
|
||||
final List<SpendChartPoint> chartData;
|
||||
final List<SpendIndustryCategory> industryBreakdown;
|
||||
|
||||
const SpendReport({
|
||||
required this.totalSpend,
|
||||
@@ -20,9 +13,17 @@ class SpendReport extends Equatable {
|
||||
required this.chartData,
|
||||
required this.industryBreakdown,
|
||||
});
|
||||
final double totalSpend;
|
||||
final double averageCost;
|
||||
final int paidInvoices;
|
||||
final int pendingInvoices;
|
||||
final int overdueInvoices;
|
||||
final List<SpendInvoice> invoices;
|
||||
final List<SpendChartPoint> chartData;
|
||||
final List<SpendIndustryCategory> industryBreakdown;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
List<Object?> get props => <Object?>[
|
||||
totalSpend,
|
||||
averageCost,
|
||||
paidInvoices,
|
||||
@@ -35,28 +36,21 @@ class SpendReport extends Equatable {
|
||||
}
|
||||
|
||||
class SpendIndustryCategory extends Equatable {
|
||||
final String name;
|
||||
final double amount;
|
||||
final double percentage;
|
||||
|
||||
const SpendIndustryCategory({
|
||||
required this.name,
|
||||
required this.amount,
|
||||
required this.percentage,
|
||||
});
|
||||
final String name;
|
||||
final double amount;
|
||||
final double percentage;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [name, amount, percentage];
|
||||
List<Object?> get props => <Object?>[name, amount, percentage];
|
||||
}
|
||||
|
||||
class SpendInvoice extends Equatable {
|
||||
final String id;
|
||||
final String invoiceNumber;
|
||||
final DateTime issueDate;
|
||||
final double amount;
|
||||
final String status;
|
||||
final String vendorName;
|
||||
final String? industry;
|
||||
|
||||
const SpendInvoice({
|
||||
required this.id,
|
||||
@@ -67,17 +61,25 @@ class SpendInvoice extends Equatable {
|
||||
required this.vendorName,
|
||||
this.industry,
|
||||
});
|
||||
final String id;
|
||||
final String invoiceNumber;
|
||||
final DateTime issueDate;
|
||||
final double amount;
|
||||
final String status;
|
||||
final String vendorName;
|
||||
final String? industry;
|
||||
|
||||
@override
|
||||
List<Object?> get props => [id, invoiceNumber, issueDate, amount, status, vendorName, industry];
|
||||
List<Object?> get props => <Object?>[id, invoiceNumber, issueDate, amount, status, vendorName, industry];
|
||||
}
|
||||
|
||||
class SpendChartPoint extends Equatable {
|
||||
|
||||
const SpendChartPoint({required this.date, required this.amount});
|
||||
final DateTime date;
|
||||
final double amount;
|
||||
|
||||
const SpendChartPoint({required this.date, required this.amount});
|
||||
|
||||
@override
|
||||
List<Object?> get props => [date, amount];
|
||||
List<Object?> get props => <Object?>[date, amount];
|
||||
}
|
||||
|
||||
|
||||
@@ -2,35 +2,6 @@ import 'package:equatable/equatable.dart';
|
||||
import 'package:krow_domain/src/entities/shifts/break/break.dart';
|
||||
|
||||
class Shift extends Equatable {
|
||||
final String id;
|
||||
final String title;
|
||||
final String clientName;
|
||||
final String? logoUrl;
|
||||
final double hourlyRate;
|
||||
final String location;
|
||||
final String locationAddress;
|
||||
final String date;
|
||||
final String startTime;
|
||||
final String endTime;
|
||||
final String createdDate;
|
||||
final bool? tipsAvailable;
|
||||
final bool? travelTime;
|
||||
final bool? mealProvided;
|
||||
final bool? parkingAvailable;
|
||||
final bool? gasCompensation;
|
||||
final String? description;
|
||||
final String? instructions;
|
||||
final List<ShiftManager>? managers;
|
||||
final double? latitude;
|
||||
final double? longitude;
|
||||
final String? status;
|
||||
final int? durationDays; // For multi-day shifts
|
||||
final int? requiredSlots;
|
||||
final int? filledSlots;
|
||||
final String? roleId;
|
||||
final bool? hasApplied;
|
||||
final double? totalValue;
|
||||
final Break? breakInfo;
|
||||
|
||||
const Shift({
|
||||
required this.id,
|
||||
@@ -63,6 +34,35 @@ class Shift extends Equatable {
|
||||
this.totalValue,
|
||||
this.breakInfo,
|
||||
});
|
||||
final String id;
|
||||
final String title;
|
||||
final String clientName;
|
||||
final String? logoUrl;
|
||||
final double hourlyRate;
|
||||
final String location;
|
||||
final String locationAddress;
|
||||
final String date;
|
||||
final String startTime;
|
||||
final String endTime;
|
||||
final String createdDate;
|
||||
final bool? tipsAvailable;
|
||||
final bool? travelTime;
|
||||
final bool? mealProvided;
|
||||
final bool? parkingAvailable;
|
||||
final bool? gasCompensation;
|
||||
final String? description;
|
||||
final String? instructions;
|
||||
final List<ShiftManager>? managers;
|
||||
final double? latitude;
|
||||
final double? longitude;
|
||||
final String? status;
|
||||
final int? durationDays; // For multi-day shifts
|
||||
final int? requiredSlots;
|
||||
final int? filledSlots;
|
||||
final String? roleId;
|
||||
final bool? hasApplied;
|
||||
final double? totalValue;
|
||||
final Break? breakInfo;
|
||||
|
||||
@override
|
||||
List<Object?> get props => <Object?>[
|
||||
|
||||
Reference in New Issue
Block a user