
enyo.kind({
  name: "XT.AvailableSessions",
  kind: "Control",
  classes: "xt-available-sessions",
  components: [
    { name: "wrapper", classes: "xt-available-sessions-wrapper", components: [
      { name: "list", kind: "List", classes: "xt-available-sessions-list", multiSelect: false, onSetupItem: "setupRow", components: [
        { name: "item", kind: "XT.SessionSelectionRow" } ] } ] }
  ],
  
  //components: [
  //  { name: "list", kind: "List", multiSelect: false, onSetupItem: "setupRow", components: [
  //    { name: "item", kind: "XT.SessionSelectionRow" } ]}
  //],
  rendered: function() {
    var sessions;
    
    this.inherited(arguments);
    
    if (this.hasNode() && XT.session && this.getShowing()) {
      sessions = XT.session.getAvailableSessions() || [];
      this.$.list.setCount(sessions.length);
      this.$.list.reset();
    }
  },
  setupRow: function(inSender, inEvent) {
    var row = this.$.item;
    var idx = inEvent.index;
    var data = XT.session.getAvailableSessions()[idx].sessionData;
    
    var ts = XT.toReadableTimestamp(data.created);
    row.$.username.setContent(data.username);
    row.$.organization.setContent(data.organization);
    row.$.created.setContent(ts);
    row.$.sid.setContent(data.sid);
  }
    
});

enyo.kind({
  name: "XT.SessionSelectionRow",
  kind: "Control",
  classes: "xt-session-selection-row",
  components: [
    { name: "username", classes: "xt-session-row-element" },
    { name: "organization", classes: "xt-session-row-element" },
    { name: "created", classes: "xt-session-row-element" },
    { name: "sid", classes: "xt-session-row-element" }
  ]
    
});
@@ -959,16 +959,80 @@
 .index;%0A
+    %0A    //console.log(XT.session.getAvailableSessions());%0A    %0A
     var 
@@ -1080,20 +1080,8 @@
 idx%5D
-.sessionData
 ;%0A  
@@ -1083,24 +1083,26 @@
 %5D;%0A    %0A    
+//
 var ts = XT.
@@ -1265,18 +1265,28 @@
 Content(
-ts
+data.created
 );%0A    r

allow to work with new datasource response