Created
November 27, 2014 02:19
-
-
Save mplatts/c6e741afab87ed36c780 to your computer and use it in GitHub Desktop.
templates2 - adding games
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- client/views/games.html --> | |
<template name="games"> | |
<h3>Games</h3> | |
{{#if creating}} | |
<form class="form-create"> | |
<select name="teamOne"> | |
{{#each teams}} | |
<option value="{{_id}}">{{name}}</option> | |
{{/each}} | |
</select> | |
vs | |
<select name="teamTwo"> | |
{{#each teams}} | |
<option value="{{_id}}">{{name}}</option> | |
{{/each}} | |
</select> | |
<button type="submit">Submit</button> | |
<a class="cancel" href="#">Cancel</a> | |
</form> | |
{{else}} | |
<a class="create" href="#">Create</a> | |
{{/if}} | |
<ul> | |
{{#each games}} | |
{{> game}} | |
{{/each}} | |
</ul> | |
</template> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment