Giter VIP home page Giter VIP logo

ticketingbundle's Introduction

TicketingBundle

License: MIT Contributions welcome Packagist download GitHub release

TicketingBundle is a community-driven project, created and maintained by a group of students from ESGI.

Installation

Add TicketingBundle to your project

$ composer require maps_red/ticketing-bundle

Documentation

  1. Setting up the bundle
  2. Setting up the entities
  3. Default configuration

Contribute

Want to report a bug or request a feature?

Check out our Issue section to create your report.

Want to contribute to TicketingBundle?

Check out our Contributing Guide to get started with setting up the repository.

License

TicketingBundle is under MIT License.

Credits

TicketingBundle is created and maintained by

Special thanks to :

ticketingbundle's People

Contributors

axele avatar mapsred avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

ticketingbundle's Issues

Reference Tickets to a Ticket

Is your feature request related to a problem? Please describe.
I would like to add a reference of ticket(s), with a link for example, to an another ticket.
With this, the user could tag an another ticket to use it like an example.

Describe the solution you'd like
That should be an another field to Ticket

Describe alternatives you've considered
This field could be nullable

Create the "all tickets" page

Create a page will all the tickets, without order for now with DataTables.

It needs to be loaded dynamically as to not slow down the page if the user have a great number of tickets.

There are no unit tests

Hello,

Your project looks great but misses one major thing to avoid bug and makes people confident with your bundle: unit tests.

Please consider addition of those tests and potentially a travis continuous integration ! 👼

Restricted tickets

In the config :

restricted_tickets_role: "ROLE_USER" # Set a role that will have access to the "staff" tickets
enable_ticket_restriction: true # if true, all new tickets will only be accessible to the owner and the **restricted_ticket_role**. If false, all new tickets will be **public**

restricted_ticket_role will be used in the RequestSubscriber and will block users

enable_ticket_restriction will be injected in the TicketManager and used in the createTicket method

Update views

  • Replace the base.html.twig with the one from the Demo to have a real base file
  • Handle the CSS with assets (assets('/bundles/ticketingbundle/css/..'))
  • To handle CSS with assets, you need this folder Resources/public/css

Add the id parameter to entities

Add the following codes to all entities :

    /**
     * @var integer
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="IDENTITY")
     */
    private $id;

    public function getId()
    {
        return $this->id;
    }

And

    public function getId(); 

To all models

Update the doc in consequence

Manager service

Create a service with all the ticketing managers inside

With dynamic (__call) methods as getTicketManager

And the get method with a class as parameter

All the manager will be in an array with this syntax

Ticket::class => TicketManager

New ticket page

Create a Controller called TicketingController (in the src/Controller folder)

In this Controller create the route "/nouveau"

Create a TicketForm (in the src/Form folder). For now just put add the description field and fill manually (with created value) the other fields

missing support for english users

Is your feature request related to a problem? Please describe.
Now eg. demo is not showing any english texts, so quite hard to know what to click etc.

Describe the solution you'd like
Make your application default language english, so that more people can see / understand what it's doing.

Describe alternatives you've considered
Or at least provide some language options that users can choose.

Additional context
Didn't found login screen after three different clicks because of that - didn't bother continue further because of this language issue.

Recipe for SF4.x

Is your feature request related to a problem? Please describe.
Seems like documentation is showing how to setup this bundle as in SF3.x So no really support for SF4.x + flex with recipes to configure this bundle automatically.

Describe the solution you'd like
Add recipe for symfony flex to configure this automatically and fix your docs for SF3 and SF4 users.

DataTables error

Describe the bug
When i use the DataTables search, I get two error :

DataTables warning: table id=DataTables_Table_0 - Invalid JSON response. For more information about this error, please see http://datatables.net/tn/1

DataTables warning: table id=DataTables_Table_0 - Ajax error. For more information about this error, please see http://datatables.net/tn/7

To Reproduce
Steps to reproduce the behavior:

  1. Go to /ticket/perso
  2. Write "Author name" or other search
  3. See error

Desktop (please complete the following information):

  • Browser [Mozilla]

Make Fixture

We should make some Fixture for User / Ticket etc..

When you come at "My tickets" page for example we have some error :
image

The fixture could fix the problem and will boost the project.

Update page List

If the User don't have the role super admin he should see his ticket AND the public.

Actually he only see his own ticket.

Following the #5

Modification Route

When you come the first time on the TicketingBundleDemo you get an error page.

We should do a redirection into the login page.

Create the ticket manager

The ticket manager will help us to interact with the ticket

For now the TicketManager need to have a TicketStatusInterface as parameter. It will be the default status of the tickets.

Create repositories

Create a Repository for all Entity

namespace Maps_red\TicketingBundle\Repository;

use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;

class TicketRepository extends ServiceEntityRepository
{
}

And add in the docs to extend the Repository

<?php

namespace App\Repository;

use App\Entity\Ticket;
use Symfony\Bridge\Doctrine\RegistryInterface;
use Maps_red\TicketingBundle\Repository\TicketRepository as BaseTicketRepository;

/**
 * @method Ticket|null find($id, $lockMode = null, $lockVersion = null)
 * @method Ticket|null findOneBy(array $criteria, array $orderBy = null)
 * @method Ticket[]    findAll()
 * @method Ticket[]    findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null)
 */
class TicketRepository extends BaseTicketRepository
{
    public function __construct(RegistryInterface $registry)
    {
        parent::__construct($registry, Ticket::class);
    }
}

Configs

Enable / disable the history

Fixtures

Move fixtures from the demo to the bundle

Create the ticket page

You need to create a DataTable for EACH ticket status exiting.

Each category needs to be dynamiccaly loaded as to not slow down the page.

Each category needs to have an auto-refresh every X minutes.

The X minutes will need to be defined in the config with a default value of 1 (minute)

New ticket | No date on "created_at"

Describe the bug
When you add a new ticket there is no date on "created_at"

To Reproduce
Steps to reproduce the behavior:

  1. Go to '/ticket/new'
  2. Fill the form
  3. Click on 'Save'
  4. See error

Expected behavior
It should create a new ticket with the value of date() on "created_at"

Desktop (please complete the following information):

  • Firefox & Chrome

Additional context
I wanted to test the issue: bug report

TicketHistory

By an Event System (see EventSubscriber) handle the ticket history (seen or not seen)

Add all the Managers

Create a Manager class for each entities :

By following the examples you need to create and configure a Manager for each entity.

Don't forget to define it as a service, with the tag and with the right class parameter (from the bundle config)

<?php

namespace Maps_red\TicketingBundle\Manager;


class TicketStatusManager extends AbstractManager
{
}
# Resources/config/services.yaml
services:
#...
    Maps_red\TicketingBundle\Manager\TicketStatusManager:
        tags:
            - { name: ticketing.manager, class: 'ticket_status'}

Add status history

Is your feature request related to a problem? Please describe.
In my opinion, it would be great to see the status history of a ticket in order to quickly see why it take too long to be closed

Describe the solution you'd like
Maybe in the details page (http://ticketing-bundle-demo.mindgame.ovh/ticket/detail/2) you may add a new block "History" below "Commentaires"

Add ticketing to navbar

Is your feature request related to a problem? Please describe.
The ticketing links are not displayed

Describe the solution you'd like
Add the links to the navbar

Field "Priority" to Ticket

Is your feature request related to a problem? Please describe.
It will be great if we can attribuate a priority system to the ticket

Describe the solution you'd like
I would like a priority system to the ticket, so I could assigned "Urgent", "Normal" or "Waiting" to a Ticket.

Describe alternatives you've considered
If there is no priority filled by the user, it will be "Normal".

Additional context
After this, we will represent this priority with color in the datatable.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.