- Introduced a new geolocation package containing APIs for IP-based geolocation, reverse geocoding, and region information.
- Added URL routes for geolocation endpoints in the account app.
- Implemented models, serializers, and views for handling geolocation data.
- Included GeoLite2 databases for IP to city and country lookups.
- Enhanced location history updates with optimized batch processing for improved performance.
- Updated settings to include the new geolocation package in installed apps.
- Updated the queryset filtering in TransmitterView to correctly filter by reliability slug instead of the reliability field directly.
- This change ensures that the API correctly interprets the status filter provided in the query parameters.
- Implemented HadisCategoryXMindView to retrieve a mind-map JSON structure for specific hadis categories.
- Added Swagger documentation detailing the endpoint's features, usage, and response structure.
- Updated URL routing to include the new endpoint for XMind format retrieval.
- Enhanced the HadisCategoryXMindView to support multi-language content and bookmark status for authenticated users.
- Enhanced the save methods in Hadis, HadisCategory, BookReference, Transmitter, and related models to ensure unique slug generation.
- Implemented robust error handling and fallback mechanisms for slug creation based on title fields, with timestamp-based fallbacks for empty or invalid titles.
- Removed unnecessary thumbnail handling from TransmittersAdmin and simplified the display_header method.
- Improved overall data integrity and consistency in slug management across the application.
- Introduced a new management command to seed OpinionStatus, TransmitterOpinion, and TransmitterOriginalText with multilingual data.
- Implemented logic to create opinion statuses with corresponding colors and titles in English, Farsi, and Russian.
- Added functionality to generate random opinions and original texts for transmitters, ensuring unique titles for each transmitter.
- Enhanced data handling for better integration with existing models and improved seeding process.
- Updated HadisCollectionAdmin and TransmittersAdmin to include a custom display header with thumbnail images.
- Modified list_display to show the new display_header method for better visual representation.
- Added thumbnail field to HadisCollection and Transmitters models, replacing FilerImageField with ImageField for improved image handling.
- Created a migration to alter the thumbnail fields in the database schema.
- Introduced custom forms for Hadis, HadisCollection, HadisTag, HadisStatus, HadisReference, and Transmitters models to utilize JSON editor widgets for better data management.
- Implemented schemas for various JSON fields including titles, descriptions, and addresses to enhance the admin interface.
- Updated list displays in admin classes to show the first text from JSON fields for improved readability.
- Added a management command to seed HadisStatus descriptions with multilingual definitions based on keywords.
- Introduced BookSubjectArea and BookType models with JSONField for titles.
- Added 'description' field to HadisStatus model.
- Updated BookReference model to include ManyToMany relationship with BookSubjectArea and a ForeignKey to BookType.
- Enhanced admin interfaces for HadisStatus, BookReference, and BookAuthor to accommodate new fields and improve usability.
- Introduced a new API endpoint to retrieve narrator layers associated with a specific hadis.
- Enhanced the HadisLayersView to fetch and return unique narrator layers, including their names, slugs, and descriptions.
- Updated serializers to include the slug in the TransmitterShortSerializer and added a new NarratorLayerSerializer for layer details.
- Improved response structure and Swagger documentation for better clarity on usage and expected outputs.
- Implemented inner atomic blocks to ensure that failures during the creation of NarratorLayer, TransmitterReliability, OpinionStatus, Transmitters, and related models do not affect the overall transaction.
- Improved logging to provide warnings for skipped records due to errors, enhancing feedback during the seeding process.
- Streamlined the creation process for authors and books, ensuring that existing records are utilized effectively while maintaining data integrity.
- Improved the process for identifying and fixing empty slugs in NarratorLayer by utilizing raw SQL for more reliable detection.
- Enhanced logging to provide clear feedback on the number of records found and fixed, including error handling for any issues encountered during the slug update.
- Streamlined the slug fixing logic to directly address problematic entries, improving overall data integrity in the seeding process.
- Enhanced the process for fixing empty slugs in NarratorLayer by checking all layers and providing detailed logging for problematic entries.
- Improved slug generation to ensure uniqueness and fallback options when names are not available.
- Streamlined the creation of narrator layers with better error handling and defensive programming practices to avoid skipping layers.
- Added warnings for insufficient narrator layers, prompting retrieval of existing records if necessary.
- Introduced a new phase to the seeding process to address existing data integrity issues before creating new records.
- Added functionality to fix empty and duplicate slugs for NarratorLayer, TransmitterReliability, and OpinionStatus models, ensuring unique identifiers.
- Enhanced logging to provide detailed feedback on the fixes applied during the seeding process, improving overall data quality.
- Refactored the slug generation process for NarratorLayer, TransmitterReliability, and OpinionStatus models to handle empty or invalid slugs more effectively.
- Implemented checks for existing records to prevent duplicates during the seeding process, improving data integrity.
- Enhanced error handling during the creation of authors and books, ensuring existing records are utilized when available.
- Updated logging to provide clearer feedback on the seeding process, including details on existing records and errors encountered.
- Enhanced the slug generation process in the TransmitterReliability and OpinionStatus models to include robust error handling, ensuring unique slugs are created even when the title is invalid or empty.
- Implemented a mechanism to fix duplicate slugs during the seeding process, ensuring data integrity and preventing conflicts.
- Updated the seeding command to handle existing records more efficiently, improving overall reliability and opinion status creation.
- Enhanced the narrator layer creation process to include error handling, ensuring that existing layers are retrieved if creation fails.
- Introduced a new migration to fix NarratorLayer records with empty or invalid slugs, generating slugs based on the name field or defaulting to a structured format.
- Improved slug conflict resolution to prevent duplicates during the migration process.
- Updated tag creation to check for existing tags before creating new ones, enhancing efficiency.
- Improved transmitter name generation by deriving the father's name from a random selection of names.
- Added safeguards to ensure reliability status is only assigned if available.
- Adjusted tag assignment to ensure a valid number of tags is added to each hadis entry.
- Added 'explanations' and 'address_details' JSON fields to the Hadis model for improved data structure.
- Updated HadisAdminForm to include new fields in the admin interface.
- Introduced a new management command for comprehensive seeding of Hadis data, including Russian language support.
- Enhanced serializers to process and return structured explanations and address details based on request language.
- Updated entrypoint script to include the new data seeding command during initialization.
- Reduced the number of Gunicorn workers in the production Docker configuration from 32 to 6 for improved resource management.
- Enhanced the hadis data seeding command to calculate and distribute hadis entries more effectively across categories, ensuring balanced creation while respecting maximum limits.
- Added a new list of Russian hadis titles for random selection during seeding.
- Refactored category creation to use batch operations for improved performance.
- Implemented bulk creation of hadis records to optimize database interactions.
- Updated command output messages to reflect optimizations and progress during execution.
- Introduced a new management command to seed Russian language data for Hadis, HadisCategory, and HadisSect.
- Updated entrypoint script to include the new command for seeding Russian data during initialization.
- Introduced SubdomainRoutingMiddleware to handle routing based on subdomains.
- Added URL configuration for the admin subdomain, including Swagger/Redoc support.
- Updated settings to include the new middleware for proper request handling.
- Implemented SubdomainRoutingMiddleware to route requests based on subdomains.
- Created urls_admin.py for handling admin-related URLs and Swagger documentation.
- Updated base settings to include the new middleware for subdomain handling.