首页 > 其他分享 >fastadmin dialog 自定义弹窗名称标题

fastadmin dialog 自定义弹窗名称标题

时间:2022-10-14 10:15:16浏览次数:48  
标签:info __ fastadmin 自定义 title dialog btn name

fastadmin列表页中的button,通过js定义后,弹出新的dialog。正常情况下,名称是通过js中的title字段去定义,如果想自定义名称,则对title字段进行修改,代码如下所示

{
                            field: 'operate',
                            title: __('Operate'),
                            table: table,
                            events: Table.api.events.operate,
                            formatter: Table.api.formatter.operate,
                            align:'right',
                            halign:'center',
                            buttons: [
                                {
                                    icon: 'fa fa-list',
                                    classname: 'btn btn-info btn-xs btn-detail btn-dialog',
                                    name: 'view_report',
                                    text: __('View report'),
                                    title: function (row) {
                                        return __('View report') + row.name;
                                    },
                                    url: 'assess/assess_user/participants',

                                },
                                {
                                    icon: 'fa fa-list',
                                    classname: 'btn btn-info btn-xs btn-detail btn-dialog',
                                    name: 'view_info',
                                    text: __('View info'),
                                    title: function (row) {
                                        return __('View info') + '-' + row.name;
                                    },
                                    url: 'assess/assess_user/info'+ '/aid/' + $('#q_id').val(),

                                },

                            ]

                        }

 

标签:info,__,fastadmin,自定义,title,dialog,btn,name
From: https://www.cnblogs.com/hjxcode/p/16790670.html

相关文章