I am trying to switch views from one page to another when a button is pressed.I am using ng-click for it but it doesnt switch the views when the button is pressed
.js file
$scope.onCreateAppointment = function () {
$scope.templates.myTemplate = "views/calendar.html";
};
}]);
.html file
ng-click="OnCreateAppointment()">Create Appointment</button>