You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (typeofthis.schema["checklistOptions"] !=="undefined"&&typeofthis.schema["checklistOptions"]["value"] !=="undefined") {
55
+
return item[this.schema.checklistOptions.value];
56
+
} else {
57
+
if (typeof item["value"] !=="undefined") {
58
+
returnitem.value;
59
+
} else {
60
+
throw"value is not defined. If you want to use another key name, add a `value` property under `checklistOptions` in the schema. https://icebob.gitbooks.io/vueformgenerator/content/fields/checklist.html#checklist-field-with-object-values";
61
+
}
62
+
}
63
+
} else {
64
+
return item;
65
+
}
57
66
},
58
-
59
67
getItemName(item) {
60
-
if (isObject(item) &&item.name)
61
-
returnitem.name;
62
-
63
-
return item;
68
+
if (isObject(item)){
69
+
if (typeofthis.schema["checklistOptions"] !=="undefined"&&typeofthis.schema["checklistOptions"]["name"] !=="undefined") {
70
+
return item[this.schema.checklistOptions.name];
71
+
} else {
72
+
if (typeof item["name"] !=="undefined") {
73
+
returnitem.name;
74
+
} else {
75
+
throw"name is not defined. If you want to use another key name, add a `name` property under `checklistOptions` in the schema. https://icebob.gitbooks.io/vueformgenerator/content/fields/checklist.html#checklist-field-with-object-values";
if (isObject(item) &&this.schema.radiosOptions.value&& item[this.schema.radiosOptions.value]){
40
-
return item[this.schema.radiosOptions.value];
32
+
if (isObject(item)){
33
+
if (typeofthis.schema["radiosOptions"] !=="undefined"&&typeofthis.schema["radiosOptions"]["value"] !=="undefined") {
34
+
return item[this.schema.radiosOptions.value];
35
+
} else {
36
+
if (typeof item["value"] !=="undefined") {
37
+
returnitem.value;
38
+
} else {
39
+
throw"value is not defined. If you want to use another key name, add a `value` property under `radiosOptions` in the schema. https://icebob.gitbooks.io/vueformgenerator/content/fields/radios.html#radios-field-with-object-values";
40
+
}
41
+
}
42
+
} else {
43
+
return item;
41
44
}
42
-
43
-
return item;
44
45
},
45
46
getItemName(item) {
46
-
if (isObject(item) &&this.schema.radiosOptions.name&& item[this.schema.radiosOptions.name]){
47
-
return item[this.schema.radiosOptions.name];
47
+
if (isObject(item)){
48
+
if (typeofthis.schema["radiosOptions"] !=="undefined"&&typeofthis.schema["radiosOptions"]["name"] !=="undefined") {
49
+
return item[this.schema.radiosOptions.name];
50
+
} else {
51
+
if (typeof item["name"] !=="undefined") {
52
+
returnitem.name;
53
+
} else {
54
+
throw"name is not defined. If you want to use another key name, add a `name` property under `radiosOptions` in the schema. https://icebob.gitbooks.io/vueformgenerator/content/fields/radios.html#radios-field-with-object-values";
55
+
}
56
+
}
57
+
} else {
58
+
return item;
48
59
}
49
-
50
-
return item;
60
+
},
61
+
onSelection(item) {
62
+
this.value=this.getItemValue(item);
51
63
},
52
64
isItemChecked(item) {
53
-
let currentValue;
54
-
if (isObject(item) &&this.schema.radiosOptions.value&& item[this.schema.radiosOptions.value]){
0 commit comments