jsf-2

How to send JSON using JSF2 Primefaces Request Context to Highchart?

做~自己de王妃 提交于 2020-01-06 08:44:18
问题 Hi I've been strugling with this for hours, I want to send my POJO in JSON format using Primefaces Request Context to a Highchart inside my JSF to update its value. Basically I am following this solution of @Bhesh Gurung from his own stackoverflow question but I cant seem to make it work. Right now it is throwing a: Cannot find component with identifier "pieData" referenced from "j_idt31". I want to sucessfully create a highchart using the JSON data through the Primefaces Request Context.

Not Able to Save/Update details from richfaces popup panel

[亡魂溺海] 提交于 2020-01-06 08:39:18
问题 I am working on richfaces4, when i am trying to edit details from a popup panel,i am not able to save/update the edited details into my database.can anybody help me to solve this. My XHTML Page is as follows: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html" xmlns:a4j="http://richfaces.org/a4j" xmlns:rich="http://richfaces.org/rich" xmlns:f=

Page On load event in JSF

ⅰ亾dé卋堺 提交于 2020-01-06 08:13:47
问题 I am trying to assign values to my dropdown during page load. I followed the way which is given in this link. Invoke JSF managed bean action on page load As per the link, i have tried using both the annotation and constructor type. but its an exception for me, SEVERE: An exception occurred javax.faces.FacesException: java.lang.reflect.InvocationTargetException Caused by: java.lang.reflect.InvocationTargetException Caused by: javax.el.ELException: Detected cyclic reference to managedBean

Page On load event in JSF

∥☆過路亽.° 提交于 2020-01-06 08:12:13
问题 I am trying to assign values to my dropdown during page load. I followed the way which is given in this link. Invoke JSF managed bean action on page load As per the link, i have tried using both the annotation and constructor type. but its an exception for me, SEVERE: An exception occurred javax.faces.FacesException: java.lang.reflect.InvocationTargetException Caused by: java.lang.reflect.InvocationTargetException Caused by: javax.el.ELException: Detected cyclic reference to managedBean

Why the accordion richfaces does not work after being rendered using the tag f: ajax?

随声附和 提交于 2020-01-06 07:31:05
问题 These are my pages: marcarConsulta.xhtml <ui:composition template="templates/main_template.xhtml" xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:a4j="http://richfaces.org/a4j" xmlns:rich="http://richfaces.org/rich" xmlns:c="http://java.sun.com/jsp/jstl/core"> <ui:define name="conteudo"> <h:panelGroup layout="block" id="ajax_especialidade"> <h:panelGroup layout="block" rendered

h:outputLink prefixes context path to a URL value

↘锁芯ラ 提交于 2020-01-06 06:50:10
问题 I have a h:outputLink as shown below: <h:outputLink value="#{doc.value}" style="color:blue">#{doc.key}</h:outputLink> The value is a URL www.example.com. When I click on the value, the URL I am seeing in the address bar is http://localhost:8080/Project/www.example.com . Why is the context path being prefixed to the URL? I looked up the HTML generated, but the value is the actual URL without the context path. I tried <a> in the JSF, but there's no difference. Any help to fix this would be

dynamic adding radio and InputText in jsf

无人久伴 提交于 2020-01-06 05:49:14
问题 i am getting problem in editing in textBox which are generated dynamically. see my code. <h:form> <h:panelGroup> <h:panelGrid columns="2"> <h:panelGrid columns="1"> <h:selectOneRadio id="radio1" value="#{dynamicBean.radiovalue}" layout="pageDirection" > <f:selectItems value="#{dynamicBean.objectList}" var="k1" itemValue="#{k1.value}" itemLabel="" /> </h:selectOneRadio> </h:panelGrid> <h:panelGrid columns="1" rowClasses="raw1"> <c:forEach items="#{dynamicBean.objectList}" var="k3"> <p

How to get element from javascript in JSF 2.0

旧时模样 提交于 2020-01-06 04:55:11
问题 I have JSF code like: <h:inputText id="from" value="#{fromToMBean.fromName}"/> I would like to get this element from JavaScript by ID ( from ), but I can't, because in generated HTML it is j_idt8:from How can I get this element in e.g. jQuery? Is there any way to force JSF2 not to change ids? 回答1: You can either use a custom class which you only assign to this element and use css selectors or assign an id to the form and get the element with the id formid:from . 回答2: Is there any way to force

How apply CSS on a <h:inputText>?

杀马特。学长 韩版系。学妹 提交于 2020-01-06 04:45:23
问题 I'm trying to apply CSS to my <h:inputText> but without success so far : <h:form id="contactform"> <h:panelGrid columns="3"> <h:outputLabel for="name">Name</h:outputLabel> <h:inputText id="name" value="#{contact.client.name}" > <f:ajax event="blur" render="nameMessage"></f:ajax> </h:inputText> <h:message id="nameMessage" for="name" /> <h:commandButton value="Send" action="#{contact.sendMessage}"> <f:ajax execute="@form" render="@form" /> </h:commandButton> <h:messages globalOnly="true" layout

<p:schedule> doesn't display in the presence of jquery

丶灬走出姿态 提交于 2020-01-06 03:24:12
问题 I'm trying to display a primefaces schedule on a xhtml page but this doesn't work. As said in this question, i eliminated Components which uses Ajax and i noticed that when i commented the link referencing the jquery file the schedual is displayed and it works fine but of course other jquery stop to work and i also got the following JS error : TypeError: b3 is undefined @ http://localhost:8080/theprojectname/javax.faces.resource/jquery/jquery.js.xhtml?ln=primefaces:14 When i uncomment the