chore: se formatean archivos estilo pep8
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
This commit is contained in:
parent
dc649a80b5
commit
5113ad0289
1
call.py
1
call.py
@ -4,6 +4,7 @@ from datetime import date
|
|||||||
from .Util.interest import Interest
|
from .Util.interest import Interest
|
||||||
from .Util.call_types import CallTypes
|
from .Util.call_types import CallTypes
|
||||||
|
|
||||||
|
|
||||||
class Call(ModelSQL, ModelView):
|
class Call(ModelSQL, ModelView):
|
||||||
'Llamada'
|
'Llamada'
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
# this repository contains the full copyright notices and license terms.
|
# this repository contains the full copyright notices and license terms.
|
||||||
from trytond.model import ModelSQL, ModelView, fields
|
from trytond.model import ModelSQL, ModelView, fields
|
||||||
|
|
||||||
|
|
||||||
class Prospect(ModelSQL, ModelView):
|
class Prospect(ModelSQL, ModelView):
|
||||||
'Prospecto'
|
'Prospecto'
|
||||||
__name__ = 'sale.prospect'
|
__name__ = 'sale.prospect'
|
||||||
@ -9,7 +10,8 @@ class Prospect(ModelSQL, ModelView):
|
|||||||
name = fields.Char('Name')
|
name = fields.Char('Name')
|
||||||
city = fields.Char('City')
|
city = fields.Char('City')
|
||||||
|
|
||||||
contact_methods = fields.One2Many('prospect.contact_method', 'prospect', 'Contact methods')
|
contact_methods = fields.One2Many(
|
||||||
|
'prospect.contact_method', 'prospect', 'Contact methods')
|
||||||
|
|
||||||
|
|
||||||
class ContactMethod(ModelSQL, ModelView):
|
class ContactMethod(ModelSQL, ModelView):
|
||||||
@ -27,4 +29,3 @@ class ContactMethod(ModelSQL, ModelView):
|
|||||||
value = fields.Char('Value')
|
value = fields.Char('Value')
|
||||||
|
|
||||||
prospect = fields.Many2One('sale.prospect', 'Prospect')
|
prospect = fields.Many2One('sale.prospect', 'Prospect')
|
||||||
|
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
from trytond.model import ModelSQL, ModelView, fields
|
from trytond.model import ModelSQL, ModelView, fields
|
||||||
from .Util.interest import Interest
|
from .Util.interest import Interest
|
||||||
|
|
||||||
|
|
||||||
class ProspectTrace(ModelSQL, ModelView):
|
class ProspectTrace(ModelSQL, ModelView):
|
||||||
'Seguimiento de un prospecto'
|
'Seguimiento de un prospecto'
|
||||||
|
|
||||||
@ -10,13 +11,16 @@ class ProspectTrace(ModelSQL, ModelView):
|
|||||||
|
|
||||||
prospect = fields.Many2One('sale.prospect', 'Prospect')
|
prospect = fields.Many2One('sale.prospect', 'Prospect')
|
||||||
prospect_name = fields.Char('Name')
|
prospect_name = fields.Char('Name')
|
||||||
prospect_contact = fields.Many2One('prospect.contact_method', 'Contact method')
|
prospect_contact = fields.Many2One(
|
||||||
|
'prospect.contact_method', 'Contact method')
|
||||||
prospect_city = fields.Char('City')
|
prospect_city = fields.Char('City')
|
||||||
|
|
||||||
calls = fields.One2Many('sale.call', 'prospect_trace', "Calls")
|
calls = fields.One2Many('sale.call', 'prospect_trace', "Calls")
|
||||||
|
|
||||||
_interest_field_type = fields.Selection(Interest.get_interest_levels(), 'Interest')
|
_interest_field_type = fields.Selection(
|
||||||
current_interest = fields.Function(_interest_field_type, '_get_current_interest')
|
Interest.get_interest_levels(), 'Interest')
|
||||||
|
current_interest = fields.Function(
|
||||||
|
_interest_field_type, '_get_current_interest')
|
||||||
|
|
||||||
@fields.depends('prospect')
|
@fields.depends('prospect')
|
||||||
def on_change_prospect(self):
|
def on_change_prospect(self):
|
||||||
@ -26,4 +30,3 @@ class ProspectTrace(ModelSQL, ModelView):
|
|||||||
|
|
||||||
def _get_current_interest(self, name):
|
def _get_current_interest(self, name):
|
||||||
return self.calls[-1].interest
|
return self.calls[-1].interest
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user