PlaceBid.html
{% extends "global/Page.html" %}

{% block title %}PlaceBid{% endblock %}
{% block content %}
    <p>
        {% if player.round_number >= 4 %}
        You are one of {{ Constants.players_per_group }} players who are bidding in this auction. The players you are bidding against
        have been <b> randomly assigned </b>
        {% elif player.round_number == 1%}
        You are one of {{ Constants.players_per_group }} players who are bidding in this auction. The players you are bidding against
        have been <b> randomly assigned </b>. Remember, you will be playing with these people again in the next round.
        {% else %}
        You are on of {{ Constants.players_per_group }} players who are bidding in this auction. The players you are bidding against
        are the <b> same </b> players you have bid against last time.
        {% endif %}
    </p>
    <p>
        If you do not place a bid before the timer runs out, a bid of 0 will be automatically placed for you.
    </p>
    <p>
        Your personal (and private) value of the item is <b>{{ player.value }}</b>.
    </p>

    <p>
        Please make your bid now. The amount can be between {{ Constants.min_allowable_bid }} and {{ Constants.max_allowable_bid }}, inclusive.
    </p>

    {% formfields %}
    <p>
        {% if player.round_number != 1 %}
            Your results from previous rounds can be found below to consider before placing your bid.
    </p>

        <div class = "card-header mb-3 text center" style ="...">
             <b> History Table </b>
        </div>

        <p>
            <div class="row justify-content-center" style="max-height: 40vh; overflow: scroll">
                <table class = "table">
                    <tr>
                        <th class = "text-center">Round </th>
                        <th class = "text-center">Your Bids </th>
                        <th class = "text-center">Your Private Value</th>
                        <th class = "text-center">Did you win? </th>
                        <th class = "text-center">Price </th>
                    </tr>
                    <tbody>
                    {% for p in player.in_previous_rounds %}
                        <tr>
                            <td class = "text-center my_style"> {{ p.round_number }}</td>
                            <td class = "text-center"> {{p.bid}}</td>
                            <td class = "text-center"> {{ p.value }}</td>
                            <td class = "text-center"> {% if p.is_winner == True  %} Yes {% else %} No {% endif %}</td>
                            <td class = "text-center"> {{ p.price }} </td>

                        </tr>
                    {% endfor %}
                    </tbody>
                </table>
            </div>


        </p>
        {% endif %}

    {% next_button %}

    {% include Constants.instructions_template %}

{% endblock %}