IZERE HIRWA Roger commited on
Commit
923dca5
Β·
1 Parent(s): bf6d969
chatbot/landing.html CHANGED
@@ -33,7 +33,7 @@
33
  <a href="#community">Community</a>
34
  <a href="#resources">Resources</a>
35
  <a href="#about">About</a>
36
- <a href="http://localhost:8000/login" class="nav-cta">Get Started</a>
37
  </div>
38
  </div>
39
  </nav>
@@ -73,7 +73,7 @@
73
  </div>
74
  </div>
75
  <div class="hero-actions">
76
- <a href="http://localhost:8000/login" class="btn-primary">
77
  <i class="fas fa-rocket"></i>
78
  Start Your Journey
79
  </a>
@@ -328,7 +328,7 @@
328
  </div>
329
  </div>
330
  <div class="community-cta">
331
- <a href="http://localhost:8000/login" class="btn-primary large">
332
  <i class="fas fa-sign-in-alt"></i>
333
  Join Community
334
  </a>
@@ -391,11 +391,11 @@
391
  <h2>Ready to Begin Your Mental Health Journey?</h2>
392
  <p>Join thousands of Rwandans who have found support through AIMHSA</p>
393
  <div class="cta-actions">
394
- <a href="http://localhost:8000/login" class="btn-primary large">
395
  <i class="fas fa-rocket"></i>
396
  Start Your Journey Today
397
  </a>
398
- <a href="http://localhost:8000/register" class="btn-secondary large">
399
  <i class="fas fa-user-plus"></i>
400
  Create Free Account
401
  </a>
@@ -422,8 +422,8 @@
422
  <div class="footer-section">
423
  <h4>Quick Links</h4>
424
  <ul>
425
- <li><a href="http://localhost:8000/login">Sign In</a></li>
426
- <li><a href="http://localhost:8000/register">Register</a></li>
427
  <li><a href="#features">Features</a></li>
428
  <li><a href="#about">About</a></li>
429
  </ul>
 
33
  <a href="#community">Community</a>
34
  <a href="#resources">Resources</a>
35
  <a href="#about">About</a>
36
+ <a href="https://prodevroger-ishingiro.hf.space/login" class="nav-cta">Get Started</a>
37
  </div>
38
  </div>
39
  </nav>
 
73
  </div>
74
  </div>
75
  <div class="hero-actions">
76
+ <a href="https://prodevroger-ishingiro.hf.space/login" class="btn-primary">
77
  <i class="fas fa-rocket"></i>
78
  Start Your Journey
79
  </a>
 
328
  </div>
329
  </div>
330
  <div class="community-cta">
331
+ <a href="https://prodevroger-ishingiro.hf.space/login" class="btn-primary large">
332
  <i class="fas fa-sign-in-alt"></i>
333
  Join Community
334
  </a>
 
391
  <h2>Ready to Begin Your Mental Health Journey?</h2>
392
  <p>Join thousands of Rwandans who have found support through AIMHSA</p>
393
  <div class="cta-actions">
394
+ <a href="https://prodevroger-ishingiro.hf.space/login" class="btn-primary large">
395
  <i class="fas fa-rocket"></i>
396
  Start Your Journey Today
397
  </a>
398
+ <a href="https://prodevroger-ishingiro.hf.space/register" class="btn-secondary large">
399
  <i class="fas fa-user-plus"></i>
400
  Create Free Account
401
  </a>
 
422
  <div class="footer-section">
423
  <h4>Quick Links</h4>
424
  <ul>
425
+ <li><a href="https://prodevroger-ishingiro.hf.space/login">Sign In</a></li>
426
+ <li><a href="https://prodevroger-ishingiro.hf.space/register">Register</a></li>
427
  <li><a href="#features">Features</a></li>
428
  <li><a href="#about">About</a></li>
429
  </ul>
chatbot/login.js CHANGED
@@ -1,6 +1,32 @@
1
  (() => {
2
  const API_BASE_URL = `https://${window.location.hostname}`;
3
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
  // Elements
5
  const loginForm = document.getElementById('loginForm');
6
  const signInBtn = document.getElementById('signInBtn');
 
1
  (() => {
2
  const API_BASE_URL = `https://${window.location.hostname}`;
3
 
4
+ // API helper function
5
+ async function api(endpoint, options = {}) {
6
+ try {
7
+ const url = endpoint.startsWith('http') ? endpoint : API_BASE_URL + endpoint;
8
+ const response = await fetch(url, {
9
+ ...options,
10
+ credentials: 'include', // Include cookies
11
+ headers: {
12
+ 'Content-Type': 'application/json',
13
+ ...options.headers
14
+ }
15
+ });
16
+
17
+ const data = await response.json();
18
+
19
+ if (!response.ok) {
20
+ throw new Error(data.message || 'API request failed');
21
+ }
22
+
23
+ return data;
24
+ } catch (err) {
25
+ console.error('API Error:', err);
26
+ throw err;
27
+ }
28
+ }
29
+
30
  // Elements
31
  const loginForm = document.getElementById('loginForm');
32
  const signInBtn = document.getElementById('signInBtn');
sms_service.py CHANGED
@@ -191,7 +191,7 @@ Email: {user_email}
191
  Location: {user_location}
192
 
193
  Please login to your dashboard to view details and accept/decline the booking:
194
- http://localhost:8000/login
195
 
196
  AIMHSA System"""
197
 
 
191
  Location: {user_location}
192
 
193
  Please login to your dashboard to view details and accept/decline the booking:
194
+ https://prodevroger-ishingiro.hf.space/login
195
 
196
  AIMHSA System"""
197
 
tests/FIELD_SPECIFIC_ERRORS_FIX.md CHANGED
@@ -151,7 +151,7 @@ python run_frontend.py
151
  ```
152
 
153
  ### **2. Open Registration Form**
154
- - Navigate to `http://localhost:8000/register`
155
  - Open browser developer tools (F12) to see console logs
156
 
157
  ### **3. Test Field-Specific Errors**
 
151
  ```
152
 
153
  ### **2. Open Registration Form**
154
+ - Navigate to `https://prodevroger-ishingiro.hf.space/register`
155
  - Open browser developer tools (F12) to see console logs
156
 
157
  ### **3. Test Field-Specific Errors**
tests/REGISTRATION_VALIDATION_IMPLEMENTATION.md CHANGED
@@ -2,7 +2,7 @@
2
 
3
  ## 🎯 **Overview**
4
 
5
- I have implemented comprehensive input validation for the registration form at `http://localhost:8000/register`. The validation includes real-time feedback, visual indicators, and comprehensive error handling for all form fields.
6
 
7
  ## πŸ”§ **Files Modified**
8
 
@@ -166,7 +166,7 @@ python run_frontend.py
166
  ```
167
 
168
  ### **2. Access Registration Form**
169
- - Open `http://localhost:8000/register`
170
  - Test all validation features
171
  - Verify real-time feedback
172
  - Test form submission
@@ -259,5 +259,5 @@ The implementation follows modern web development best practices and provides an
259
 
260
  **πŸš€ Ready for Production Use!**
261
 
262
- The registration form at `http://localhost:8000/register` now has full validation implemented and is ready for production use.
263
 
 
2
 
3
  ## 🎯 **Overview**
4
 
5
+ I have implemented comprehensive input validation for the registration form at `https://prodevroger-ishingiro.hf.space/register`. The validation includes real-time feedback, visual indicators, and comprehensive error handling for all form fields.
6
 
7
  ## πŸ”§ **Files Modified**
8
 
 
166
  ```
167
 
168
  ### **2. Access Registration Form**
169
+ - Open `https://prodevroger-ishingiro.hf.space/register`
170
  - Test all validation features
171
  - Verify real-time feedback
172
  - Test form submission
 
259
 
260
  **πŸš€ Ready for Production Use!**
261
 
262
+ The registration form at `https://prodevroger-ishingiro.hf.space/register` now has full validation implemented and is ready for production use.
263
 
tests/SYNTAX_ERROR_FIX.md CHANGED
@@ -61,7 +61,7 @@ python run_frontend.py
61
  ```
62
 
63
  ### **2. Test Registration Form**
64
- - Open `http://localhost:8000/register`
65
  - Try registering with various full names
66
  - Test field-specific error handling
67
 
 
61
  ```
62
 
63
  ### **2. Test Registration Form**
64
+ - Open `https://prodevroger-ishingiro.hf.space/register`
65
  - Try registering with various full names
66
  - Test field-specific error handling
67
 
tests/THERAPY_BOOKING_README.md CHANGED
@@ -88,7 +88,7 @@ AIMHSA is an advanced AI-powered mental health support system specifically desig
88
  5. **Start Frontend**
89
  ```bash
90
  python run_frontend.py
91
- # Runs on http://localhost:8000
92
  ```
93
 
94
  ## πŸ‘₯ User Roles & Access
 
88
  5. **Start Frontend**
89
  ```bash
90
  python run_frontend.py
91
+ # Runs on https://prodevroger-ishingiro.hf.space
92
  ```
93
 
94
  ## πŸ‘₯ User Roles & Access
tests/start_aimhsa.bat CHANGED
@@ -5,7 +5,7 @@ echo ================================================
5
  echo.
6
  echo Starting AIMHSA system...
7
  echo Backend API: https://prodevroger-ishingiro.hf.space
8
- echo Frontend: http://localhost:8000
9
  echo.
10
  echo Press Ctrl+C to stop both services
11
  echo.
 
5
  echo.
6
  echo Starting AIMHSA system...
7
  echo Backend API: https://prodevroger-ishingiro.hf.space
8
+ echo Frontend: https://prodevroger-ishingiro.hf.space
9
  echo.
10
  echo Press Ctrl+C to stop both services
11
  echo.
tests/start_simple.bat CHANGED
@@ -5,7 +5,7 @@ echo ================================================
5
  echo.
6
  echo Starting simplified AIMHSA system...
7
  echo Backend API: https://prodevroger-ishingiro.hf.space
8
- echo Frontend: http://localhost:8000
9
  echo.
10
 
11
  REM Check if app.pybcp.py exists
 
5
  echo.
6
  echo Starting simplified AIMHSA system...
7
  echo Backend API: https://prodevroger-ishingiro.hf.space
8
+ echo Frontend: https://prodevroger-ishingiro.hf.space
9
  echo.
10
 
11
  REM Check if app.pybcp.py exists
tests/start_single_port.bat CHANGED
@@ -4,7 +4,7 @@ echo AIMHSA - Single Port Launcher
4
  echo ================================================
5
  echo.
6
  echo Starting AIMHSA on single port...
7
- echo Frontend & API: http://localhost:8000
8
  echo.
9
  echo Press Ctrl+C to stop
10
  echo.
 
4
  echo ================================================
5
  echo.
6
  echo Starting AIMHSA on single port...
7
+ echo Frontend & API: https://prodevroger-ishingiro.hf.space
8
  echo.
9
  echo Press Ctrl+C to stop
10
  echo.
tests/test_field_errors.html CHANGED
@@ -132,7 +132,7 @@
132
  <br><code>python app.py</code> (Backend on port 7060)
133
  <br><code>python run_frontend.py</code> (Frontend on port 8000)
134
  </li>
135
- <li><strong>Open registration form:</strong> <code>http://localhost:8000/register</code></li>
136
  <li><strong>Test field-specific errors:</strong>
137
  <ul>
138
  <li>Try submitting with empty fields</li>
 
132
  <br><code>python app.py</code> (Backend on port 7060)
133
  <br><code>python run_frontend.py</code> (Frontend on port 8000)
134
  </li>
135
+ <li><strong>Open registration form:</strong> <code>https://prodevroger-ishingiro.hf.space/register</code></li>
136
  <li><strong>Test field-specific errors:</strong>
137
  <ul>
138
  <li>Try submitting with empty fields</li>
tests/test_field_specific_errors.html CHANGED
@@ -133,7 +133,7 @@
133
  <br><code>python app.py</code> (Backend on port 7060)
134
  <br><code>python run_frontend.py</code> (Frontend on port 8000)
135
  </li>
136
- <li><strong>Open registration form:</strong> <code>http://localhost:8000/register</code></li>
137
  <li><strong>Open browser developer tools:</strong> Press F12 to see console logs</li>
138
  <li><strong>Try the test cases above</strong></li>
139
  <li><strong>Verify:</strong>
 
133
  <br><code>python app.py</code> (Backend on port 7060)
134
  <br><code>python run_frontend.py</code> (Frontend on port 8000)
135
  </li>
136
+ <li><strong>Open registration form:</strong> <code>https://prodevroger-ishingiro.hf.space/register</code></li>
137
  <li><strong>Open browser developer tools:</strong> Press F12 to see console logs</li>
138
  <li><strong>Try the test cases above</strong></li>
139
  <li><strong>Verify:</strong>
tests/test_registration_validation.html CHANGED
@@ -70,7 +70,7 @@
70
  </head>
71
  <body>
72
  <h1>πŸ§ͺ AIMHSA Registration Validation Test Suite</h1>
73
- <p>This page tests the comprehensive validation implemented for the registration form at <code>http://localhost:8000/register</code></p>
74
 
75
  <div class="test-section">
76
  <h2>πŸ“‹ Validation Features Implemented</h2>
@@ -147,7 +147,7 @@
147
  <ol>
148
  <li>Start the AIMHSA server: <code>python app.py</code> (port 7060)</li>
149
  <li>Start the frontend server: <code>python run_frontend.py</code> (port 8000)</li>
150
- <li>Open <code>http://localhost:8000/register</code> in your browser</li>
151
  <li>Test each field with valid and invalid inputs</li>
152
  <li>Verify real-time validation feedback</li>
153
  <li>Test password strength indicator</li>
 
70
  </head>
71
  <body>
72
  <h1>πŸ§ͺ AIMHSA Registration Validation Test Suite</h1>
73
+ <p>This page tests the comprehensive validation implemented for the registration form at <code>https://prodevroger-ishingiro.hf.space/register</code></p>
74
 
75
  <div class="test-section">
76
  <h2>πŸ“‹ Validation Features Implemented</h2>
 
147
  <ol>
148
  <li>Start the AIMHSA server: <code>python app.py</code> (port 7060)</li>
149
  <li>Start the frontend server: <code>python run_frontend.py</code> (port 8000)</li>
150
+ <li>Open <code>https://prodevroger-ishingiro.hf.space/register</code> in your browser</li>
151
  <li>Test each field with valid and invalid inputs</li>
152
  <li>Verify real-time validation feedback</li>
153
  <li>Test password strength indicator</li>