Hi,

in storm_quicktt.module, function storm_quicktt_store_time() the function drupal_get_messages() is called too early. If the timetracker is running and you create for example a new node no error messages are displayed if the form is submitted but there was an error.

the reason is that in the function storm_quicktt_store_time() drupal_get_message() is called to remove all messages. If this functions gets called later in the function everything is fine, because the function is left before by a return.

Greetings
Carsten

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jurgenhaas’s picture

Thanks Carsten for submitting the patch, it looks good at a first glance but I'm not quite sure it wouldn't introduce other problems. E.g. if there is an error while saving timetracking (not doing anything else at the time), then this error would be cached untilt the next page reload and those errors would be displayed comepletely out of context then.

With regard to your problem I'm not able to reproduce the problem either. Can you please give me instructions on how to see that happening?

Carsten Müller’s picture

The problem occured when creating a new node. If an error appeared the messages were not displayed because they were catched before in the function storm_quicktt_store_time(). If i have left the title field of the node blank, the title field was marked red but the error message did not appear.

jurgenhaas’s picture

Status: Needs review » Postponed (maintainer needs more info)
FileSize
71.06 KB

Still can't reproduce the problem. See attached screenshot. Timetracking is started (bottom left corner of the screen) and I wanted to save a node without a title and as expected I'm getting the error message that title is a required field.

Carsten Müller’s picture

Hi,

i'm not sure what the reason is. Maybe because all the other modules. We have an intranet containing storm, storm dashboard, storm quicktt, sorm contrib, forum, ....
At the moment about 100 persons in the system, up to 60 working at the same time. Maybe too many modules with different weights so the quicktt module is called late and fetching the messages.

At the moment i am a little busy, when i have some time left, i will search for that.With the patch the messages are shown.

kfritsche’s picture

Status: Postponed (maintainer needs more info) » Fixed

Took me a while to figure out, what is wrong.
Even we have this patch in out intranet active since nearly a year, i tried to figure out, why jurgenhaase can't reproduce it.
My first attempt to save a node, worked great. Then i looked a while in the code and tried to figure out what is wrong. After this i retried it and the described error occured.
So it is only happening after the first update. If you open a node and click immediately on save, all works fine. But when you wait a while, this error occurs.

Patch from Carsten Müller commited.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.