title: Switching between tabs in modal in angular
body: <p>I have a login and a signup form that opens in a modal. At the top I have two tabs switching between login and signup. see picture<img src="https://i.stack.imgur.com/B8mQF.png" alt="enter image description here"></p>
  
  <p>Switching between the tabs works fine. However, I want the user to be able to choose login as well as signup on my actual page and open the modal directly in the right tab. </p>
  
  <p>In my main.controller I have:</p>
  
  <pre><code>  $scope.openLoggerMenu=function(){
  
            $modal.open({
              templateUrl: 'app/account/loggingNavigation.html',
  
            })
  
          };
  </code></pre>
  
  <p>In my html menu I have:</p>
  
  <pre><code>  &lt;div class="col-md-1 loginButtonLanding" ng-click="openLoggerMenu()"&gt;
      Login
    &lt;/div&gt;
    &lt;div class="col-md-1  loginButtonLanding" ng-click="openLoggerMenu()"&gt;
      Signup
    &lt;/div&gt;
  </code></pre>
  
  <p>And finally the content of the modal looks like this:</p>
  
  <pre><code>&lt;div class="container loginContainer"&gt;
    &lt;div class="row"&gt;
      &lt;div class="col-sm-4 col-sm-offset-2 col-xs-6 col-md-4 col-md-offset-2 loggingModal loggings" ng-click="showSignup=false; " ng-class="{'activeLogging':!showSignup}"&gt;
        Login
      &lt;/div&gt;
      &lt;div class="col-sm-4  col-xs-6 col-md-4  loggingModal loggings" ng-click="showSignup=true;" ng-class="{'activeLogging':showSignup}"&gt;
        Sign Up
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;login ng-show="!showSignup;"&gt;&lt;/login&gt;
    &lt;signup ng-show="showSignup;"&gt;&lt;/signup&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>When I now click to open the login modal it works fine and I can swtich between the tabs. But when I try to open the signup modal directly it just opens the login window from where I can switch to sign up.</p>
  
  <p>Any idea how to solve this?</p>