angular.module('app.routes', ['ui.router'])

.config(function($stateProvider, $urlRouterProvider) {
  //
  // For any unmatched url, redirect to /state1
  $urlRouterProvider.otherwise("/");
  //
  // Now set up the states
  $stateProvider
    .state('home', {
      url: "/",
      templateUrl: "partials/home.html",
      controller:"HomeCtrl"
    })
    .state('auth',{
      url:"/auth",
      templateUrl: "partials/auth.html",
      controller:"ClientCtrl"
    })
    .state('livres',{
    	url:"/livres/:id",
    	templateUrl:"partials/livres.html",
    	controller:"LivreCtrl"
    })
    .state('panier',{
      url:"/panier",
      templateUrl:"partials/panier.html",
      controller:"PanierCtrl"
    })
    .state('search',{
      url:"/search/:mc",
      templateUrl:"partials/search.html",
      controller:"SearchCtrl"
    });
    

});