-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hello,
i have the following
<?xml version="1.0" encoding="UTF-8"?>
<div apply="ui.IndexUI">
<label id="aLbl"/>
<window>
<label id="anotherLbl"/>
</window>
</div>
</zk>
and the composer
public class IndexUI extends SelectorComposer<Component>{
@Wire
Label aLbl;
@Wire
Label anotherLbl;
@Override
public void doAfterCompose(Component comp) throws Exception {
super.doAfterCompose(comp);
log("aLbl : " + aLbl);
log("anotherLbl : " + anotherLbl);
}
}
the output of this is
aLbl : <Label tS7Q1#aLbl>
anotherLbl : null
which seems to not wire anotherLbl. Why ? What i have understand wrong ?
My zk version is 7.0.3CE
Asked: 2016-08-12 09:51:01 +0800
Seen: 27 times
Last updated: Aug 20 '16
Your seconden label is in a window, witch means new idspace. Use CSS selector in order tot say window - label
chillworld ( 2016-08-12 19:10:40 +0800 )edit