Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3523

Tables & Dropdowns

$
0
0

Hello,

 

I would like to have dropdowns in a table to change the status of each row.

What I did so far: See code velow

 

XML:

<Table rows="{/opportunities}" >     <Column>           <m:Label text="Status" />                    <template>                            <m:Select change="changeStatus" selectedKey="{Status}" items="{/stati}" >                                <c:Item text="{Status}" key="{Status}" />                            </m:Select>                    </template>   </Column>     <Column>           <m:Label text="Transaction ID" />            <template>                      <m:Text text="{TransactionID}"/>          </template>   </Column></Table>

Javascript:

changeStatus: function(Selection){        var sel = Selection.getParameter("selectedItem").getText();        alert(sel);
}

So whenever I select a Status, I also want to get the "TransactionID" so that I know for which ID I want to change the status.

 

Hwo do I do that?

 

Greetings,

Jan


Viewing all articles
Browse latest Browse all 3523

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>