<turbo-stream action="replace" target="content"><template><turbo-frame id="content"><h5 class="strong">Game</h5><div class="grid-x grid-padding-x"><div class="small-6 cell"><p class="slim">Games are the smallest table but the controlling model.</p><pre><code>class Game < ActiveRecord::Base
 belongs_to :group
 has_many :scored_rounds
 has_many :event_rounds
 has_many :rounds, :dependent => :destroy
 has_many :players, through: :rounds
end</code></pre><div class="strong">Purpose</div><ul class="classic ml-4"><li>To define information on games played on a date.</li><li>To link group players who played</li><li>To link rounds to players, including scores and teams</li></ul></div><div class="small-6 cell"><div class="strong">Data Elements</div><dl class="indent-dd"><dt>group_id</dt><dd>Defines the group the event belongs to </dd><dt>date</dt><dd>The date the event occurred.</dd><dt>status</dt><dd>The current status of the event.</dd><dt>games </dt><dd>option information on side games played during the event</dd><dd><dl class="indent-dd"><dt>Games</dt><dd>Information on what games were played, the game pot and who was in the game</dd><dt>Game</dt><dd>Statistics on who won the game</dd><dt>Cards</dt><dd>Scorecards for players who played the skins game (what there score was on each hole relative to par (birdie, eagle, etc)).</dd></dl></dd></dl></div></div></turbo-frame></template></turbo-stream>