FOSUserBundle or PUGXMultiUserBundle have two different user profiles (Symfony2)

I doubt how to approach this problem:

The My Symfony2 application for this problem has two different profiles: the name "Seller" and "Buyer". The goal is to preserve a bunch of attributes about the "Seller", and on the other hand, not much about the "Buyer" (email and password will do this).

I understand that it is not easy to log in and register using the FOSUserBundle. There are quite a few other packages, such as PUGXMultiUserBundle, which β€œcrack” the FOSUserBundle and are not easily configured / implemented.

So my quiestion: is it right to use the hacked PUGXMultiUserBundle that offers its implementation and configuration, or is it better to stick to the FOSUserBundle, have a custom object and a one-to-one relationship with the Seller company, which represents seller attributes different from the buyer? Another problem with this approach is with the registration form, which should be divided into two parts, for the register of the seller and the buyer (which I do not know if this is possible / expedient with the help of FOSUserBundle).

Hope you guys help me figure it out. Greetings :)

+4
source share
1 answer

PUGXMultiUserBundle. , , , :

1

----------------------------------------
| id  | username  |  type  |------------
|-----|-----------|--------|------------
|  1  |  mgdepoo  | buyer  |------------
|  2  | Sydney_o9 | seller |------------
----------------------------------------

2

----------------------------------------
| id  |  buyer_specific_field_1
|-----|---------------------------------
|  1  |  
----------------------------------------

3

----------------------------------------
| id  |  seller_specific_field_1
|-----|---------------------------------
|  2  |  
----------------------------------------

.

, , , . 2 ( / , ).

, . , , , , - , . ? , .

+6

All Articles