They all have the .ui-dialog-content class, so select by that and close them, like this:
$(".ui-dialog-content").dialog("close");
They all have the .ui-dialog-content class, so select by that and close them, like this:
$(".ui-dialog-content").dialog("close");