Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
1f5da95
feat(api): add auctions API with views, serializers and permissions
dev-sandoval Sep 4, 2025
cbb31d0
feat(notifications): implement real-time notification system
dev-sandoval Sep 4, 2025
a88f74e
feat(styles): add new profile, dashboard and search page styles with …
dev-sandoval Sep 4, 2025
4f3db30
feat: add frontend javascript modules for alerts, dashboard and search
dev-sandoval Sep 4, 2025
e115133
feat(templates): add list_item component and update alert/footer styles
dev-sandoval Sep 4, 2025
5cabd93
refactor(auction): split watchlist button into separate forms for cla…
dev-sandoval Sep 4, 2025
a2485cc
feat(layout): add search functionality and improve user dropdown
dev-sandoval Sep 4, 2025
1259ef7
feat(notifications): add real-time notification system with websockets
dev-sandoval Sep 4, 2025
eec0c0b
feat(search): add search page with advanced filters and autocomplete
dev-sandoval Sep 4, 2025
a69c432
feat(profile): add user profile page with stats and quick actions
dev-sandoval Sep 4, 2025
2713895
feat(dashboard): add business intelligence dashboard template
dev-sandoval Sep 4, 2025
c7bc30d
feat(templatetags): add watchlist check and json conversion filters
dev-sandoval Sep 4, 2025
2c12023
refactor(auctions): set default auto field and import signals in ready
dev-sandoval Sep 4, 2025
f2be7c4
fix: remove duplicate title validation and debug print
dev-sandoval Sep 4, 2025
85977f8
feat(middleware): add rate limiting and security middleware
dev-sandoval Sep 4, 2025
02c43bd
feat(models): add notification system and improve model fields
dev-sandoval Sep 4, 2025
cddfb66
feat(pagination): add custom pagination class with configurable page …
dev-sandoval Sep 4, 2025
bb5bd17
feat(urls): add new endpoints and remove trailing slashes
dev-sandoval Sep 4, 2025
b1eeefa
feat(security): add rate limiting decorator for API endpoints
dev-sandoval Sep 4, 2025
d04cce9
feat(websocket): add websocket support for notifications
dev-sandoval Sep 4, 2025
f114a84
test: add minimal test settings for Django commerce app
dev-sandoval Sep 4, 2025
d958698
feat(routing): add websocket routing configuration for auctions notif…
dev-sandoval Sep 4, 2025
783381f
feat(settings): add API, security, and async support to Django settings
dev-sandoval Sep 4, 2025
7f935a9
test: add test settings configuration for Django project
dev-sandoval Sep 4, 2025
07ae686
feat(api): add API endpoints and documentation support
dev-sandoval Sep 4, 2025
a948c1d
style: change single quotes to double quotes in wsgi.py
dev-sandoval Sep 4, 2025
e0de0be
test: add comprehensive test suite for auction platform
dev-sandoval Sep 4, 2025
0383162
test: add script to generate test data for auctions app
dev-sandoval Sep 4, 2025
48128a2
test: add mock django_heroku module for testing
dev-sandoval Sep 4, 2025
25994b9
feat: add script for code formatting and linting
dev-sandoval Sep 4, 2025
1c8b075
test: add script to load test data for auction system
dev-sandoval Sep 4, 2025
892298b
feat: add data management script for auction project
dev-sandoval Sep 4, 2025
dd2f874
style: use double quotes consistently in manage.py
dev-sandoval Sep 4, 2025
4e771c5
build: add flake8 configuration file
dev-sandoval Sep 4, 2025
45da0fd
build: add black and flake8 configuration files
dev-sandoval Sep 4, 2025
e1ee078
build(pytest): add pytest configuration file with custom settings
dev-sandoval Sep 4, 2025
d8dd415
build: update requirements.txt with testing and development dependencies
dev-sandoval Sep 4, 2025
727e022
new migrations
dev-sandoval Sep 4, 2025
3025a8f
docs: add project description and role documentation
dev-sandoval Sep 4, 2025
3d3a86a
docs: add system architecture documentation
dev-sandoval Sep 4, 2025
f136ea6
docs: add key features walkthrough documentation
dev-sandoval Sep 4, 2025
c5df6ad
docs: add technical challenges and solutions documentation
dev-sandoval Sep 4, 2025
6e90069
docs: add technical presentation guide for auction platform
dev-sandoval Sep 4, 2025
f8eeab0
docs: add technical interview preparation guide
dev-sandoval Sep 4, 2025
91a7d90
🐛 fix: update URL naming for auction creation link
dev-sandoval Sep 12, 2025
0d05b85
♻️ refactor: update auction creation URL references to 'new_auction'
dev-sandoval Sep 12, 2025
7ce1c48
♻️ refactor: improve variable naming and streamline watchlist functi…
dev-sandoval Sep 13, 2025
67efae3
♻️ refactor: update watchlist logic to use filtered active listings
dev-sandoval Sep 13, 2025
2f63fa1
Add comprehensive test suite for the auctions app
google-labs-jules[bot] Sep 13, 2025
4dea272
style: format code with Black and Ruff Formatter
deepsource-autofix[bot] Sep 13, 2025
5a031d7
➕ chore: add factory-boy to requirements for improved test data manag…
dev-sandoval Sep 13, 2025
5f1e4d5
✨ feat: add Django management command for generating automated reports
dev-sandoval Sep 13, 2025
e9ba291
🔥 chore: remove unused navbar CSS styles
dev-sandoval Sep 13, 2025
c426e0d
💄 style: clean up CSS by removing redundant container styles
dev-sandoval Sep 13, 2025
c9d69cb
💄 feat: add navigation component styles
dev-sandoval Sep 13, 2025
9009239
💄 feat: add error pages CSS styles
dev-sandoval Sep 13, 2025
aae5991
💄 style: remove redundant container styles from login page CSS
dev-sandoval Sep 13, 2025
2fab0d0
💄 style: enhance component styles and import variables
dev-sandoval Sep 13, 2025
ee57ee8
💄 feat: add main layout styles to CSS
dev-sandoval Sep 13, 2025
f656a1e
💄 feat: enhance auction app with new features and styles
dev-sandoval Sep 13, 2025
51398e5
✨ feat: add management package for auction app
dev-sandoval Sep 13, 2025
b941133
✨ feat: add interactive error page management script
dev-sandoval Sep 13, 2025
0e1cacf
✨ feat: add layout JavaScript for theme management and accessibility
dev-sandoval Sep 13, 2025
2ba58f6
✨ feat: add analytics dashboard template for auction app
dev-sandoval Sep 13, 2025
f58135a
✨ feat: add admin panel template for auction app
dev-sandoval Sep 13, 2025
e1c44dd
✨ feat: add comprehensive admin dashboard template for auction app
dev-sandoval Sep 13, 2025
abe50ee
✨ feat: add detailed listing detail template for auction admin panel
dev-sandoval Sep 13, 2025
b1f5c3c
✨ feat: add auction listings management template for admin panel
dev-sandoval Sep 13, 2025
4599198
✨ feat: add comprehensive reports template for auction admin panel
dev-sandoval Sep 13, 2025
1b55262
✨ feat: add user management template for auction admin panel
dev-sandoval Sep 13, 2025
ef83a43
✨ feat: add navigation component template for auction app
dev-sandoval Sep 13, 2025
350d202
✨ feat: add 400 error page template for auction app
dev-sandoval Sep 13, 2025
c63ce49
✨ feat: add 403 error page template for auction app
dev-sandoval Sep 13, 2025
1a0aa3b
✨ feat: add 404 error page template for auction app
dev-sandoval Sep 13, 2025
6dd61e0
✨ feat: add 500 error page template for auction app
dev-sandoval Sep 13, 2025
9a8bd0f
✨ feat: add static CSS support and styling for auction page
dev-sandoval Sep 13, 2025
bdb1f0a
✨ feat: include static CSS for categories page and enhance layout
dev-sandoval Sep 13, 2025
33c0dad
✨ feat: include static CSS for auctions index page and update layout …
dev-sandoval Sep 13, 2025
f96ca1a
✨ feat: refactor layout template to improve structure and load perfor…
dev-sandoval Sep 13, 2025
1ab06a1
✨ feat: add static CSS support for login page to enhance styling and …
dev-sandoval Sep 13, 2025
448753d
✨ feat: add static CSS support for new auction page to enhance styling
dev-sandoval Sep 13, 2025
4ea1013
✨ feat: add static CSS support for registration page to enhance styli…
dev-sandoval Sep 13, 2025
b2b8b33
✨ feat: add static CSS support for watch list page to enhance styling…
dev-sandoval Sep 13, 2025
1dfc50c
✨ feat: add custom template filters for arithmetic operations and CSS…
dev-sandoval Sep 13, 2025
1cf334b
✨ feat: add admin configuration file for dashboard settings, includin…
dev-sandoval Sep 13, 2025
a81ce2f
✨ feat: implement admin views for superusers, including dashboard, an…
dev-sandoval Sep 13, 2025
653a0e8
✨ feat: add data analytics module for auction insights, including met…
dev-sandoval Sep 13, 2025
b1e88fe
✨ feat: introduce data processing and reporting utilities for auction…
dev-sandoval Sep 13, 2025
b86ef12
✨ feat: add custom error handling views for 400, 403, 404, and 500 er…
dev-sandoval Sep 13, 2025
783b4b5
✨ feat: implement custom error handling middleware for 404, 403, and …
dev-sandoval Sep 13, 2025
0e30fae
✨ feat: update auction URLs to include admin panel routes and modify …
dev-sandoval Sep 13, 2025
3e991ab
✨ feat: enhance settings configuration by adding django_extensions an…
dev-sandoval Sep 13, 2025
6c2049e
✨ feat: update commerce URL configuration to include custom error han…
dev-sandoval Sep 13, 2025
db14c56
🙈 feat: update .gitignore to include static files directory, improvi…
dev-sandoval Sep 13, 2025
428ce41
✨ feat: add admin panel configuration file with customizable settings…
dev-sandoval Sep 13, 2025
f6e226f
➕ feat: add business intelligence libraries to requirements for enha…
dev-sandoval Sep 13, 2025
c33320b
Refactor CSS to unify styles and remove inline code
google-labs-jules[bot] Sep 14, 2025
adc2a82
style: format code with Black and Ruff Formatter
deepsource-autofix[bot] Sep 14, 2025
fb1f339
Merge pull request #26 from sandovaldavid:refactor/css-styles-unifica…
dev-sandoval Sep 14, 2025
8706252
Fix: Link variables.css to enable theme switching
google-labs-jules[bot] Sep 14, 2025
ffdbfca
Merge pull request #28 from sandovaldavid:fix-dark-mode
dev-sandoval Sep 14, 2025
291af49
💄 style: update CSS variables for light theme support
dev-sandoval Sep 14, 2025
adf539d
🐛 fix: remove inline JavaScript for theme toggle in navigation component
dev-sandoval Sep 14, 2025
e7941ca
♻️ refactor: improve theme initialization and logging in layout.js
dev-sandoval Sep 14, 2025
05a201c
refactor: Enhance color contrast for accessibility
google-labs-jules[bot] Sep 14, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,8 @@ dmypy.json
# Cython debug symbols
cython_debug/

/staticfiles/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
Expand Down
139 changes: 139 additions & 0 deletions admin_panel_config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
"""
Configuración del Panel de Administración
Variables de entorno y configuraciones personalizables
"""

import os
from django.conf import settings

# Configuración del Panel de Administración
ADMIN_PANEL_CONFIG = {
"enabled": os.getenv("ADMIN_PANEL_ENABLED", "True").lower() == "true",
"refresh_interval": int(os.getenv("ADMIN_REFRESH_INTERVAL", "30000")),
"chart_height": int(os.getenv("ADMIN_CHART_HEIGHT", "300")),
"table_page_size": int(os.getenv("ADMIN_TABLE_PAGE_SIZE", "20")),
"max_recent_items": int(os.getenv("ADMIN_MAX_RECENT_ITEMS", "10")),
}

# Configuración de Análisis
ANALYTICS_CONFIG = {
"min_data_points": int(os.getenv("ANALYTICS_MIN_DATA_POINTS", "10")),
"confidence_thresholds": {
"high": float(os.getenv("ANALYTICS_CONFIDENCE_HIGH", "0.8")),
"medium": float(os.getenv("ANALYTICS_CONFIDENCE_MEDIUM", "0.6")),
"low": float(os.getenv("ANALYTICS_CONFIDENCE_LOW", "0.4")),
},
}

# Configuración de Alertas
ALERT_CONFIG = {
"low_activity_threshold": int(os.getenv("ALERT_LOW_ACTIVITY_THRESHOLD", "5")),
"high_bid_threshold": int(os.getenv("ALERT_HIGH_BID_THRESHOLD", "1000")),
"suspicious_activity_threshold": int(
os.getenv("ALERT_SUSPICIOUS_ACTIVITY_THRESHOLD", "50")
),
}

# Configuración de Exportación
EXPORT_CONFIG = {
"max_records": int(os.getenv("EXPORT_MAX_RECORDS", "10000")),
"date_format": os.getenv("EXPORT_DATE_FORMAT", "%Y-%m-%d %H:%M:%S"),
"supported_formats": ["csv", "xlsx", "json"],
}

# Configuración de Colores
CHART_COLORS = {
"primary": os.getenv("CHART_PRIMARY_COLOR", "#667eea"),
"secondary": os.getenv("CHART_SECONDARY_COLOR", "#764ba2"),
"success": os.getenv("CHART_SUCCESS_COLOR", "#4facfe"),
"info": os.getenv("CHART_INFO_COLOR", "#00f2fe"),
"warning": os.getenv("CHART_WARNING_COLOR", "#f093fb"),
"danger": os.getenv("CHART_DANGER_COLOR", "#f5576c"),
"light": os.getenv("CHART_LIGHT_COLOR", "#a8edea"),
"dark": os.getenv("CHART_DARK_COLOR", "#fed6e3"),
}

# Configuración de Base de Datos para Análisis
DATABASE_CONFIG = {
"query_timeout": int(os.getenv("DB_QUERY_TIMEOUT", "30")),
"max_connections": int(os.getenv("DB_MAX_CONNECTIONS", "20")),
"enable_query_logging": os.getenv("DB_ENABLE_QUERY_LOGGING", "False").lower()
== "true",
}

# Configuración de Caché
CACHE_CONFIG = {
"enabled": os.getenv("CACHE_ENABLED", "True").lower() == "true",
"timeout": int(os.getenv("CACHE_TIMEOUT", "300")), # 5 minutos
"key_prefix": os.getenv("CACHE_KEY_PREFIX", "admin_panel"),
}

# Configuración de Logging
LOGGING_CONFIG = {
"level": os.getenv("LOG_LEVEL", "INFO"),
"file": os.getenv("LOG_FILE", "admin_panel.log"),
"max_size": int(os.getenv("LOG_MAX_SIZE", "10485760")), # 10MB
"backup_count": int(os.getenv("LOG_BACKUP_COUNT", "5")),
}


def get_config(section):
"""
Obtener configuración de una sección específica
"""
configs = {
"admin_panel": ADMIN_PANEL_CONFIG,
"analytics": ANALYTICS_CONFIG,
"alerts": ALERT_CONFIG,
"export": EXPORT_CONFIG,
"colors": CHART_COLORS,
"database": DATABASE_CONFIG,
"cache": CACHE_CONFIG,
"logging": LOGGING_CONFIG,
}

return configs.get(section, {})


def is_feature_enabled(feature):
"""
Verificar si una funcionalidad está habilitada
"""
feature_configs = {
"admin_panel": ADMIN_PANEL_CONFIG["enabled"],
"analytics": True,
"alerts": True,
"export": True,
"caching": CACHE_CONFIG["enabled"],
"query_logging": DATABASE_CONFIG["enable_query_logging"],
}

return feature_configs.get(feature, False)


def get_chart_color(color_name):
"""
Obtener color para gráficos
"""
return CHART_COLORS.get(color_name, "#667eea")


def get_alert_threshold(alert_type):
"""
Obtener umbral para alertas
"""
return ALERT_CONFIG.get(alert_type, 0)


def get_export_limit():
"""
Obtener límite de exportación
"""
return EXPORT_CONFIG["max_records"]


def get_refresh_interval():
"""
Obtener intervalo de actualización
"""
return ADMIN_PANEL_CONFIG["refresh_interval"]
44 changes: 44 additions & 0 deletions auctions/admin_config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
"""
Configuración del panel de administración
Configuraciones específicas para el dashboard de BI
"""

# Configuración de colores para gráficos
CHART_COLORS = {
"primary": "#667eea",
"secondary": "#764ba2",
"success": "#4facfe",
"info": "#00f2fe",
"warning": "#f093fb",
"danger": "#f5576c",
"light": "#a8edea",
"dark": "#fed6e3",
}

# Configuración de métricas
METRICS_CONFIG = {
"refresh_interval": 30000, # 30 segundos
"chart_height": 300,
"table_page_size": 20,
"max_recent_items": 10,
}

# Configuración de exportación
EXPORT_CONFIG = {
"supported_formats": ["csv", "xlsx"],
"max_records_per_export": 10000,
"date_format": "%Y-%m-%d %H:%M:%S",
}

# Configuración de análisis predictivo
PREDICTION_CONFIG = {
"min_data_points": 10,
"confidence_thresholds": {"high": 0.8, "medium": 0.6, "low": 0.4},
}

# Configuración de alertas
ALERT_CONFIG = {
"low_activity_threshold": 5, # días sin actividad
"high_bid_threshold": 1000, # pujas muy altas
"suspicious_activity_threshold": 50, # pujas por usuario por día
}
Loading