Hi,

I was wondering if you would be able to help us.

Requested Business requirement: Allow administrators to attach a staff member to a visual floor plan (using Google Maps with an overlay).

We have the following detailed requirements:
-Ability to save a staff member's location on a floor plan using Google Maps and an overlay image.
-Overlay image depends on which floor the staff member works on. Able to be changed by a list box (e.g. Level 1, Level 2, Level 2).
-Ability to click on a staff member's profile and see the floorplan where they sit.

We have so far managed to get an overlay working using the gmap macro.

The thing we would like to know is what your advice is on creating the floor plan and having the ability to have multiple floors so that the overlay changes for each person depending on the floor number selected in a drop down box.

Please feel free to ask me for more clarification.

Realy appreciate your help a lot.

cheers,

Ben

Comments

hutch’s picture

I would suggest that you should write a helper module to do something like this:

Provide the page the administrator will use to attach floorplan to user. The page would display a map and dropdown and a way to select a user.
Write some javascript to manage the dropdown, using jquery to collect what has been selected (floorplan and user) and send this information to another javascript function that disables any other floorplan layers and enables the selected floorplan layer and updates the map. Once the setting has been accepted (with another button) you could use jquery ajax to update a table/field on the server with the new information and reset the map and form ready for another entry.
The helper module can use hook_user() to add information to the user's profile page.
Another advantage of rolling your own is that you can use Google Maps API version 3 which is much better.

johnv’s picture

Title: Using the GMap and Location modules in D7 to create a floor plan » Add new layer to GMap to create a floor plan