今天再做一個表格的時候需要使用到自訂一的 input
然後想在 change 的時候去做一些事情
所以研究了一下怎麼觸發
如下
{
field: 'last_xxxx',
title: __('Last_xxxx'),
formatter: Controller.api.last_xxxx,
events:Controller.api.test
},
api: { bindevent: function () { Form.api.bindevent($("form[role=form]")); }, test:{ 'change .last_xxxx': function (e, value, row, index) { alert('benny'); } }, last_episode: function (value, row, index) { return "<input type='number' id='xxxx_" + row.id + "' " + "value='" + value + "' " + "class='last_xxxx form-control' " + "/>"; }, }
文章標籤
全站熱搜
