This question has been flagged
1 Reply
2394 Views

I have two models.

In first model

I have two field: Place(textbox), Type(Selection)-Source,Destination,Both

In second model

I have source, destination, both are many2one fields.

in source field,i want place with type source & both

in destination field,i want place with type destination & both

How can i write the code?

For example:

3 places -- src,dest,both

src (type:source),

dest(type:destination) ,

both(type:both).

When call the source field in any other form, i want to list down src,both in my source field.

Avatar
Discard
Best Answer

You have to check the docs. The python is just one thing what you should now. https://doc.openerp.com/v6.1/developer/03_modules_2/ https://doc.openerp.com/trunk/server/api_models/

You can find easy way the solutions if you check the source code. I can paste the code here, but I think you cannot use in proper way.

Avatar
Discard
Author

Can you please provide the code?

Please define more deeply, the following: " in source field,i want place with type source & both

in destination field,i want place with type destination & both

"

Author

For example: src (type:source), dest(type:destination) , both(type:both). When call the source field in any other form, i want to list down src,both in my source field.

Try for a function field of type selection