feat: validate user availability
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
>
|
||||
<option value="">Select Category</option>
|
||||
<option value="users" {{if eq .Category "users"}}selected{{end}}>Users & Teams</option>
|
||||
<option value="address" {{if eq .Category "address"}}selected{{end}}>Addresses</option>
|
||||
<option value="addresses" {{if eq .Category "addresses"}}selected{{end}}>Addresses</option>
|
||||
<option value="appointments" {{if eq .Category "appointments"}}selected{{end}}>Appointments</option>
|
||||
<option value="polls" {{if eq .Category "polls"}}selected{{end}}>Polls</option>
|
||||
<option value="availability" {{if eq .Category "availability"}}selected{{end}}>Availability</option>
|
||||
@@ -53,19 +53,19 @@
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Actions -->
|
||||
{{if .Result}}
|
||||
<div class="flex items-center gap-3 text-sm">
|
||||
<div class="text-gray-600">
|
||||
<span>{{.Result.Count}} results</span>
|
||||
</div>
|
||||
<button onclick="exportResults()" class="px-3 py-1.5 bg-green-600 text-white hover:bg-green-700 transition-colors">
|
||||
<!-- <button onclick="exportResults()" class="px-3 py-1.5 bg-green-600 text-white hover:bg-green-700 transition-colors">
|
||||
<i class="fas fa-download mr-1"></i>Export CSV
|
||||
</button>
|
||||
<button onclick="printReport()" class="px-3 py-1.5 bg-blue-600 text-white hover:bg-blue-700 transition-colors">
|
||||
<i class="fas fa-print mr-1"></i>Print
|
||||
</button>
|
||||
</button> -->
|
||||
</div>
|
||||
{{end}}
|
||||
</div>
|
||||
@@ -146,34 +146,32 @@
|
||||
<script>
|
||||
const reportDefinitions = {
|
||||
users: [
|
||||
{ id: 'participation', name: 'Volunteer Participation Rate' },
|
||||
{ id: 'top_performers', name: 'Top Performing Volunteers' },
|
||||
{ id: 'efficiency', name: 'Response-to-Donation Ratio' },
|
||||
{ id: 'coverage', name: 'User Address Coverage' }
|
||||
{ id: 'volunteer_participation_rate', name: 'Volunteer Participation Rate' },
|
||||
{ id: 'top_performing_volunteers', name: 'Top-Performing Volunteers & Team Leads' },
|
||||
{ id: 'response_donation_ratio', name: 'Response-to-Donation Ratio per Volunteer' },
|
||||
{ id: 'user_address_coverage', name: 'User Address Coverage' }
|
||||
],
|
||||
address: [
|
||||
{ id: 'responses_by_address', name: 'Total Responses by Address' },
|
||||
addresses: [
|
||||
{ id: 'poll_responses_by_address', name: 'Total Poll Responses by Address' },
|
||||
{ id: 'donations_by_address', name: 'Total Donations by Address' },
|
||||
{ id: 'street_breakdown', name: 'Street-Level Breakdown' },
|
||||
{ id: 'quadrant_summary', name: 'Quadrant Summary' }
|
||||
{ id: 'street_level_breakdown', name: 'Street-Level Breakdown (Responses & Donations)' },
|
||||
{ id: 'quadrant_summary', name: 'Quadrant-Level Summary (NE, NW, SE, SW)' }
|
||||
],
|
||||
appointments: [
|
||||
{ id: 'upcoming', name: 'Upcoming Appointments' },
|
||||
{ id: 'completion', name: 'Appointments Completion Rate' },
|
||||
{ id: 'geo_distribution', name: 'Appointments by Quadrant' },
|
||||
{ id: 'lead_time', name: 'Average Lead Time' }
|
||||
{ id: 'upcoming_appointments', name: 'Upcoming Appointments per Volunteer/Team Lead' },
|
||||
{ id: 'missed_vs_completed', name: 'Missed vs Completed Appointments' },
|
||||
{ id: 'appointments_by_quadrant', name: 'Appointments by Quadrant/Region' },
|
||||
{ id: 'scheduling_lead_time', name: 'Average Lead Time (Scheduled vs Actual Date)' }
|
||||
],
|
||||
polls: [
|
||||
{ id: 'distribution', name: 'Response Distribution' },
|
||||
{ id: 'average', name: 'Average Poll Response' },
|
||||
{ id: 'response_distribution', name: 'Response Distribution (Yes/No/Neutral)' },
|
||||
{ id: 'average_poll_response', name: 'Average Poll Response (Yes/No %)' },
|
||||
{ id: 'donations_by_poll', name: 'Donations by Poll' },
|
||||
{ id: 'correlation', name: 'Response-to-Donation Correlation' }
|
||||
{ id: 'response_donation_correlation', name: 'Response-to-Donation Correlation' }
|
||||
],
|
||||
availability: [
|
||||
{ id: 'by_date', name: 'Volunteer Availability by Date' },
|
||||
{ id: 'gaps', name: 'Coverage Gaps' },
|
||||
{ id: 'overlaps', name: 'Volunteer Overlaps' },
|
||||
{ id: 'fulfillment', name: 'Volunteer Fulfillment' }
|
||||
{ id: 'volunteer_availability_schedule', name: 'Volunteer Availability by Date Range' },
|
||||
{ id: 'volunteer_fulfillment', name: 'Volunteer Fulfillment (Available vs Actually Worked)' }
|
||||
]
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user