Hello, I am trying to add date dynamically i.e. multiple dates
again for each date iam trying to have multiple time fields. But fallowing code is not working as I expected. When I say extend date date row along with time is added
dynamically but having the same time fileds as that of the first row. When I select
extend time time fields are getting added for all date row. What is the solution for this. Why <xforms:setvalue
ref="instance('event-instance')/EventDate[index('list')]/EventTime[index('timelist')]/StartTime"
value="instance('time-instance')/newstarttime" /> Is not working properly? <table
align="center" >
<th></th>< > Start Date</th><th > End
Date</th><th>Start Time</th><th >End
Time</th><th >Time description</th>
<xforms:repeat id="list"
nodeset="instance('event-instance')/EventDate"> <tr
bgcolor="#FFFFFF"> <td
align="right"><xforms:trigger
appearance="minimal"> <xforms:label><xforms:output
value="concat('<img src=''', instance('date-instance')/removeimage,
'''>')" mediatype="text/html"/></xforms:label>
<xforms:action ev:event="DOMActivate"
if="count(instance('event-instance')/EventDate) != 1">
<xforms:delete context="instance('event-instance')"
nodeset="EventDate"
at="index('list')"/>
</xforms:action>
</xforms:trigger>
</td>
<td><xforms:input ref="StartDate">
</xforms:input></td>
<td><xforms:input ref="EndDate">
</xforms:input></td> <xforms:variable
name="datelistnum" value="index('list')"/>
<td><!--*********Multiple Times***********--><xforms:output
value="index('list')"/><xforms:output name="pos"
value="position()"/>
<xforms:trigger appearance="minimal">
<xforms:label>Extend time</xforms:label> <xforms:message
ref="url" ev:event="DOMActivate"
level="modal"/>
<xforms:action ev:event="DOMActivate">
<xforms:insert
nodeset="instance('event-instance')/EventDate[index('list')]/EventTime[index('timelist')]"
at="last()" position="after" />
<xforms:setvalue
ref="instance('event-instance')/EventDate[index('list')]/EventTime[index('timelist')]/StartTime"
value="instance('time-instance')/newstarttime" />
<xforms:setvalue ref="instance('event-instance')/EventDate[index('list')]/EventTime[index('timelist')]/EndTime"
value="instance('time-instance')/newendtime" />
<xforms:setvalue
ref="instance('event-instance')/EventDate[index('list')]/EventTime[index('timelist')]/Description"
value="instance('time-instance')/newdes" />
</xforms:action>
</xforms:trigger>
<table>
<xforms:repeat id="timelist"
nodeset="instance('event-instance')/EventDate[index('list')]/EventTime"> <tr>
<td><xforms:input ref="StartTime">
</xforms:input> </td>
<td><xforms:input ref="EndTime">
</xforms:input></td><td>
<xforms:textarea ref="Description"
style="width:100px;height:28px">
</xforms:textarea></td></tr>
</xforms:repeat>
</table>
<!--********************--></td>
</tr>
</xforms:repeat>
</table> Thanks & Regards Prameela
R Software Engineer Prodigy Systems & Services Ph: +91 40 2001 6080 | +91 9052368989 Web: www.prodigygroupindia.com -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
I am not very clear about your requirement but
<xforms:setvalue ref="instance('event-instance')/EventDate[index('list')]/EventTime[index('ti melist')]/StartTime" value="instance('time-instance')/newstarttime" /> As per the above setvalue would set value of instance('time-instance')/newstarttime to all its repeat elements as this is out of loop. be more clear about your requirement thread lacks in info. Vinith Gowda.
|
Free forum by Nabble | Edit this page |