<xen:require css="nflj_sportsbook_member.css" />
<div class="profileContent sportsbookWagerList">
<ol>
<xen:if is="{$wagers}">
<xen:foreach loop="$wagers" value="$wager">
<li class="sportsbookWagerListItem" id="wager-{$wager.wager_id}">
<div class="listBlock main">
<div class="listBlockInner">
<span class="status">
<xen:if is="{$wager.event_status} == 'open' ">
<span class="{$wager.event_status}">{xen:phrase nflj_sportsbook_status_open}</span>
<xen:elseif is="{$wager.event_status} == 'closed' " />
<span class="{$wager.event_status}">{xen:phrase nflj_sportsbook_status_closed}</span>
<xen:elseif is="{$wager.event_status} == 'awaiting_settlement' " />
<span class="{$wager.event_status}">{xen:phrase nflj_sportsbook_status_awaiting}</span>
<xen:elseif is="{$wager.event_status} == 'settled' " />
<xen:if is="{$wager.outcome_pays} == 'Y' ">
<span class="{$wager.event_status}">{xen:phrase nflj_sportsbook_paid_out}</span>
<xen:elseif is="{$wager.outcome_pays} == 'P' " />
<span class="{$wager.event_status}">{xen:phrase nflj_sportsbook_push}</span>
</xen:if>
<span class="{$wager.event_status}">{xen:phrase nflj_sportsbook_status_settled}</span>
<xen:else />
<span style="color:red;">{xen:phrase nflj_sportsbook_status_abandoned}</span>
</xen:if>
</span>
<h3 class="title">
<a href="{xen:link sportsbook/outcome, $wager}" class="overlayScroll OverlayTrigger">{xen:helper snippet, $wager.outcome_title, 40}</a>
<xen:if is="{$event.category_abbr}"><span class="categoryAbbr">{$event.category_abbr}</span></xen:if>
</h3>
<div class="eventDetails muted">
<a href="{xen:link sportsbook, $wager}">{$wager.title}</a>
</div>
<div class="statusDate muted">
<xen:if is="{$wager.event_status} == 'open' ">
<span class="open">{xen:phrase nflj_sportsbook_event_closes} <xen:datetime time="$wager.date_close" /></span>
<xen:elseif is="{$wager.event_status} == 'closed' " />
<span class="closed">{xen:phrase nflj_sportsbook_event_currently_not_taking_wagers}</span>
<xen:elseif is="{$wager.event_status} == 'awaiting_settlement' " />
<span class="">{xen:phrase nflj_sportsbook_event_closed} <xen:datetime time="$wager.date_close" /></span>
<xen:elseif is="{$wager.event_status} == 'settled' " />
<span class="settled">{xen:phrase nflj_sportsbook_event_settled} <xen:datetime time="$wager.date_settle" /></span>
<xen:else />
<span style="color:red;">{xen:phrase nflj_sportsbook_status_abandoned}</span>
</xen:if>
</div>
</div>
</div>
<div class="listBlock wagerStats">
<div class="listBlockInner">
<div class="pairsJustified">
<dl class="wagerStaked">
<dt>{xen:phrase nflj_sportsbook_staked}:</dt>
<dd>{$xenOptions.sbCurrencySymbol}{$wager.wager_amount_placed}</dd>
</dl>
<dl class="wagerOdds">
<dt>{xen:phrase nflj_sportsbook_wagered_odds}:</dt>
<dd>{$wager.wager_odds_against}/{$wager.wager_odds_for} {xen:if '{$wager.wager_odds_decimal}', '({$wager.wager_odds_decimal})', ''}</dd>
</dl>
<xen:if is="{$wager.event_status} == 'settled' ">
<dl class="wagerWinLossAmount">
<xen:if is="{$wager.outcome_pays} == 'Y' ">
<dt>{xen:phrase nflj_sportsbook_won}:</dt>
<dd><span class="win">{$xenOptions.sbCurrencySymbol}{xen:number $wager.wager_amount_won, 2}</span></dd>
<xen:elseif is="{$wager.outcome_pays} == 'P' " />
<dt>{xen:phrase nflj_sportsbook_push}:</dt>
<dd><span class="push">{xen:phrase nflj_sportsbook_stake_returned}</span></dd>
<xen:else />
<dt>{xen:phrase nflj_sportsbook_lost}:</dt>
<dd><span class="loss">-{$xenOptions.sbCurrencySymbol}{xen:number $wager.wager_amount_placed}</span></dd>
</xen:if>
</dl>
</xen:if>
</div>
</div>
</div>
</li>
</xen:foreach>
<div class="sectionFooter">
<ul class="listInline bulletImplode">
<li><a href="{xen:link sportsbook/member, $wager}" rel="nofollow">{xen:phrase nflj_sportsbook_find_all_wagers_by_x, 'name={$wager.username}'}</a></li>
</ul>
</div>
<xen:else />
<li class="sportsbookWagerListItem">
{xen:phrase nflj_sportsbook_no_viewable_wagers}
</li>
</xen:if>
</ol>
</div>