Results 1 to 3 of 3

Thread: How to: DataView with record relation, select related record

  1. #1
    Ext JS Premium Member
    Join Date
    Apr 2010
    Location
    Montreal, Canada
    Posts
    265
    Answers
    3

    Question Answered: How to: DataView with record relation, select related record

    My view presentation work really well. Now I need to add the "select" event, where when a use clicks the <li> something happens in the application. So far, the template iterate through the record to create the <ul> and creates <li> for each records' relation.


    My 2 issues:
    - I need to catch the <li> clicks
    - I need to be able to catch different <li> clicks on the same or different <ul>




    Code:
    itemSelector: 'ul.dateColumn',
    
    
    tpl: [
        '<tpl for=".">',
        '   <ul class="dateColumn">',
        '       <tpl for="times">',
        '           <li class="timeCell">{time}</li>',
        '       </tpl>',
        '   </ul>',
        '</tpl>'
    ]
    Capture.PNG


    I tried changing the itemsSelector to "li.timeCell" but ExtJs throws an error Uncaught TypeError: Cannot read property 'internalId' of undefined.

    Any help would be appreciated!

  2. Used my credits to get an answer for this problem and they provided me with a working solution.

    https://fiddle.sencha.com/#fiddle/1t5o&view/editor

    Many thanks guys !

  3. #2
    Ext JS Premium Member
    Join Date
    Apr 2010
    Location
    Montreal, Canada
    Posts
    265
    Answers
    3

  4. #3
    Ext JS Premium Member
    Join Date
    Apr 2010
    Location
    Montreal, Canada
    Posts
    265
    Answers
    3

    Default

    Used my credits to get an answer for this problem and they provided me with a working solution.

    https://fiddle.sencha.com/#fiddle/1t5o&view/editor

    Many thanks guys !

Similar Threads

  1. ST2 Dataview List record with editable combo/Select field
    By amol.sonawane in forum Sencha Touch 2.x: Q&A
    Replies: 3
    Last Post: 23 Jul 2014, 12:37 PM
  2. [INFOREQ] [RC] dataview select (after load) selects old record
    By jensen83 in forum Sencha Touch 2.x: Bugs
    Replies: 3
    Last Post: 28 Feb 2012, 9:22 AM
  3. Replies: 3
    Last Post: 20 Jan 2012, 10:16 AM
  4. how can I select item in DataView if I only have record.id?
    By moegal in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 20 May 2009, 2:48 AM
  5. [solved] DataView::select by a record.id
    By Foggy in forum Sencha Ext JS Q&A
    Replies: 3
    Last Post: 7 Oct 2008, 4:17 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •