소스 검색

tickets

ideas
Charly 3 년 전
부모
커밋
c92af79607
5개의 변경된 파일14개의 추가작업 그리고 21개의 파일을 삭제
  1. +2
    -19
      Controller/Ticket/TicketAdminController.php
  2. +1
    -1
      Factory/Ticket/TicketFactory.php
  3. +8
    -0
      Factory/Ticket/TicketFactoryInterface.php
  4. +1
    -1
      Form/Ticket/TicketFormType.php
  5. +2
    -0
      Resources/translations/admin.fr.yaml

+ 2
- 19
Controller/Ticket/TicketAdminController.php 파일 보기

@@ -2,33 +2,19 @@

namespace Lc\SovBundle\Controller\Ticket;

use App\Entity\Ticket\Ticket;
use App\Entity\Ticket\TicketMessage;
use EasyCorp\Bundle\EasyAdminBundle\Collection\FieldCollection;
use EasyCorp\Bundle\EasyAdminBundle\Config\Action;
use EasyCorp\Bundle\EasyAdminBundle\Config\Actions;
use EasyCorp\Bundle\EasyAdminBundle\Config\Assets;
use EasyCorp\Bundle\EasyAdminBundle\Config\Crud;
use EasyCorp\Bundle\EasyAdminBundle\Config\Filters;
use EasyCorp\Bundle\EasyAdminBundle\Config\KeyValueStore;
use EasyCorp\Bundle\EasyAdminBundle\Context\AdminContext;
use EasyCorp\Bundle\EasyAdminBundle\Event\AfterCrudActionEvent;
use EasyCorp\Bundle\EasyAdminBundle\Event\AfterEntityPersistedEvent;
use EasyCorp\Bundle\EasyAdminBundle\Event\BeforeCrudActionEvent;
use EasyCorp\Bundle\EasyAdminBundle\Event\BeforeEntityPersistedEvent;
use EasyCorp\Bundle\EasyAdminBundle\Exception\ForbiddenActionException;
use EasyCorp\Bundle\EasyAdminBundle\Exception\InsufficientEntityPermissionException;
use EasyCorp\Bundle\EasyAdminBundle\Factory\EntityFactory;
use EasyCorp\Bundle\EasyAdminBundle\Field\AssociationField;
use EasyCorp\Bundle\EasyAdminBundle\Field\ChoiceField;
use EasyCorp\Bundle\EasyAdminBundle\Field\DateField;
use EasyCorp\Bundle\EasyAdminBundle\Field\IntegerField;
use EasyCorp\Bundle\EasyAdminBundle\Field\TextField;
use EasyCorp\Bundle\EasyAdminBundle\Router\AdminUrlGenerator;
use EasyCorp\Bundle\EasyAdminBundle\Security\Permission;
use Lc\SovBundle\Factory\Ticket\TicketFactory;
use Lc\SovBundle\Factory\Ticket\TicketFactoryInterface;
use Lc\SovBundle\Factory\Ticket\TicketMessageFactory;
use Lc\SovBundle\Field\StatusField;
use Lc\SovBundle\Form\Ticket\TicketFormType;
use Lc\SovBundle\Form\Ticket\TicketMessageFormType;
use Lc\SovBundle\Form\Ticket\TicketStatusType;
@@ -36,9 +22,6 @@ use Lc\SovBundle\Model\Ticket\TicketInterface;
use Lc\SovBundle\Controller\AbstractAdminController;
use Lc\SovBundle\Model\Ticket\TicketModel;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Translation\TranslatableMessage;

class TicketAdminController extends AbstractAdminController
{
@@ -48,7 +31,7 @@ class TicketAdminController extends AbstractAdminController
protected $em;

public function __construct(
TicketFactory $ticketFactory,
TicketFactoryInterface $ticketFactory,
TicketMessageFactory $ticketMessageFactory,
AdminUrlGenerator $adminUrlGenerator
) {

+ 1
- 1
Factory/Ticket/TicketFactory.php 파일 보기

@@ -7,7 +7,7 @@ use Doctrine\ORM\EntityManagerInterface;
use Lc\SovBundle\Factory\AbstractFactory;
use Lc\SovBundle\Model\Ticket\TicketInterface;

class TicketFactory extends AbstractFactory
class TicketFactory extends AbstractFactory implements TicketFactoryInterface
{
protected $ticketMessageFactory;


+ 8
- 0
Factory/Ticket/TicketFactoryInterface.php 파일 보기

@@ -0,0 +1,8 @@
<?php

namespace Lc\SovBundle\Factory\Ticket;

interface TicketFactoryInterface
{

}

+ 1
- 1
Form/Ticket/TicketFormType.php 파일 보기

@@ -49,7 +49,7 @@ class TicketFormType extends AbstractType
ChoiceType::class,
[
'label' => 'Type',
'choices' => $this->translatorAdmin->transChoices(TicketModel::getChoicesType(),TicketModel::class),
'choices' => $this->translatorAdmin->transChoices($entityName::getChoicesType(),TicketInterface::class),
]
);


+ 2
- 0
Resources/translations/admin.fr.yaml 파일 보기

@@ -75,6 +75,8 @@ entity:
typeOptions:
general-question: Questions générales
technical-problem: Problème technique
product-unavailable: Produit manquant
product-error: Erreur sur un produit
lastMessage: Dernier message
statusOptions:
open: Ouvert

Loading…
취소
저장