in index.js if (! endElement. classList. contains( 'e-datetimepicker' )) {
new ej. calendars. DateTimePicker ({ value: new Date ( endElement. value) || new Date () }, endElement);
}
var DurElement = args. element. querySelector( '#Duration' );
if (! DurElement . classList. contains( 'e-slider-container' )) {
slider= new ej. inputs. Slider ({
min: 0 ,
max: 120 ,
step: 5 ,
value: 25 ,
tooltip: {
placement: 'Before' , isVisible: true , cssClass: 'e-tooltip-cutomization'
},
ticks: { placement: 'Before' , largeStep: 10 , showSmallTicks: true },
attrs: { name: 'Duration' }
}, DurElement );
}
The slider is not updating the value to 25. How can I update the slider. {
Id: 1,
Subject: 'Server Maintenance',
StartTime: new Date(2018, 1, 11, 10, 0),
EndTime: new Date(2018, 1, 11, 11, 30),
EventType: 'maintenance',
City: 'Seattle',
CategoryColor: '#1aaa55', Duration:50 }, I want to bind a data property called duration to the slider.
3 Replies
Oldest first
VD
Vinitha Devi Murugan
Syncfusion Team
October 22, 2019 11:12 AM UTC
Hi Premith,
Syncfusion greetings.
We have prepared the sample based on the requirement which is available in below link.
In the above sample, you can render the Slider components in popupOpen event. Once open the dialog we need to refresh the position of Slider component by reposition method in the Dialog ’s open event like below, and also set the zIndex to show the tooltip.
var DurElement = args . element . querySelector ( "#Slider" );
var dialog = args . element . ej2_instances [ 0 ];
dialog . open = function () {
DurElement . ej2_instances [ 0 ]. reposition ();
DurElement . ej2_instances [ 0 ]. zIndex = 2000 ;
};
When we add new event with duration, we need to update the event object in popupClose event like below
popupClose : function ( args ){
if ( args . type === 'Editor' && args . data ) {
var DurElement = args . element . querySelector ( "#Slider" );
args . data . Duration = DurElement . ej2_instances [ 0 ]. value ;
}
}
Kindly check the above sample and revert us for further assistance.
Regards,
M.Vinitha devi
PU
Premith Unnikrishnan
October 22, 2019 11:30 PM UTC
Thank you for the quick response this works perfectly awesome job.
VD
Vinitha Devi Murugan
Syncfusion Team
October 23, 2019 05:34 AM UTC
Hi Premith ,
We are happy to hear that our solution has fulfilled your requirement.
Regards,
M.Vinitha devi.
3 Replies
2 Participants
Want to subscribe?
Created by
PU
Premith Unnikrishnan
Platform
Control
Created On Oct 22, 2019 04:00 AM UTC
Last Activity On Oct 23, 2019 05:34 AM UTC
1/15/2025 03:44:18 AM
Sun, 15 December 2024 03:30:00 UTC
Sun, 15 December 2024 03:30:00 AM
Wed, 16 Feb 2022 04:59:00 UTC