BoldSignEasily embed eSignatures in your .NET applications. Free sandbox with native SDK available.
popupOpen="onPopupOpen"
function onPopupOpen(args) {
if (args.type === 'Editor') {
if (typeof (document.getElementById("EventType_Error")) == 'undefined') {
document.getElementById("Subject_Error").style.display = "none";
}
var formElement = args.element.querySelector('.e-schedule-form');
var statusElement = args.element.querySelector('#EventType');
if (!statusElement.classList.contains('e-dropdownlist')) {
var dropDownListObject = new ej.dropdowns.DropDownList({
placeholder: 'Choose status', value: statusElement.value,
dataSource: ['New', 'Requested', 'Confirmed'],
change: function () {
if (typeof (document.getElementById("EventType_Error")) != 'undefined') {
document.getElementById("EventType_Error").style.display = "none";
}
}
});
dropDownListObject.appendTo(statusElement);
statusElement.setAttribute('name', 'EventType');
}
var startElement = args.element.querySelector('#StartTime');
if (!startElement.classList.contains('e-datetimepicker')) {
new ej.calendars.DateTimePicker({ value: new Date(startElement.value) || new Date() }, startElement);
}
var endElement = args.element.querySelector('#EndTime');
if (!endElement.classList.contains('e-datetimepicker')) {
new ej.calendars.DateTimePicker({ value: new Date(endElement.value) || new Date() }, endElement);
}
var validator = (formElement).ej2_instances[0];
validator.addRules('EventType', { required: [true, 'O campo é obrigatório'] });
}
}
|
@*Alignment CSS for error message*@
<style type="text/css">
.e-tooltip-wrap.e-schedule-error {
top: 38px !important;
margin-left: 200px;
}
</style> |