Subversion Repositories SmartDukaan

Rev

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

<style>
        .table-striped > tbody > tr:nth-child(odd) > td{
                background: white;
                background-color: white;
        }
        .table-striped > tbody > tr:nth-child(even) > td{
                background: white;
                background-color:white;
        }
        .table-striped > tbody > tr:hover > td,
        .table-striped > tbody > tr:hover {
                background-color: #e98c8f;
                color:white;
        }
        .btn:hover{
                color: grey;
                text-decoration: none;
        }
        .btn-primary:hover{
                color: grey;
                text-decoration: none;
        }
        .sale-details{
                cursor:pointer;
        }
</style>


<section class="wrapper">
        <div class="row">
                <div class="col-lg-12">
                        <h3 class="page-header"><i class="icon_document_alt"></i>DEMO SALE APPROVAL</h3>
                        <ol class="breadcrumb">
                                <li><i class="fa fa-home"></i><a href="${rc.contextPath}/dashboard">Home</a></li>
                                <li><i class="icon_document_alt"></i>Demo Sale Approval</li>                                                    
                        </ol>
                </div>
        </div>
        
                <div>
                <div class="row">
                <div class="col-lg-3">
                <div class="input-group">
                                <input id="partnerId" type="text" class="typeahead form-control form-control-sm" placeholder="Search Partner by Store" data-provide="typeahead" 
                                 #if(${retailerName}) value="${retailerName}" #end
                                 autocomplete="off"/>
                        <div class="input-group-btn">
                                        <button class="live_demo btn btn-primary">Search</button>
                                </div>
                        </div>
                </div>
                </div>
        
        <div id="live-demo-billing-table">
                <div class="row">
                <div class="col-lg-12">
                        <table class="table table-striped table-advance table-hover">
                                <tbody>
                                        <tr>
                                                <th>Item Id</th>
                                                <th>Retailer Name</th>
                                                <th>Model Name</th>
                                                <th>Model Number</th>
                                                <th>Color</th>
                                                <th>Serial Number</th>
                                                <th>Status</th>
                                
                                        </tr>
                                                #if(!$liveDemo.isEmpty())
                                                                #foreach( $liveDemoModel in $liveDemo )
                                                                <tr class="live-demo" data="$liveDemoModel.getId()">
                                                                        <td>$liveDemoModel.getItemId()</td>
                                                                <td>$fofoIdsAndRetailerName.getBusinessName()</td>
                                                                        <td>$liveDemoModel.getItem().getModelName()</td>
                                                                        <td>$liveDemoModel.getItem().getModelNumber()</td>
                                                                        <td>$liveDemoModel.getItem().getColor()</td>
                                                                        <td>$liveDemoModel.getSerialNumber()</td>
                                                                        <td>
                                                                                <button class="btn btn-primary approve-billing"
                                                                                                data-serial="$liveDemoModel.getSerialNumber()" type="button"
                                                                                                style="width:100%;border-radius:0px;">Approve
                                                                                </button>
                                                                     </td>
                                                                
                                                        </tr>   
                                   #end
                                        #else
                                                <tr>
                                                        <td colspan="12" style="text-align:center;">NO MATCHING DATA FOUND FOR CRITERIA</td>
                                                </tr>
                                        #end
                                </tbody>
                        </table>
                </div>
            </div>
    </div>
    </section>
 
<script type="text/javascript">


$(document).ready(function() {
var customRetailers = ${customRetailers};
        $("#partnerId").typeahead({
          source: customRetailers,
          autoSelect: true,
          displayText:function(item){return item.businessName + "-" + item.address.city;},
          afterSelect:  function(currentItem){
                                                currentFofoId = currentItem.partnerId;
                                                console.log(currentFofoId);
                                        }
        });
        
});

</script>