从 firebase 中删除数据后,它仍然以角度 4 显示在 table 中

after deleting data from firebase it is still showing in table in angula 4

我正在处理 angular 4 个项目,我在其中使用智能 table。对于数据库,我使用的是 firebase。 我写了一个函数来删除它从 firebase 中删除的行数据,但其他数据显示两次(重复)。 以下是代码

我在服务中有写函数来获取数据如下

getEData() 
 {

    return this.af.list('/enquirydata').snapshotChanges().map(changes => {
      return changes.map(c => ({ key: c.payload.key, ...c.payload.val() }));
    });
 }

同样为了删除我在服务中写了下面的函数

deleteEnquiry(data){
    this.af.list(`/enquirydata`).remove(data);
    console.log("item deleted");

}

现在component.ts我写了如下

source: LocalDataSource = new LocalDataSource();
  items: Array<any> = [];


  constructor(private service: SmartTableService, private router: Router) {
 this.service.getEData().subscribe(k=> {
  k.map(c=> {
  this.items.push(c);
      this.source.load(this.items);
  })
  });
    } 

onDelete(event) {
console.log(event);
    if (window.confirm('Are you sure you want to delete?')) {
      this.service.deleteEnquiry(event.data.key);
    } else {
      event.confirm.reject();
    }
  }

有什么帮助吗?

 this.service.getEData().subscribe(k=> {
   this.items = [...k]; // use can use array destructuring
   this.source.load(this.items);
 });
}