Question

I'm having an issue with bindings, so time to refer to the experts.

I have a cfselect that binds to a cfc.

 <cfselect name="events" id="events" selected="#form.event_id#" 
 bind="cfc:feat.models.dynform.getEventsByGroup({groups})" display="event_name" 
 value="nd_event_id" queryPosition="below">

Which works well in my local environment, defined as "feat" under my local /www directory. My issue is when I move it to the dev server, which I believed to be in "beat", ie:

 bind="cfc:beat.models.dynform.getEventsByGroup({groups})"

I receive the error "model not found", event though the model is there. I assume this is because the dev server is arranged differently than my local one. Is there a clue in the ColdBox config as to where this should point?

I also attempted to change the bind to call the model (so I wouldn't have to use different markup than my local) by placing the model in the rc collection:

 bind="cfc:#rc.dynformservice#.getEventsByGroup({groups})"

However, I get an error "cannot cast complex datatypes as string".

Any suggestions? I'm in your debt for any help.

Was it helpful?

Solution

The coldbox way of passing in a path is

 cfc:#getSetting('AppMapping')#.model.dynform... 
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top