<%@ Page Language="C#" MasterPageFile="~/CITAD.Master" 
    AutoEventWireup="true" 
    CodeBehind="frmLetterMsgCreate.aspx.cs" 
    Inherits="CITAD.Modules.TaoLenhTraSoat.Web.frmLetterMsgCreate" 
    Culture="auto" 
    meta:resourcekey="PageResource1" 
    UICulture="auto" 
    Title="Tra soát" %>

<%@ Register Src="../../Controls/MessageBox.ascx" TagName="MessageBox" TagPrefix="uc1" %>
    
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">

    <script type="text/javascript">
	    window.document.onkeydown=KeyDown;
	    function onMBoxOK_Click()
        {
            try
            {
                
                var focusControlName=$get('<%=hidFocusControlName.ClientID %>').value;
                if(focusControlName!="")
                {
                    var ctlFocusControl = $get(focusControlName)
                    if (ctlFocusControl.disabled!='disabled' || ctlFocusControl.disabled!=true) ctlFocusControl.focus();
                    $get('<%=hidFocusControlName.ClientID %>').value = "";
                }
                else
                {
                    $get(activeControl.id).focus();
                }
            }
            catch (err){}
        }
	</script>
   
    <cc1:ToolkitScriptManager runat="Server" ID="ScriptManager1" EnableScriptGlobalization="True"
        EnableScriptLocalization="True" CombineScripts="True" EnablePageMethods="true"  />
<div style="width:770px;">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server"> 
        <%--<Triggers>
            <asp:AsyncPostBackTrigger ControlID="txtRelation_No_Org" EventName="TextChanged" />
            <asp:AsyncPostBackTrigger ControlID="rdbSend" EventName="CheckedChanged" />
            <asp:AsyncPostBackTrigger ControlID="rdbReceive" EventName="CheckedChanged" />
        </Triggers>--%>
        <ContentTemplate>
            <table border="0" cellpadding="0" cellspacing="0">
                <tr>
                    <td valign="top" style="width: 686px">
                            <table cellpadding="0" cellspacing="1">
                                <tr>
                                    <td style="width: 117px">
                                        <asp:Label ID="lblO_CI_CODE" runat="server" Text="Ng&#226;n h&#224;ng gửi" meta:resourcekey="lblO_CI_CODEResource1" Width="100px"></asp:Label></td>
                                    <td align="left" style="width: 318px">
                                        <asp:TextBox ID="txtO_CI_CODE" runat="server" Width="100px" meta:resourcekey="txtO_CI_CODEResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox>
                                        <asp:Label ID="lblO_CI_Name" runat="server" meta:resourcekey="lblO_CI_NameResource1"></asp:Label></td>
                                    <td align="right" style="width: 105px">
                                        <asp:Label ID="lblSerial_No" runat="server" Text="Số điện tra so&#225;t" meta:resourcekey="lblSerial_NoResource1" Width="100px"></asp:Label>&nbsp;</td>
                                    <td align="right">
                                        &nbsp;<asp:TextBox ID="txtSerial_No" runat="server" Width="120px" meta:resourcekey="txtSerial_NoResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                </tr>
                                <tr>
                                    <td style="width: 117px">
                                        <asp:Label ID="lblR_CI_CODE" runat="server" Text="Ng&#226;n h&#224;ng nhận" meta:resourcekey="lblR_CI_CODEResource1" Width="100px"></asp:Label></td>
                                    <td align="left" style="width: 318px">
                                        <asp:TextBox ID="txtR_CI_CODE" runat="server" Width="100px" meta:resourcekey="txtR_CI_CODEResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox>&nbsp;
                                        <asp:Label ID="lblR_CI_Name" runat="server" meta:resourcekey="lblR_CI_NameResource1"></asp:Label></td>
                                    <td align="right" style="width: 105px">
                                        <asp:Label ID="lblUser_ID" runat="server" Text="Teller ID" meta:resourcekey="lblUser_IDResource1"></asp:Label>&nbsp;</td>
                                    <td align="right">
                                        <asp:TextBox ID="txtUser_ID" runat="server" Width="120px" meta:resourcekey="txtUser_IDResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                </tr>
                                <tr>
                                    <td style="height: 22px; width: 117px;">
                                        <asp:Label ID="lblSD_Time" runat="server" Text="Thời điểm tra so&#225;t" meta:resourcekey="lblSD_TimeResource1"></asp:Label></td>
                                    <td style="height: 22px; width: 318px;">
                                        <asp:TextBox ID="txtSD_Time" runat="server" Width="150px" meta:resourcekey="txtSD_TimeResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                    <td align="right" style="height: 22px; width: 105px;">
                                        <asp:Label ID="lblTrx_Date" runat="server" Text="Ng&#224;y lệnh" meta:resourcekey="lblTrx_DateResource1"></asp:Label>&nbsp;</td>
                                    <td align="right" style="height: 22px">
                                        <asp:TextBox ID="txtTrx_Date" runat="server" Width="120px" meta:resourcekey="txtTrx_DateResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                </tr>
                                <tr>
                                    <td colspan="5" align="right">
                                        <asp:Label ID="lblTrx_Status" runat="server" Text="T&#236;nh trạng giao dịch" meta:resourcekey="lblTrx_StatusResource1"></asp:Label>
                                        <asp:TextBox ID="txtTrx_Status" runat="server" Width="251px" style="color: maroon; background-color: lightskyblue" Font-Bold="True" meta:resourcekey="txtTrx_StatusResource1" CssClass="citad-txtReadonly" TabIndex="-1" BackColor="#C3DAF9" ForeColor="Red"></asp:TextBox></td>
                                </tr>                                
                            </table>
                            
                            
                            <fieldset id="fdsInterbankMarket" runat="server" visible="False">
                                <legend>
                                    <asp:Label ID="lblLNH" meta:resourcekey="lblLNHResource1" runat="server" Text="Thông tin giao dịch trên thị trường LNH"></asp:Label>
                                </legend>
                                <table cellpadding="0" cellspacing="1" >
                                    <tr>
                                        <td style="width: 118px" >
                                            <asp:Label ID="lblNgayGiaoDich" runat="server" Text="Ngày giao dịch"></asp:Label></td>
                                    
                                    <td style="width: 107px" >
                                        <asp:TextBox ID="dtpTRX_Date" runat="server" 
                                            Width="70px" MaxLength="8" ReadOnly="true" CssClass="citad-txt citad-txtReadonly"  TabIndex="-1"></asp:TextBox>

                                    </td>
                                    <td align="right" style="padding-right:3px;width: 78px">
                                        <asp:Label ID="lblLoaiGiaoDich" meta:resourcekey="lblLoaiGiaoDichResource1" runat="server" Text="Loại giao dịch"></asp:Label>
                                    </td>
                                    <td><asp:TextBox ID="txtTrxType" runat="server"  TabIndex="-1"
                                            Width="30px" MaxLength="3" ReadOnly="true" CssClass="citad-txt citad-txtReadonly"></asp:TextBox>
                                    
                                        </td>
                                  <td colspan="3" style="width:170px;"><asp:Label ID="lblTrxType" style="margin-left:3px;"  ForeColor="#0046D5" runat="server" Text="" /></td>
                                    <td align="right" style="padding-right:3px">
                                        <asp:Label ID="lblLaiSuat" meta:resourcekey="lblLaiSuatResource1" runat="server" Text="Lãi suất"></asp:Label>
                                    </td>
                                    <td><asp:TextBox ID="txtLaiSuat" runat="server" meta:resourcekey="dtpTRX_DateResource1" TabIndex="-1"
                                            Width="35px" MaxLength="5" ReadOnly="true" CssClass="citad-txt citad-txtReadonly"></asp:TextBox> 
                                            <asp:Label ID="lblNam" meta:resourcekey="lblNamResource1" runat="server" Text="Năm"/>
                                            </td>
                                </tr>
                                <tr>
                                <td><asp:Label ID="lblKyHan" meta:resourcekey="lblKyHanResource1" runat="server" Text="Kỳ hạn"></asp:Label></td>
                                <td>
                                <asp:TextBox ID="txtKyHan" runat="server"  TabIndex="-1"
                                            Width="50px" MaxLength="4" CssClass="citad-txt citad-txtReadonly" ReadOnly="true"></asp:TextBox>
                                            <asp:Label ID="lblNgay" meta:resourcekey="lblNgayResource1" runat="server" Text="Ngày"></asp:Label>
                                </td>
                                <td align="right" style="padding-right:3px"><asp:Label ID="lblLoaiTien" runat="server" Text="Loại tiền" />
                                </td>
                                <td><asp:TextBox ID="txtCurrency2" runat="server"  TabIndex="-1"
                                            Width="30px" MaxLength="3" ReadOnly="true" CssClass="citad-txt citad-txtReadonly" /></td>
                                <td><asp:Label ID="lblCurrency" runat="server" ForeColor="#0046D5" /></td>
                                <td align="right" style="padding-right:3px">
                                <asp:Label ID="lblLoaiGTCG" meta:resourcekey="lblLoaiGTCGResource1" style="margin-left:3px;" runat="server" Text="Loại GTCG" />
                                </td>
                                <td><asp:TextBox ID="txtValuablePapers" runat="server"  TabIndex="-1"
                                            Width="40px" MaxLength="4" ReadOnly="true" CssClass="citad-txt citad-txtReadonly"></asp:TextBox>
                                            </td>
                                            <td colspan="2"><asp:Label ID="lblValuablePapers" style="margin-left:3px;" ForeColor="#0046D5" runat="server" Text="" /></td>
                                </tr>
                            </table>
                            
                            </fieldset>
                            
                                        <fieldset style="width: 99%;" class="fieldset">
                                            <legend class="legend"><asp:Label ID="lblLetterContent" runat="server" Text="Nội dung tra so&#225;t" meta:resourcekey="lblLetterContentResource1"></asp:Label></legend>
                                            <table cellpadding="0" cellspacing="1">
                                                <tr>
                                                    <td style="width: 130px;">
                                                        <asp:Label ID="lblTrx_Date_Org" runat="server" Text="Ng&#224;y giao dịch" meta:resourcekey="lblTrx_Date_OrgResource1" Width="98px" TabIndex="-1"></asp:Label>
                                                        </td>
                                                    <td style="width: 127px;">
                                                        <asp:TextBox ID="txtTrx_Date_Org" runat="server" Width="80px" TabIndex="8" MaxLength="8" AutoPostBack="true" meta:resourcekey="txtTrx_Date_OrgResource1" CssClass="citad-txt" OnTextChanged="txtTrx_Date_Org_TextChanged"></asp:TextBox>
                                                                    <cc1:MaskedEditValidator ID="MEV5" runat="server" ControlExtender="M5" ControlToValidate="txtTrx_Date_Org" 
                                                                    EmptyValueMessage="Date is required" InvalidValueMessage="Date is invalid" Display="Dynamic" 
                                                                    EmptyValueBlurredText="*" InvalidValueBlurredMessage="*" ValidationGroup="MKE" ErrorMessage="M5" meta:resourcekey="MaskedEditValidator5Resource1" />
                                                        <asp:ImageButton ID="imgCalendar" runat="server" ImageUrl="~/Images/Calendar.png"
                                                            meta:resourcekey="imgCalendarResource1" />
                                                                    <cc1:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="txtTrx_Date_Org" Format="dd/MM/yyyy" Enabled="True" PopupButtonID="imgCalendar"></cc1:CalendarExtender>
                                                        </td>                                                        
                                                    <td style="width: 111px" align="right">
                                                        <asp:Label ID="lblAmount" runat="server" Text="Số tiền" meta:resourcekey="lblAmountResource1"></asp:Label>&nbsp;</td>
                                                    <td style="width: 316px">
                                                        <asp:TextBox ID="txtAmount" runat="server" Width="120px" style="text-align: right" meta:resourcekey="txtAmountResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                                </tr>
                                                <tr>
                                                    <td style="width: 130px; height: 22px;">
                                                        <asp:Label ID="grbFlow_Lag" runat="server" Text="Chiều giao dịch" meta:resourcekey="grbFlow_LagResource1" TabIndex="-1"></asp:Label></td>
                                                    <td style="width: 107px; height: 22px;">
                                                        <asp:RadioButton ID="rdbSend" runat="server" Text="Đi" GroupName="grpGiaoDich" meta:resourcekey="rdbSendResource1" OnCheckedChanged="rdbSend_CheckedChanged" Checked="True" AutoPostBack="True" TabIndex="9" />
                                                        <asp:RadioButton ID="rdbReceive" runat="server" Text="Đến" GroupName="grpGiaoDich" meta:resourcekey="rdbReceiveResource1" OnCheckedChanged="rdbReceive_CheckedChanged" AutoPostBack="True" TabIndex="10"/></td>
                                                    <td style="width: 111px; height: 22px;" align="right">
                                                        <asp:Label ID="lblRelation_No_Org" runat="server" Text="Số b&#250;t to&#225;n" meta:resourcekey="lblRelation_No_OrgResource1"></asp:Label>&nbsp;
                                                    </td>
                                                    <td align="left" style="width: 316px; height: 22px;">
                                                        <asp:TextBox ID="txtRelation_No_Org" runat="server" Width="120px" onpropertychange="Upper()" onblur="Blur(this)" AutoPostBack="True" MaxLength="40" OnTextChanged="txtRelation_No_Org_TextChanged" meta:resourcekey="txtRelation_No_OrgResource1" CssClass="citad-txt"></asp:TextBox></td>
                                                </tr>
                                                <tr>
                                                    <td style="width: 130px">
                                                        <asp:Label ID="grbTrx_Type_Org" runat="server" Text="Gi&#225; trị" meta:resourcekey="grbTrx_Type_OrgResource1" TabIndex="-1"></asp:Label></td>
                                                    <td style="width: 107px">
                                                        <asp:RadioButton ID="rdbHV" runat="server" Text="Cao" GroupName="grpGiaTri" meta:resourcekey="rdbHVResource1" TabIndex="11" />
                                                        <asp:RadioButton ID="rdbLV" runat="server" Text="Thấp" GroupName="grpGiaTri" meta:resourcekey="rdbLVResource1" Checked="True" TabIndex="12" /></td>
                                                    <td style="width: 111px" align="right">
                                                        <asp:Label ID="lblSerial_No_Org" runat="server" Text="Số giao dịch" meta:resourcekey="lblSerial_No_OrgResource1"></asp:Label>&nbsp;
                                                    </td>
                                                    <td align="left" style="width: 316px">
                                                        <asp:TextBox ID="txtSerial_No_Org" runat="server" Width="120px" meta:resourcekey="txtSerial_No_OrgResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                                </tr>
                                                <tr>
                                                    <td style="width: 130px">
                                                        <asp:Label ID="lblO_InDirect_Org" runat="server" Text="NH c&#243; TK gửi" meta:resourcekey="lblO_InDirect_OrgResource1"></asp:Label></td>
                                                    <td style="width: 107px">
                                                        <asp:TextBox ID="txtO_InDirect_CODE_Org" runat="server" Width="100px" meta:resourcekey="txtO_InDirect_CODE_OrgResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                                    <td align="left" colspan="2">
                                                        <asp:Label ID="lblO_InDirect_CODE_Org_Name" runat="server" meta:resourcekey="lblO_InDirect_CODE_Org_NameResource1"></asp:Label></td>
                                                </tr>
                                                <tr>
                                                    <td style="width: 130px">
                                                        <asp:Label ID="lblR_InDirect_Org" runat="server" Text="NH c&#243; TK nhận" meta:resourcekey="lblR_InDirect_OrgResource1"></asp:Label></td>
                                                    <td style="width: 107px">
                                                        <asp:TextBox ID="txtR_InDirect_CODE_Org" runat="server" Width="100px" meta:resourcekey="txtR_InDirect_CODE_OrgResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                                    <td align="left" colspan="2">
                                                        <asp:Label ID="lblR_InDirect_CODE_Org_Name" runat="server" meta:resourcekey="lblR_InDirect_CODE_Org_NameResource1"></asp:Label></td>
                                                </tr>
                                                <tr>
                                                    <td valign="top" style="width: 130px;">
                                                        <asp:Label ID="lblLetter_Content" runat="server" Text="Nội dung y&#234;u cầu tra so&#225;t"  meta:resourcekey="lblLetter_ContentResource1"></asp:Label></td>
                                                    <td colspan="3" valign="top">
                                                        <asp:TextBox ID="txtLetter_Content" runat="server" Height="75px" TextMode="MultiLine" Width="550px" TabIndex="1" onkeyup="checkMaxLength(this, 210);" meta:resourcekey="txtLetter_ContentResource1" CssClass="citad-txt" MaxLength="210"></asp:TextBox></td>
                                                </tr>
                                                <tr>
                                                    <td valign="middle" style="width: 130px">
                                                        <asp:Label ID="lblTrx_DateX" runat="server" Text="Thời điểm xử l&#253; tại ng&#226;n h&#224;ng nhận" meta:resourcekey="lblTrx_DateXResource1"></asp:Label></td>
                                                    <td colspan="3" valign="middle">
                                                        <asp:TextBox ID="txtTrx_DateX" runat="server" meta:resourcekey="txtTrx_DateXResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                                </tr>
                                                <tr>
                                                    <td valign="top" style="width: 130px">
                                                        <asp:Label ID="lblLetter_ContentX" runat="server" Text="Nội dung ng&#226;n h&#224;ng nhận trả lời" meta:resourcekey="lblLetter_ContentXResource1"></asp:Label></td>
                                                    <td colspan="3" valign="top">
                                                        <asp:TextBox ID="txtLetter_ContentX" runat="server" Height="75px" TextMode="MultiLine" Width="550px" meta:resourcekey="txtLetter_ContentXResource1" CssClass="citad-txtReadonly" TabIndex="-1"></asp:TextBox></td>
                                                </tr>
                                            </table>
                                                        <cc1:MaskedEditExtender ID="M5" runat="server" TargetControlID="txtTrx_Date_Org" Mask="99/99/9999" MaskType="Date" ErrorTooltipEnabled="True" CultureAMPMPlaceholder="" CultureCurrencySymbolPlaceholder="" CultureDateFormat="" CultureDatePlaceholder="" CultureDecimalPlaceholder="" CultureThousandsPlaceholder="" CultureTimePlaceholder="" Enabled="True" />
                                        </fieldset>
                    </td>
                    <td valign="top" align="center" style="width: 81px">
                        <table width="100%" cellpadding="0" cellspacing="1">
                            <tr>
                                <td align="center">
                            <asp:Button ID="btnNew" runat="server" Text="Thêm mới" OnClick="btnNew_Click" meta:resourcekey="btnNewResource1" CssClass="citad-btn" TabIndex="8" /></td>
                            </tr>
                            <tr>
                                <td align="center" style="height: 28px">
                                <asp:Button ID="btnSave" runat="server" Text="Ghi" OnClick="btnSave_Click" meta:resourcekey="btnSaveResource1" CssClass="citad-btn" TabIndex="2" /></td>
                            </tr>
                            <tr>
                                <td align="center">
                                <asp:Button ID="btnDelete" runat="server" Text="X&#243;a"  OnClick="btnDelete_Click" meta:resourcekey="btnDeleteResource1" CssClass="citad-btn" TabIndex="3" /></td>
                            </tr>                            
                            <tr>
                                <td align="center">
                                <asp:Button ID="btnPrevious" runat="server" Text="Trước" OnClick="btnPrevious_Click" meta:resourcekey="btnPreviousResource1" CssClass="citad-btn" TabIndex="4" /></td>
                             </tr>
                            <tr>
                                <td align="center">
                                <asp:Button ID="btnNext" runat="server" Text="Tiếp" OnClick="btnNext_Click" meta:resourcekey="btnNextResource1" CssClass="citad-btn" TabIndex="5" /></td>
                            </tr>
                            <tr>
                                <td align="center">
                                <asp:Button ID="btnPrint" runat="server" Text="In" OnClick="btnPrint_Click" meta:resourcekey="btnPrintResource1" CssClass="citad-btn" TabIndex="6" /></td>
                            </tr>
                            <tr>
                                <td align="center">
                                <asp:Button ID="btnClose" runat="server" Text="Đóng" OnClick="btnClose_Click" meta:resourcekey="btnCancelResource1" CssClass="citad-btn" TabIndex="7"/></td>
                            </tr>
                            <tr>
                                <td style="vertical-align:middle; text-align:center;" align="center">
                                                <asp:Label ID="lblTongSo" runat="server" Text="Tổng số:" meta:resourcekey="lblTongSoResource1"></asp:Label><br />
                                                <asp:Label ID="lblTotal" runat="server" Text="0/0" meta:resourcekey="lblTotalResource1"></asp:Label></td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
            <asp:HiddenField ID="hidFocusControlName" runat="server" />
            <asp:HiddenField ID="hidMsg_Key" runat="server" />     
            <asp:HiddenField ID="hidID" runat="server" />
            <asp:HiddenField ID="hidMAC" runat="server" />       
            <%--<asp:Panel ID="Panel1" runat="server" Style="display: none" CssClass="modalPopup" Width="400px" meta:resourcekey="Panel1Resource1">
                <p style="font-size:14px;"><asp:Label ID="lblTieuDeThongBao" runat="server" Text="Th&#244;ng b&#225;o" meta:resourcekey="lblTieuDeThongBaoResource1"></asp:Label></p>
                <p><asp:Label ID="lblMessage" runat="server" Text="Label" meta:resourcekey="lblMessageResource1"></asp:Label></p>
                <p style="text-align: center;">
                    <asp:Button ID="OkButton" runat="server" Text="OK" CssClass="citad-btn" Width="70px" meta:resourcekey="OkButtonResource1" />                        
                </p>
            </asp:Panel> --%>   
            <uc1:MessageBox id="MessageBox1" runat="server">
            </uc1:MessageBox>
            <br />
           <asp:HiddenField ID="hidModalPopup" runat="server" />
           
           <%--<cc1:ModalPopupExtender ID="ModalPopupExtender1" runat="server" 
                TargetControlID="hidModalPopup"
                PopupControlID="Panel1" 
                BackgroundCssClass="modalBackground" 
                OkControlID="OkButton" DynamicServicePath="" Enabled="True"
                />--%>
                
            <%--<cc1:ConfirmButtonExtender ID="ConfirmButtonExtender1" runat="server" TargetControlID="btnDelete" ConfirmText="Bạn c&#243; muốn x&#243;a bản ghi n&#224;y kh&#244;ng?" Enabled="True">
            </cc1:ConfirmButtonExtender>--%>
        </ContentTemplate>
    </asp:UpdatePanel>
</div>
</asp:Content>