Jsf 我们可以在对话框中显示p:编辑器吗?

Jsf 我们可以在对话框中显示p:编辑器吗?,jsf,primefaces,Jsf,Primefaces,嗨,当我试图将p:编辑器放入对话框时,它没有显示。如何将其放入对话框 <p:commandButton value="Submit" update="display" oncomplete="dlg.show()" icon="ui-icon-disk" /> <p:dialog header="Content" widgetVar="dlg" showEffect="fade" hideEffect="fade"> <p:editor id="edit

嗨,当我试图将p:编辑器放入对话框时,它没有显示。如何将其放入对话框

 <p:commandButton value="Submit" update="display" oncomplete="dlg.show()" icon="ui-icon-disk" />

<p:dialog header="Content" widgetVar="dlg" showEffect="fade" hideEffect="fade">
    <p:editor id="editor" widgetVar="editorWidget" value="#{editorView.text}" width="600" />
   </p:dialog>

它被渲染成

<div id="form1:editorsad" style="visibility:hidden">
<textarea id="form1:editorsad_input" name="form1:editorsad_input"></textarea>
</div>

但是正常的p:editor不是在对话框中渲染的,就像

<div id="form1:editor" style="">
<div class="ui-editor" style="width: 600px; height: 250px;">
<div class="ui-editor-toolbar" style="height: 53px;">
<textarea id="form1:editor_input" name="form1:editor_input" style="display: none; width: 600px; height: 197px;"></textarea>
<iframe frameborder="0" src="javascript:true;" style="display: block; width: 600px; height: 197px;">
</div>
</div>


如何解决这个问题???

我找到了一个解决方案,它无法加载内容,因为它无法通过dialog.js-Line No:136中的条件(包含在primeface jar 3.3.1中)
----------------如果(!this.loaded&&this.cfg.dynamic)------------------ 在“show:function()”中。。。。如果该'if'条件通过此.loadContents();将执行并加载编辑器组件内容。我在“if”条件之外使用了this.loadContents(),以便能够获取“editor”组件。我不知道“如果条件失败,为什么会这样”。有人能告诉我,如果条件失败,为什么会这样吗?????

您使用的是哪种PF版本?你有JS错误吗?在PrimeFaces5.1(在JSF2.3.0-m01上运行)上工作正常。我刚刚更改了
oncomplete
属性的值,以反映PrimeFaces 4.0之后所做的新更改,即
oncomplete=“PF('dlg')。show()”
。我使用的是PrimeFaces 3.3.1,但对话框和编辑器的渲染器类没有太大的更改。。。我没有收到任何js错误,只有警告。。