get-things-done / affiliate
0.2.0
2020-12-15 04:23 UTC
Requires
- php: ^7.4|^8.0
- illuminate/contracts: ^8.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.16
- orchestra/testbench: ^6.0
- phpunit/phpunit: ^9.3
- vimeo/psalm: ^4.1
This package is auto-updated.
Last update: 2024-09-15 12:17:02 UTC
README
这里应该放置您的描述。请限制为一到两段话。可以考虑添加一个小例子。
安装
您可以通过composer安装此包
composer require get-things-done/affiliate
您可以使用以下命令发布和运行迁移
php artisan vendor:publish --provider="GetThingsDone\Affiliate\AffiliateServiceProvider" --tag="migrations" php artisan migrate
您可以使用以下命令发布配置文件
php artisan vendor:publish --provider="GetThingsDone\Affiliate\AffiliateServiceProvider" --tag="config"
这是已发布配置文件的内容
return [
];
用法
//Get invite url $inviteUrl = \GetThingsDone\Affiliate\Affiliate::getInviteUrl($user->id); //Get user's referral $referral = \GetThingsDone\Affiliate\Affiliate::getReferral($user->id); //Get user's network $network = \GetThingsDone\Affiliate\Affiliate::getNetwork($user->id,$maxLevel = 2); $networkAllLevel = $network->get(); $networkLevel1 = $network->getByLevel(1);
测试
composer test
变更日志
请参阅 变更日志 了解最近更改的详细信息。
贡献
请参阅 贡献指南 了解详细信息。
安全漏洞
请参阅 我们的安全策略 了解如何报告安全漏洞。
致谢
许可
MIT许可(MIT)。请参阅 许可文件 了解更多信息。