[263] | 1 | require([ |
---|
[288] | 2 | // functions required for run |
---|
| 3 | 'dojo/_base/window','dojo/parser', 'rft/ui/LoginDialog', |
---|
| 4 | 'dojo/dom', 'dojo/_base/connect', 'rft/auth', 'rft/content', |
---|
| 5 | 'dojo/domReady!', |
---|
| 6 | |
---|
| 7 | // general widgets |
---|
[281] | 8 | 'dojo/data/ObjectStore', |
---|
| 9 | 'dojo/store/JsonRest', |
---|
[347] | 10 | 'dijit/InlineEditBox', |
---|
[281] | 11 | 'dijit/MenuBar', |
---|
| 12 | 'dijit/MenuBarItem', |
---|
| 13 | 'dijit/PopupMenuBarItem', |
---|
| 14 | 'dijit/DropDownMenu', |
---|
| 15 | 'dijit/TitlePane', |
---|
[347] | 16 | 'dijit/layout/BorderContainer', |
---|
[281] | 17 | 'dijit/layout/ContentPane', |
---|
| 18 | 'dijit/layout/TabContainer', |
---|
| 19 | 'dijit/layout/AccordionContainer', |
---|
[347] | 20 | 'dijit/form/DateTextBox', |
---|
[263] | 21 | 'dijit/form/Form', |
---|
[274] | 22 | 'dijit/form/TextBox', |
---|
| 23 | 'dijit/form/Button', |
---|
| 24 | 'dijit/form/Textarea', |
---|
[292] | 25 | 'dijit/form/SimpleTextarea', |
---|
[281] | 26 | 'dijit/form/ComboBox', |
---|
| 27 | 'dijit/form/Select', |
---|
[263] | 28 | 'dojox/grid/DataGrid', |
---|
[281] | 29 | 'dojox/widget/TitleGroup', |
---|
[365] | 30 | 'dojox/data/QueryReadStore', |
---|
| 31 | 'rft/elastic/ElasticReadStore', |
---|
[374] | 32 | 'rft/ui/List', |
---|
| 33 | 'rft/ui/OrderedList', |
---|
[365] | 34 | 'rft/ui/AccountListView', |
---|
[311] | 35 | 'rft/ui/MainMenu', |
---|
[263] | 36 | 'rft/ui/MenuBarLink', |
---|
[274] | 37 | 'rft/ui/MenuLink', |
---|
[311] | 38 | 'rft/ui/Notifications', |
---|
[275] | 39 | 'rft/ui/LineWithActionsWidget', |
---|
[350] | 40 | 'rft/ui/ObjectBox', |
---|
[281] | 41 | 'rft/ui/QuestionWidget', |
---|
[350] | 42 | 'rft/ui/Selector', |
---|
[281] | 43 | 'rft/ui/TitleGroup', |
---|
[378] | 44 | /*PreviewWidgets*/ |
---|
| 45 | 'rft/ui/InnerWidgetFactory', |
---|
[288] | 46 | // pages -> load dynamically? |
---|
[359] | 47 | 'rft/pages/index', |
---|
[292] | 48 | 'rft/pages/questions', |
---|
[366] | 49 | 'rft/pages/question', |
---|
[359] | 50 | 'rft/pages/session', |
---|
[350] | 51 | 'rft/pages/sessions', |
---|
[292] | 52 | 'rft/pages/surveys', |
---|
[366] | 53 | 'rft/pages/survey' |
---|
[292] | 54 | ], |
---|
[260] | 55 | function(win,parser,LoginDialog,dom,connect,auth,content) { |
---|
| 56 | parser.parse(); |
---|
| 57 | |
---|
[263] | 58 | var login = new LoginDialog().placeAt(win.body()); |
---|
[260] | 59 | login.startup(); |
---|
| 60 | |
---|
| 61 | auth.restore() |
---|
[263] | 62 | .then(function(){ |
---|
[260] | 63 | content.initial(); |
---|
| 64 | },function(){ |
---|
| 65 | login.show(); |
---|
| 66 | }); |
---|
| 67 | |
---|
[274] | 68 | connect.connect(dom.byId('loginMenu'),'click',function(){ |
---|
[260] | 69 | login.show(); |
---|
| 70 | }); |
---|
[274] | 71 | |
---|
[347] | 72 | }); |
---|
| 73 | |
---|
| 74 | function goToPage(page) { |
---|
| 75 | throw "Obsolete navigation to "+page; |
---|
[350] | 76 | } |
---|