Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for vendor reviews #7297

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Commits on Aug 13, 2024

  1. Add support for vendor reviews

    Fixes nopSolutions#7244
    
    Add support for vendor reviews, both written about a vendor and aggregated from product reviews.
    
    * **VendorReview Class**: Add `VendorReview` class in `src/Libraries/Nop.Core/Domain/Vendors/VendorReview.cs` to handle vendor reviews with properties for `VendorId`, `CustomerId`, `Rating`, `ReviewText`, `IsApproved`, and `CreatedOnUtc`.
    * **Vendor Class**: Update `Vendor` class in `src/Libraries/Nop.Core/Domain/Vendors/Vendor.cs` to include a list of `VendorReview` and a method to calculate the average rating from the reviews.
    * **VendorController**: Update `VendorController` in `src/Presentation/Nop.Web/Areas/Admin/Controllers/VendorController.cs` to handle vendor reviews.
      - Add actions to handle vendor reviews, such as `VendorReviewsSelect`, `VendorReviewAdd`, and `VendorReviewDelete`.
      - Update the `Edit` action to include vendor reviews in the model.
    * **Caching**: Add `VendorReviewCacheEventConsumer` class in `src/Libraries/Nop.Services/Catalog/Caching/VendorReviewCacheEventConsumer.cs` to handle caching for vendor reviews.
    nirzaf committed Aug 13, 2024
    Configuration menu
    Copy the full SHA
    2c69ef8 View commit details
    Browse the repository at this point in the history