Subversion Repositories SmartDukaan

Rev

Rev 25093 | Rev 30607 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
22245 ashik.ali 1
<style>
30601 amit.gupta 2
    .table-striped > tbody > tr:nth-child(odd) > td {
3
        background: white;
4
        background-color: white;
5
    }
6
 
7
    .table-striped > tbody > tr:nth-child(even) > td {
8
        background: white;
9
        background-color: white;
10
    }
11
 
12
    .table-striped > tbody > tr:hover > td,
13
    .table-striped > tbody > tr:hover {
14
        background-color: #e98c8f;
15
        color: white;
16
    }
17
 
18
    .btn:hover {
19
        color: grey;
20
        text-decoration: none;
21
    }
22
 
23
    .btn-primary:hover {
24
        color: grey;
25
        text-decoration: none;
26
    }
27
 
28
    .sale-details {
29
        cursor: pointer;
30
    }
22245 ashik.ali 31
</style>
32
<script>
30601 amit.gupta 33
    $(function () {
22245 ashik.ali 34
 
30601 amit.gupta 35
        let start = moment().subtract(29, 'days');
36
        let end = moment();
37
        $('#saleDuration').daterangepicker(getRangedDatePicker(true, start, end));
38
    });
22245 ashik.ali 39
</script>
40
 
30601 amit.gupta 41
<section class="wrapper">
42
    <div class="row">
43
        <div class="col-lg-12">
44
            <h3 class="page-header"><i class="icon_document_alt"></i>SALE HISTORY</h3>
45
            <ol class="breadcrumb">
46
                <li><i class="fa fa-home"></i><a href="${rc.contextPath}/dashboard">Home</a></li>
47
                <li><i class="icon_document_alt"></i>SALE HISTORY</li>
48
            </ol>
49
        </div>
22245 ashik.ali 50
    </div>
30601 amit.gupta 51
 
52
    <div id="sale-history-search">
53
        <div class="row">
54
            <div class="col-lg-2 form-group">
55
                <select class="form-control" id="searchType" name="searchType" placeholder="Search Type">
56
                    <option value="" disabled selected>Search Type</option>
57
                    #foreach($searchType1 in $searchTypes)
58
                        #if($searchType.getValue()==$searchType1.getValue())
59
                            <option value="$searchType1" selected>$searchType1.getValue()</option>
60
                        #else
61
                            <option value="$searchType1">$searchType1.getValue()</option>
62
                        #end
63
                    #end
64
                </select>
65
            </div>
66
            #if($searchType.getValue()=="Date-Range")
67
                <div class="col-lg-3">
68
                    <div class="input-group">
69
                        <input class="form-control" placeholder="Sale Period" id="saleDuration" type="text"
70
                               value="$searchValue">
71
                    </div>
72
                </div>
73
            #elseif($searchType)
74
                <div class="col-lg-3">
75
                    <input type="text" class="form-control" id="sale-history-search-text"" placeholder="Search
76
                    by $searchType.getValue()" value="$searchValue" />
77
                </div>
78
            #else
79
                <div class="col-lg-3">
80
                    <input type="text" class="form-control" id="sale-history-search-text"" placeholder="Search by"
81
                    value="$searchValue" />
82
                </div>
83
            #end
84
            <div class="col-lg-1">
85
                <button class="btn btn-primary submit" id="sale-history-search-button" type="button">Search</button>
86
            </div>
87
            <div class="col-lg-2">
88
                <button class="btn btn-primary submit" id="invoice-download-button" type="button">Download(Upto 100
89
                    invoices)
90
                </button>
91
            </div>
92
 
93
        </div>
94
    </div>
95
    <div id="sale-history-table">
96
        <div class="row">
97
            <div class="col-lg-12">
98
                <table class="table table-striped table-advance table-hover">
99
                    <tbody>
100
                    <tr>
101
                        <th>Invoice Number</th>
102
                        <th>Total Amount</th>
103
                        <th>Created On</th>
104
                        <th>View Details</th>
105
                    </tr>
106
                        #if(!$saleHistories.isEmpty())
107
                            #foreach( $saleHistory in $saleHistories )
108
                            <tr class="sale-details" data="$saleHistory.getId()">
109
                                <td>$saleHistory.getInvoiceNumber()</td>
110
                                <td>$saleHistory.getTotalAmount()</td>
111
                                <td>$saleHistory.getFormattedDate()</td>
112
                                <td>
113
                                    <button class="btn btn-primary">View</button
114
                                </td>
115
                            </tr>
116
                            #end
117
                        #else
118
                        <tr>
119
                            <td colspan="6" style="text-align:center;">NO MATCHING DATA FOUND FOR CRITERIA</td>
120
                        </tr>
121
                        #end
122
                    </tbody>
123
                </table>
124
            </div>
125
        </div>
126
    </div>
22245 ashik.ali 127
    #if(!$saleHistories.isEmpty())
30601 amit.gupta 128
        <div class="row" id="sale-history-paginated">
129
            <div class="col-lg-9">
130
                <p>Showing <span class="start">$start</span> to <span class="end">$end</span> of <span
131
                        class="size">$size</span> items</p>
132
            </div>
133
            <div class="col-lg-3" style="text-align:right;">
134
                <div class="btn-group" style="width:40%">
135
                    <button class="btn btn-primary previous" disabled="disabled" style="width:100%">Previous</button>
136
                </div>
137
                <div class="btn-group" style="width:40%">
138
                    #if($end >= $size)
139
                        <button class="btn btn-primary next" style="width:100%" disabled="disabled">Next</button>
140
                    #else
141
                        <button class="btn btn-primary next" style="width:100%">Next</button>
142
                    #end
143
                </div>
144
            </div>
145
        </div>
22245 ashik.ali 146
    #end
147
</section>
148
<div id="sale-details-container" style="background:white;background-color:white;">
149
</div>