-import {Component, Input, ViewChild, TemplateRef, OnInit} from '@angular/core';
+import {Component, Input, ViewChild, TemplateRef, OnInit, Renderer2} from '@angular/core';
import {Observable, from, empty, throwError} from 'rxjs';
import {DialogComponent} from '@eg/share/dialog/dialog.component';
import {AlertDialogComponent} from '@eg/share/dialog/alert.component';
@ViewChild('fail', { static: true }) private fail: AlertDialogComponent;
constructor(
+ private renderer: Renderer2,
private idl: IdlService,
private evt: EventService,
private net: NetService,
update() {
this.leadListName = this.grid.context.getSelectedRows()[0].name();
+ this.renderer.selectRootElement('#create-picklist-name').focus();
+ this.selectionListName = 'Copy of ' + this.leadListName;
}
cloneList() {
-import {Component, Input, ViewChild, TemplateRef, OnInit} from '@angular/core';
+import {Component, Input, ViewChild, TemplateRef, OnInit, Renderer2} from '@angular/core';
import {Observable, from, empty, throwError} from 'rxjs';
import {DialogComponent} from '@eg/share/dialog/dialog.component';
import {AlertDialogComponent} from '@eg/share/dialog/alert.component';
@ViewChild('fail', { static: true }) private fail: AlertDialogComponent;
constructor(
+ private renderer: Renderer2,
private idl: IdlService,
private evt: EventService,
private net: NetService,
this.selectionListName = '';
}
+ update() {
+ this.selectionListName = '';
+ this.renderer.selectRootElement('#create-picklist-name').focus();
+ }
+
createList() {
const picklist = this.idl.create('acqpl');
picklist.owner(this.auth.user().id())