source: Dev/trunk/src/client/qed-client/pages/index.js @ 491

Last change on this file since 491 was 490, checked in by hendrikvanantwerpen, 11 years ago
  • Mark content as dirty to prevent moving away from unsaved data.
  • Better change propagation from lists and our own widgets.
  • Generate notifications for errors and show correct message.
  • Moved all path/url generation to the class stores, not everywhere we use it.
  • Give user always a choice between Save and Save & Close.
  • Better refresh behaviour on form changes and saves.
  • Don't generate duplicate code error when existing object is the one you're storing.
File size: 1.1 KB
Line 
1define([
2    "../app/Page",
3    "../app/Router",
4    "../model/classes/questions",
5    "../model/classes/surveys",
6    "dojo/_base/declare",
7    "dojo/text!./templates/index.html"
8], function(Page, Router, questions, surveys, declare, template) {
9    return declare([Page],{
10        templateString: template,
11        selectedObject: null,
12        startup: function() {
13            if ( this._started ) { return; }
14            this.inherited(arguments);
15            //this.btnContentCreate.on("click",function(){ Router.go("/sessions"); });
16            //this.btnContentFacilitate.on("click",function(){ Router.go("/run"); });
17            this.btnSurveys.on("click",function(){
18                Router.go(surveys.getCollectionPath());
19            });
20            this.btnQuestions.on("click",function(){
21                Router.go(questions.getCollectionPath());
22            });
23            //this.btnApplications.on("click",function(){Router.go("/applications");});
24            //this.btnDashboards.on("click",function(){ Router.go("/dashboards"); });
25            //this.btnResults.on("click",function(){ Router.go("/results"); });
26        }
27    });
28});
Note: See TracBrowser for help on using the repository browser.