<fieldset class="fieldset -fieldset">
    <legend>{{ page_title }}</legend>
    <div>
        <form id="form-purchaseOrderUpdate">
            <fieldset class="fieldset -fieldset">
                {% for purchaseOrderBreakdown in purchaseOrder.purchaseorderbreakdowns %}
                    <div class="-fieldset-content">
                        <div class="row small-up-1 medium-up-2">
                            <div class="column">
                                <label>PO Number</label>
                                <input type="text" name="" value="{{ purchaseOrderBreakdown.purchaseOrderNo }}" />
                            </div>
                            <div class="column">
                                <label>Payment Method</label>
                                <select name="" >
                                    <option value="Normal" {{ purchaseOrderBreakdown.paymentmethod == 'Normal' ? 'selected' : '' }}>Normal</option>
                                    <option value="COD" {{ purchaseOrderBreakdown.paymentmethod == 'COD' ? 'selected' : '' }}>COD</option>
                                    <option value="PDC" {{ purchaseOrderBreakdown.paymentmethod == 'PDC' ? 'selected' : '' }}>PDC</option>
                                </select>
                            </div>
                        </div>
                        <div>
                            <table class="display responsive purchaseOrderItem-datalist" width="100%">
                                <thead>
                                <tr>
                                    <th>Item</th>
                                    <th>Quantity</th>
                                </tr>
                                </thead>
                                <tbody>
                                {% for purchaseOrderItem in purchaseOrder.purchaseorderitems %}
                                    {% set quantity = 0 %}
                                    {% for purchaseOrderBreakdownItem in purchaseOrderBreakdown.purchaseorderbreakdownitems %}
                                        {% if purchaseOrderItem == purchaseOrderBreakdownItem.purchaseorderitem %}
                                            {% set quantity = purchaseOrderBreakdownItem.quantity %}
                                        {% endif %}
                                    {% endfor %}
                                    <tr>
                                        <td>{{ purchaseOrderItem.materialrequisitionitem.item.description }}</td>
                                        <td>
                                            <input type="text" class="amount" name="" value="{{ quantity }}" />
                                        </td>
                                    </tr>
                                {% endfor %}
                                </tbody>
                            </table>
                        </div>
                    </div>
                {% endfor %}
            </fieldset>
        </form>
    </div>
</fieldset>