rolandsaven/bugherd-bundle
最新稳定版本:0.1.0
Composer 安装命令:
composer require rolandsaven/bugherd-bundle
包简介
This is a Symfony 2-3 bundle to interact with the Bugherd API v2
README 文档
README
This is a Symfony 2-3 bundle to interact with the Bugherd API v2 via php-bugherd-api.
Requirements
- A Bugherd account
- PHP 5.5+
- Symfony 2.8+
Installation
Use Composer to add this bundle to your Symfony application.
Add rolandsaven/bugherd-bundle to your composer.json file:
{
"require": {
"rolandsaven/bugherd-bundle": "dev-master"
}
}
Edit AppKernel.php by inserting the following:
public function registerBundles() { $bundles = array( // ... new RolandSaven\BugherdBundle\BugherdBundle(), // ... ); }
To use the API, please generate an API key for your organization from within BugHerd, under Settings > General Settings and add it to config.yml:
bugherd: api_key: your_bugherd__api_key
Finally, run composer update.
Accessing the Bugherd API
In a controller you can access the Bugherd client and the API resources as follows:
// Get the BugHeard Api Client $bugherd = $this->get('bugherd'); /** Projects **/ // Get all projects $projects = $bugherd->api('project')->all(); // Get all active projects $active_projects = $bugherd->api('project')->allActive(); // Get all projects with name/id pairs $projects = $bugherd->api('project')->listing($forceUpdate, $reverse); // Get all active projects with name/id pairs $active_projects = $bugherd->api('project')->listingActive($forceUpdate, $reverse); // Get project id given its name $id = $bugherd->api('project')->getIdByName($name); // Get a project $project = $bugherd->api('project')->show($id); // Create a project $project = $bugherd->api('project')->create(array( 'name' => 'Name of the Project', 'devurl' => 'http://example.com/', 'is_active' => true, 'is_public' => false, )); /** Users **/ // Get all users $users = $bugherd->api('user')->all(); // Get all guests $guests = $bugherd->api('user')->getGuests(); // Get all members $members = $bugherd->api('user')->getMembers(); / Tasks **/ // Get a task $task = $bugherd->api('task')->show($projectId, $taskId); // Create a task $task = $bugherd->api('task')->create($projectId, array( 'description' => 'Some description', 'requester_id' => $requester_id, 'requester_email' => $requester_email )); // Update a task $task = $bugherd->api('task')->update($projectId, $taskId, array( 'description' => 'Some new description', )); // Get all tasks $tasks = $bugherd->api('task')->all($projectId, array( 'status' => 'backlog', 'priority' => 'critical' )); /** Organization **/ // Get organization information $organization = $bugherd->api('organization')->show(); /** Comments **/ // Create a comment $comment = $bugherd->api('comment')->create($projectId, $taskId, array( 'text' => 'some comment', 'user_id' => $user_id, 'user_email' => $user_email )); // Get all comments $comments = $bugherd->api('comment')->all($projectId, $taskId); /** Webhooks **/ // Get all webhooks $webhooks = $bugherd->api('webhook')->all(); // Create a webhook $webhook = $bugherd->api('webhook')->create(array( 'target_url' => 'http://example.com/tasks/create', 'event' => 'task_create' // this could be task_update, task_destroy, comment )); // Delete a webhook $bugherd->api('webhook')->remove($webhookId);
Contributing
This library is still work in progress.PR-s are welcome both here and for the PHP SDK php-bugherd-api.
Author
The library was written and maintained by Roland Kalocsaven from Onwwward.
References
rolandsaven/bugherd-bundle 适用场景与选型建议
rolandsaven/bugherd-bundle 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 5 次下载、GitHub Stars 达 0, 最近一次更新时间为 2016 年 08 月 02 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「symfony」 「bugherd」 「support」 「help desk」 「bug tracker」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 rolandsaven/bugherd-bundle 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 rolandsaven/bugherd-bundle 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 rolandsaven/bugherd-bundle 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
The bundle for easy using json-rpc api on your project
Bundle Symfony DaplosBundle
a simple toolkit for social networks
ARCANEDEV Support Helpers
Easily install Bugherd on your Craft CMS site
Bugherd.com implementation for Silverstripe
统计信息
- 总下载量: 5
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 12
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-08-02