Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0031749
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminoralways2015-12-18 13:102015-12-29 22:16
ReporterNaroaIriarteView Statuspublic 
Assigned ToNaroaIriarte 
PrioritynormalResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revision1b4cba742662
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toinigosanchez
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0031749: When a record is saving a warning is thrown, the message is not correct.

DescriptionIf you create a record and click on "save" and if a callout which has to show a warning is thrown out, the warning message is not correct. It shows "Saving failed" message appended to the original warning message. That is not correct because a warning may not impede to save a record.
Steps To Reproduce1- Create a callout with a simple logic that only shows a warning message.

http://wiki.openbravo.com/wiki/How_to_create_a_Callout [^]

2- Associate the callout to a column.
2.1- As System Admin, go to "Tables and Columns".
2.2- Go to the "Obuiapp_gc_system" table.
2.3- In the "Column" tab, open "Text_filter_behavior" record.
2.4- Fill the "callout" field with the callout you have just created.

3- export the database and compile with smartbuild.
4- As System Admin, go to "Grid configuration at System" window.
5- Create a new record.
6- Go to the "Text filter behavior" field and modify it (this is for throwing the callout).
7- Click on the save button.
8- Realize that the shown message is not correct, the warning shows the "Saving failed" message appended to the warning message. And that is not correct, it is possible to save the record.
Proposed SolutionThe "setMessage" function of the "ob-messagebar.js" has to be modified.
There is a condition which have to be changed

"if ((form && form.isSaving) || (grid && grid.isSaving)) {
 text = OB.I18N.getLabel('OBUIAPP_ErrorSavingFailed') + ' ' + text;
 }"

Here it is necessary to add a logic to avoid showing the "Saving failed" text if it is not an error. For example an info message or as in this example, a warning.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 00165083.0MP0 closediperdomo Remove the light box at all times, the red message bar is enough. 

-  Notes
(0082885)
hgbot (developer)
2015-12-21 14:50

Repository: erp/devel/pi
Changeset: 1b4cba742662a131987285c8c35313fd9d444f96
Author: Naroa Iriarte <naroa.iriarte <at> openbravo.com>
Date: Fri Dec 18 14:17:11 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/1b4cba742662a131987285c8c35313fd9d444f96 [^]

fixed issue 31749: The warning message is not correct.

When a warning message had to be shown when saving a record, it was not the proper message.
It showed "Saving failed" text appended to the original warning message.
That was not correct because it was possible to save the record.
To fix this the "setMessage" function of the "ob-messagebar.js" has been changed.
Now, it appends the "Saving failed" message only if the message type is an error.

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/main/ob-messagebar.js
---
(0082906)
NaroaIriarte (developer)
2015-12-21 16:47

For testing it:
I have written following code:

this.view.messageBar.setMessage('error', 'test error message', 'test error');


In a block of code where the isSaving is set to true, and I have realized that it works properly when the message which has to be shown is error.

I have tested in my own case, where the warning message needed to be shown too and now it is shown without the "Saving failed" text appended, it works as expected.
(0082912)
hudsonbot (developer)
2015-12-21 20:21

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/1874af35afc7 [^]
Maturity status: Test
(0083065)
inigosanchez (developer)
2015-12-29 22:16

Reviewed and tested in pi@64dfe1cd7ea5

- Issue History
Date Modified Username Field Change
2015-12-18 13:10 NaroaIriarte New Issue
2015-12-18 13:10 NaroaIriarte Assigned To => NaroaIriarte
2015-12-18 13:10 NaroaIriarte Modules => Core
2015-12-18 13:10 NaroaIriarte Triggers an Emergency Pack => No
2015-12-18 13:10 NaroaIriarte Relationship added related to 0016508
2015-12-18 14:39 NaroaIriarte Summary When a record is saved and a callout for showing a warning is thrown, the message is not correct. => When a record is saving a warning is thrown, the message is not correct.
2015-12-21 14:50 hgbot Checkin
2015-12-21 14:50 hgbot Note Added: 0082885
2015-12-21 14:50 hgbot Status new => resolved
2015-12-21 14:50 hgbot Resolution open => fixed
2015-12-21 14:50 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/1b4cba742662a131987285c8c35313fd9d444f96 [^]
2015-12-21 16:47 NaroaIriarte Note Added: 0082906
2015-12-21 16:47 NaroaIriarte Review Assigned To => alostale
2015-12-21 20:21 hudsonbot Checkin
2015-12-21 20:21 hudsonbot Note Added: 0082912
2015-12-28 14:10 inigosanchez Review Assigned To alostale => inigosanchez
2015-12-29 22:16 inigosanchez Status resolved => closed
2015-12-29 22:16 inigosanchez Note Added: 0083065


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker