View unanswered posts | View active topics
|
Page 1 of 1
|
[ 3 posts ] |
|
| Author |
Message |
|
le_dilem
|
Post subject: How to assign a value in a field in the same form Posted: Wed Apr 13, 2011 6:15 pm |
|
Joined: Wed Dec 22, 2010 10:54 am Posts: 401
|
|
Hello I created a field (Test) "One2Many" in the product from Calibrate which is in the object product.test.one Then a button confirmation.
I'm trying to create a function to assign the value in the form of product description_sale.
Help thx.
_________________ je fume du thé et je reste éveillé le cauchemar continue
|
|
| Top |
|
 |
|
le_dilem
|
Post subject: Re: How to assign a value in a field in the same form Posted: Wed Apr 13, 2011 6:46 pm |
|
Joined: Wed Dec 22, 2010 10:54 am Posts: 401
|
|
def confirmation(self, cr, uid, ids, *args): for o in self.browse(cr, uid, ids): if o.test: self.write(cr, uid, ids, {'description_sale': o.test})
I like matches : browse_record(product.test, 1) no value
_________________ je fume du thé et je reste éveillé le cauchemar continue
|
|
| Top |
|
 |
|
le_dilem
|
Post subject: Re: How to assign a value in a field in the same form Posted: Wed Apr 13, 2011 7:03 pm |
|
Joined: Wed Dec 22, 2010 10:54 am Posts: 401
|
|
the solution :
def confirmation(self, cr, uid, ids, context=None): for o in self.browse(cr, uid, ids, context=context): if o.test: self.write(cr, uid, ids, {'description_sale': o.test.name})
tx
_________________ je fume du thé et je reste éveillé le cauchemar continue
|
|
| Top |
|
 |
|
Page 1 of 1
|
[ 3 posts ] |
|
|
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
|