Remove dashboard route

This commit is contained in:
Peter Stockings
2025-07-22 09:46:06 +10:00
parent 6891ce5661
commit 2c089fcaf7
3 changed files with 3 additions and 8 deletions

7
app.py
View File

@@ -120,11 +120,6 @@ def home():
def documentation(): def documentation():
return render_template("documentation.html") return render_template("documentation.html")
@ app.route("/dashboard", methods=["GET"])
@login_required
def dashboard():
return redirect(url_for("home.index"))
def _generate_script_from_natural_language(natural_query): def _generate_script_from_natural_language(natural_query):
"""Generates a Javascript function from natural language using Gemini REST API.""" """Generates a Javascript function from natural language using Gemini REST API."""
gemni_model = os.environ.get("GEMINI_MODEL", "gemini-1.5-flash") gemni_model = os.environ.get("GEMINI_MODEL", "gemini-1.5-flash")
@@ -440,7 +435,7 @@ def signup():
user = User(id=str(user_data['id']), username=user_data['username'], password_hash=user_data['password_hash'], created_at=user_data['created_at']) user = User(id=str(user_data['id']), username=user_data['username'], password_hash=user_data['password_hash'], created_at=user_data['created_at'])
login_user(user) login_user(user)
return redirect(url_for('dashboard')) return redirect(url_for('home.index'))
@app.route("/logout") @app.route("/logout")
@login_required @login_required

View File

@@ -61,7 +61,7 @@
href="{{ url_for('documentation') }}">Documentation</a> href="{{ url_for('documentation') }}">Documentation</a>
</li> </li>
</ul> </ul>
<a href="{{ url_for('dashboard') }}" <a href="{{ url_for('home.index') }}"
class="mx-auto lg:mx-0 hover:underline gradient2 text-gray-800 font-extrabold rounded my-6 py-4 px-8 shadow-lg cursor-pointer">Login</a> class="mx-auto lg:mx-0 hover:underline gradient2 text-gray-800 font-extrabold rounded my-6 py-4 px-8 shadow-lg cursor-pointer">Login</a>
</div> </div>
</div> </div>

View File

@@ -88,7 +88,7 @@
href="#">About</a> href="#">About</a>
</li> </li>
</ul> </ul>
<a href="{{ url_for('dashboard') }}" <a href="{{ url_for('home.index') }}"
class="mx-auto lg:mx-0 hover:underline gradient2 text-gray-800 font-extrabold rounded my-6 py-4 px-8 shadow-lg cursor-pointer">Login</a> class="mx-auto lg:mx-0 hover:underline gradient2 text-gray-800 font-extrabold rounded my-6 py-4 px-8 shadow-lg cursor-pointer">Login</a>
</div> </div>
</div> </div>