2026-01-11 13:53:46 +00:00
|
|
|
|
# Admin Panel - Hosting Platform Management
|
|
|
|
|
|
|
|
|
|
|
|
Admin panel for managing the hosting platform, customers, subscription plans, and Cloudflare accounts.
|
|
|
|
|
|
|
|
|
|
|
|
## Project Structure
|
|
|
|
|
|
|
|
|
|
|
|
```
|
|
|
|
|
|
AdminPanel/
|
|
|
|
|
|
├── backend/ # Flask API (Port 5001)
|
|
|
|
|
|
│ ├── app/
|
|
|
|
|
|
│ │ ├── routes/ # API routes
|
|
|
|
|
|
│ │ ├── models.py # Database models
|
|
|
|
|
|
│ │ └── main.py # Flask app
|
|
|
|
|
|
│ └── requirements.txt
|
|
|
|
|
|
├── frontend/ # React + Vite
|
|
|
|
|
|
│ └── src/
|
|
|
|
|
|
└── README.md
|
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
## Features
|
|
|
|
|
|
|
|
|
|
|
|
- **Admin Authentication** - Secure admin login system
|
|
|
|
|
|
- **Customer Management** - View and manage customers
|
|
|
|
|
|
- **Subscription Plans** - Create and manage subscription plans
|
|
|
|
|
|
- **Cloudflare Accounts** - Manage company CF accounts
|
|
|
|
|
|
- **Audit Logs** - Track all admin actions
|
|
|
|
|
|
|
|
|
|
|
|
## Backend Setup
|
|
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
|
cd backend
|
|
|
|
|
|
python3 -m venv venv
|
|
|
|
|
|
source venv/bin/activate
|
|
|
|
|
|
pip install -r requirements.txt
|
|
|
|
|
|
|
|
|
|
|
|
# Create database
|
|
|
|
|
|
createdb admin_hosting_db
|
|
|
|
|
|
|
|
|
|
|
|
# Run
|
|
|
|
|
|
python -m app.main
|
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
Default admin credentials:
|
|
|
|
|
|
- Username: `admin`
|
|
|
|
|
|
- Password: `admin123`
|
|
|
|
|
|
|
|
|
|
|
|
## Frontend Setup
|
|
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
|
cd frontend
|
|
|
|
|
|
npm install
|
|
|
|
|
|
npm run dev
|
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
## Database
|
|
|
|
|
|
|
|
|
|
|
|
Separate PostgreSQL database: `admin_hosting_db`
|
|
|
|
|
|
|
|
|
|
|
|
Tables:
|
|
|
|
|
|
- `admin_users` - Admin accounts
|
|
|
|
|
|
- `subscription_plans` - Subscription plans
|
|
|
|
|
|
- `cloudflare_accounts` - Company CF accounts
|
|
|
|
|
|
- `audit_logs` - Admin action logs
|
|
|
|
|
|
|
|
|
|
|
|
## API Endpoints
|
|
|
|
|
|
|
|
|
|
|
|
### Authentication
|
|
|
|
|
|
- `POST /api/auth/login` - Admin login
|
|
|
|
|
|
- `GET /api/auth/me` - Get current admin
|
|
|
|
|
|
- `POST /api/auth/logout` - Logout
|
|
|
|
|
|
|
|
|
|
|
|
### Plans
|
|
|
|
|
|
- `GET /api/plans` - List all plans
|
|
|
|
|
|
- `POST /api/plans` - Create plan
|
|
|
|
|
|
- `PUT /api/plans/:id` - Update plan
|
|
|
|
|
|
- `DELETE /api/plans/:id` - Delete plan
|
|
|
|
|
|
|
|
|
|
|
|
### CF Accounts
|
|
|
|
|
|
- `GET /api/cf-accounts` - List CF accounts
|
|
|
|
|
|
- `POST /api/cf-accounts` - Create CF account
|
|
|
|
|
|
- `PUT /api/cf-accounts/:id` - Update CF account
|
|
|
|
|
|
- `DELETE /api/cf-accounts/:id` - Delete CF account
|
|
|
|
|
|
|
|
|
|
|
|
### Customers
|
|
|
|
|
|
- `GET /api/customers` - List customers (via customer API)
|
|
|
|
|
|
- `GET /api/customers/:id` - Get customer details
|
|
|
|
|
|
- `PUT /api/customers/:id/plan` - Update customer plan
|
|
|
|
|
|
|
|
|
|
|
|
## Deployment
|
|
|
|
|
|
|
|
|
|
|
|
- **Domain:** admin.argeict.net
|
|
|
|
|
|
- **Backend Port:** 5001
|
|
|
|
|
|
- **Database:** admin_hosting_db
|
|
|
|
|
|
|
2026-01-12 10:58:47 +00:00
|
|
|
|
## 📚 Dokümantasyon
|
|
|
|
|
|
|
|
|
|
|
|
### İş Akışı ve Sistem Şemaları
|
|
|
|
|
|
- 📊 **[README_WORKFLOW.md](./README_WORKFLOW.md)** - Hızlı başlangıç ve genel bakış
|
|
|
|
|
|
- 📖 **[WORKFLOW_DOCUMENTATION.md](./WORKFLOW_DOCUMENTATION.md)** - Detaylı teknik dokümantasyon ve API referansı
|
|
|
|
|
|
- 🎨 **[WORKFLOW_DIAGRAMS.md](./WORKFLOW_DIAGRAMS.md)** - Görsel diyagramlar ve sistem şemaları
|
2026-01-12 11:29:24 +00:00
|
|
|
|
- 🎯 **[ADMIN_PANEL_DIAGRAMS.md](./ADMIN_PANEL_DIAGRAMS.md)** - Admin Panel özel diyagramları (10 adet, düzenlenebilir)
|
2026-01-12 10:58:47 +00:00
|
|
|
|
- 🚀 **[DEPLOYMENT.md](./DEPLOYMENT.md)** - Deployment kılavuzu
|
|
|
|
|
|
|
|
|
|
|
|
## 📝 License
|
|
|
|
|
|
|
|
|
|
|
|
© 2026 ARGE ICT. All rights reserved.
|
|
|
|
|
|
|