fastadmin列表按钮自定义样式与自定义事件
{field: 'id', title: __('网站地址'), formatter: function(value, row, index){ return '<span data-url="//' + row["ip"] + ':' + row["port"] + '" ' + 'class="label label-info jump" ' + 'data-toggle="tooltip" title="">' + row["ip"] + ':' + row["port"] + '</span>'; }}, //点击跳转 $(document).on("click", ".jump", function () { var url = $(this).attr('data-url'); window.open(url); });
php开发交流群: 901326020