Yongcong Luo
Yongcong Luo

Reputation: 63

How to add check box in Angular 2 ng2-smart-table?

I am writing

checkbox: {
      title: 'Re-Assiiiiign',
      type: 'html',
      valuePrepareFunction: (value) => { return this._sanitizer.bypassSecurityTrustHtml(this.input); },

      filter: false
 },

and

public input: string = '<input type="checkbox"></input>';
constructor(private _hrdashboardservice: HRDashboardService, private _sanitizer: DomSanitizer){
}

but the check box cannot be clicked. Anybody knows any other way to solve add checkbox in ng2-smart-table?

Upvotes: 0

Views: 3446

Answers (1)

Kristian Lucido
Kristian Lucido

Reputation: 21

Try to add in your table model

selectMode: 'multi'

Example ng2-smart-table

Upvotes: 2

Related Questions