Jump to content

Share users ni multiple prestashop sites.


wncdevelopment
 Share

Recommended Posts

Hi, i need prestashop to save and load users from a separate database, which contains "customers" table.
For that, i ve tried adding the name of that database to the sentences where "customers" table is used .
Example (not real )
select * from customers
is now:
select * from usersdb.customers
where usersdb is the database we use for all customers.

The problem is that the way i did it, i doesnt work. I need some advice from prestashop experts who can help me in this. I know its not simple but i really need that.
I want that if you want to buy in any of my stores, you just make a single user from my website or any store in my store network and you can use it for buying in all that stores

Thanks in advance, i hope you can help me .

Share this post


Link to post
Share on other sites

  • 3 weeks later...

Hi,

Have you managed to do this ? I'm busy form time to time also with this, the issue is the views up updates and so on... a "select" view is kinda simple... now the rest.

Share this post


Link to post
Share on other sites

Hi,

Have you managed to do this ? I'm busy form time to time also with this, the issue is the views up updates and so on... a "select" view is kinda simple... now the rest.

The only solution i found was moving my project into opencart ecommerce. Prestashop was too complex (or impossible, we tried really hard, with a friend and we couldnt make it work) to modify that part, opencart in the other hand was perfect for what we need. It doesnt have too much templates, modules, etc, but the basics are great.
Sorry for not closing this thread before, ive been busy and forgot to do it .
With OC now i have treee databases with different data, for example i have users in one, categories in another (not implemented yet, because i didnt have that idea when i started the project) and a third database for each site containing all specific data for the store (config, prods, etc)

Share this post


Link to post
Share on other sites

The proper way to do is to create a view in the database. You create a view that points to the other table. You first need to delete the customer table on the second installation, and create a view with the same name pointing to the customer table in the first installation. Check this:

http://dev.mysql.com/doc/refman/5.0/en/create-view.html


I have done that, works great for login but I was stuck on insert a new one or updating a user....

So any help on that would be nice!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More