Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Form without database fields

By
Tom
on 7/6/14, 9:34 AM 550 views

I would like to create a from with fields which are not saved to the database.
The data should be sent to an webservices to check availabillity.

Can someone give me an example... ?

 

Thnx !

0
DelphineL
On 7/6/14, 10:01 AM

Hi Look at how to do a wizard?

0

Ludo - Neobis

--Ludo - Neobis--
2387
| 2 2 5
Hoogvliet, Netherlands
--Ludo - Neobis--

Developer

Ludo - Neobis
On 7/7/14, 3:35 AM

For this you could use the new orm.transientmodel class. This will create a record in database like the regular orm/osv models but it will auto-remove itself after a certain period of time (I believe the default is 5 or 10 minutes).

You can create forms and such like you normally would with any other object/view.

--- EDIT ---

I meant osv.AbstractModel.

0

Hello Tom,

You can try out overriding "fields_view_get" method where you can create fields which are not there in the database, and then you can use those fields values for sending to a webservice, so actually, as the fields don't belongs to any of the model they will not get save in the database. This way actaully you are creating a dynamic view.

 

Regards

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

2 follower(s)

Stats

Asked: 7/6/14, 9:34 AM
Seen: 550 times
Last updated: 3/16/15, 8:10 AM