Compare commits

..

No commits in common. "ai-dev" and "master" have entirely different histories.

19 changed files with 164 additions and 181 deletions

View File

@ -1,14 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>{% block title %}AutoTask{% endblock %}</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&family=Roboto+Mono:wght@400;700&display=swap" rel="stylesheet">
{% block head %}{% endblock %}
</head>
<body>
{% block content %}{% endblock %}
</body>
</html>

View File

@ -1,14 +0,0 @@
{% extends 'base.html' %}
{% block title %}{{ article.title }}{% endblock %}
{% block content %}
<div class="container mt-5">
<h1>{{ article.title }}</h1>
<p class="text-muted">Published on {{ article.created_at|date:"F d, Y" }}</p>
<hr>
<div>
{{ article.content|safe }}
</div>
</div>
{% endblock %}

View File

@ -1,56 +1,157 @@
{% extends 'base.html' %}
{% load static %}
<!doctype html>
<html lang="en">
{% block title %}{{ project_name }} Dashboard{% endblock %}
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{ project_name }}</title>
{% if project_description %}
<meta name="description" content="{{ project_description }}">
<meta property="og:description" content="{{ project_description }}">
<meta property="twitter:description" content="{{ project_description }}">
{% endif %}
{% if project_image_url %}
<meta property="og:image" content="{{ project_image_url }}">
<meta property="twitter:image" content="{{ project_image_url }}">
{% endif %}
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap" rel="stylesheet">
<style>
:root {
--bg-color-start: #6a11cb;
--bg-color-end: #2575fc;
--text-color: #ffffff;
--card-bg-color: rgba(255, 255, 255, 0.08);
--card-border-color: rgba(255, 255, 255, 0.18);
}
{% block head %}
<link rel="stylesheet" href="{% static 'css/custom.css' %}">
<meta name="description" content="AutoTask AI-powered automation platform dashboard.">
{% endblock %}
* {
box-sizing: border-box;
}
{% block content %}
<div class="dashboard-container">
<header class="text-center mb-4">
<h1>{{ project_name }}</h1>
</header>
body {
margin: 0;
font-family: 'Inter', sans-serif;
background: linear-gradient(130deg, var(--bg-color-start), var(--bg-color-end));
color: var(--text-color);
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
text-align: center;
overflow: hidden;
position: relative;
}
body::before {
content: '';
position: absolute;
inset: 0;
background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140' viewBox='0 0 140 140'><path d='M-20 20L160 20M20 -20L20 160' stroke-width='1' stroke='rgba(255,255,255,0.05)'/></svg>");
animation: bg-pan 24s linear infinite;
z-index: -1;
}
@keyframes bg-pan {
0% {
transform: translate3d(0, 0, 0);
}
100% {
transform: translate3d(-140px, -140px, 0);
}
}
main {
padding: clamp(2rem, 4vw, 3rem);
width: min(640px, 92vw);
}
.card {
background: var(--card-bg-color);
border: 1px solid var(--card-border-color);
border-radius: 20px;
padding: clamp(2rem, 4vw, 3rem);
backdrop-filter: blur(24px);
-webkit-backdrop-filter: blur(24px);
box-shadow: 0 20px 60px rgba(15, 23, 42, 0.35);
}
h1 {
margin: 0 0 1.2rem;
font-weight: 700;
font-size: clamp(2.2rem, 3vw + 1.3rem, 3rem);
letter-spacing: -0.04em;
}
p {
margin: 0.6rem 0;
font-size: 1.1rem;
line-height: 1.7;
opacity: 0.92;
}
.loader {
margin: 1.5rem auto;
width: 56px;
height: 56px;
border: 4px solid rgba(255, 255, 255, 0.25);
border-top-color: #fff;
border-radius: 50%;
animation: spin 1s linear infinite;
}
@keyframes spin {
to {
transform: rotate(360deg);
}
}
.sr-only {
position: absolute;
width: 1px;
height: 1px;
padding: 0;
margin: -1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
border: 0;
}
code {
background: rgba(15, 23, 42, 0.35);
padding: 0.2rem 0.6rem;
border-radius: 0.5rem;
font-size: 0.95rem;
}
footer {
margin-top: 2.4rem;
font-size: 0.86rem;
opacity: 0.7;
}
</style>
</head>
<body>
<main>
<section class="wallet-card mb-5">
<h2>Wallet Balance</h2>
<div class="wallet-balance-btc">{{ wallet.balance_btc|floatformat:8 }} BTC</div>
<div class="wallet-balance-usd">~ ${{ wallet.balance_usd|floatformat:2 }} USD</div>
</section>
<section class="transactions">
<h2>Recent Transactions</h2>
<div class="table-responsive">
<table class="transaction-table">
<thead>
<tr>
<th>Description</th>
<th>Amount (BTC)</th>
<th>Timestamp</th>
</tr>
</thead>
<tbody>
{% for tx in transactions %}
<tr>
<td>{{ tx.description }}</td>
<td class="{% if tx.type == 'credit' %}text-credit{% else %}text-debit{% endif %}">
{% if tx.type == 'credit' %}+{% endif %}{{ tx.amount_btc|floatformat:8 }}
</td>
<td>{{ tx.timestamp }}</td>
</tr>
{% empty %}
<tr>
<td colspan="3">No transactions yet.</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="card">
<h1>Analyzing your requirements and generating your website…</h1>
<div class="loader" role="status" aria-live="polite" aria-label="Applying initial changes">
<span class="sr-only">Loading…</span>
</div>
</section>
<p>Appwizzy AI is collecting your requirements and applying the first changes.</p>
<p>This page will refresh automatically as the plan is implemented.</p>
<p>
Runtime: Django <code>{{ django_version }}</code> · Python <code>{{ python_version }}</code>
UTC <code>{{ current_time|date:"Y-m-d H:i:s" }}</code>
</p>
</div>
<footer>
Page updated: {{ current_time|date:"Y-m-d H:i:s" }} (UTC)
</footer>
</main>
</body>
</div>
{% endblock %}
</html>

View File

@ -1,7 +1,7 @@
from django.urls import path
from .views import index
from .views import home
urlpatterns = [
path("", index, name="index"),
path("", home, name="home"),
]

View File

@ -11,25 +11,21 @@ from .forms import TicketForm
from .models import Ticket
def index(request):
"""Render the main dashboard with wallet and transaction data."""
# Mock data for the wallet and transactions
wallet_data = {
'balance_btc': 0.00123456,
'balance_usd': 50.12
}
transactions_data = [
{'id': 'a1b2', 'description': 'Automated Task Reward', 'amount_btc': 0.00005, 'type': 'credit', 'timestamp': '2025-10-25 10:00:00'},
{'id': 'c3d4', 'description': 'Strategy Execution Fee', 'amount_btc': -0.000005, 'type': 'debit', 'timestamp': '2025-10-25 09:30:00'},
{'id': 'e5f6', 'description': 'Automated Task Reward', 'amount_btc': 0.00007, 'type': 'credit', 'timestamp': '2025-10-24 18:00:00'},
{'id': 'g7h8', 'description': 'VIP ★2 Upgrade', 'amount_btc': -0.0005, 'type': 'debit', 'timestamp': '2025-10-24 12:00:00'},
{'id': 'i9j0', 'description': 'Initial Deposit', 'amount_btc': 0.001, 'type': 'credit', 'timestamp': '2025-10-23 20:15:00'},
]
def home(request):
"""Render the landing screen with loader and environment details."""
host_name = request.get_host().lower()
agent_brand = "AppWizzy" if host_name == "appwizzy.com" else "Flatlogic"
now = timezone.now()
context = {
"wallet": wallet_data,
"transactions": transactions_data,
"project_name": "AutoTask",
"project_name": "New Style",
"agent_brand": agent_brand,
"django_version": django_version(),
"python_version": platform.python_version(),
"current_time": now,
"host_name": host_name,
"project_description": os.getenv("PROJECT_DESCRIPTION", ""),
"project_image_url": os.getenv("PROJECT_IMAGE_URL", ""),
}
return render(request, "core/index.html", context)

View File

@ -1,86 +0,0 @@
:root {
--color-background: #1a1a1d;
--color-primary-accent: #00ffff;
--color-text: #c5c6c7;
--color-credit: #39ff14;
--color-debit: #ff0033;
--font-headings: 'Orbitron', sans-serif;
--font-body: 'Roboto Mono', monospace;
}
body {
background-color: var(--color-background);
color: var(--color-text);
font-family: var(--font-body);
margin: 0;
padding: 2rem;
}
h1, h2, h3, h4, h5 {
font-family: var(--font-headings);
color: var(--color-primary-accent);
text-shadow: 0 0 5px var(--color-primary-accent);
}
.dashboard-container {
max-width: 960px;
margin: 0 auto;
}
.wallet-card {
background-color: #2c2c31;
border: 1px solid var(--color-primary-accent);
border-radius: 8px;
padding: 2rem;
margin-bottom: 2rem;
box-shadow: 0 0 15px rgba(0, 255, 255, 0.2);
}
.wallet-card h2 {
margin-top: 0;
}
.wallet-balance-btc {
font-size: 2.5rem;
font-weight: 700;
color: var(--color-primary-accent);
text-shadow: 0 0 10px var(--color-primary-accent);
}
.wallet-balance-usd {
font-size: 1.2rem;
color: var(--color-text);
opacity: 0.8;
}
.transaction-table {
width: 100%;
border-collapse: collapse;
background-color: #2c2c31;
border-radius: 8px;
overflow: hidden;
box-shadow: 0 0 15px rgba(0, 255, 255, 0.1);
}
.transaction-table th,
.transaction-table td {
padding: 1rem;
text-align: left;
border-bottom: 1px solid #444;
}
.transaction-table th {
font-family: var(--font-headings);
color: var(--color-primary-accent);
}
.text-credit {
color: var(--color-credit);
font-weight: 700;
}
.text-debit {
color: var(--color-debit);
font-weight: 700;
}