public function remove(Application $app, Request $request, $productClassId)
{
$this->isTokenValid($app);
log_info('カート削除処理開始', array('product_class_id' => $productClassId));
// FRONT_CART_REMOVE_INITIALIZE
$event = new EventArgs(array('productClassId' => $productClassId), $request);
$app['eccube.event.dispatcher']->dispatch(EccubeEvents::FRONT_CART_REMOVE_INITIALIZE, $event);
$productClassId = $event->getArgument('productClassId');
$app['eccube.service.cart']->removeProduct($productClassId)->save();
log_info('カート削除処理完了', array('product_class_id' => $productClassId));
// FRONT_CART_REMOVE_COMPLETE
$event = new EventArgs(array('productClassId' => $productClassId), $request);
$app['eccube.event.dispatcher']->dispatch(EccubeEvents::FRONT_CART_REMOVE_COMPLETE, $event);
if ($event->hasResponse()) {
return $event->getResponse();
}
return $app->redirect($app->url('cart'));
}