# 🗺️ How to Navigate to Boundary Commission Features

## Quick Navigation Guide

### Step 1: Login
1. Open your browser
2. Go to: `http://localhost:3000/login`
3. Enter credentials:
   - Username: `admin`
   - Password: `admin123` (or your password)

### Step 2: Access Boundary Commission
After logging in, you'll be on the Dashboard. In the **left sidebar**, you'll see:

```
🏠 Overview
📄 Transaction
🏠 Property
👥 Party
👤 Applicant
📐 Survey Plan
🗺️ Boundary Commission  ← Click here!
🛡️ Users & Roles
📊 Data Centric Center
```

**Click on "🗺️ Boundary Commission"**

### Step 3: Use Boundary Commission Features

#### Option A: Search Boundaries
1. You'll see a search form with fields:
   - Boundary Number (e.g., "BND-001")
   - Boundary Name (e.g., "Plateau-Benue")
   - Boundary Type (dropdown)
   - State (e.g., "Plateau State")
   - Status (dropdown)

2. Fill in search criteria and click **"🔍 Search Boundaries"**

3. Results appear below showing:
   - Boundary name
   - States involved
   - Type and status
   - Click any result to view details

#### Option B: Search Disputes
1. Switch to "Disputes" tab (if available) or search for disputes
2. Fill in search criteria:
   - Dispute Number (e.g., "DSP-001")
   - Title
   - Status
   - Priority
   - State
   - Claimants

3. Click **"⚖️ Search Disputes"**

4. Results show dispute cases - click to view details

### Step 4: View Details

#### Boundary Detail Page
When you click a boundary, you'll see:
- **Basic Information**: Type, states, length, established date
- **Coordinates**: GPS coordinates table
- **Markers**: Physical boundary markers
- **Active Disputes**: Linked disputes
- **Recent Surveys**: Survey data
- **Related Treaties**: Boundary agreements
- **Documents**: Uploaded documents (click to view PDF)

#### Dispute Detail Page
When you click a dispute, you'll see:
- **Dispute Information**: Claimants, status, priority
- **Related Boundary**: Link to boundary
- **Evidence**: Documents and evidence
- **Stakeholders**: Parties involved
- **Timeline**: Event history
- **Documents**: Evidence documents (click to view PDF)

### Step 5: View Documents
1. On any detail page, scroll to **"Documents"** section
2. You'll see a list of documents with:
   - Document title
   - Type and page count
   - Upload date
   - "View PDF →" button

3. **Click on any document** or the "View PDF →" button
4. PDF opens in a modal (same as Aumentum document viewer)

## Direct URLs

If you want to access pages directly:

### Boundary Detail:
```
http://localhost:3000/boundary/BND-001
http://localhost:3000/boundary/BND-002
http://localhost:3000/boundary/BND-003
```

### Dispute Detail:
```
http://localhost:3000/dispute/DSP-001
http://localhost:3000/dispute/DSP-002
```

### Dashboard with Boundary Section:
```
http://localhost:3000/dashboard?section=boundary
```

## Sample Data Available

You can test with these document numbers:

**Boundaries:**
- `BND-001` - Plateau-Benue Interstate Boundary
- `BND-002` - Plateau-Kaduna Interstate Boundary
- `BND-003` - Plateau-Nasarawa Interstate Boundary
- `BND-004` - Jos North-Jos South Administrative Boundary
- `BND-005` - Plateau-Cameroon International Boundary

**Disputes:**
- `DSP-001` - Plateau-Benue Land Dispute at Wase Area
- `DSP-002` - Jos North-South Administrative Boundary Dispute
- `DSP-003` - General Interstate Boundary Clarification

## Troubleshooting

### If "Boundary Commission" doesn't appear in sidebar:
1. Make sure the Next.js server is running: `npm run dev`
2. Check that you're logged in
3. Refresh the page

### If search returns no results:
- The database has sample data, so searches should work
- Try searching for "Plateau" or "BND-001"
- Check that the API server is running on port 8001

### If documents don't show:
- Documents section only appears if documents are linked
- You can upload documents using the upload API endpoint
- Currently, no documents are linked to sample boundaries/disputes

## Next Steps

1. **Upload Documents**: Use the upload API to add documents to boundaries/disputes
2. **View PDFs**: Once documents are uploaded, click to view them
3. **Create New Records**: Use the API to create new boundaries or disputes

