Changeset 510 for Dev/trunk/src/server


Ignore:
Timestamp:
03/12/14 15:16:54 (11 years ago)
Author:
hendrikvanantwerpen
Message:
  • Factored out general object mapping and iteration.
  • Split widgets for multiplechoice and singlechoice.
  • Restored readOnly/disabled setting for QuestionEditorPreviewItem? on innerWidget (since view innerWidget is not a form anymore, we cannot just set it on that, we iterate over all form children now).
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Dev/trunk/src/server/config/couchdb-schema.json

    r509 r510  
    114114          { "$ref": "#/definitions/content/NumberInput" },
    115115          { "$ref": "#/definitions/content/ScaleInput" },
     116          { "$ref": "#/definitions/content/SingleChoiceInput" },
    116117          { "$ref": "#/definitions/content/MultipleChoiceInput" }
    117118        ]
     
    200201        "additionalProperties": false
    201202      },
     203      "SingleChoiceInput": {
     204        "type": "object",
     205        "properties": {
     206          "type": { "type": "string", "pattern": "^SingleChoiceInput$" },
     207          "items": { "type": "array", "items": {
     208              "type": "object",
     209              "properties": {
     210                  "text": { "$ref": "#/definitions/nonEmptyString" },
     211                  "value": { "$ref": "#/definitions/nonEmptyString" }
     212              },
     213              "required": ["text","value"],
     214              "additionalProperties": false
     215          } },
     216          "otherItem": {
     217              "type": "object",
     218              "properties": {
     219                  "text": { "$ref": "#/definitions/nonEmptyString" },
     220                  "value": { "$ref": "#/definitions/nonEmptyString" }
     221              },
     222              "required": ["subcode","value"],
     223              "additionalProperties": false
     224          },
     225          "subcode": { "$ref": "#/definitions/codeString" }
     226        },
     227        "required":["type","items","subcode"],
     228        "additionalProperties": false
     229      },
    202230      "MultipleChoiceInput": {
    203231        "type": "object",
    204232        "properties": {
    205233          "type": { "type": "string", "pattern": "^MultipleChoiceInput$" },
    206           "allowMultiple": { "type": "boolean" },
    207234          "items": { "type": "array", "items": {
    208235              "type": "object",
Note: See TracChangeset for help on using the changeset viewer.