akveo / akveo/ngx-admin

Datepicker breaks the application on navigation

未关闭
#2,092 10 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
TypeScript
星标
25.7k
派生
7.9k
PR 合并指标
30 天内没有已合并 PR

描述

### Issue type

**I'm submitting a ...** (check one with "x")

* [ ] bug report
Regarding datepicker

### Issue description
If we navigate from current page which has datepicker to another page then application breaks.

**Current behavior:**
Navigation from current page containing datepicker to another page breaks application.

**Expected behavior:**
Should not break.

**Steps to reproduce:**
Go to page which has datepicker
Navigate away from the page to another page.
application breaks

**Related code:**

insert short code snippets here
```







### Other information:

**Browser
Chrome

**Description of Error
core.js:15724 ERROR Error: Uncaught (in promise): TypeError: Cannot read property 'destroy' of undefined
TypeError: Cannot read property 'destroy' of undefined
at NbDatepickerComponent.push../node_modules/@nebular/theme/components/datepicker/datepicker.component.js.NbBasePicker.ngOnDestroy (datepicker.component.js:146)
at callProviderLifecycles (core.js:22422)
at callElementProvidersLifecycles (core.js:22390)
at callLifecycleHooksChildrenFirst (core.js:22380)
at destroyView (core.js:23442)
at callViewAction (core.js:23568)
at execEmbeddedViewsAction (core.js:23511)
at destroyView (core.js:23440)
at callViewAction (core.js:23568)
at execEmbeddedViewsAction (core.js:23511)
at resolvePromise (zone.js:814)
at resolvePromise (zone.js:771)
at zone.js:873
at ZoneDelegate.push../node_modules/zone.js/dist/zone.js.ZoneDelegate.invokeTask (zone.js:421)
at Object.onInvokeTask (core.js:17290)
at ZoneDelegate.push../node_modules/zone.js/dist/zone.js.ZoneDelegate.invokeTask (zone.js:420)
at Zone.push../node_modules/zone.js/dist/zone.js.Zone.runTask (zone.js:188)
at drainMicroTaskQueue (zone.js:595)
at ZoneTask.push../node_modules/zone.js/dist/zone.js.ZoneTask.invokeTask [as invoke] (zone.js:500)
at invokeTask (zone.js:1540)

**Angular, Nebular**
```

```
"@angular/animations": "^7.2.11",
"@angular/cdk": "^7.3.6",
"@angular/common": "^7.2.11",
"@angular/compiler": "^7.2.11",
"@angular/core": "^7.2.11",
"@angular/forms": "^7.2.11",
"@angular/http": "^7.2.11",
"@angular/platform-browser": "^7.2.11",
"@angular/platform-browser-dynamic": "^7.2.11",
"@angular/router": "^7.2.11",
"@nebular/bootstrap": "3.4.2",
"@nebular/security": "3.4.2",
"@nebular/theme": "3.4.2",
"@ng-bootstrap/ng-bootstrap": "^4.0.0",

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。