wildwestriverrider/laravel-ratings-and-reviews 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

wildwestriverrider/laravel-ratings-and-reviews

最新稳定版本:3.1

Composer 安装命令:

composer require wildwestriverrider/laravel-ratings-and-reviews

包简介

Ratings and reviews for Laravel 10+

README 文档

README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

This package allows you to add ratings and reviews to any model in your Laravel application.

Installation

You can install the package via composer:

composer require wildwestriverrider/laravel-ratings-and-reviews

You can publish and run the migrations with:

php artisan vendor:publish --tag="ratings-and-reviews-migrations"
php artisan migrate

You can publish the config file with:

php artisan vendor:publish --tag="ratings-and-reviews-config"

This is the contents of the published config file:

return [
    'max-rating' => 5,
    'min-rating' => 1
];

Usage

Traits

HasRatings - add this to the user model that will be giving ratings

HasReviews - add this to the user model that will be giving reviews

Rateable - add this to any model that should be rateable

Reviewable - add this to any model that should be reviewable

$laravelRatingsAndReviews = new Wildwestriverrider\LaravelRatingsAndReviews();

Testing

composer test

统计信息

  • 总下载量: 610
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 4
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-10-03