#111 ✓resolved
Mike Dvorkin

Provide support for running Fat Free CRM from sub-directory

Reported by Mike Dvorkin | October 8th, 2009 @ 09:28 PM | in 0.9.8 "Lasker"

From the email: Here's our pagination error in a nutshell, and we're convinced it has something to do with the sub-uri deployment. First, we tried to get FFCRM working with a "/crm" sub-uri with this method:

http://groups.google.com/group/fat-free-crm-users/browse_thread/thr...

We added "/crm" before every tab url in the settings.yml file, followed by rake crm:settings:load. That led to routing errors (i.e. clicking on the task tab would try to take you to ~/crm/crm/tasks rather than ~/crm/tasks).

In our second attempt, we tried the relative_url_root method (and returned the settings.yml to the default state):

http://groups.google.com/group/phusion-passenger/browse_thread/thre...

While this appeared to work fine at first, it broke the pagination so that clicking on the little number links on the bottom returns the following error:

The page at http://localhost:3000 says:

RJS error: TypeError: $("activities") is null

plus the following output afterward:

The page at http://localhost:3000 says:$("activities").update("<li class='activity' id='activity_502'>....

In short, to recreate our error you can try the following (using version 0.9.7)

  1. Add this line to environment.yml
    config.action_controller.relative_url_root = "/crm"

  2. In application.js:
    Change "/" to "/crm/" for the new Ajax.Request in the search function
    Change "/" to "/crm/" for the new Ajax.Autocompleter in the auto_complete function

  3. run the following in the FFCRM directory
    script/server --path=/crm

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Ruby on Rails CRM platform for Web 2.0 and beyond

People watching this ticket

Referenced by

Pages