You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ResQTrack application now uses OpenStreetMap with Leaflet.js for enhanced map functionality. This implementation is completely free and requires no API keys.
6
+
7
+
### 1. Features Added
8
+
9
+
#### Map Improvements
10
+
-**OpenStreetMap Integration**: Uses free OpenStreetMap tiles with Leaflet.js
11
+
-**No API Key Required**: Completely free to use with no billing concerns
12
+
-**Enhanced Geocoding**: Uses Nominatim API for accurate location resolution
13
+
-**Custom Markers**: Hospital and police station markers with custom icons
14
+
-**Interactive Popups**: Click on markers to see detailed information
15
+
-**Location Picker**: Interactive map for selecting precise locations
16
+
17
+
#### Data Management Features
18
+
-**CSV File Management**: View and delete uploaded CSV files
19
+
-**Bulk Data Clearing**: Clear all data for specific service types (hospitals, police stations, etc.)
20
+
-**Individual Entry Deletion**: Delete specific entries from emergency services
21
+
-**File Upload Tracking**: Monitor uploaded files with size and modification date
22
+
23
+
### 2. New API Endpoints
24
+
25
+
The following new endpoints have been added to the backend:
26
+
27
+
-`GET /data/uploaded-files` - List uploaded CSV files
28
+
-`DELETE /data/delete-file` - Delete a specific CSV file
29
+
-`DELETE /data/clear-data/<service_type>` - Clear all data for a service type
30
+
-`DELETE /data/delete-entry/<service_type>/<entry_id>` - Delete a specific entry
31
+
32
+
### 3. Usage
33
+
34
+
#### Location Picker (`location-picker.html`)
35
+
- Search for locations using Nominatim geocoding
36
+
- Use device location with geolocation API
37
+
- Click on map to select precise coordinates
38
+
- Copy coordinates or send to backend
39
+
- Mobile-friendly responsive design
40
+
41
+
#### Hospitals Page
42
+
- Switch between List View and Map View
43
+
- Click on map markers to see hospital details
44
+
- Hospitals are geocoded automatically from their location field
45
+
46
+
#### Admin Dashboard
47
+
- View all emergency services on interactive maps
48
+
- Add new locations using the location picker map
49
+
- Manage uploaded CSV files
50
+
- Clear data or delete individual entries
51
+
52
+
#### Data Dashboard
53
+
- Import CSV files for different service types
54
+
- View uploaded files and delete them
55
+
- Clear all data for specific service types
56
+
- Delete individual emergency service entries
57
+
58
+
### 4. Technical Implementation
59
+
60
+
#### Libraries Used
61
+
-**Leaflet.js**: Open-source JavaScript library for interactive maps
62
+
-**OpenStreetMap**: Free, open-source map data
63
+
-**Nominatim**: Free geocoding service for OpenStreetMap
64
+
65
+
#### Configuration
66
+
The map settings are configured in `frontend/config.js`:
67
+
```javascript
68
+
constCONFIG= {
69
+
MAP_DEFAULT_CENTER: { lat:20.5937, lng:78.9629 }, // India center
0 commit comments