Use /home everywhere

pull/4/merge
Emmanuel ROHEE 10 years ago
parent 4c7df52360
commit de0706493a
  1. 10
      webclient/app.js
  2. 4
      webclient/home/home-controller.js
  3. 2
      webclient/home/home.html
  4. 2
      webclient/index.html
  5. 4
      webclient/login/login-controller.js
  6. 2
      webclient/room/room-controller.js

@ -19,7 +19,7 @@ var matrixWebClient = angular.module('matrixWebClient', [
'MatrixWebClientController',
'LoginController',
'RoomController',
'RoomsController',
'HomeController',
'SettingsController',
'UserController',
'matrixService',
@ -45,9 +45,9 @@ matrixWebClient.config(['$routeProvider', '$provide', '$httpProvider',
templateUrl: 'room/room.html',
controller: 'RoomController'
}).
when('/rooms', {
templateUrl: 'rooms/rooms.html',
controller: 'RoomsController'
when('/home', {
templateUrl: 'home/home.html',
controller: 'HomeController'
}).
when('/settings', {
templateUrl: 'settings/settings.html',
@ -58,7 +58,7 @@ matrixWebClient.config(['$routeProvider', '$provide', '$httpProvider',
controller: 'UserController'
}).
otherwise({
redirectTo: '/rooms'
redirectTo: '/home'
});
$provide.factory('AccessTokenInterceptor', ['$q', '$rootScope',

@ -16,8 +16,8 @@ limitations under the License.
'use strict';
angular.module('RoomsController', ['matrixService', 'mFileInput', 'mFileUpload', 'eventHandlerService'])
.controller('RoomsController', ['$scope', '$location', 'matrixService', 'mFileUpload', 'eventHandlerService', 'eventStreamService',
angular.module('HomeController', ['matrixService', 'mFileInput', 'mFileUpload', 'eventHandlerService'])
.controller('HomeController', ['$scope', '$location', 'matrixService', 'mFileUpload', 'eventHandlerService', 'eventStreamService',
function($scope, $location, matrixService, mFileUpload, eventHandlerService, eventStreamService) {
$scope.config = matrixService.config();

@ -1,4 +1,4 @@
<div ng-controller="RoomsController" class="rooms">
<div ng-controller="HomeController">
<div id="page">
<div id="wrapper">

@ -15,10 +15,10 @@
<script src="app-controller.js"></script>
<script src="app-directive.js"></script>
<script src="app-filter.js"></script>
<script src="home/home-controller.js"></script>
<script src="login/login-controller.js"></script>
<script src="room/room-controller.js"></script>
<script src="room/room-directive.js"></script>
<script src="rooms/rooms-controller.js"></script>
<script src="settings/settings-controller.js"></script>
<script src="user/user-controller.js"></script>
<script src="components/matrix/matrix-service.js"></script>

@ -53,7 +53,7 @@ angular.module('LoginController', ['matrixService'])
matrixService.saveConfig();
eventStreamService.resume();
// Go to the user's rooms list page
$location.url("rooms");
$location.url("home");
},
function(error) {
if (error.data) {
@ -84,7 +84,7 @@ angular.module('LoginController', ['matrixService'])
});
matrixService.saveConfig();
eventStreamService.resume();
$location.url("rooms");
$location.url("home");
}
else {
$scope.feedback = "Failed to login: " + JSON.stringify(response.data);

@ -364,7 +364,7 @@ angular.module('RoomController', ['ngSanitize', 'mUtilities'])
matrixService.leave($scope.room_id).then(
function(response) {
console.log("Left room ");
$location.url("rooms");
$location.url("home");
},
function(error) {
$scope.feedback = "Failed to leave room: " + error.data.error;

Loading…
Cancel
Save