This forum is now just an archive. Use the new Q&A website
It is currently Wed Apr 23, 2014 9:08 am

All times are UTC + 2 hours




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: [SOLVED] Reload form, after hitting a button
PostPosted: Fri Mar 16, 2012 8:23 pm 
Offline

Joined: Wed Feb 18, 2009 4:01 pm
Posts: 195
Location: Lisboa, Portugal
Cheers!

I'm trying to reload a form the moment the user pushes a button. Unfortunately, it keeps opening a new window instead of reloading the original one.

Here's the code:

Code:
return {
          'res_id': myRecordID,
          'name': 'Revisões',
          'view_type': 'form',
          'view_mode': 'form',
          'res_model': 'myModule.myClass',
          'view_id': myViewID,
          'type': 'ir.actions.act_window',
          'target':'current',
}


Last edited by catinga on Mon Mar 26, 2012 10:53 am, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Reload form, after hitting a button
PostPosted: Sat Mar 24, 2012 5:22 pm 
Offline

Joined: Sat Mar 24, 2012 4:56 pm
Posts: 4
Location: Gandhinagar
Hi,

You are calling an action which calls a form.

If you wish to reload the form, write a dummy method on the button with type=object.

Thanks.


Top
 Profile  
 
 Post subject: Re: Reload form, after hitting a button
PostPosted: Mon Mar 26, 2012 10:53 am 
Offline

Joined: Wed Feb 18, 2009 4:01 pm
Posts: 195
Location: Lisboa, Portugal
Thanks!!!

For the record:
It works because, when you call a button, the form is saved so, what one has to do is to call the dummy function and, within this one, do whatever is necessary.

;)


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC + 2 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:

Protected by Anti-Spam ACP