Page 1 of 1

possible to call module in company directory

Posted: Thu May 01, 2008 10:29 am
by relic
Is it possible to call a module in company directory listings? for example in using the company directory to list night clubs around the country, what im wanting to do is call the album module in curtain company listings.

Possible?

CMSMS Specs:

Version: 1.2.4
Company module: 1.1.3

Re: possible to call module in company directory

Posted: Thu May 01, 2008 1:40 pm
by calguy1000
Sure, go for it.  I've used the address field from companydirectory to call the CGSimpleGoogleMap module to display a map to the location.

Re: possible to call module in company directory

Posted: Fri May 02, 2008 6:13 am
by relic
calguy1000 wrote: Sure, go for it.  I've used the address field from companydirectory to call the CGSimpleGoogleMap module to display a map to the location.
Thanks calguy,

But just a few more questions, i have created a custom field named "Photos" and in that field when adding a company i have just put this in:

Code: Select all

{if $entry->photos ne ''} Photos: {$entry->photos}{/if}
But nothing shows.. so i tried the following, and i think this would be easier for the site editors ect but its just getting it to work.

I have created a custom "detail" template for the company directory in that template i have been calling the "photos" field like so:

Code: Select all

{cms_module module='album' albums='{$entry->photos}'}
now this is somewhat working, but on the front end output i get this:
There are no pictures in this album.Error: The template named "" that this Album is set to use does not exist. Please go to the Album Admin Panel and assign a different template to this Album.'}
Like the error says "assign a different template" i have tried that, but no change.

this is probably something simple, but im new with CMSMS "code"

Any help or insight would be greatly appreciated.

Cheers
Dave