Angular UI Bootstrap modal - use custom modal window

后端 未结 3 619
情书的邮戳
情书的邮戳 2021-01-26 06:13

As given in the link http://angular-ui.github.io/bootstrap ( select modal from Directive drop down on top), there is a parameter called windowTemplateUrl which is used to over

3条回答
  •  情书的邮戳
    2021-01-26 07:02

    This is how windowTemplateUrl is working

    $scope.open = function () {
    
    var modalInstance = $modal.open({
      templateUrl:'myModalContent.html',
      windowTemplateUrl: 'customModal.html',
      controller: 'ModalInstanceCtrl',
      resolve: {
      params: function(){
         return {
            title: 'Custom title 2'
               };
             }
          }
       });
    };
    

    Original version of angular-ui (not working)

    Modificated version of angular-ui (working)

提交回复
热议问题