You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by sijaffer <si...@gmail.com> on 2010/02/19 21:49:06 UTC

[Trinidad] - Passing parameters with charts to back end bean

I am trying to pass two parameters with a trinidad chart, is that possible, I
get 

setActionListener must be inside of a UIComponent tag.

my jsp has

				<tr:chart id="chart" inlineStyle="width:680px; height:400px;"
							value="#{iPIChartBean.value}" binding="#{iPIChartBean.component}">
							<tr:setActionListener from="HPI" to="ScenarioItemType"/>
							<tr:setActionListener from="3" to="ScenarioItemID"/>
				</tr:chart>

Bean code:
			RequestContext context = RequestContext.getCurrentInstance();
			Map map = context.getPageFlowScope();
			ScenarioItemType = (String)map.get("ScenarioItemType");
			ScenarioItemID = (Integer)map.get("ScenarioItemID");
			_chartModel.setScenarioItemID(ScenarioItemID);
			_chartModel.setScenarioItemType(ScenarioItemType);

what am I doing wrong. 

I have tried the <f:param solution but get null when I use FaceContext to
get the data.


Regards,

Sameer Jaffer
-- 
View this message in context: http://old.nabble.com/-Trinidad----Passing-parameters-with-charts-to-back-end-bean-tp27660062p27660062.html
Sent from the My Faces - Dev mailing list archive at Nabble.com.


Re: [Trinidad] - Passing parameters with charts to back end bean

Posted by sijaffer <si...@gmail.com>.

Anyone??



sijaffer wrote:
> 
> I am trying to pass two parameters with a trinidad chart, is that
> possible, I get 
> 
> setActionListener must be inside of a UIComponent tag.
> 
> my jsp has
> 
> 				<tr:chart id="chart" inlineStyle="width:680px; height:400px;"
> 							value="#{iPIChartBean.value}" binding="#{iPIChartBean.component}">
> 							<tr:setActionListener from="HPI" to="ScenarioItemType"/>
> 							<tr:setActionListener from="3" to="ScenarioItemID"/>
> 				</tr:chart>
> 
> Bean code:
> 			RequestContext context = RequestContext.getCurrentInstance();
> 			Map map = context.getPageFlowScope();
> 			ScenarioItemType = (String)map.get("ScenarioItemType");
> 			ScenarioItemID = (Integer)map.get("ScenarioItemID");
> 			_chartModel.setScenarioItemID(ScenarioItemID);
> 			_chartModel.setScenarioItemType(ScenarioItemType);
> 
> what am I doing wrong. 
> 
> I have tried the <f:param solution but get null when I use FaceContext to
> get the data.
> 
> 
> Regards,
> 
> Sameer Jaffer
> 

-- 
View this message in context: http://old.nabble.com/-Trinidad----Passing-parameters-with-charts-to-back-end-bean-tp27660062p27690817.html
Sent from the My Faces - Dev mailing list archive at Nabble.com.