task

v-005-001

menuMain module

[previously]

  1. [2015-06-14] NEW task IN outline
    1. i] # # - PRB - PAGE Register/Login - ERROR - menu undefined, this happens b/c we are not passing the menu into the view for register, therefore the layout file which is using menu variables, craps out.
    2. ] build the menu as a standalone module,
    3. ] replace calls to buildMenu function and pass menuMain var defined in home.js, with call to mainMenu() module from pass
    4. ] TRY - with /register, /login - entry point is in code in server.js,
    5. ] TRY - pass var into template layout.jade VS passing into each view 
  2. [00:00] NEW task IN PAGE menuMain.js,
    1. x] CREATE new module 'mainMenu' in /routes, returns menu object
  3. [00:00] NEW task IN PAGE server.js
    1. x] ADD requires to server.js in /routes section
  4. [00:00] NEW task IN home.js
    1. x] ADD var mainMenu = requires('./mainMain) to PAGE routes/home(index).js
    2. x] CALL mainMenu() in pass data to each view, example -  menu: mainMenu()  
      1. *] re JSON.stringify - in module, return json vs return obj, not necessary
      2. *] using menuMain VS menuMain() - will return the function text as string
  5. [00:00] NEW task IN
    1. x] REPLACE existing menu object in index.js
  6. [00:00] NEW task IN
    1. x] REPLACE call to build mainMenu in each app.get/page/:param
  7. [00:00] NEW task IN
    1. x] # # - deprecate 'home.js(index) versions -v-001, -v-002, -v-003
    2. x] # # - deprecate 'entrants.js' -v-001, -v-002, -v-003 - module create
  8. [00:00] NEW task IN
    1. x] # # - remove greenspace - aka previous code - like the menu object, build menu function, calls to build menu, ... x] TEST = pass
  9. [00:00] NEW task IN
    1. ]

[currently]

  1. ] # # - update menu - get current race is currently hardcoded B/C functions getCurrentRace are in index.js
    1. ] function
  2. ] # # - races module
    1. ] contains races data, races methods ( getCurrentRace, setCurrentRace, )

[next]

  1. ] art = pass vars into jade template
  2. [2015-06-14][09:00] NEW task IN /prj-4800
    1. x] # # - PASS results - added entry for team "YOU", selections, results, teams
  3. [09:30] NEW task IN
    1. x] # # - REM code for writing 'rankings1.json' file, put into standalone function, only need to write file once,
 
block vars 
  - var pageTitle = 'hello register'

 

Details Photos Edit more

Details

ID: 5287

NAME: 4800-v-005-001

DESCRIPTION: PAGE ] PBR register/login - menu problem ] modularize menu code

START DATE TIME: 2015-06-14 19:06:40

EST DURATION: 01:00:00

END DATE TIME: 2015-06-14 20:06:40

STATUS: Completed

PRIORITY: -5

OWNER ID: 75

Content Photos Edit more

photos

photos for this task

actions

Agenda Email task SMS task Priorities