In my Angular project, I am creating a waiting list system where users can join a waiting list and then be moved to a member list. To populate the table with rows of waiting people, I am using ng-repeat. Each row has a button that, when clicked, should move that person to the member list.
First concern: I am unsure if I am assigning the correct value to the button. It should display the email of the person.
<input type="submit" ng-click="makeMember()" ng-model="member" value="Member" id="{{person.email}}">
Second issue: I need to use the user's email to create an SQL query for the database in order to move them to the member list (email is the primary key).
I attempted to reference the ng-model with $scope.member, but it returns undefined.
The makeMember function was created just for testing purposes, and it does not work as expected.
$scope.makeMember = function() {
alert("Person email: " + $scope.member);
};
Any assistance would be greatly appreciated!