source: Dev/branches/rest-dojo-ui/client/rft/ui/QuestionWidget.js @ 274

Last change on this file since 274 was 274, checked in by hendrikvanantwerpen, 13 years ago
  • [Client] Moved pages in subtree of rft/, allowing controllers next to them.
  • [Client] Created questions page, gives overview and allows adding.
  • [Client] Page controllers inherit from _Page, because the previous mechanism w

asn't working.

  • [Client] Added new user registration.
  • [Server] Changed user passwords to passwordHash/passwordSalt combination.
  • [Server] Added simple object marshalling and unmarshalling to preserve types.
  • [Server] Added ResearchToolObjectInterface? with static create() method. Implemented for all model classes.
File size: 753 bytes
Line 
1define(['dojo/_base/declare','dijit/_WidgetBase','dijit/_TemplatedMixin','dijit/_WidgetsInTemplateMixin','dojo/text!rft/ui/QuestionWidget.html'],
2    function(declare,_WidgetBase,_TemplatedMixin,_WidgetsInTemplateMixin,templateString){
3        return declare('rft.ui.QuestionWidget',[_WidgetBase,_TemplatedMixin,_WidgetsInTemplateMixin],{
4            templateString: templateString,
5            question: null,
6            startup: function() {
7                if ( this.question ) {
8                    this.codeField.innerHTML = this.question.code;
9                    this.titleField.innerHTML = this.question.title;
10                    this.descriptionField.innerHTML = this.question.description;
11                }
12            }
13        });
14    });
Note: See TracBrowser for help on using the repository browser.