{% load static %}

<!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <title>Ammico : Home</title>
  
  <link rel="stylesheet" type="text/css" href="{% static 'ammico/css/lib.css' %}"/>
  <link rel="stylesheet" type="text/css" href="{% static 'ammico/css/app.css' %}"/>
  
</head>
<body ng-controller="homeCtrl" ng-app="ammico" ng-cloak>
  <div class="navbar navbar-inverse" role="navigation">
      <div class="container">
        <div class="navbar-header">
          <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
          <a class="navbar-brand" id="logo" href="#/">
          	<img src="{% static 'ammico/img/ammico_logo_small.png' %}">
          </a>
        </div>
        <div class="collapse navbar-collapse">
          <ul class="nav navbar-nav" ng-controller="routeClassCtrl">
            <li ng-class="{active:isActive('/')}"><a href="#/">Home</a></li>
            <li ng-class="{active:isActive('/my_visit')}"><a href="#/my_visit">Ma dernière Visite</a></li>
            <li ng-class="{active:isActive('/visites')}"><a href="#/visites">Mes Visites</a></li>
            <li ng-class="{active:isActive('/books')}"><a href="#/books">Mes Books</a></li>
          </ul>
          <ul class="nav navbar-nav navbar-right" ng-controller="routeClassCtrl">
            <li ng-hide="globals.userLogged" ng-class="{active:isActive('/login')}"><a href="#/auth/login">Login</a></li>
            <li ng-show="globals.userLogged"><a href="#/auth/logout">Logout</a></li>
          </ul>
          <form class="navbar-form navbar-right" role="search" ng-submit="searchSubmit()">
            <div class="form-group">
                <input class="form-control" type="text" ng-model="q" placeholder="Chercher" />
                <button class="btn btn-default" type="submit"><span class="glyphicon glyphicon-search"></span></button>
            </div>
          </form>
        </div>
      </div>
  </div>
  <div class="container">
    <div class="ammico-content">
      <div ng-view></div>
    </div>
    <footer>
      <div class="row">
        <div class="footer-img col-md-6">
            <a href="http://www.iri.centrepompidou.fr" target="_blank">
            	<img src="{% static 'ammico/img/logo_IRI_footer.png' %}" alt="Logo IRI" />
            </a>
        </div>
        <div class="col-md-6 text-right">
            ammico vBeta - ©2014
        </div>
      </div>
    </footer>
  </div>
  
  <script src="{% static 'ammico/js/lib.js' %}"></script>
  <script src="{% static 'ammico/js/templates.js' %}"></script>
  <script src="{% static 'ammico/js/app.js' %}"></script>
  
  <script type="text/javascript">
      angular.module("ammico")
          .value('context', {
              record: angular.fromJson('{"record": "record value"}'),
              urls: {
                  base_static: "./",
                  ammicoUrl: "http://0.0.0.0:8080/ammico",
                  searchUrl: "http://ammico.labs.exalead.com/search-api"
              }
          });

  </script>
</body>
</html>
