Once we can choose a random users, we can use our methods to add awards to each user. We'll need a small form in order to do this.
- [Instructor] For our last feature,…I'm going to add the ability…to add individual awards to people.…That way I can give more than one prize at a meet-up.…Now to do that, I'm going to add a second button…to each user right in this list.…So, let's go to the section…where I have the different buttons,…and I'm going to add another one.…And this button will have an ngClick directive…that will execute something called showLove…and will pass along the individual check-in…so the check-in information for that user.…
In the span, we'll just put a label…that says Show the love.…The next thing I need to do is create the form…that allows me to fill out that information…and send it to our database.…So right here, after the info, going to create a form.…The class will just be a clearfix.…It's not going to have an action or a method,…we're going to handle everything with AngularJS.…So this will have an ng-submit.…And we're going to create another function called giveLove,…pass along the checkin,…and then the checkin…dot…giftText.…
Learn how to create forms, edit database records, create methods, randomize record selections, and style and secure your app. With these project-based lessons, you'll learn how to see how data-driven programming with AngularJS can help your apps react to real-time data streams.
- Customizing an Angular template
- Adding forms to create meetings and check in users
- Adding, showing, and deleting database records
- Using events to track meetings
- Adding a form to the app
- Creating methods
- Randomizing prizes
- Creating conditional styles
- Managing app permissions