承接 boraguler/round-robin 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

boraguler/round-robin

Composer 安装命令:

composer require boraguler/round-robin

包简介

RoundRobin for Laravel 5.8+ and above...

README 文档

README

Latest Stable Version Total Downloads Monthly Downloads Latest Unstable Version License

BoraGuler\Round-Robin is an easy way to create schedule with round-robin(rr) technique.

Installation

  1. In order to install BoraGuler\Round-Robin, just add the following to your composer.json. Then run composer update:
"boraguler/round-robin": "1.0.*"

or run composer require boraguler/round-robin

  1. Open your config/app.php and add the following to the providers array:
BoraGuler\RoundRobin\RoundRobinServiceProvider::class,
  1. Open your config/app.php and add the following to the facades array:
'RoundRobin' => boraguler\RoundRobin\RoundRobinFacade::class,

Controllers and etc

use BoraGuler\RoundRobin\RoundRobin;

Using (Examples)

Setuping (without Facade):

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = new RoundRobin($teams)->make();
// or with 'from' static method
$schedule = RoundRobin::from($teams)->make();

With a facade:

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = RoundRobin::from($teams)->make();

Generate a schedule without randomly shuffling the teams using the $shuffle boolean parameter:

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = RoundRobin::from($teams)->doNotShuffle()->make();

Use your own seed with the $seed integer parameter for predetermined shuffling:

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = RoundRobin::from($teams)->shuffle(15)->make();

If you want to pre-define round number (default = 1):

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = RoundRobin::from($teams)->rounds(3)->make();

If you want a double Round-robin:

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = RoundRobin::from($teams)->doubleRoundRobin()->make();

If you want a get a Schedule Object:

$teams = ['Galatasaray', 'Arsenal', 'Atlético de Madrid', 'Borussia', 'Barcelona','Liverpool', 'Bayer 04', 'Real Madrid'];
$schedule = RoundRobin::from($teams)->makeSchedule();

License

BoraGuler Round-Robin is free software distributed under the terms of the MIT license.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-04-02

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固