src/org/openbravo/erpCommon/ad_actionButton/CreateFrom_CRemittance.html
changeset 1605 8a0fe0193bef
parent 1572 e29d45957ddb
child 1709 d1079c01be35
equal deleted inserted replaced
1604:a1c518e6ed93 1605:8a0fe0193bef
    19 <html>
    19 <html>
    20 <head>
    20 <head>
    21 <title>Create from Remittance</title>
    21 <title>Create from Remittance</title>
    22   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></meta>
    22   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></meta>
    23   <link rel="stylesheet" type="text/css" href="../../../../../web/skins/Default/Popup/Popup.css" id="paramCSS"></link>
    23   <link rel="stylesheet" type="text/css" href="../../../../../web/skins/Default/Popup/Popup.css" id="paramCSS"></link>
    24   <script language="JavaScript" type="text/javascript" id="paramLanguage">LNG_POR_DEFECTO = "en_US";</script>
    24   <script language="JavaScript" type="text/javascript" id="paramLanguage">defaultLang = "en_US";</script>
    25   <script language="JavaScript" type="text/javascript" id="paramDirection">var baseDirection = "../../../../../web/";</script>
    25   <script language="JavaScript" type="text/javascript" id="paramDirectory">var baseDirectory = "../../../../../web/";</script>
    26   <script language="JavaScript" src="../../../../../web/js/shortcuts.js" type="text/javascript"></script>
    26   <script language="JavaScript" src="../../../../../web/js/shortcuts.js" type="text/javascript"></script>
    27   <script language="JavaScript" src="../../../../../web/js/utils.js" type="text/javascript"></script>
    27   <script language="JavaScript" src="../../../../../web/js/utils.js" type="text/javascript"></script>
    28   <script language="JavaScript" src="../../../../../web/js/windowKeyboard.js" type="text/javascript"></script>
    28   <script language="JavaScript" src="../../../../../web/js/windowKeyboard.js" type="text/javascript"></script>
    29   <script language="JavaScript" src="../../../../../web/js/searchs.js" type="text/javascript"></script>
    29   <script language="JavaScript" src="../../../../../web/js/searchs.js" type="text/javascript"></script>
    30   <script language="JavaScript" src="../../../../../web/js/ajax.js" type="text/javascript"></script>
    30   <script language="JavaScript" src="../../../../../web/js/ajax.js" type="text/javascript"></script>
    46       top.close();
    46       top.close();
    47       return true;
    47       return true;
    48     }
    48     }
    49 
    49 
    50     function submitThisPage(strCommand) {
    50     function submitThisPage(strCommand) {
    51       if (depurar(strCommand)) {
    51       if (validate(strCommand)) {
    52         submitCommandForm(strCommand, false, null, null, '_top');
    52         submitCommandForm(strCommand, false, null, null, '_top');
    53         return true;
    53         return true;
    54       }
    54       }
    55       return true;
    55       return true;
    56     }
    56     }
    57   </script>
    57   </script>
    58   <script language="JavaScript" type="text/javascript">
    58   <script language="JavaScript" type="text/javascript">
    59     function enableLocalShortcuts() {
    59     function enableLocalShortcuts() {
    60     keyArray[keyArray.length] = new keyArrayItem("ENTER", "openSearch(null, null, '../info/BusinessPartner.html', 'SELECTOR_BUSINESS', false, 'frmMain', 'inpcBpartnerId', 'inpcBpartnerId_DES', document.frmMain.inpcBpartnerId_DES.value, 'Command', 'KEY');", "inpcBpartnerId_DES", "null");
    60     keyArray[keyArray.length] = new keyArrayItem("ENTER", "openSearch(null, null, '../info/BusinessPartner.html', 'SELECTOR_BUSINESS', false, 'frmMain', 'inpcBpartnerId', 'inpcBpartnerId_DES', document.frmMain.inpcBpartnerId_DES.value, 'Command', 'KEY');", "inpcBpartnerId_DES", "null");
    61     }
    61     }
    62     function depurar(action) {
    62     function validate(action) {
    63       var frm=document.frmMain;
    63       var frm=document.frmMain;
    64       if (action=="FIND_SETTLEMENT") {
    64       if (action=="FIND_SETTLEMENT") {
    65         if (frm.inpplanneddateFrom.value!=null && frm.inpplanneddateFrom.value!="" && !isValidDate(frm.inpplanneddateFrom.value, frm.inpplanneddateFrom.displayFormat)) {
    65         if (frm.inpplanneddateFrom.value!=null && frm.inpplanneddateFrom.value!="" && !isValidDate(frm.inpplanneddateFrom.value, frm.inpplanneddateFrom.displayFormat)) {
    66           setWindowElementFocus(frm.inpplanneddateFrom);
    66           setWindowElementFocus(frm.inpplanneddateFrom);
    67           frm.inpplanneddateFrom.select();
    67           frm.inpplanneddateFrom.select();
    68           mensaje(5);
    68           showJSMessage(5);
    69           setTimeout('resizeAreaCreateFrom()',100);
    69           setTimeout('resizeAreaCreateFrom()',100);
    70           return false;
    70           return false;
    71         } else if (frm.inpplanneddateTo.value!=null && frm.inpplanneddateTo.value!="" && !isValidDate(frm.inpplanneddateTo.value, frm.inpplanneddateTo.displayFormat)) {
    71         } else if (frm.inpplanneddateTo.value!=null && frm.inpplanneddateTo.value!="" && !isValidDate(frm.inpplanneddateTo.value, frm.inpplanneddateTo.displayFormat)) {
    72           setWindowElementFocus(frm.inpplanneddateTo);
    72           setWindowElementFocus(frm.inpplanneddateTo);
    73           frm.inpplanneddateTo.select();
    73           frm.inpplanneddateTo.select();
    74           mensaje(5);
    74           showJSMessage(5);
    75           setTimeout('resizeAreaCreateFrom()',100);
    75           setTimeout('resizeAreaCreateFrom()',100);
    76           return false;
    76           return false;
    77         } else if (frm.inpamountFrom.value!=null && frm.inpamountFrom.value!="" && !campoNumerico(frm.inpamountFrom, true, true)) {
    77         } else if (frm.inpamountFrom.value!=null && frm.inpamountFrom.value!="" && !validateNumberField(frm.inpamountFrom, true, true)) {
    78           setWindowElementFocus(frm.inpamountFrom);
    78           setWindowElementFocus(frm.inpamountFrom);
    79           return false;
    79           return false;
    80         } else if (frm.inpamountTo.value!=null && frm.inpamountTo.value!="" && !campoNumerico(frm.inpamountTo, true, true)) {
    80         } else if (frm.inpamountTo.value!=null && frm.inpamountTo.value!="" && !validateNumberField(frm.inpamountTo, true, true)) {
    81           setWindowElementFocus(frm.inpamountTo);
    81           setWindowElementFocus(frm.inpamountTo);
    82           return false;
    82           return false;
    83         } else if (frm.inpamount.value!=null && frm.inpamount.value!="" && !campoNumerico(frm.inpamount, true, true)) {
    83         } else if (frm.inpamount.value!=null && frm.inpamount.value!="" && !validateNumberField(frm.inpamount, true, true)) {
    84           setWindowElementFocus(frm.inpamount);
    84           setWindowElementFocus(frm.inpamount);
    85           return false;
    85           return false;
    86         }
    86         }
    87       } else if (radioValue(frm.inpcDebtPaymentId)==null) {
    87       } else if (radioValue(frm.inpcDebtPaymentId)==null) {
    88         mensaje(1);
    88         showJSMessage(1);
    89         setTimeout('resizeAreaCreateFrom()',100);
    89         setTimeout('resizeAreaCreateFrom()',100);
    90         return false;
    90         return false;
    91       }
    91       }
    92         return true;
    92         return true;
    93     }
    93     }
    94 
    94 
    95     function actualizarDatos(clave, marcar) {
    95     function updateData(key, mark) {
    96       if (marcar==null) marcar=false;
    96       if (mark==null) mark=false;
    97       var frm = document.frmMain;
    97       var frm = document.frmMain;
    98       //frm.elements["inpwriteoff" + clave].disabled=!marcar;
    98       //frm.elements["inpwriteoff" + key].disabled=!mark;
    99       //frm.elements["inpispaid" + clave].disabled=!marcar;
    99       //frm.elements["inpispaid" + key].disabled=!mark;
   100       return true;
   100       return true;
   101     }
   101     }
   102 
   102 
   103     function cargarDatos(marcar) {
   103     function loadData(mark) {
   104       var radio=document.frmMain.inpcDebtPaymentId;
   104       var radio=document.frmMain.inpcDebtPaymentId;
   105       if (marcar==null) marcar=false;
   105       if (mark==null) mark=false;
   106         var frm = document.frmMain;
   106         var frm = document.frmMain;
   107       if (!radio) return false;
   107       if (!radio) return false;
   108       else if (!radio.length) {
   108       else if (!radio.length) {
   109           radio.checked = marcar;
   109           radio.checked = mark;
   110       } else if (radio.length > 20) {
   110       } else if (radio.length > 20) {
   111         return submitCommandForm('FIND_SETTLEMENT', true);
   111         return submitCommandForm('FIND_SETTLEMENT', true);
   112       } else {
   112       } else {
   113           var total = radio.length;
   113           var total = radio.length;
   114         for (var i=0;i<total;i++) {
   114         for (var i=0;i<total;i++) {
   115               radio[i].checked=marcar;
   115               radio[i].checked=mark;
   116         }
   116         }
   117       }
   117       }
   118       return true;
   118       return true;
   119     }
   119     }
   120 
   120 
   167       <td>
   167       <td>
   168         <table cellspacing="0" cellpadding="0" class="Popup_ContentPane_NavBar">
   168         <table cellspacing="0" cellpadding="0" class="Popup_ContentPane_NavBar">
   169           <tr class="Popup_NavBar_bg"><td></td>
   169           <tr class="Popup_NavBar_bg"><td></td>
   170             <td class="Popup_NavBar_separator_cell"></td>
   170             <td class="Popup_NavBar_separator_cell"></td>
   171             <td class="Popup_NavBar_bg_logo_left"></td>
   171             <td class="Popup_NavBar_bg_logo_left"></td>
   172             <td class="Popup_NavBar_bg_logo" width="1" onclick="abrirNuevoBrowser('http://www.openbravo.com', 'Openbravo');return false;"><img src="../../../../../web/images/blank.gif" alt="Openbravo" title="Openbravo" border="0" id="openbravoLogo" class="Popup_NavBar_logo" /></td>
   172             <td class="Popup_NavBar_bg_logo" width="1" onclick="openNewBrowser('http://www.openbravo.com', 'Openbravo');return false;"><img src="../../../../../web/images/blank.gif" alt="Openbravo" title="Openbravo" border="0" id="openbravoLogo" class="Popup_NavBar_logo" /></td>
   173             <td class="Popup_NavBar_bg_logo_right"></td>
   173             <td class="Popup_NavBar_bg_logo_right"></td>
   174             <td class="Popup_NavBar_Popup_title_cell"><span>Create from Remittance</span></td>
   174             <td class="Popup_NavBar_Popup_title_cell"><span>Create from Remittance</span></td>
   175             <td class="Popup_NavBar_separator_cell"></td>
   175             <td class="Popup_NavBar_separator_cell"></td>
   176           </tr>
   176           </tr>
   177         </table>
   177         </table>
   510       <td>
   510       <td>
   511         <div class="Popup_ContentPane_Client" style="overflow: auto; display: none;" id="client_middle">
   511         <div class="Popup_ContentPane_Client" style="overflow: auto; display: none;" id="client_middle">
   512           <table cellspacing="0" cellpadding="0" width="100%" class="DataGrid_Header_Table DataGrid_Body_Table" style="table-layout: auto;">
   512           <table cellspacing="0" cellpadding="0" width="100%" class="DataGrid_Header_Table DataGrid_Body_Table" style="table-layout: auto;">
   513 
   513 
   514             <tr class="Popup_Client_Selector_DataGrid_HeaderRow">
   514             <tr class="Popup_Client_Selector_DataGrid_HeaderRow">
   515               <td class="DataGrid_Body_LineNoCell" width="25"><span class="Checkbox_container_NOT_Focused"><input type="checkbox" name="inpTodos" onclick="cargarDatos(this);return true;" value="Y" id="fieldMarcarTodos"></input></span></td>
   515               <td class="DataGrid_Body_LineNoCell" width="25"><span class="Checkbox_container_NOT_Focused"><input type="checkbox" name="inpTodos" onclick="loadData(this);return true;" value="Y" id="fieldMarcarTodos"></input></span></td>
   516               <th class="DataGrid_Header_Cell">Business Partner</th>
   516               <th class="DataGrid_Header_Cell">Business Partner</th>
   517               <th class="DataGrid_Header_Cell">Organization</th>
   517               <th class="DataGrid_Header_Cell">Organization</th>
   518               <th class="DataGrid_Header_Cell">Invoice</th>
   518               <th class="DataGrid_Header_Cell">Invoice</th>
   519               <th class="DataGrid_Header_Cell">Payment rule</th>
   519               <th class="DataGrid_Header_Cell">Payment rule</th>
   520               <th class="DataGrid_Header_Cell">Planned date</th>
   520               <th class="DataGrid_Header_Cell">Planned date</th>
   524             </tr>
   524             </tr>
   525 
   525 
   526             <div id="sectionDetail">
   526             <div id="sectionDetail">
   527               <tr class="DataGrid_Body_Row DataGrid_Body_Row_yy" id="inpRecord10000003">
   527               <tr class="DataGrid_Body_Row DataGrid_Body_Row_yy" id="inpRecord10000003">
   528                 <td class="DataGrid_Body_LineNoCell">
   528                 <td class="DataGrid_Body_LineNoCell">
   529                 <span class="Checkbox_container_NOT_Focused"><input type="checkbox" name="inpcDebtPaymentId" value="" id="fieldCDebtPaymentId" onclick="actualizarDatos(this.value, this.checked);return true;"></input></span></td>
   529                 <span class="Checkbox_container_NOT_Focused"><input type="checkbox" name="inpcDebtPaymentId" value="" id="fieldCDebtPaymentId" onclick="updateData(this.value, this.checked);return true;"></input></span></td>
   530                 <td class="DataGrid_Body_Cell" id="fieldBpartner">xxQuantity</td>
   530                 <td class="DataGrid_Body_Cell" id="fieldBpartner">xxQuantity</td>
   531                 <td class="DataGrid_Body_Cell" id="fieldOrg">xx</td>
   531                 <td class="DataGrid_Body_Cell" id="fieldOrg">xx</td>
   532                 <td class="DataGrid_Body_Cell" id="fieldInvoice">xxUOM</td>
   532                 <td class="DataGrid_Body_Cell" id="fieldInvoice">xxUOM</td>
   533                 <td class="DataGrid_Body_Cell" id="fieldPaymentRuleDes">xxProduct</td>
   533                 <td class="DataGrid_Body_Cell" id="fieldPaymentRuleDes">xxProduct</td>
   534                 <td class="DataGrid_Body_Cell" id="fieldPlannedDate">xxP</td>
   534                 <td class="DataGrid_Body_Cell" id="fieldPlannedDate">xxP</td>