Hey,
i created the following custom canvas item:
the component embeds a combo-box with date picker button next to it.
I have 2 problems with it:
1. when i try setting the "selectedValue" with the change functions, it is not being set. why is that?
2. when i do "getValues()" on the containing DynamicForm, I'm not getting any value from my component. what do i need to do to fix this? should i implement a function for that?
Thanks.
i created the following custom canvas item:
Code:
isc.ClassFactory.defineClass("DatePickerComboBox", CanvasItem); DatePickerComboBox.addProperties({ valueMap: null, selectedValue: "", init:function () { this.canvas = isc.DynamicForm.create({ numCols:"4", cellPadding : 0, fields:[ { valueMap: this.valueMap, editorType:"comboBox", showTitle:false, width:244, change: function (form, item, value) { this.selectedValue = value; } }, { type:"date", showTitle:false, useTextField:true, width: 16, pickerIconPrompt: "", textFieldProperties:{ visible:false }, change:function (form, item, value) { var date = this.parseDate(value); form.getItems()[0].setValue(date); this.selectedValue = date; } } ] }); return this.Super("init", arguments); } });
I have 2 problems with it:
1. when i try setting the "selectedValue" with the change functions, it is not being set. why is that?
2. when i do "getValues()" on the containing DynamicForm, I'm not getting any value from my component. what do i need to do to fix this? should i implement a function for that?
Thanks.
Comment