Merging Spree and BrowserCMS for my app

Hello All,

I have a fixed price contract to develop a website for a training
organisation that will show courses they offer,
dates, times and venues when they run. There is also a fair amount
of typical CMS content, and the potential for more course content,
so BrowserCMS seems well suited.

They also want to have bookings and payments online via PayPal, so
I have been considering Spree, although on further analysis I only
need/can use the shopping cart & checkout, plus the data structures
(models) from Spree. I think I can avoid the user seeing the Spree
backend
or product pages (nothing personal, these pages are just more CMS
than product like.)

So far my preferred strategy is (not necessarily in order) :

  1. merge the spree and BCMS tables into a single database.
    The only naming overlap is users, schema_migrations and potentially
    sessions.
  2. if they can’t share sessions, then patch BCMS to create/delete Spree
    sessions
    in parallel with its own sessions.
  3. run Spree and BCMS independantly with Apache and Passenger on
    different
    subdomains.
  4. write a BCMS module to load spree’s models
  5. patch the new admin panels into the BCMS admin
  6. Create product selection forms on BCMS pages that use the Spree
    models,
    eventually constructing an order and redirecting the customer to
    the spree cart on its own subdomain.

Any feedback/warnings/advice/encouragement/gasps of horror would be
welcome.

While this may not be following the golden path toward mountable apps,
hopefully there will be some contribution toward a nice integration
between these (IMHO) flagship Rails projects that together would cover
the needs of so many business sites.

Cheers,

Gary McGhee
Buzzware Solutions

Hi,
I am also doing same thing. I also have “users” table overlap in the
BCMS and in my Spree application. We decided to use the “users” table of
“spree” application.
Here is problem as BCMS already have a “user.rb” model so How would I
make the connection to the “spree” application database for “users”
table.
I have intsalled the browser cms gem due to that all code went to the
ruby dir.
How would I solve this problem?
How should I override the model?
Do you have any idea?

Thanks,
Tushar

Tushar G. wrote:

Hi,
I am also doing same thing. I also have “users” table overlap in the
BCMS and in my Spree application. We decided to use the “users” table of
“spree” application.

I went the other way - renaming the Spree table. See
http://railsdog.lighthouseapp.com/projects/31096/tickets/739-one-line-change-to-make-spree-cope-with-its-users-table-being-renamed-in-order-to-share-the-database-with-another-integrated-app

You may be able to use a similar technique on the browsercms side.

Cheers

Gary