Last change
on this file was
511,
checked in by hendrikvanantwerpen, 11 years ago
|
- Added open item options to singe and multiple choice.
- Question view widgets are forms again, because we needed the control.
- Multiple and singel choice share their widgets.
- QuestionEditorPreview? now has items that were already there close,
but opens newly dropped items.
- PreviewItems? will save modified value even when we change to view
before the widget loses its focus (which causes a change event).
|
File size:
867 bytes
|
Line | |
---|
1 | define([ |
---|
2 | "../../../widgets/_ComplexValueWidget", |
---|
3 | "dojo/_base/declare", |
---|
4 | "dojo/text!./templates/NumberInputWidget.html" |
---|
5 | ], function(_ComplexValueWidget, declare, template) { |
---|
6 | return declare([_ComplexValueWidget],{ |
---|
7 | templateString: template, |
---|
8 | text: '', |
---|
9 | subcode: '', |
---|
10 | startup: function() { |
---|
11 | if ( this._started ) { return; } |
---|
12 | this.inherited(arguments); |
---|
13 | |
---|
14 | var constraints = {}; |
---|
15 | if ( this.min && !isNaN(this.min) ) { |
---|
16 | constraints.min = this.min; |
---|
17 | } |
---|
18 | if ( this.max && !isNaN(this.max) ) { |
---|
19 | constraints.max = this.max; |
---|
20 | } |
---|
21 | if ( this.places && !isNaN(this.places) ) { |
---|
22 | constraints.places = this.places; |
---|
23 | } |
---|
24 | this.numberBox.set('constraints', constraints); |
---|
25 | } |
---|
26 | }); |
---|
27 | }); |
---|
Note: See
TracBrowser
for help on using the repository browser.