/** * Récupère les Activities * * @Annotations\QueryParam(name="offset", requirements="\d+", nullable=true, description="Offset from which to start listing objects.") * @Annotations\QueryParam(name="limit", requirements="\d+", default="10", description="How many objects to return.") * @Annotations\QueryParam(name="sort_field", requirements="\w+", default="id", description="Field to use for sorting.", nullable=true) * @Annotations\QueryParam(name="sort_order", requirements="^asc|desc$", default="desc", description="Order of the sort.", nullable=true) * @Annotations\QueryParam(name="action", requirements="\w+", description="Filtre sur une action", nullable=true) * @Annotations\QueryParam(name="from_user_id", requirements="\w+", description="Id user émetteur", nullable=true) * @Annotations\QueryParam(name="to_user_id", requirements="\w+", description="Id user destinataire", nullable=true) * @Annotations\QueryParam(name="object_type", requirements="\w+", description="Type objet", nullable=true) * @Annotations\QueryParam(name="child_object_type", requirements="\w+", description="Type objet enfant", nullable=true) * @Annotations\QueryParam(name="_return_objects", requirements="^1|0$", default="0", description="Retourne ou pas les objets liés") * * @param Request $request the request object * @param ParamFetcherInterface $paramFetcher param fetcher service * * @ApiDoc() * @Annotations\Get("/activities") */ public function getActivitysAction(Request $request, ParamFetcherInterface $paramFetcher) { $serialize_groups = ['Default']; if ($paramFetcher->get('_return_objects') == 1) { $serialize_groups[] = 'link'; } else { $serialize_groups[] = 'id'; } return parent::getObjectsAction($request, $paramFetcher, $serialize_groups); }
/** * Récupère une traduction * * @param string $id Identifiant * @return [type] [description] * * @ApiDoc() */ public function getTranslationAction($id) { return parent::getObjectAction($id); }
/** * Récupère les Email Activities * * @Annotations\QueryParam(name="offset", requirements="\d+", nullable=true, description="Offset from which to start listing objects.") * @Annotations\QueryParam(name="limit", requirements="\d+", default="10", description="How many objects to return.") * @Annotations\QueryParam(name="sort_field", requirements="\w+", description="Field to use for sorting.", nullable=true) * @Annotations\QueryParam(name="sort_order", requirements="^asc|desc$", description="Order of the sort.", nullable=true) * @Annotations\QueryParam(name="from_user_id", requirements="\w+", description="Id user émetteur", nullable=true) * @Annotations\QueryParam(name="to_user_id", requirements="\w+", description="Id user destinataire", nullable=true) * * @param Request $request the request object * @param ParamFetcherInterface $paramFetcher param fetcher service * * @ApiDoc() * @Annotations\Get("/email_activities") */ public function getEmailActivitysAction(Request $request, ParamFetcherInterface $paramFetcher) { return parent::getObjectsAction($request, $paramFetcher); }