So friends,
I'm trying to use reveal modal with angular because I have data that I would like to inject into the modal based upon a ng-click of links that are created by ng-repeat, allow me to present some code:
<table ng-controller="oflClassCtrl">
<thead>
<tr>
<th>Course Title(Apex/Isis)</th>
</tr>
</thead>
<tbody>
<tr ng-repeat = "selectedClass in classes | filter:searchTxt">
<td><a href="#" data-reveal-id="myModal" ng-click="setClass($index)">{{selectedClass.class}}</a></td>
and controller:
var oflApp = angular.module('oflApp', []);
oflApp.controller('oflClassCtrl', function ($scope,$http) {
// $http.get('../courses/coursedata.json');
$scope.classes = [
{"class": "ENGLISH I: INTRO TO LITERATURE AND COMPOSITION Sem 2", "href": "../courses/english.php#p1"},
{"class": "ENGLISH II: CRITICAL READING AND EFFECTIVE WRITING Sem 1"},ect,
$scope.setClass = function(index) {
$scope.selectedClass = $scope.classes[index];
};
});
I've looked over http://pineconellc.github.io/angular-foundation/ however im not sure do i just download a file and link it in head,and thhen add a new module?
All I want to do, is have my data show up in a reveal modal when a user clicks the relevant course that will be displayed with ng-repeat. I have a template layout out for that as well if it would be necessary for me to post it but basically just want it to render the class info.
can someone give me a breif example of how to set this up plz. Thank you.