弹出窗口中的触发器保存按钮 [英] Trigger save button in popup

查看:59
本文介绍了弹出窗口中的触发器保存按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我想在弹出窗口中自动触发保存按钮。



< pre lang =cs> showBootstrapModal(' / AgendaEvent / Edit /',{
id: event .id,
title: event .title,
start: event .start.format(),
end: event .end.format(),
top:(jsEvent.clientY - 240 )+ ' px'
左:(jsEvent.clientX - 260 )+ ' px'
按钮: {
保存:function(){
$(' #<%= Agenda-event -create%>')。click();
$(' #modal-wrapper')。modal(' hide'); // 测试ModaL POPUP
},

}
})





但保存按钮没有触发。



谢谢

解决方案

' #<% = agenda-event-create%>')。click();


' #modal-wrapper')。modal(' hide'); // 测试ModaL POPUP
},

}
})





但保存按钮没有触发。



谢谢


您需要在load事件中调用click事件处理程序。您可以尝试 start:


Hi everybody,

I want to automatically trigger the save button in popup.

showBootstrapModal('/AgendaEvent/Edit/', {
                               id: event.id,
                               title: event.title,
                               start: event.start.format(),
                               end: event.end.format(),
                               top: (jsEvent.clientY - 240) + 'px',
                               left: (jsEvent.clientX - 260) + 'px',
                               buttons: {
                                   Save: function () {
                                       $('#<%=agenda-event-create %>').click();
                                       $('#modal-wrapper').modal('hide'); //Test ModaL POPUP
                                   },

                               }
                           })



But the save button is not triggering.

Thank you

解决方案

('#<%=agenda-event-create %>').click();


('#modal-wrapper').modal('hide'); //Test ModaL POPUP }, } })



But the save button is not triggering.

Thank you


You need to call the click event handler in the load event.You can try start:


这篇关于弹出窗口中的触发器保存按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆