Changed the `identifier` parameter in the DOI resolution path to accept the full path format. This fixes issues where complex identifiers containing slashes were not resolving correctly. Ensures proper routing for a broader range of DOIs.
Introduced email notifications for the suffix approval process:
- Notify prefix owners when a new suffix requires approval
- Notify users when their suffix has been approved
This helps keep stakeholders informed about the status of their suffix requests, improving transparency and workflow efficiency.
Adjusted the HTML structure in prefix_list template to fix the conditional rendering of the 'No prefixes' message. This change ensures that closing list tag renders correctly and prevents layout issues. The 'Create new prefix' button for superusers was also repositioned for better code readability.
Fixes layout glitch when no prefixes are present.
Fixed a missing space in the template's superuser conditional check. This resolves an issue where the message about contacting the administrator wasn't displayed correctly to non-superusers. This change ensures proper logic execution and clearer user instructions.
Added rate limiting to the SendLoginEmailView to prevent abuse by applying the `ratelimit` decorator. Configured Redis as a cache backend based on settings from the configuration file. Updated dependencies to include `django-ratelimit`, `redis`, and `django-redis` packages to support these enhancements.
These changes improve the security and performance of the application by limiting login email attempts and using Redis for caching.
Configured DEFAULT_FROM_EMAIL to "noreply@freedoi.org" to ensure all outgoing emails have a consistent sender, improving email deliverability and reducing the likelihood of emails being marked as spam.
Configured email backend to use SMTP, console, or file-based backends based on settings. Added fallback values to handle various configurations. Updated `.gitignore` to exclude email files. This enhances email handling capabilities and ensures configuration flexibility.
- Add local Bootstrap CSS and JS files to the static directory.
- Add local jQuery file to the static directory.
- Update HTML templates to reference local static files instead of CDN links.
- Load Django static files in the base template.
- Add STATIC_ROOT to Django settings for static file collection.
These changes improve website performance and reliability by serving static assets locally, avoiding dependence on external CDNs. Additionally, this facilitates easier offline development and deployment.
Introduced endpoints for generating and managing API tokens,
enabling users to manage and regenerate their tokens via a
web interface. Added Django forms and templates to support
these functionalities.
Enhanced REST API with new endpoints for creating, updating,
and retrieving identifiers and suffixes, and included necessary
serializers.
Updated settings to include Django REST framework and token
authentication.
Formatted multiple HTML templates in the project for better readability and maintainability. Introduced indentation, adjusted spacing, and improved overall structure without altering the business logic or functionality.
Added VS Code settings to associate HTML files with Jinja syntax highlighting to enhance the development experience.
No functional changes introduced, focused solely on code readability and development efficiency improvements.
Replaced Django's built-in LogoutView with a custom LogoutView. This change includes implementing the custom view in place of the previous auth_views.LogoutView. The custom view directly logs out the user and redirects to the home page.
This refactor allows greater flexibility and control over the logout process, potentially enabling additional custom logic to be added in future.
Updated the category descriptions on the homepage to provide more detailed and clear classifications. Added new categories to cover a broader range of fields including Literature, Charity, Business, Government, and Personal. This enhances the educational value and usability of the prefix explanations.
Implemented LOGOUT_REDIRECT_URL to ensure users are redirected to the homepage after logging out, improving user experience by providing a clear redirect path. This enhancement aligns with the existing LOGIN_REDIRECT_URL settings for a consistent flow
Configured default redirection to the homepage upon login and logout actions. This improves user experience by ensuring a consistent landing page post-authentication flow.
Added custom validation methods to ensure input integrity:
- `clean_suffix` in `PrefixForm` and `SuffixForm` now enforces numeric input with minimum digit length.
- `clean_identifier` in `IdentifierForm` restricts input to alphanumeric or specific special characters.
Updated templates to display form errors, enhancing user feedback and experience.
Introduced a suffix approval workflow, allowing admins to manage pending suffixes via a new approval form and pending suffix list view. Added the ability to mark suffixes as approved, updating multiple templates and views accordingly. Ensured only the relevant suffixes appear in lists based on user permissions and approval status.
- Added SuffixApprovalForm for approval actions.
- Created migration to add description field to the Suffix model.
- Updated navigation links and templates to reflect user-specific data.
- Implemented views for pending suffixes and suffix approval.
This enhancement improves the admin experience by providing streamlined management of suffix approvals.
Introduced a description field to the Suffix model to allow for additional information to be recorded. This enhances the granularity and informativeness of the stored data, especially useful for documentation and clarification purposes.
Improved the user interface of various forms by integrating django-crispy-forms and crispy-bootstrap5. Updated form templates to use crispy forms for better styling and layout consistency. Removed the standalone login template in favor of using email-based login flow.
Benefits include:
- Enhanced form layout and styling using Bootstrap 5.
- Improved user experience with clearer instructions and polished designs.
Additionally, updated settings to include crispy forms and Bootstrap 5 template pack.
Updated the login email view to use get_or_create for retrieving user by email, ensuring a user is created if the email doesn't exist. This prevents errors when attempting to login with an unregistered email, enhancing the user experience and robustness of the login process
Updated the login link to include "Login / Register" and point to the new 'login' view instead of 'send_login_email'. This change improves user experience by clarifying the login process and emphasizing registration availability.
Updated the login button text to "Login or Sign Up" for clarity and removed the redundant "Email Login" option on the home page. Fixed the identifier list to properly handle cases where 'suffix' might be null, ensuring correct URL generation and display formatting. These changes improve user experience and address navigation issues.
Introduce a management command to delete inactive users older than 7 days. Adjust `CustomUser` model to include `date_joined` with new default settings. Enhance UI across multiple templates to improve consistency and user experience.
- Inactive user accounts cleanup enhances database hygiene.
- Updates to `CustomUser` default settings ensure consistent account states.
- Refined UI for identifier and suffix templates for better accessibility and UX.
Updated the home page greeting to show the user's email instead of their first name. This change improves user identification and ensures consistency when the first name is not provided.
Updated the identifier list to display full identifier details and target URL. Improved the suffix list to show the prefix, suffix, and name together for better clarity. These changes aim to provide more comprehensive and user-friendly information in the HTML views.
Revamped homepage content with improved welcome message, clear description of FreeDOI functionalities, and structured instructions for new users. Added sections for "What is FreeDOI?," "How Does It Work?," "Get Started," and "Contact Us." Enhanced user navigation and clarified the non-affiliation with the official DOI system.
Enhances the get_form_kwargs method in SuffixUpdateView to include the current user in the form parameters. This allows for user-specific form processing and validation, ensuring forms can access and utilize the requesting user's details.
Added validation in both the model and view to enforce a limit on the number of suffixes a user can create based on their maximum suffixes property. This ensures that users cannot exceed their allowed number of suffixes and maintains system integrity.
Updated settings to dynamically select the database backend (MySQL, MariaDB, PostgreSQL, or SQLite) based on the configuration file. This change improves flexibility and allows easier customization of the database setup by just modifying the config file.
- Added standard project documentation including README.md
- Added .gitignore for ignoring unnecessary files (.venv, *.pyc, etc.)
- Implemented basic Django application structure with accounts and resolver apps
- Configured Django settings, including two-factor auth and database setup
- Set up Django admin and basic model structures for Prefixes, Suffixes, Identifiers, and Permissions
- Added templates for accounts and resolver management
- Configured initial migrations and custom user model
- Included poetry dependencies and project setup configuration
This commit sets up the fundamental structure of the FreeDOI project, enabling DOI-like identifier creation and resolution.