我在以下路径中有一张图片:
resources
\_____img
\_______sites
\_______reddit.png
Run Code Online (Sandbox Code Playgroud)
我使用以下命令行来引用它:
<p:graphicImage library="img" name="/sites/reddit.png"/>
Run Code Online (Sandbox Code Playgroud)
但在开发控制台中却说:
GET http://localhost:8080/RES_NOT_FOUND 404 ()
Run Code Online (Sandbox Code Playgroud)
并且不会渲染图像。
怎么了?
如何设置自动完成宽度以正确填充面板?
如您所见,使用:
.ui-autocomplete input {
width: 100%;
}
Run Code Online (Sandbox Code Playgroud)
将箭头移出面板
编辑:panelGrid
<p:panelGrid columns="3" style="border: hidden; width: 100%" styleClass="ui-panelgrid-blank">
<p:panelGrid>
<p:outputLabel value="Item name" for="haveName" />
<br/>
<p:autoComplete id="haveName" effect="fade" dropdown="true" forceSelection="true"/>
</p:panelGrid>
<p:panelGrid>
<p:outputLabel value="Paint" for="havePaint" />
<br/>
<p:autoComplete id="havePaint" effect="fade" dropdown="true" forceSelection="true"/>
</p:panelGrid>
<p:panelGrid>
<p:outputLabel value="Certification" for="haveCert" />
<br/>
<p:autoComplete id="haveCert" effect="fade" dropdown="true" forceSelection="true"/>
</p:panelGrid>
</p:panelGrid>
Run Code Online (Sandbox Code Playgroud)
EDIT2:这就是我style="width: 100%"在 autoComplete 标签中设置时发生的情况:
EDIT3:当我结合两者时会发生这种情况:
我的代码如下所示:
/*
* A B
* 0 0 -> 1
* 0 1 -> 0
* 1 0 -> 0
* 1 1 -> 0
*/
#define A condition_1
#define B condition_2
if (A) {
// do nothing
} else {
if (B) {
// do nothing
} else {
// do something
}
}
Run Code Online (Sandbox Code Playgroud)
上面我已经报告了1istrue和0is两个条件的真值表false,有没有办法将真值表表达为单个 if 条件?
primefaces ×2
autocomplete ×1
c++ ×1
css ×1
graphicimage ×1
if-statement ×1
jsf ×1
truthtable ×1
width ×1