Subversion Repositories SmartDukaan

Rev

Rev 36022 | Blame | Compare with Previous | Last modification | View Log | RSS feed

<h4>Invoice - <a href="${rc.contextPath}/purchase-invoice/$invoiceNumber" target="_blank">$invoiceNumber</a></h4>

#if($allReturned)
<div class="alert alert-success">
        <strong>All items already returned for this invoice.</strong>
</div>
#end

#if($isShipped)
<div class="alert alert-warning">
        <strong>Shipped Invoice.</strong> This invoice has been shipped. Finance approval required for refund.
</div>
#end

<table class="table table-striped table-condensed table-bordered">
        <thead>
                <tr>
                        <th>Order Id</th>
                        <th>Item</th>
                        <th>Qty</th>
                        <th>Return Qty</th>
                        <th>Unit Price</th>
                        <th>Status</th>
                </tr>
        </thead>
        <tbody>
                #foreach($order in $orders)
                <tr>
                        <td>$order.getId()</td>
                        <td>$order.getLineItem().getBrand() $order.getLineItem().getModelName()</td>
                        <td>$order.getLineItem().getQuantity()</td>
                        <td>$order.getLineItem().getReturnQty()</td>
                        <td>$order.getLineItem().getUnitPrice()</td>
                        <td>$order.getStatusDescription()</td>
                </tr>
                #end
        </tbody>
</table>

#if(!$allReturned)
        #if($canAutoApprove)
        <div class="form-group">
                <label>Remark</label>
                <textarea id="invoice-return-remark" class="form-control" rows="3" placeholder="Enter remark"></textarea>
        </div>
        <button class="btn btn-danger process-invoice-return" data-invoice="$invoiceNumber">Process Return & Refund</button>
        #elseif($canReceive)
        <div class="form-group">
                <label>Remark</label>
                <textarea id="invoice-return-remark" class="form-control" rows="3" placeholder="Enter remark"></textarea>
        </div>
        <button class="btn btn-info process-invoice-return" data-invoice="$invoiceNumber">Receive Return (Pending Finance Approval)</button>
        #else
        <div class="alert alert-info">
                <strong>View Only.</strong> Not authorized to process returns.
        </div>
        #end
#end