~elbati/c2c-rd-addons/fix_chricar_partner_parent_companies_menu_id

« back to all changes in this revision

Viewing changes to chricar_tenant/tenant.py

  • Committer: openerp@bazaar.camptocamp.net
  • Date: 2012-09-04 10:49:51 UTC
  • Revision ID: openerp@bazaar.camptocamp.net-20120904104951-4r92wd49rq9mpniy
[FIX] default must match field type

Show diffs side-by-side

added added

removed removed

Lines of Context:
139
139
             now = time.strftime('%Y-%m-%d %H:%M:%S')
140
140
             tenant_obj = self.pool.get('chricar.tenant')
141
141
             tenant_ids = tenant_obj.search(cr,uid,['|',('to_date','=',False),('to_date','>',now),('name','<=',now),('top_id','=',p.id)])
142
 
             lease_cur = 0
 
142
             lease_cur = 0.0
143
143
             for lease in tenant_obj.browse(cr, uid, tenant_ids,context):
144
144
                 lease_cur = lease.lease
145
145
             result[p.id] = lease_cur
152
152
             now = time.strftime('%Y-%m-%d %H:%M:%S')
153
153
             tenant_obj = self.pool.get('chricar.tenant')
154
154
             tenant_ids = tenant_obj.search(cr,uid,['|',('to_date','=',False),('to_date','>',now),('name','<=',now),('top_id','=',p.id)])
155
 
             price = 0
 
155
             price = 0.0
156
156
             for lease in tenant_obj.browse(cr, uid, tenant_ids,context):
157
157
                 price = lease.price
158
158
             potential = 0.0