Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
目前,当我在我的 ng2 表上单击编辑时,我得到一个内联编辑选项。
但是,我想要发生的是有一个弹出式可编辑框(示例图像用于添加,但对于仅使用预填充数据和不同标题的编辑来说是相同的)
有没有办法做到这一点?
将“模式:'外部'”添加到您的设置对象
HTML:
<ng2-smart-table [settings]="settings" (edit)="editRow($event)">
设置对象:
settings = { mode: 'external', edit: { editButtonContent: 'string_or_html' } columns: {...} }
然后像这样使用它:
editRow(event) { console.log('event: ', event) }