0

Select Grid Row, I need show popup with label and value

asked 2014-04-21 13:04:40 +0800

sathishk gravatar image sathishk
17 5

updated 2014-04-21 13:24:20 +0800

sitansu gravatar image sitansu
2254 13
http://java91.blogspot.in...

Dear sir, I am new at Zk,Please help me I need,When i click the grid row,selected row shown as a popup with label name and value.

<grid id="displayref" visible="true" model="@load(vm.gridLists)" sizedByContent="true" 
span="true" emptyMessage="No Records Found." height="250px">
<columns sizable="true">
    <column align="center" width="140px">Referal Name</column>
    <column align="center" width="215px">Referral Email-id</column>
    <column align="center" width="120px">Contact Number </column>
    <column align="center" width="135px">Project Type</column>
    <column align="center" width="120px">Project Name</column>
    <column align="center" width="120px">Send me a copy</column>
</columns>
                                        <template name="model">
  <row popup="detail_${each.referID}, position=end_before" style="cursor:pointer">
     <label value="@load(each.referalname)" />
     <label value="@load(each.referalemail)" />
     <label value="@load(each.contactnumber)" />
     <label value="@load(each.projecttype)" />
     <label value="@load(each.projectname)" />
     <label value="@load(each.sendmeacopy)"/>
 </row>
</template>
</grid>

The above given file belongs to zul file grid. please provide me code for how to display popup a selected row.

delete flag offensive retag edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-04-22 09:44:17 +0800

chillworld gravatar image chillworld flag of Belgium
5367 4 9
https://github.com/chillw...

If you want to do a popup="" that must reference to an id of a real popup element in your zul.

example (out of mine head so its not tested so if it won't work let me know) :

<row popup="${forEachStatus.index}, position=end_before" style="cursor:pointer">
    <popup id="${forEachStatus.index}">
         <label value="@load(each.referalname)"/>
     </popup>
     <label value="@load(each.referalname)" />
     <label value="@load(each.referalemail)" />
     <label value="@load(each.contactnumber)" />
     <label value="@load(each.projecttype)" />
     <label value="@load(each.projectname)" />
     <label value="@load(each.sendmeacopy)"/>
</row>

special attention : You have to make sure that your ID of the menuPopup is unique. That's why I use here the forEachStatus.index.

Greetz chill.

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
1 follower

RSS

Stats

Asked: 2014-04-21 13:04:40 +0800

Seen: 26 times

Last updated: Apr 22 '14

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More