Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
148971 | Nov 9,2019 10:12 PM UTC | Nov 11,2019 11:35 AM UTC | Angular - EJ 2 | 1 |
![]() |
Tags: Schedule |
onPopupOpen(args: PopupOpenEventArgs): void {
if (args.type === 'Editor') {
// Create required custom elements in initial time
if (!args.element.querySelector('.custom-field-row')) {
let row: HTMLElement = createElement('div', {className: 'custom-field-row'});
let formElement: HTMLElement = args.element.querySelector('.e-schedule-form');
formElement.firstChild.insertBefore(row, args.element.querySelector('.e-title-location-row'));
let container: HTMLElement = createElement('div', {className: 'custom-field-container'});
let inputEle: HTMLInputElement = createElement('input', {
className: 'e-field', attrs: {name: 'Client'}
}) as HTMLInputElement;
container.appendChild(inputEle);
row.appendChild(container);
let dropDownList: DropDownList = new DropDownList({
dataSource: [
{text: 'Person1', value: 'Person1'},
{text: 'Person2', value: 'Person2'},
{text: 'Person3', value: 'Person3'},
{text: 'Person4', value: 'Person4'}
],
fields: {text: 'text', value: 'value'},
value: (<{ [key: string]: Object }>(args.data)).Client as string,
floatLabelType: 'Always', placeholder: 'Client'
});
dropDownList.appendTo(inputEle);
inputEle.setAttribute('name', 'Client');
}
}
}
(sorry for posting this in two forum parts as I didnt know where to post it exactly)
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.