@@ -10,28 +10,23 @@ function init(Survey, $) {
10
10
} ,
11
11
isDefaultRender : true ,
12
12
activatedByChanged : function ( activatedBy ) {
13
- if (
14
- Survey . JsonObject . metaData . findProperty ( "text" , "choices" ) !== null ||
15
- Survey . JsonObject . metaData . findProperty ( "text" , "choicesByUrl" ) !== null
16
- ) {
17
- return ;
18
- }
19
- Survey . JsonObject . metaData . addProperty ( "text" , {
13
+ if ( ! ! Survey . Serializer . findProperty ( "text" , "choices" ) || ! ! Survey . Serializer . findProperty ( "text" , "choicesByUrl" ) ) return ;
14
+ Survey . Serializer . addProperty ( "text" , {
20
15
name : "choices:itemvalues" ,
21
16
category : "choices" ,
22
17
categoryIndex : 1 ,
23
18
} ) ;
24
- Survey . JsonObject . metaData . addProperty ( "text" , {
19
+ Survey . Serializer . addProperty ( "text" , {
25
20
name : "choicesByUrl:restfull" ,
26
21
className : "ChoicesRestfull" ,
27
22
category : "choicesByUrl" ,
28
23
visible : false ,
29
24
categoryIndex : 2 ,
30
25
} ) ;
31
- Survey . JsonObject . metaData . addProperty ( "text" , {
26
+ Survey . Serializer . addProperty ( "text" , {
32
27
name : "config" ,
33
28
category : "general" ,
34
- default : null ,
29
+ visible : false ,
35
30
} ) ;
36
31
} ,
37
32
afterRender : function ( question , el ) {
@@ -118,7 +113,7 @@ function init(Survey, $) {
118
113
} ,
119
114
} ;
120
115
121
- Survey . CustomWidgetCollection . Instance . addCustomWidget ( widget , "type" ) ;
116
+ Survey . CustomWidgetCollection . Instance . addCustomWidget ( widget ) ;
122
117
}
123
118
124
119
if ( typeof Survey !== "undefined" ) {
0 commit comments