details: /erp/devel/pi/rev/487ce999589d
changeset: 10720:487ce999589d
user: Antonio Moreno <antonio.moreno <at> openbravo.com>
date: Wed Feb 16 17:15:02 2011 +0100
summary: Create closeSearch() differently so that old selectors work
details: /erp/devel/pi/rev/412428123708
changeset: 10721:412428123708
user: Antonio Moreno <antonio.moreno <at> openbravo.com>
date: Wed Feb 16 18:30:32 2011 +0100
summary: Changes so that the correct values are displayed in the fields which
use a selector
diffstat:
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-formitem-widgets.js
| 7 +++++--
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
| 8 +++-----
2 files changed, 8 insertions(+), 7 deletions(-)
diffs (45 lines):
diff -r ba6483ea020a -r 412428123708
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-formitem-widgets.js
---
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-formitem-widgets.js
Wed Feb 16 18:22:18 2011 +0100
+++
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-formitem-widgets.js
Wed Feb 16 18:30:32 2011 +0100
@@ -67,10 +67,12 @@
isc.ClassFactory.mixInInterface('OBSearchItem', 'OBLinkTitleItem');
// a global function as it is called from classic windows
-function closeSearch(action, value, display, parameters, wait){
+(function(w) {
+
+w.closeSearch = function (action, value, display, parameters, wait){
var length, i, hiddenInputName, targetFld = isc.OBSearchItem.openSearchItem,
currentValue = targetFld.getValue();
- if (action === 'SAVE' && currentValue !== value) {
+ if (action === 'SAVE') {
if (!targetFld.valueMap) {
targetFld.valueMap = {};
}
@@ -98,6 +100,7 @@
isc.OBSearchItem.openedWindow.close();
isc.OBSearchItem.openSearchItem = null;
}
+}(this));
isc.OBSearchItem.addProperties({
showPickerIcon: true,
diff -r ba6483ea020a -r 412428123708
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
---
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
Wed Feb 16 18:22:18 2011 +0100
+++
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
Wed Feb 16 18:30:32 2011 +0100
@@ -516,12 +516,10 @@
identifier = field.valueMap[columnValue.value];
}
if (identifier) {
- if (entries) {
- if (!field.valueMap) {
- field.valueMap = {};
- }
- field.valueMap[columnValue.value] = identifier;
+ if (!field.valueMap) {
+ field.valueMap = {};
}
+ field.valueMap[columnValue.value] = identifier;
if (field.form) {
if (field.displayField) {
field.form.setValue(field.displayField, identifier);
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits