Ignore:
Timestamp:
07/26/12 16:03:40 (13 years ago)
Author:
jkraaijeveld
Message:

Created a factory for the inner widgets on the Question edit screen - can be easily made more generic if necessary too.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Dev/branches/rest-dojo-ui/client/rft/ui/QuestionEditorToolkit.js

    r377 r378  
    135135                                        label: "Header",
    136136                                        objectData: {
    137                                                 _id: null,
    138                                                 type: "HeaderItem",
    139                                                 widgetProps: {}
     137                                                widgetType: "Header",
    140138                                        },
    141139                                        icon: "Header"
     
    144142                                        label: "Text",
    145143                                        objectData: {
    146                                                 _id: null,
    147                                                 type: "TextItem",
    148                                                 widgetProps: {}
     144                                                widgetType: "Text",
    149145                                        },
    150146                                        icon: "TextBox"
     
    153149                                        label: "Image",
    154150                                        objectData: {
    155                                                 _id: null,
    156                                                 widgetType: "rft.surveyContent.ImageDialog",
    157                                                 widgetProps: {}
     151                                                widgetType: "Image",
    158152                                        },
    159153                                        icon: "Image"
     
    162156                                        label: "External media",
    163157                                        objectData: {
    164                                                 _id: null,
    165                                                 widgetType: "rft.surveyContent.ExternalDialog",
    166                                                 widgetProps: {}
     158                                                widgetType: "ExternalMedia",
    167159                                        },
    168160                                        icon: "External"
     
    171163                                        label: "Divider",
    172164                                        objectData: {
    173                                                 _id: null,
    174                                                 widgetType: "rft.surveyContent.Divider",
    175                                                 widgetProps: {}
     165                                                widgetType: "Divider",
    176166                                        },
    177167                                        icon: "Divider"
     
    184174                                        label: "Free text",
    185175                                        objectData: {
    186                                                 _id: null,
    187                                                 widgetType: "rft.surveyContent.TextInput",
    188                                                 widgetProps: {}
     176                                                widgetType: "FreeTextInput",
    189177                                        },
    190178                                        icon: "Text"
     
    194182                                        objectData: {
    195183                                                _id: null,
    196                                                 widgetType: "rft.surveyContent.IntegerInput",
     184                                                widgetType: "IntegerInput",
    197185                                                widgetProps: {}
    198186                                        },
     
    203191                                        objectData: {
    204192                                                _id: null,
    205                                                 widgetType: "rft.surveyContent.ScaleInput",
     193                                                widgetType: "ScaleInput",
    206194                                                widgetProps: {}
    207195                                        },
     
    212200                                        objectData: {
    213201                                                _id: null,
    214                                                 widgetType: "rft.surveyContent.CardsInput",
     202                                                widgetType: "CardsInput",
    215203                                                widgetProps: {}
    216204                                        },
     
    221209                                        objectData: {
    222210                                                _id: null,
    223                                                 widgetType: "rft.surveyContent.MultipleChoiceInput",
     211                                                widgetType: "MultipleChoiceInput",
    224212                                                widgetProps: {}
    225213                                        },
Note: See TracChangeset for help on using the changeset viewer.