Rename Bus Add to Create

This commit is contained in:
James Brooks
2017-03-18 09:30:36 +00:00
parent 7d27c61abe
commit a55575656d
34 changed files with 163 additions and 116 deletions

View File

@@ -12,10 +12,10 @@
namespace CachetHQ\Cachet\Http\Controllers\Dashboard;
use AltThree\Validator\ValidationException;
use CachetHQ\Cachet\Bus\Commands\Component\AddComponentCommand;
use CachetHQ\Cachet\Bus\Commands\Component\CreateComponentCommand;
use CachetHQ\Cachet\Bus\Commands\Component\RemoveComponentCommand;
use CachetHQ\Cachet\Bus\Commands\Component\UpdateComponentCommand;
use CachetHQ\Cachet\Bus\Commands\ComponentGroup\AddComponentGroupCommand;
use CachetHQ\Cachet\Bus\Commands\ComponentGroup\CreateComponentGroupCommand;
use CachetHQ\Cachet\Bus\Commands\ComponentGroup\RemoveComponentGroupCommand;
use CachetHQ\Cachet\Bus\Commands\ComponentGroup\UpdateComponentGroupCommand;
use CachetHQ\Cachet\Models\Component;
@@ -182,7 +182,7 @@ class ComponentController extends Controller
$tags = array_pull($componentData, 'tags');
try {
$component = dispatch(new AddComponentCommand(
$component = dispatch(new CreateComponentCommand(
$componentData['name'],
$componentData['description'],
$componentData['status'],
@@ -276,7 +276,7 @@ class ComponentController extends Controller
public function postAddComponentGroup()
{
try {
$group = dispatch(new AddComponentGroupCommand(
$group = dispatch(new CreateComponentGroupCommand(
Binput::get('name'),
Binput::get('order', 0),
Binput::get('collapsed'),