Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
144189 | Apr 24,2019 06:06 AM UTC | Apr 29,2019 08:51 AM UTC | ASP.NET MVC - EJ 2 | 6 |
![]() |
Tags: Schedule |
function onPopupOpen(args) {
if (args.type === 'Editor') {
var ImpData = @Html.Raw(Json.Encode(ViewBag.ImplementLst));
var statusElement = args.element.querySelector('#ImplementId');
if (!statusElement.classList.contains('e-dropdownlist')) {
var dropDownListObject = new ej.dropdowns.DropDownList({
placeholder: 'Choose status', value: args.data.ImplementId,
fields: { text: 'text', value: 'Id' },
dataSource: [
{ Id: 1, text: 'PROJECT 1' },
{ Id: 2, text: 'PROJECT 2' },
]
});
dropDownListObject.appendTo(statusElement);
statusElement.setAttribute('name', 'ImplementId');
}
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);
}
}
};
|
hi there thanks for reply,i have an issue which is regarding the dropdown filling. if i fill the dropdown with static data it works fine if pulled from request it push an error of groupid undefinedthis is static data.dataSource: [{ Id: 1, text: 'Alice' },{ Id: 2, text: 'Nancy' },{ Id: 3, text: 'Robert' },{ Id: 4, text: 'Robson' },{ Id: 5, text: 'Laura' },{ Id: 6, text: 'Margaret'}]but i want it to be dynamic. please do guide me for this
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.