在$ http.post调用后尝试打开ngDialog时,对话框功能中断 以下是保存($ http.post)调用后打开弹出窗口的代码
$scope.$parent.studio.saveBodData().then(function () { //API call
vm.openPreviewGenerateModal('results'); //Code to open Popup
});
function openPreviewGenerateModal(page) {
vm.generateResultsPopupflag = true;
vm.previewDialog = ngDialog.open({
template: 'templates/bod/previewGenerateModal.tmpl.html',
className: 'ngdialog-theme-default ngdialog-custom preview-Modal-wrapper',scope: $scope,
data: {
page: page
},
showClose: false,
closeByEscape: false,
closeByDocument: false
});
}