task

PAGE view/selections.jade

 

[WHAT]

  1. [ def ] this page displays the "race selections", aka the team or group of drivers "selected" from the list of entrants, to compete, in this weeks competition
  2. [ args ] none, 

[WHY]

  1. ]

[WHERE called from]

  1. ]

[WHEN]

  1. ]

[EXAMPLE]

[HOW-TO]

  1. ]

[REFERENCE]

  1. [2015-06-dd] index -v-001
    1. ] #
  2. ]

developer implementation

[process]

  1.  

[notes]

  1.  

[by_date]

  1. [YYYY-mm-DD]

status

[previously]

  1. [2015-06-04] modify route to add :race paramter
    1. ] can now call page with
  2. [2015-06-05] add inline script to template
    1. ] use script. tag, indent code
  3. [2015-06-05] add script to return indexOf obj in array
    1. ] this will be lookup function, return driverID  given teamID, can then lookup driver name and properties from driver
  4. [2015-06-05]
    1. ] PRB accessing 'global' variables defined, can access these vars in the page, but NOT in the inline script

[currently]

  1. ]  // GET the array index of the given team, ex team 48= element 6,
  2. ] next = access teams[6] to get driver id,
  3. ] next = access drivers with driver id to get driver name
  4. [***********]
  5. x] replace hardcoded text (for dover selections) with x] selections, x] drivers,
  6. ] iterate selections, display drivers  
  7. ] PRB - drivers data has no team id, selections are be team id(ie car#)
    1. ] add team id param to drivers,
    2. ] NEED return driver from drivers where driver.teamID=

[next]

  1. ]

 

 

 

    function lookup(teamID) {
            // alert(teamID);
            // GET the array index of the given team, ex team 48= element 6, next = access teams[6] to get driver id, next = access drivers with driver id to get driver name
            // PRB = passing in the array OR trying to access the array variable
            // return (teams.indexOf(teamID) != -1);
            // alert ( teams[teamID].id); FAIL
        }
 
        // lookup(2);
 

//
          li(class="two")
              h5 18 Kyle Busch
              p
                | Kyle once dominated an entire weekend here winning in races in all 3 series, this could be his best chance to get the W he needs to get into this years chase.
          li(class="three")
              h5 19 Carl Edwards
              p
                | Edwards captured the checkered flag at last weekends Coca Cola 600 and
                a(href="http://sospep.com/view/person?id=75", target="_blank") Learn more...
          li(class="four")
              h5 20 Matt Kenseth
              p
              | Matt had a good run at Charlotte last week and qualified especially well here.
           li(class="five")
              h5 33 Brian Scott
              p
              | This weeks value selection, Scott qualified in 30th position
 
Details Photos Edit more

Details

ID: 5235

NAME: PAGE-view-selections

DESCRIPTION: ] dynamic display, ] select by race ]

START DATE TIME: 2015-06-05 11:39:00

EST DURATION: 01:00:00

END DATE TIME: 2015-06-05 12:39:00

STATUS: Completed

PRIORITY: -5

OWNER ID: 75

Content Photos Edit more

photos

photos for this task

actions

Agenda Email task SMS task Priorities