p:textEditor doesn't work after ajax update

UI Components for JSF
Post Reply
k.i.b.o.r.g.
Posts: 17
Joined: 30 Oct 2016, 10:30

11 Mar 2017, 19:24

Hello. I noticed that toolbar of p:textEditor in dialog doesn't work after ajax update. But if we do a replace p:textEditor on p:editor everything works fine. Dialog is updated while opening for get values from bean. Here my dialog.xhtml

Code: Select all

<p:dialog position="center top" id="browseNoteDialogID" closable="false" widgetVar="browseNoteDialog" resizable="false" modal="true"
                  draggable="false">
                   <p:textEditor widgetVar="editorEditNote" height="200" value="#{mainView.selectedItem.comments}"
                                  valueChangeListener="#{mainView.commentsIsChanged}" style="width: 400px"/>
</p:dialog>
It seems that p:textEditor doesn't survive an update. I use Primafaces 6.1.RC1

k.i.b.o.r.g.
Posts: 17
Joined: 30 Oct 2016, 10:30

12 Mar 2017, 12:25

So if insert <p:ajax event="open' update="textEditor"/> into dialog it will be work fine. I just did update from bean :

Code: Select all

 RequestContext.getCurrentInstance().update("DialogID");
and it causes a strange behaviour somehow...

tandraschko
PrimeFaces Core Developer
Posts: 3979
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

12 Mar 2017, 14:50

I don't think that

Code: Select all

RequestContext.getCurrentInstance().update("DialogID");
will work. You need the whole absolute ID.
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

k.i.b.o.r.g.
Posts: 17
Joined: 30 Oct 2016, 10:30

12 Mar 2017, 15:28

Code: Select all

RequestContext.getCurrentInstance().update("DialogID");
it works, but then toolbar of textEditor works badly and I dont understand why. if I use the p:ajax update after the code above toolbar works perfectly again.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 55 guests