Re: An elegant and simple way to fire a signal after a Save is complete (completely complete :) )

2014-10-15 Thread Spiros Mouzakitis
Thanks for the suggestion, i will also try django-transaction-hooks. On Tuesday, October 14, 2014 11:40:21 PM UTC+3, Carl Meyer wrote: > > On 10/14/2014 01:58 PM, Spiros Mouzakitis wrote: > > What i finally did was to create a post_save signal as usual, and then > > in my r

Re: An elegant and simple way to fire a signal after a Save is complete (completely complete :) )

2014-10-14 Thread Spiros Mouzakitis
put a time sleep. By the time the thread is resumed from the time.sleep function, the database has been updated and unlocked It works, but definitely not elegant :) On Tuesday, October 14, 2014 7:05:36 PM UTC+3, Spiros Mouzakitis wrote: > > Hi all, > > I have a model (model Employ

Run some code after Model Save completes (and after database is updated)

2014-10-14 Thread Spiros Mouzakitis
Hi, -I am looking for an elegant, and universal way to add some code AFTER the saving of a model and after of course the database is updated with changes. -I have tried post_save signals, but the transaction is still on, the entries do not exist in database -I have tried overriding save in model

An elegant and simple way to fire a signal after a Save is complete (completely complete :) )

2014-10-14 Thread Spiros Mouzakitis
Hi all, I have a model (model Employee) and i want to each time that it is created / saved to run a specific code block. My specific code requires that the model is already saved in the database (i call an external API) I can't use post_save signal , because the transaction is still pending (th