src/org/openbravo/erpCommon/info/BusinessPartnerMultiple.html
author Gorka Gil <gorka.gil@openbravo.com>
Mon, 26 May 2008 11:32:48 +0000
changeset 1028 8b85368639cc
parent 712 aa0c40278c5a
child 1044 8691bbc94032
permissions -rw-r--r--
Manual windows of bug 0000436 Blank required fields don't take the focus
ivan@712
     1
<!--
ivan@712
     2
 *************************************************************************
ivan@712
     3
 * The contents of this file are subject to the Openbravo  Public  License
ivan@712
     4
 * Version  1.0  (the  "License"),  being   the  Mozilla   Public  License
ivan@712
     5
 * Version 1.1  with a permitted attribution clause; you may not  use this
ivan@712
     6
 * file except in compliance with the License. You  may  obtain  a copy of
ivan@712
     7
 * the License at http://www.openbravo.com/legal/license.html 
ivan@712
     8
 * Software distributed under the License  is  distributed  on  an "AS IS"
ivan@712
     9
 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
ivan@712
    10
 * License for the specific  language  governing  rights  and  limitations
ivan@712
    11
 * under the License. 
ivan@712
    12
 * The Original Code is Openbravo ERP. 
ivan@712
    13
 * The Initial Developer of the Original Code is Openbravo SL 
ivan@712
    14
 * All portions are Copyright (C) 2001-2008 Openbravo SL 
ivan@712
    15
 * All Rights Reserved. 
ivan@712
    16
 * Contributor(s):  ______________________________________.
ivan@712
    17
 ************************************************************************
ivan@712
    18
-->
ivan@712
    19
<html>
ivan@712
    20
<head>
ivan@712
    21
<title>Business Partner selector</title>
ivan@712
    22
<link rel="stylesheet" type="text/css" href="../../../../../web/skins/Default/Popup/Popup.css" id="paramCSS"></link>
ivan@712
    23
<script language="JavaScript" src="../../../../../web/js/ajax.js" type="text/javascript"></script>
ivan@712
    24
<script language="JavaScript" src="../../../../../web/js/shortcuts.js" type="text/javascript"></script>
ivan@712
    25
<script language="JavaScript" src="../../../../../web/js/utils.js" type="text/javascript"></script>
ivan@712
    26
<script language="JavaScript" src="../../../../../web/js/windowKeyboard.js" type="text/javascript"></script>
ivan@712
    27
<script language="JavaScript" src="../../../../../web/js/appStatus.js" type="text/javascript"></script>
ivan@712
    28
<script language="JavaScript" src="../../../../../web/js/dojoConfig.js" type="text/javascript"></script>
ivan@712
    29
<script language="JavaScript" src="../../../../../web/js/dojo/dojo.js" type="text/javascript"></script>
ivan@712
    30
<script language="JavaScript" src="../../../../../web/js/openbravo/core.js" type="text/javascript"></script>
ivan@712
    31
<script language="JavaScript" src="../../../../../web/js/openbravo/widget/DataGrid.js" type="text/javascript"></script>
ivan@712
    32
<script language="JavaScript" src="../../../../../web/js/searchs.js" type="text/javascript"></script>
ivan@712
    33
<script type="text/javascript">
ivan@712
    34
        dojo.hostenv.writeIncludes(); //makes debugging in Venkman possible
ivan@712
    35
</script>
ivan@712
    36
<link rel="SHORTCUT ICON" href="../../../../../web/images/favicon.ico"></link>
ivan@712
    37
<script language="JavaScript" type="text/javascript" id="paramDirection">var baseDirection = "http://yourSite/web/";</script>
ivan@712
    38
<script language="JavaScript" type="text/javascript" id="paramLanguage">LNG_POR_DEFECTO = "en_US";</script>
ivan@712
    39
<script language="JavaScript" type="text/javascript">
ivan@712
    40
function depurar() {	
ivan@712
    41
	var frm = document.forms[0];
ivan@712
    42
	if ((frm.inpKey.value==null || frm.inpKey.value=="") && (frm.inpName.value==null || frm.inpName.value=="") && (frm.inpContact.value==null || frm.inpContact.value=="") && (frm.inpZIP.value==null || frm.inpZIP.value=="") && (frm.inpPhone.value==null || frm.inpPhone.value=="") && !frm.inpClients.checked) {
gorka@1028
    43
		setWindowElementFocus(frm.inpKey);
ivan@712
    44
		mensaje(7);
ivan@712
    45
		return false;
ivan@712
    46
	}	
ivan@712
    47
	return true;
ivan@712
    48
}
ivan@712
    49
</script>
ivan@712
    50
<script language="JavaScript" type="text/javascript">
ivan@712
    51
	function onLoadDo(){
ivan@712
    52
    this.windowTables = new Array(
ivan@712
    53
      new windowTableId('client_top', null, 'buttonSearch', null),
ivan@712
    54
      new windowTableId('client_middle', null, 'buttonOK', null),
ivan@712
    55
      new windowTableId('client_bottom', null, 'buttonOK', null)
ivan@712
    56
    );
ivan@712
    57
    setWindowTableParentElement();
ivan@712
    58
    enableShortcuts('popup');
ivan@712
    59
ivan@712
    60
    try {
ivan@712
    61
      onloadFunctions();
ivan@712
    62
    } catch (e) {}
ivan@712
    63
ivan@712
    64
    setWindowElementFocus('firstElement');
ivan@712
    65
    resizeAreaInfo();
ivan@712
    66
  }
ivan@712
    67
ivan@712
    68
  function onResizeDo(){
ivan@712
    69
    resizeAreaInfo(true);
ivan@712
    70
  }
ivan@712
    71
  
ivan@712
    72
  function depurarSelector(action) {
ivan@712
    73
  	var pos; var keys;  var clave; var texto; var parameter; var data;
ivan@712
    74
  	if(action == "SAVE") {
ivan@712
    75
  		data = new Array();
ivan@712
    76
  		rows = dojo.widget.byId('grid').getSelectedRows();
ivan@712
    77
  		for(var i=0; i < rows.length; i++) {
ivan@712
    78
  			var rowkey = rows[i].split("#");
ivan@712
    79
  			var rval = new Array(rowkey[0], rowkey[1]);
ivan@712
    80
  			data.push(rval);
ivan@712
    81
  		}
ivan@712
    82
    }
ivan@712
    83
  	parent.opener.closeMultiSearch(action, data);
ivan@712
    84
  }
ivan@712
    85
</script>
ivan@712
    86
<script language="JavaScript" type="text/javascript" id="selectedColumn">  
ivan@712
    87
  dojo.require("openbravo.widget.DataGrid");
ivan@712
    88
  var selectedRow = 0;
ivan@712
    89
  var orderByPositions = new Array("1");
ivan@712
    90
  var orderByDirections = new Array("ASC");
ivan@712
    91
</script>
ivan@712
    92
</head>
ivan@712
    93
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="onLoadDo();" onresize="onResizeDo();">
ivan@712
    94
<form name="frmSelector" method="POST" action="BusinessPartnerMultiple.html">
ivan@712
    95
  <input type="hidden" name="Command" />
ivan@712
    96
  <input type="hidden" name="IsPopUpCall" value="1" />
ivan@712
    97
  <input type="hidden" name="inpAD_Org_ID" value="xx" id="fieldOrgs" />
ivan@712
    98
  <div class="Popup_ContentPane_CircleLogo">
ivan@712
    99
    <div class="Popup_WindowLogo">
ivan@712
   100
      <img class="Popup_WindowLogo_Icon Popup_WindowLogo_Icon_businessPartner" src="../../../../../web/images/blank.gif" border=0/></img>
ivan@712
   101
    </div>
ivan@712
   102
  </div>
ivan@712
   103
  <table cellspacing="0" cellpadding="0" width="100%" id="table_header">
ivan@712
   104
    <tr>
ivan@712
   105
      <td>
ivan@712
   106
        <table cellspacing="0" cellpadding="0" class="Popup_ContentPane_NavBar">
ivan@712
   107
          <tr class="Popup_NavBar_bg"><td></td>
ivan@712
   108
            <td class="Popup_NavBar_separator_cell"></td>
ivan@712
   109
            <td class="Popup_NavBar_bg_logo_left"></td>
ivan@712
   110
            <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>
ivan@712
   111
            <td class="Popup_NavBar_bg_logo_right"></td>
ivan@712
   112
            <td class="Popup_NavBar_Popup_title_cell"><span>Business Partner selector</span></td>
ivan@712
   113
            <td class="Popup_NavBar_separator_cell"></td>
ivan@712
   114
          </tr>
ivan@712
   115
        </table>
ivan@712
   116
      </td>
ivan@712
   117
    </tr>
ivan@712
   118
ivan@712
   119
    <tr>
ivan@712
   120
      <td>
ivan@712
   121
        <table cellspacing="0" cellpadding="0" class="Popup_ContentPane_SeparatorBar">
ivan@712
   122
          <tr>
ivan@712
   123
            <td class="Popup_SeparatorBar_bg"></td>
ivan@712
   124
          </tr>
ivan@712
   125
        </table>
ivan@712
   126
      </td>
ivan@712
   127
    </tr>
ivan@712
   128
ivan@712
   129
  </table>
ivan@712
   130
ivan@712
   131
  <table cellspacing="0" cellpadding="0" width="100%">
ivan@712
   132
ivan@712
   133
    <tr>
ivan@712
   134
      <td>
ivan@712
   135
        <div class="Popup_ContentPane_Client" style="overflow: auto; height:185px;" id="client_top">
ivan@712
   136
          <table cellspacing="0" cellpadding="0" class="Popup_Client_TableSelector">
ivan@712
   137
ivan@712
   138
            <tr>
ivan@712
   139
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   140
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   141
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   142
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   143
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   144
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   145
            </tr>
ivan@712
   146
ivan@712
   147
            <tr>
ivan@712
   148
              <td colspan="6">
ivan@712
   149
                <table class="FieldGroup" cellspacing="0" cellpadding="0" border="0">
ivan@712
   150
                  <tr class="FieldGroup_TopMargin"></tr>
ivan@712
   151
                  <tr>
ivan@712
   152
                    <td class="FieldGroupTitle_Left"><img class="FieldGroupTitle_Left_bg" border="0" src="../../../../../web/images/blank.gif"></img></td>
ivan@712
   153
                    <td class="FieldGroupTitle">Primary Filters</td>
ivan@712
   154
                    <td class="FieldGroupTitle_Right"><img class="FieldGroupTitle_Right_bg" border="0" src="../../../../../web/images/blank.gif"></img></td>
ivan@712
   155
                    <td class="FieldGroupContent"></td>
ivan@712
   156
ivan@712
   157
                  </tr>
ivan@712
   158
                  <tr class="FieldGroup_BottomMargin"></tr>
ivan@712
   159
                </table>
ivan@712
   160
              </td>
ivan@712
   161
            </tr>
ivan@712
   162
ivan@712
   163
            <tr>
ivan@712
   164
              <td class="TitleCell"><span class="LabelText">Key</span></td>
ivan@712
   165
              <td class="TextBox_ContentCell"><input class="dojoValidateValid TextBox_OneCell_width" type="text" name="inpKey" value="" id="fieldKey"></input></td>
ivan@712
   166
              <td></td>
ivan@712
   167
              <td class="TitleCell"><span class="LabelText">Name</span></td>
ivan@712
   168
              <td class="TextBox_ContentCell" colspan="2"><input type="text" name="inpName" value="" id="fieldName" class="dojoValidateValid TextBox_TwoCells_width"></input></td>
ivan@712
   169
              <td></td>
ivan@712
   170
            </tr>
ivan@712
   171
ivan@712
   172
            <tr>
ivan@712
   173
              <td class="TitleCell"><span class="LabelText">Contact</span></td>
ivan@712
   174
              <td class="TextBox_ContentCell" colspan="2"><input type="text" name="inpContact" class="dojoValidateValid TextBox_TwoCells_width"></input></td>
ivan@712
   175
ivan@712
   176
              <td class="TitleCell"><span class="LabelText">City</span></td>
ivan@712
   177
              <td class="TextBox_ContentCell" colspan="2"> <input type="text" name="inpCity" class="dojoValidateValid TextBox_TwoCells_width"></input></td>
ivan@712
   178
            </tr>
ivan@712
   179
      
ivan@712
   180
            <tr>
ivan@712
   181
              <td class="TitleCell"><span class="LabelText">Postal Code</span></td>
ivan@712
   182
              <td class="TextBox_ContentCell"><input class="dojoValidateValid TextBox_OneCell_width" type="text" name="inpZIP"></input></td>
ivan@712
   183
ivan@712
   184
              <td></td>
ivan@712
   185
ivan@712
   186
              <td class="TitleCell"><span class="LabelText">Region</span></td>
ivan@712
   187
              <td class="TextBox_ContentCell" colspan="2"><input type="text" name="inpProvincia" class="dojoValidateValid TextBox_TwoCells_width"></input> </td>
ivan@712
   188
            </tr>
ivan@712
   189
        
ivan@712
   190
            <tr> 
ivan@712
   191
             <td class="TitleCell"><span class="LabelText">Customer</span></td>
ivan@712
   192
             <td class="Radio_Check_ContentCell"><span class="Radio_container_NOT_Focused"><input type="radio" name="inpBpartner" value="costumer" id="fieldClientsSelect"></input></span></td>
ivan@712
   193
ivan@712
   194
             <td class="TitleCell"><span class="LabelText">Providers</span></td>
ivan@712
   195
             <td class="Radio_Check_ContentCell"><span class="Radio_container_NOT_Focused"><input type="radio" name="inpBpartner" value="vendor" id="fieldVendorsSelect"></input></span></td>
ivan@712
   196
ivan@712
   197
             <td class="TitleCell"><span class="LabelText">All</span></td>
ivan@712
   198
             <td class="Radio_Check_ContentCell"><span class="Radio_container_NOT_Focused"><input type="radio" name="inpBpartner" value="all" id="fieldAllSelect"></input></span></td>
ivan@712
   199
            </tr>
ivan@712
   200
ivan@712
   201
            <tr>
ivan@712
   202
              <td></td>
ivan@712
   203
              <td class="Button_LeftAlign_ContentCell">
ivan@712
   204
                <div>
ivan@712
   205
                  <a class="ButtonLink" href="#"
ivan@712
   206
                    onfocus="setWindowElementFocus(this); window.status='Search'; return true;"
ivan@712
   207
                    onblur="window.status=''; return true;"
ivan@712
   208
                    onkeypress="this.className='ButtonLink_active'; return true;"
ivan@712
   209
                    onkeyup="this.className='ButtonLink_focus'; return true;"
ivan@712
   210
                    onclick="setFilters();return false;"
ivan@712
   211
                    id="buttonSearch">
ivan@712
   212
                    <table class="Button"
ivan@712
   213
                      onmousedown="this.className='Button_active'; return true;"
ivan@712
   214
                      onmouseup="this.className='Button'; return true;"
ivan@712
   215
                      onmouseover="this.className='Button_hover'; window.status='Search'; return true;"
ivan@712
   216
                      onmouseout="this.className='Button'; window.status=''; return true;">
ivan@712
   217
                      <tr>
ivan@712
   218
                        <td class="Button_left"><img class="Button_Icon Button_Icon_search" alt="Search" title="Search" src="../../../../../web/images/blank.gif" border=0/></td>
ivan@712
   219
                        <td class="Button_text Button_width">Search</td>
ivan@712
   220
                        <td class="Button_right"></td>
ivan@712
   221
                      </tr>
ivan@712
   222
                    </table>
ivan@712
   223
                  </a>
ivan@712
   224
                </div>
ivan@712
   225
              </td>
ivan@712
   226
              <td></td>
ivan@712
   227
              <td></td>
ivan@712
   228
              <td></td>
ivan@712
   229
              <td></td>
ivan@712
   230
            </tr>
ivan@712
   231
          </table>
ivan@712
   232
        </div>
ivan@712
   233
      </td>
ivan@712
   234
    </tr>
ivan@712
   235
ivan@712
   236
    <tr>
ivan@712
   237
      <td>
ivan@712
   238
        <div class="Popup_ContentPane_Client" style="overflow: hidden; height: 0px;" id="client_middle">
ivan@712
   239
          <table summary="" id="sectionDetail">
ivan@712
   240
            <tr>
ivan@712
   241
              <td>
ivan@712
   242
                <table cellspacing="0" cellpadding="0" width="10px" class="DataGrid_Header_Table DataGrid_Body_Table" style="table-layout: auto;" id="grid_sample">
ivan@712
   243
                  <tr class="DataGrid_Body_Row" id="grid_sample_header">
ivan@712
   244
                    <th width="10px" class="DataGrid_Header_Cell">DataGrid</th>
ivan@712
   245
                  </tr>
ivan@712
   246
                  <tr class="DataGrid_Body_Row DataGrid_Body_Row_1" onclick="selectActual(this); loadData('BBAccountingUser', '1000012', '', '1'); return true;" id="grid_sample_row">
ivan@712
   247
                    <td class="DataGrid_Body_Cell">Loading...</td>
ivan@712
   248
                  </tr>
ivan@712
   249
                </table>
ivan@712
   250
                <table width="100%" cellspacing="0" cellpadding="0" border="0" class="Main_Client_TableRelation" id="grid_table">
ivan@712
   251
                  <tr>
ivan@712
   252
                    <td>
ivan@712
   253
                      <div id="grid" dojotype="openbravo:DataGrid"
ivan@712
   254
                        structureurl="../info/BusinessPartnerMultiple.html?Command=STRUCTURE"
ivan@712
   255
                        dataurl="../info/BusinessPartnerMultiple.html?Command=DATA"
ivan@712
   256
                        updatesurl="../info/BusinessPartnerMultiple.html?Command=DATA"
ivan@712
   257
                        calculatenumrows="true" editable="false" sortable="true"
ivan@712
   258
                        deleteable="true" oninvalidvalue="alert" onscroll="updateHeader"
ivan@712
   259
                        ongridload="onGridLoadDo" buffersize="3.0" showlinenumbers="true"
ivan@712
   260
                        offset="0" sortcols="1" sortdirs="ASC" defaultrow="0"
ivan@712
   261
                        maxwidth="99%" percentagewidthrelativetoid="client_middle"
ivan@712
   262
                        multipleRowSelection="true"
ivan@712
   263
                        preventcache="true" usecache="true" cachecontent="false">
ivan@712
   264
                      </div>
ivan@712
   265
                      <script>djConfig.searchIds.push("grid");</script>
ivan@712
   266
                    </td>
ivan@712
   267
                  </tr>
ivan@712
   268
                </table>
ivan@712
   269
              </td>
ivan@712
   270
            </tr>
ivan@712
   271
          </table>
ivan@712
   272
        </div>
ivan@712
   273
      </td>
ivan@712
   274
    </tr>
ivan@712
   275
    <tr>
ivan@712
   276
      <td>
ivan@712
   277
        <div class="Popup_ContentPane_Client" style="overflow: auto; height:50px;" id="client_bottom">
ivan@712
   278
          <table cellspacing="0" cellpadding="0" class="Popup_Client_TableSelector">
ivan@712
   279
ivan@712
   280
            <tr>
ivan@712
   281
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   282
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   283
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   284
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   285
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   286
              <td class="TableEdition_OneCell_width"></td>
ivan@712
   287
            </tr>
ivan@712
   288
            <tr>
ivan@712
   289
              <td></td>
ivan@712
   290
              <td></td>
ivan@712
   291
              <td class="Button_RightAlign_ContentCell">
ivan@712
   292
                <div>
ivan@712
   293
                  <a class="ButtonLink" href="#"
ivan@712
   294
                    onfocus="setWindowElementFocus(this); window.status='OK'; return true;"
ivan@712
   295
                    onblur="window.status=''; return true;"
ivan@712
   296
                    onkeypress="this.className='ButtonLink_active'; return true;"
ivan@712
   297
                    onkeyup="this.className='ButtonLink_focus'; return true;"
ivan@712
   298
                    onclick="depurarSelector('SAVE');return false;"
ivan@712
   299
                    id="buttonOK">
ivan@712
   300
                    <table class="Button"
ivan@712
   301
                      onmousedown="this.className='Button_active'; return true;"
ivan@712
   302
                      onmouseup="this.className='Button'; return true;"
ivan@712
   303
                      onmouseover="this.className='Button_hover'; window.status='OK'; return true;"
ivan@712
   304
                      onmouseout="this.className='Button'; window.status=''; return true;">
ivan@712
   305
                      <tr>
ivan@712
   306
                        <td class="Button_left"><img class="Button_Icon Button_Icon_ok" alt="OK" title="OK" src="../../../../../web/images/blank.gif" border=0/></td>
ivan@712
   307
                        <td class="Button_text Button_width">OK</td>
ivan@712
   308
                        <td class="Button_right"></td>
ivan@712
   309
                      </tr>
ivan@712
   310
                    </table>
ivan@712
   311
                  </a>
ivan@712
   312
                </div>
ivan@712
   313
              </td>
ivan@712
   314
              <td class="Button_LeftAlign_ContentCell">
ivan@712
   315
                <div>
ivan@712
   316
                  <a class="ButtonLink" href="#"
ivan@712
   317
                    onfocus="setWindowElementFocus(this); window.status='Cancel'; return true;"
ivan@712
   318
                    onblur="window.status=''; return true;"
ivan@712
   319
                    onkeypress="this.className='ButtonLink_active'; return true;"
ivan@712
   320
                    onkeyup="this.className='ButtonLink_focus'; return true;"
ivan@712
   321
                    onclick="depurarSelector('CLEAR');return false;">
ivan@712
   322
                    <table class="Button"
ivan@712
   323
                      onmousedown="this.className='Button_active'; return true;"
ivan@712
   324
                      onmouseup="this.className='Button'; return true;"
ivan@712
   325
                      onmouseover="this.className='Button_hover'; window.status='Cancel'; return true;"
ivan@712
   326
                      onmouseout="this.className='Button'; window.status=''; return true;">
ivan@712
   327
                      <tr>
ivan@712
   328
                        <td class="Button_left"><img class="Button_Icon Button_Icon_cancel" alt="Cancel" title="Cancel" src="../../../../../web/images/blank.gif" border=0/></td>
ivan@712
   329
                        <td class="Button_text Button_width">Cancel</td>
ivan@712
   330
                        <td class="Button_right"></td>
ivan@712
   331
                      </tr>
ivan@712
   332
                    </table>
ivan@712
   333
                  </a>
ivan@712
   334
                </div>
ivan@712
   335
              </td>
ivan@712
   336
              <td></td>
ivan@712
   337
              <td></td>
ivan@712
   338
            </tr>
ivan@712
   339
          </table>
ivan@712
   340
        </div>
ivan@712
   341
      </td>
ivan@712
   342
    </tr>
ivan@712
   343
  </table>
ivan@712
   344
</form>
ivan@712
   345
</body>
ivan@712
   346
</html>