Giter Club home page Giter Club logo

Comments (12)

hackzilla avatar hackzilla commented on June 30, 2024

It should be possible, as I did write the bundle with the expectation to use other data sources.
Use the model interfaces, and then register your entities in the app config.

Doctrine Ticket Entity Example

Then to register your class:
https://github.com/hackzilla/TicketBundleDemoApp/blob/master/app/config/config.yml#L80

If you have any problems, then let mw know, and I'll have a better look.

Let me know if it works, as I haven't had anyone use a different data source (that I know of).

from ticketbundle.

Keko94 avatar Keko94 commented on June 30, 2024

I can't success, I think the problem is from the entity manager. The bundle works only with an ORM.
https://github.com/hackzilla/TicketBundle/blob/develop/DependencyInjection/Compiler/DoctrineOrmMappingsPass.php

The service "hackzilla_ticket.ticket_manager" has a dependency on a non-existent service "doctrine.orm.entity_manager", one of my errors that I got.

Then do you think it's always possible to not use doctrine/orm, but an odb
I'm using FOSUserBundle with mongodb, my users work.

Thanks

from ticketbundle.

hackzilla avatar hackzilla commented on June 30, 2024

Thank you for bringing this to my attention.
I had hoped that it was compatible, but I had forgotten about dependency.

This makes more sense if I deal with #109

At least now I have an example setup to work with (FOSUserBundle and mongodb)

Related to #47

from ticketbundle.

hackzilla avatar hackzilla commented on June 30, 2024

Can I ask what version of Symfony and PHP you are using?

from ticketbundle.

Keko94 avatar Keko94 commented on June 30, 2024

from ticketbundle.

Keko94 avatar Keko94 commented on June 30, 2024

Any news ?
Maybe there is something interesting here: http://symfony.com/doc/current/doctrine/mapping_model_classes.html

from ticketbundle.

hackzilla avatar hackzilla commented on June 30, 2024

I apologise for the lack of feedback. I am still working on #109, as I noticed there were a couple of dependancies that needed removing.

I am still working on it.

from ticketbundle.

Keko94 avatar Keko94 commented on June 30, 2024

I just successed to make it work with mongodb. But... I did it fastly then it doesn't work anymore with orm, but it's not hard to make it work with both ! If I have time i will do it and i'll submit a pull request ;)

from ticketbundle.

hackzilla avatar hackzilla commented on June 30, 2024

If you link me to the mongodb version, then I'm sure I can combine them.
Personally, I don't have any experience with mongodb, so it will help.

from ticketbundle.

hackzilla avatar hackzilla commented on June 30, 2024

I've just pushed an alpha version #109.

The plan is to create a ODM version of this.
https://github.com/hackzilla/TicketBundle/blob/develop/Manager/StorageManager/DoctrineOrmStorageManager.php

from ticketbundle.

hackzilla avatar hackzilla commented on June 30, 2024

I think I've got it mostly working.

You'll have to use the develop branch for the moment, as its still not quite finished.

        "hackzilla/ticket-bundle": "dev-develop",

If you need an example of how got it setup then checkout https://github.com/hackzilla/TicketBundleDemoApp/tree/feature/mongodb

At the moment, I can't get past this error in Mongo.

app/console  fos:user:crea admin

 [Doctrine\Common\Persistence\Mapping\MappingException]                                                   
  The class 'AppBundle\Entity\User' was not found in the chain configured namespaces FOS\UserBundle\Model  

from ticketbundle.

phansys avatar phansys commented on June 30, 2024

@Keko94, are you still interested in this feature? If yes, I'd like to know if could you bring some testing for this. I'm working on #129, where I think the support for Doctrine ODM could be added.

Thank you.

from ticketbundle.

Related Issues (20)

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.