Problem/Motivation

Integrate the Trash module into Varbase, ensuring it is enabled and properly configured during the Varbase installation process.

Proposed resolution

  • Add the Trash module as a dependency in the Varbase installation profile.
  • Ensure the module is enabled automatically when installing Varbase.
  • Confirm that trash/recycle bin functionality works out-of-the-box for supported content types (nodes, taxonomy, etc.).
  • Test for accessibility, responsiveness, and multi-lingual readiness of trash-related UI.
  • Add brief documentation in Varbase docs describing the trash feature, its configuration, and usage.
  • Update Varbase’s install/update tests to cover the Trash module integration.
  • Ensure there are no conflicts with existing Varbase features or permissions.
  • Verify multi-site and multi-language compatibility.

Requested by Razem:

Enable auto purge after 2 months

Remaining tasks

  • ✅ File an issue about this project
  • ✅ Addition/Change/Update/Fix to this project
  • ✅ Testing to ensure no regression
  • ✅ Automated unit/functional testing coverage
    #3545544: Add automated functional acceptance testing for Trash module integration in Varbase
  • ✅ Developer Documentation support on feature change/addition

    Added Trash to Varbase Admin doc page

  • ➖ User Guide Documentation support on feature change/addition
  • ➖ UX/UI designer responsibilities
  • ➖ Accessibility and Readability
  • ✅ Code review from 1 Varbase core team member
  • ✅ Full testing and approval
  • ✅ Credit contributors
  • ✅ Review with the product owner
  • ✅ Update Release Notes and Update Helper on new feature change/addition
  • ✅ Release varbase-10.1.0-beta1, varbase_core-10.1.57

Varbase update type

  • ✅ No Update
  • ➖ Optional Update
  • ➖ Forced Update
  • ➖ Forced Update if Unchanged

User interface changes

  • N/A

API changes

  • N/A

Data model changes

  • N/A

Release notes snippet

Feature: Content Management - Trash Management
     As a logged in user with a permission to manage content
     I want to be able to manage content lifecycle using the trash module
     So that I can soft-delete, restore, and permanently purge content individually.

  @javascript @local @development @staging @production
  Scenario: Verify Normal user cannot access trash management pages
    Given I am a logged in user with the "Normal user" user
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Access denied"
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Access denied"

  @javascript @local @development @staging @production
  Scenario: Verify Editor can access trash content but not configuration
    Given I am a logged in user with the "Editor" user
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Trash"
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Access denied"

  @javascript @local @development @staging @production
  Scenario: Verify Content admin can access trash content but not configuration
    Given I am a logged in user with the "Content admin" user
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Trash"
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Access denied"

  @javascript @local @development @staging @production
  Scenario: Verify SEO admin can access trash content but not configuration
    Given I am a logged in user with the "SEO admin" user
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Trash"
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Access denied"

  @javascript @local @development @staging @production
  Scenario: Verify Site admin can access trash content but not configuration
    Given I am a logged in user with the "Site admin" user
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Trash"
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Access denied"

  @javascript @local @development @staging @production
  Scenario: Verify webmaster has full access to trash content and configuration
    Given I am a logged in user with the "webmaster" user
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Trash"
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Trash"

  @javascript @local @development @staging @production
  Scenario: Verify default trash settings include auto-purge enabled for 2 months
    Given I am a logged in user with the "webmaster" user
     When I go to "/admin/config/content/trash"
      And wait
     Then I should see "Entity types"

    # Verify default auto-purge settings (enabled by default in varbase_admin with 2 months)
      And the "auto_purge[enabled]" checkbox should be checked
      And the "auto_purge[after]" field should contain "2 months"

  @javascript @local @development @staging @production
  Scenario: Verify complete trash workflow allows deleting, restoring, and purging content individually
    Given I am a logged in user with the "Site admin" user
    
    # Create test content for complete workflow
     When I go to "/node/add/page"
      And wait
     Then I should see "Create Basic page"
     When I fill in "Complete Workflow Test Page" for "Title"
      And wait 3s
      And I fill in the rich text editor field "Body" with "This content will be used to test complete trash workflow including delete, restore, and purge operations individually"
      And I select "published" from "edit-moderation-state-0-state--2"
      And I press the "Save as" button
      And wait
     Then I should see "Basic page Complete Workflow Test Page has been created."

    # Delete content via individual delete form
     When I go to "/admin/content"
      And wait
     Then I should see "Content"
     When I fill in "Complete Workflow Test Page" for "Title"
      And I press the "Filter" button
      And wait 3s
     Then I should see "Complete Workflow Test Page"
     When I click "Edit" in the "Complete Workflow Test Page" row
      And wait
     Then I should see "Complete Workflow Test Page"
     When I open the top bar page actions menu
     Then I should see "Delete"
     When I click "Delete"
      And wait
     Then I should see "Are you sure you want to delete"
     When I press "Delete"
      And wait 3s
     Then I should see "has been deleted."

    # Verify content appears in trash
     When I go to "/admin/content/trash"
      And wait
     Then I should see "Trash"
      And I should see "Complete Workflow Test Page"

    # Test individual restore functionality (verify restore operation works)
     When I click "Restore" in the "Complete Workflow Test Page" row
      And wait 3s
     Then I should see "Are you sure you want to restore"
     When I press the confirm button in modal
      And wait 3s
      And I wait for AJAX to finish
@javascript @local @development @staging @production
Scenario: Verify Editor can successfully restore content from trash

@javascript @local @development @staging @production
Scenario: Verify SEO admin can view and delete content but has limited trash operations
  Given I am a logged in user with the "SEO admin" user
   When I go to "/node/add/page"
    And wait
   Then I should see "Create Basic page"
   When I fill in "SEO Admin Permission Test" for "Title"
    And wait 3s
    And I fill in the rich text editor field "Body" with "Test page for SEO admin permissions - view only access to trash"
    And I select "published" from "edit-moderation-state-0-state--2"
    And I press the "Save as" button
    And wait
   Then I should see "Basic page SEO Admin Permission Test has been created."

  # Delete content as SEO admin
   When I go to "/admin/content"
    And wait
   Then I should see "Content"
   When I fill in "SEO Admin Permission Test" for "Title"
    And I press the "Filter" button
    And wait 3s
   Then I should see "SEO Admin Permission Test"
   When I click "Edit" in the "SEO Admin Permission Test" row
    And wait
   Then I should see "SEO Admin Permission Test"
   When I open the top bar page actions menu
   Then I should see "Delete"
   When I click "Delete"
    And wait
   Then I should see "Are you sure you want to delete"
   When I press "Delete"
    And wait 3s
   Then I should see "has been deleted."

  # Verify SEO admin can view trash but has limited operations
   When I go to "/admin/content/trash"
    And wait
   Then I should see "Trash"
    And I should see "SEO Admin Permission Test"

Comments

rajab natshah created an issue. See original summary.

rajab natshah’s picture

Issue summary: View changes

rajab natshah’s picture

Assigned: rajab natshah » s.halawani
Issue summary: View changes
Status: Active » Needs review
Issue tags: +varbase-10.1.0-beta1, +varbase_core-10.1.57
rajab natshah’s picture

Issue summary: View changes
rajab natshah’s picture

Assigned: s.halawani » Unassigned
Status: Needs review » Fixed

rajab natshah’s picture

Issue summary: View changes

  • rajab natshah committed a5843124 on 10.1.x
    Issue #3542860: change the default Varbase Admin recipe to grant...
rajab natshah’s picture

Issue summary: View changes
rajab natshah’s picture

Issue summary: View changes
rajab natshah’s picture

rajab natshah’s picture

Issue summary: View changes
rajab natshah’s picture

Issue summary: View changes

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

rajab natshah’s picture

Issue summary: View changes