<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPages/Main.master" AutoEventWireup="true"
	CodeFile="EJSearch.aspx.cs" Inherits="EJSearch" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
	<!-- DataTables -->
	<link rel="stylesheet" href="../plugins/datatables-bs4/css/dataTables.bootstrap4.min.css">
	<link rel="stylesheet" href="../plugins/datatables-responsive/css/responsive.bootstrap4.min.css">
	<link rel="stylesheet" href="../plugins/datatables-buttons/css/buttons.bootstrap4.min.css">
    <!-- Radio Button style -->
    <link rel="stylesheet" href="../css/custom_radio1.css">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
	<asp:ScriptManager ID="ScriptManager1" runat="server">
	</asp:ScriptManager>
	<!-- Content Wrapper. Contains page content -->
	<div class="content-wrapper">
		<!-- Content Header (Page header) -->
	<section class="content-header">
	  <div class="container-fluid">
		<div class="row mb-2">
		  <div class="col-sm-6">
			<h1>EJ Transactions Search</h1>
		  </div>
		  <div class="col-sm-6">
			<ol class="breadcrumb float-sm-right">
			  <li class="breadcrumb-item"><a href="#">Home</a></li>
			  <li class="breadcrumb-item active">Reconciliation</li>
			  <li class="breadcrumb-item active">Ej Transaction Search</li>
			</ol>
		  </div>
		</div>
	  </div><!-- /.container-fluid -->
	</section>
		<!-- /.content-header -->
		<!-- Main content -->
	<section class="content">
	    <div class="container-fluid">
        <div class="card card-warning">
              <%--<div class="card-header">
                <h3 class="card-title">Search Filters</h3>
              </div>--%>
              <!-- /.card-header -->
              <div class="card-body">
                  <div class="row">
                    <div class="col-sm-3">
                      <!-- text input -->
                      <div class="form-group">
                        <label>ATM number</label>
                        <asp:TextBox ID="txtTerminal" runat="server" class="form-control" ></asp:TextBox>
                        <asp:Label ID="lbTermNotFoundlError" runat="server" Style="color: #FF0000"></asp:Label>
                      </div>
                    </div>
                    <div class="col-sm-3">
                      <div class="form-group">
                        <label>Card Number</label>
                        <asp:TextBox ID="txtCardNumber" MaxLength="19" runat="server" class="form-control" ></asp:TextBox>
                      </div>
                    </div>
                    <div class="col-sm-3">
                      <div class="form-group">
                        <label>Trace ID</label>
                        <asp:TextBox ID="txtTraceID" MaxLength="16" runat="server" class="form-control" ></asp:TextBox>
                      </div>
                    </div>
                    <div class="col-sm-3 radio radio-primary">
                      <div class="form-group">
                        <label>Search Type</label><br />
                         <asp:RadioButton ID="rdOnUs" runat="server" GroupName="aa" Text="On Us" Checked="True" />&nbsp;&nbsp;&nbsp;
                         <asp:RadioButton ID="rdOther" runat="server" GroupName="aa" Text="Others" OnCheckedChanged="rdOther_CheckedChanged" />
                      </div>
                    </div>
                    <div class="col-sm-3">
                      <div class="form-group">
                        <label>Match Status</label>
                        <asp:DropDownList ID="ddlMatch" runat="server" DataTextField="status"
                                            DataValueField="sid" class="form-control select">
                                        </asp:DropDownList>
                      </div>
                    </div>
                    <div class="col-sm-3">
                      <div class="form-group">
                        <label>Account Number <span style="color: Red">*</span></label>
                        <asp:TextBox ID="txtAccountNo"  runat="server" class="form-control" ></asp:TextBox>
                      </div>
                    </div>
                    <div class="col-sm-3">
                      <div class="form-group">
                        <label>Match Status</label>
                        
                                        <asp:DropDownList ID="ddlETT" runat="server" DataTextField="Ett_Desc" Width="350px"
                                            DataValueField="ID" class="form-control select">
                                        </asp:DropDownList>
                      </div>
                    </div>
                    <div class="col-sm-3">
                      <!-- textarea -->
                      <div class="form-group">
                  <label>Date</label>

                  <div class="input-group">
                    <div class="input-group-prepend">
                      <span class="input-group-text">
                        <i class="far fa-calendar-alt"></i>
                      </span>
                    </div>
                    <asp:TextBox ID="txtDate" data-target="#reservationdate" runat="server" class="form-control float-right"></asp:TextBox>
                  </div>
                  <!-- /.input group -->
                </div>
                    </div>
                  </div>
                  <div class="row">
                      <div class="col-12" style="text-align: center">
                          <asp:Button ID="btnSearch" runat="server" Text="Search" OnClick="btnSearch_Click" CssClass="btn btn-primary btn-l" />
                      </div>
                  </div>
              </div>
              <!-- /.card-body -->
            </div>
		<!-- Default box -->
		<div id="SResults" class="card card-info color-palette-box" visible="false" runat="server">
			<div class="card-header">
				<h3 class="card-title">
                    <i class="fas fa-tag"></i>
                    Search Results
                </h3>

				<div class="card-tools">
					<button type="button" class="btn btn-tool" data-card-widget="collapse" title="Collapse">
						<i class="fas fa-minus"></i>
					</button>
					</div>
			</div>
            <div class="card-body">
                <div style="min-height: 100px; width: 100%; display: inline-block; vertical-align: top; overflow-x: auto;">
                    <asp:GridView ID="GridView1" class="table table-striped table-bordered table-sm" runat="server" AutoGenerateColumns="False" OnPreRender="GridView1_PreRender"
                        OnRowCommand="GridView1_RowCommand" OnRowCreated="GridView1_RowCreated" EmptyDataText="There are no results">
                        <Columns>
                            <asp:BoundField DataField="card_no" HeaderText="Card&nbsp;No" />
                            <asp:BoundField DataField="tran_date" HeaderText="Date" />
                            <asp:BoundField DataField="tran_time" HeaderText="Time" />
                            <asp:BoundField DataField="settle_date" HeaderText="Settle&nbsp;Date" />
                            <asp:BoundField DataField="txn_cur" HeaderText="Currency" />
                            <asp:BoundField DataField="amount" HeaderText="Amount" />
                            <asp:BoundField DataField="terminal_id" HeaderText="Terminal&nbsp;ID" />
                            <asp:BoundField DataField="record_date" HeaderText="Record&nbsp;Date" />
                            <asp:BoundField DataField="proc_flag" HeaderText="Proc&nbsp;Flag" />
                            <asp:BoundField DataField="seq_no" HeaderText="Seq&nbsp;No" />
                            <asp:BoundField DataField="tran_status" HeaderText="" />
                            <asp:BoundField DataField="status" HeaderText="" />
                            <asp:BoundField DataField="luno_id" HeaderText="" />
                            <asp:BoundField DataField="ACCOUNT" HeaderText="" />
                            <asp:BoundField DataField="disp_a" HeaderText="" />
                            <asp:BoundField DataField="disp_b" HeaderText="" />
                            <asp:BoundField DataField="disp_c" HeaderText="" />
                            <asp:BoundField DataField="disp_d" HeaderText="" />
                            <asp:BoundField DataField="txn_date" HeaderText="" />
                            <asp:BoundField DataField="status_code" HeaderText="" />
                            <asp:TemplateField HeaderText="Actions" Visible="true">
                                <ItemTemplate>
                                    <button type="button" class="btn btn-default btn-block btn-xs dropdown-toggle" data-toggle="dropdown">
                                        Action
                                    </button>
                                    <div class="dropdown-menu">
                                        <a class="dropdown-item" href="#">
                                            <asp:Button ID="Button5" CssClass="btn btn-outline-info btn-block btn-sm" runat="server" Text="Details" CommandName="v" CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" /></a>
                                    </div>
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                </div>
                <div class="row" style="margin-left: 1%; margin-top: 1%; margin-bottom: 1%">
                    <div style="margin-top: 3px;">
                        <asp:Label ID="LGTP" runat="server" Text="Go To Page"></asp:Label>&nbsp;: &nbsp;</div>
                    <asp:DropDownList ID="ddlPages" runat="server" class="form-control select2" AutoPostBack="True" Width="7%" Height="6%" OnSelectedIndexChanged="ddlPages_SelectedIndexChanged"></asp:DropDownList>
                </div>
            </div>
					
			<!-- /.card-body -->
		</div>

        
        <!-- /.card -->
		<div class="row">
			<div class="modal fade" id="modal-xl">
		   
				<div class="modal-dialog modal-xl" style="max-width: max-content;">
					<div class="modal-content">
					<div class="modal-header">
						<h4 class="modal-title">Transaction Details</h4>
						<button type="button" class="close" data-dismiss="modal" aria-label="Close">
						<span aria-hidden="true">&times;</span>
						</button>
					</div>
					<div class="modal-body">
							
						<div class="card-body">
							<table border="0" cellpadding="0" cellspacing="0" class="add_ItemTB1">
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Card Number
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label1" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Sequence Number
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label2" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Transaction Status
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label3" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Transaction Date
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label4" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Transaction Time
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label5" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Settle Date
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label6" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Account
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label7" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Transaction Currency
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label8" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Amount
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label9" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Status
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label14" runat="server" Text="Label" Font-Bold="True"></asp:Label></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Terminal ID
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label11" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Record Date
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label12" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Processing flag
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label13" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                        </td>
                                    </tr>
                                    
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Cassette &quot;A&quot; (100)
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label10" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Cassette &quot;B&quot; (500)
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label15" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="tdNormal" style="width: 15%">
                                            Cassette &quot;C&quot; (50)
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label16" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                        <td class="tdNormal" style="width: 10%">
                                            &nbsp;
                                        </td>
                                        <td class="tdNormal" style="width: 15%">
                                            Cassette &quot;D&quot; (100)
                                        </td>
                                        <td class="tdNormal" style="width: 30%">
                                            <asp:Label ID="Label17" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                                        </td>
                                    </tr>
                                    
                    </tr>
                   
                    <tr>
                        <td class="tdNormal" style="width: 15%">
                            Denomination
                        </td>
                        <td class="tdNormal" style="width: 30%">
                            <asp:Label ID="lblDenom" runat="server" Text="Label" Font-Bold="True"></asp:Label>
                        </td>
                        <td class="tdNormal" style="width: 10%">
                        </td>
                        <td class="tdNormal" style="width: 15%">
                        </td>
                        <td class="tdNormal" style="width: 30%">
                        </td>
                    </tr>
                    
                    <tr>
                        <td class="tdNormal" style="width: 15%">
                            EDC status
                        </td>
                        <td class="tdNormal" colspan="4">
                            <asp:GridView ID="GridView2" CssClass="gridMaster" Width="100%" runat="server" AutoGenerateColumns="False"
                                CellPadding="4" ForeColor="#333333" GridLines="None" EmptyDataText="There are no status messages">
                                <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                                <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                                <Columns>
                                    <asp:BoundField DataField="status" HeaderText="status" />
                                    <asp:BoundField DataField="stat_desc" HeaderText="Description" />
                                    <asp:BoundField DataField="TERM_TRACE" HeaderText="Trace" />
                                    <asp:BoundField DataField="TXN_PREV_TRACE" HeaderText="Prev&nbsp;Trace" />
                                </Columns>
                                <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                                <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                                <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="Black" />
                                <EditRowStyle BackColor="#999999" />
                                <AlternatingRowStyle BackColor="White" ForeColor="#284775" HorizontalAlign="Right" />
                            </asp:GridView>
                        </td>
                    </tr>
                </table>
								  
						</div>
						<!-- /.card-body -->

							  
					</div>
					<div class="modal-footer justify-content-between">
						<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
					</div>
					</div>
					<!-- /.modal-content -->
				</div>
				<!-- /.modal-dialog -->
			  
				</div>
                
				<!-- /.modal -->
		</div>
	</div><!-- /.container-fluid -->
	</section>
		<!-- /.content -->
	</div>
	<!-- Toastr -->
	<!-- jQuery -->
	<script src="../plugins/jquery/jquery.min.js"></script>
	<!-- Bootstrap 4 -->
	<script src="../plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
	<!-- SweetAlert2 -->
	<script src="../plugins/sweetalert2/sweetalert2.min.js"></script>
	<!-- Toastr -->
	<script src="../plugins/toastr/toastr.min.js"></script>
	<!-- AdminLTE App -->
	<script src=".../dist/js/adminlte.min.js"></script>
	<!-- AdminLTE for demo purposes -->
	<script src="../plugins/datatables-buttons/js/dataTables.buttons.min.js"></script>
	<script src="../plugins/datatables/jquery.dataTables.min.js"></script>
	<script src="../plugins/datatables-bs4/js/dataTables.bootstrap4.min.js"></script>
	<script src="../plugins/datatables-responsive/js/dataTables.responsive.min.js"></script>
	<script src="../plugins/datatables-responsive/js/responsive.bootstrap4.min.js"></script>
	<script src="../plugins/datatables-buttons/js/dataTables.buttons.min.js"></script>
	<script src="../plugins/datatables-buttons/js/buttons.bootstrap4.min.js"></script>
	<script src="../plugins/jszip/jszip.min.js"></script>
	<script src="../plugins/pdfmake/pdfmake.min.js"></script>
	<script src="../plugins/pdfmake/vfs_fonts.js"></script>
	<script src="../plugins/datatables-buttons/js/buttons.html5.min.js"></script>
	<script src="../plugins/datatables-buttons/js/buttons.print.min.js"></script>
	<script src="../plugins/datatables-buttons/js/buttons.colVis.min.js"></script>
    <script src="../plugins/tempusdominus-bootstrap-4/js/tempusdominus-bootstrap-4.min.js"></script>
	<!-- AdminLTE App -->
	<script src="../dist/js/adminlte.min.js"></script>
	<!-- AdminLTE for demo purposes -->
	<script src="../dist/js/demo.js"></script>
    <script src="../plugins/select2/js/select2.full.min.js"></script>
    <!-- Bootstrap4 Duallistbox -->
    <script src="../plugins/bootstrap4-duallistbox/jquery.bootstrap-duallistbox.min.js"></script>
    <!-- InputMask -->
    <script src="../plugins/moment/moment.min.js"></script>
    <script src="../plugins/inputmask/jquery.inputmask.min.js"></script>
    <!-- date-range-picker -->
    <script src="../plugins/daterangepicker/daterangepicker.js"></script>
    <!-- bootstrap color picker -->
    <script src="../plugins/bootstrap-colorpicker/js/bootstrap-colorpicker.min.js"></script>
    <!-- Tempusdominus Bootstrap 4 -->
    <script src="../plugins/tempusdominus-bootstrap-4/js/tempusdominus-bootstrap-4.min.js"></script>
    <!-- Bootstrap Switch -->
    <script src="../plugins/bootstrap-switch/js/bootstrap-switch.min.js"></script>
    <!-- BS-Stepper -->
    <script src="../plugins/bs-stepper/js/bs-stepper.min.js"></script>
    <!-- dropzonejs -->
    <script src="../plugins/dropzone/min/dropzone.min.js"></script>
    <!-- AdminLTE App -->
	<script>

	    $(function () {

	        $('#ContentPlaceHolder1_GridView1').DataTable({
	            "responsive": true, "lengthChange": false, "autoWidth": false,
	            "buttons": ["copy", "csv", "excel", "pdf", "print", "colvis"]
	        }).buttons().container().appendTo('#example1_wrapper .col-md-6:eq(0)');

	        //Date picker
	        $('#reservationdate').daterangepicker();
//	        $('#ctl00_ContentPlaceHolder1_reservation').daterangepicker()({
//	            format: 'DD/MM/YYYY - DD/MM/YYYY'
//	        });
	        $('#ctl00_ContentPlaceHolder1_txtDate').daterangepicker({
	            locale: {
	                format: 'DD/MM/YYYY'
	            }
	        })
	        
	        //		    $('#reservationdate').datetimepicker({
	        //		        format: 'DD/MM/YYYY'
	        //		    });

	        //        $('#ContentPlaceHolder1_GridView1').DataTable({
	        //            "responsive": true, "lengthChange": false, "autoWidth": false,
	        //            "buttons": ["copy", "csv", "excel", "pdf", "print", "colvis"]
	        //        }).buttons().container().appendTo('#example1_wrapper .col-md-6:eq(0)');

	        //        $('#ContentPlaceHolder1_gvChannel').DataTable({
	        //            "responsive": true, "lengthChange": false, "autoWidth": false,
	        //            "buttons": ["copy", "csv", "excel", "pdf", "print", "colvis"]
	        //        }).buttons().container().appendTo('#example1_wrapper .col-md-6:eq(0)');

	        //        $('#ContentPlaceHolder1_gvEJ').DataTable({
	        //            "responsive": true, "lengthChange": false, "autoWidth": false,
	        //            "buttons": ["copy", "csv", "excel", "pdf", "print", "colvis"]
	        //        }).buttons().container().appendTo('#example1_wrapper .col-md-6:eq(0)');
	    });
</script>
</asp:Content>
