Ignore:
Timestamp:
08/15/12 18:30:58 (13 years ago)
Author:
hendrikvanantwerpen
Message:

Added survey viewer page.

Added view.html page to view surveys. Widgets from the questions are
displayed, no answers are saved yet.

The content module is split for index.html and view.html, so viewers
cannot navigate to other pages. Widgets to pre-load are now seperated
in stddeps.js module and shared between run.js & view.js.

Location:
Dev/branches/rest-dojo-ui
Files:
1 edited
1 copied

Legend:

Unmodified
Added
Removed
  • Dev/branches/rest-dojo-ui

    • Property svn:ignore
      •  

        old new  
        11nbproject
         2.project
  • Dev/branches/rest-dojo-ui/client/rft/view.js

    r398 r399  
    11require([
    2     // functions required for run
    3     'dojo/_base/connect',
    4     'dojo/_base/window',
    5     'dojo/dom',
    62    'dojo/parser',
    73    'rft/auth',
    84    'rft/content',
    9     'rft/ui/LoginDialog',
    10     'dojo/domReady!',
    11    
    12     // dijit & rft widgets used declaratively in templates and pages
    13     'dijit/Dialog',
    14     'dijit/DropDownMenu',
    15     'dijit/InlineEditBox',
    16     'dijit/MenuBar',
    17     'dijit/MenuBarItem',
    18     'dijit/PopupMenuBarItem',
    19     'dijit/TitlePane',
    20     'dijit/layout/AccordionContainer',
    21     'dijit/layout/BorderContainer',
    22     'dijit/layout/ContentPane',
    23     'dijit/layout/TabContainer',
    24     'dijit/form/Button',
    25     'dijit/form/ComboBox',
    26     'dijit/form/DateTextBox',
    27     'dijit/form/Form',
    28     'dijit/form/NumberSpinner',
    29     'dijit/form/Select',
    30     'dijit/form/SimpleTextarea',
    31     'dijit/form/Textarea',
    32     'dijit/form/TextBox',
     5    'rft/stddeps',
     6    'rft/viewContent',
     7    'dojo/domReady!'
     8],function(parser,auth,content) {
     9    parser.parse();
     10    content.init();
    3311
    34     'dojox/grid/DataGrid',
    35 
    36     'rft/ui/LineWithActionsWidget',
    37     'rft/ui/MainMenu',
    38     'rft/ui/MenuBarLink',
    39     'rft/ui/MenuLink',
    40     'rft/ui/Notifications',
    41     'rft/ui/ObjectBox',
    42     'rft/ui/QuestionWidget',
    43     'rft/ui/Selector',
    44     'rft/ui/TitleGroup',
    45     'rft/ui/lists/AccountListView',
    46     'rft/ui/lists/List',
    47     'rft/ui/lists/OrderedList',
    48 
    49     // pages -> load dynamically?
    50     'rft/pages/index',
    51     'rft/pages/questions',
    52     'rft/pages/question',
    53     'rft/pages/session',
    54     'rft/pages/sessions',
    55     'rft/pages/surveys',
    56     'rft/pages/survey'
    57     ],
    58     function(connect,win,dom,parser,auth,content,LoginDialog) {
    59         parser.parse();
    60 
    61         var login = new LoginDialog().placeAt(win.body());
    62         login.startup();
    63 
    64         auth.restore()
    65         .then(function(){
    66             content.initial();
    67         },function(){
    68             login.show();
    69         });
    70 
    71         connect.connect(dom.byId('loginMenu'),'click',function(){
    72             login.show();
    73         });
    74 
     12    auth.restore()
     13    .then(function(){
     14        content.initial();
     15    },function(){
    7516    });
    7617
    77 function goToPage(page) {
    78     throw "Obsolete navigation to "+page;
    79 }
     18});
Note: See TracChangeset for help on using the changeset viewer.