//Last updated on: 10-June-2010, 10:46 AM

function OpenMultiAddress(txtcustomerid, AccountMode) {
   
       var customerid = document.getElementById(txtcustomerid).value;
       window.open('../CustomerMultipleAdress/frmCustomer_Multipal_Address.aspx?CustId=' + customerid + '&AccountMode=' + AccountMode + '', 'SecondaryAddress', 'scrollbars=no,resizable=yes,menubar=0,status=1,width=500,height=550');
}
function OpenProductKYC(txtcustomerid,cbocuststatus,hdnRFQ,lblError,cboPC, sAccMode, sMode)
{

    var curProductCategory = '';  //document.getElementById(cboPC).options[document.getElementById(cboPC).selectedIndex].text; 
       var customerid = document.getElementById(txtcustomerid).value;
       var ScreenMode ="EDIT";  
       if (customerid == "" )
       {
            customerid = document.getElementById(hdnRFQ).value;
            ScreenMode ="NEW";  
            if (customerid == "" )
            {
                document.getElementById(lblError).innerTEXT="Please enter account holder deatails first."
                return 0;
            }
       }
       var SignAuth = "";
       var mode = "ACCOUNT";
      
       SignAuth = document.getElementById(cbocuststatus).value;
       if ((SignAuth == "JOINT") || (SignAuth == "Joint") || (SignAuth == "joint")) {
           window.open('../Product_KYC_Master/FinIQ_Customer_Product_KYC.aspx?Customer_ID=' + customerid + '&SignAuth=' + SignAuth + '&ScreenMode=' + ScreenMode + '&Mode=' + mode + '&ProductCategory=' + curProductCategory + '&AccountMode=' + sAccMode + '', '_blank', 'height=650, width=780,status= no, resizable=yes, scrollbars=yes, toolbar=no,location=no,menubar=no,left=20');
       }
       else {
           window.open('../Product_KYC_Master/FinIQ_Customer_Product_KYC.aspx?Customer_ID=' + customerid + '&SignAuth=' + SignAuth + '&ScreenMode=' + ScreenMode + '&Mode=' + mode + '&ProductCategory=' + curProductCategory + '&AccountMode=' + sAccMode + '', '_blank', 'height=650, width=780,status= no, resizable=yes, scrollbars=yes, toolbar=no,location=no,menubar=no,left=20');
       }
}
//function OpenSSI(txtcustomerid, OrderEntryMode, sMode)
//{
//       var customerid = document.getElementById(txtcustomerid).value;
//       window.open('../SSI/SSI.aspx?customerid=' + customerid + '&AccountMode=' + OrderEntryMode + '' + '&Mode=' + sMode + '', '_blank', 'scrollbars=yes,resizable=yes,menubar=0,status=1,width=800,height=300');
//}

function OpenDormancy(txtcustomerid)
{
       var customerid = document.getElementById(txtcustomerid).value;
       window.open('../Customer_Dormancy/Customer_Dormancy.aspx?Customer_Id=' + customerid + '','Customer_Dormancy', 'scrollbars=no,resizable=no,menubar=0,status=1,width=700,height=200');

}
function OpenCustomerProductMap(Pan, Name, Mode, AccountTypeId, sAccMode, sMode) {
    var sAccountType = document.getElementById(AccountTypeId).options[document.getElementById(AccountTypeId).selectedIndex].text;
    var customerid = document.getElementById(Pan).value;
    var customername = document.getElementById(Name).value;


    window.open('../Customer_Product_Map/Customer_Product_Mapping.aspx?CustomerPan=' + customerid + '&CustomerName=' + customername + '&Mode=' + Mode + '&AccountType=' + sAccountType + '&AccountMode=' + sAccMode + '' + '&AccSetupMode=' + sMode + '', 'Customer_Product_Map', 'scrollbars=yes,resizable=yes,menubar=0,status=1,width=600,height=500');
}
