Compare commits
6 Commits
Reportes
...
4826687b3b
| Author | SHA1 | Date | |
|---|---|---|---|
| 4826687b3b | |||
| bd62abb43f | |||
| 18d06374fe | |||
| d5ca112bff | |||
| d1ad40203b | |||
| 9c368809f9 |
@@ -7,7 +7,7 @@
|
|||||||
[ ! -d "$SRC" ] && die "no se ubica ruta en SRC"
|
[ ! -d "$SRC" ] && die "no se ubica ruta en SRC"
|
||||||
|
|
||||||
# dependencias minimas
|
# dependencias minimas
|
||||||
pip3 install psycopg2 proteus inotify honcho
|
pip3 install psycopg2 proteus==6.8 inotify honcho
|
||||||
|
|
||||||
# instalar dependencias de tryton desde paquete
|
# instalar dependencias de tryton desde paquete
|
||||||
python3 setup.py install
|
python3 setup.py install
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ FROM node as builder-node
|
|||||||
|
|
||||||
ENV SERIES 6.8
|
ENV SERIES 6.8
|
||||||
RUN npm install -g bower
|
RUN npm install -g bower
|
||||||
RUN curl https://downloads.tryton.org/${SERIES}/tryton-sao-last.tgz | tar zxf - -C /
|
RUN curl https://downloads.tryton.org/${SERIES}/tryton-sao-6.8.4.tgz | tar zxf - -C /
|
||||||
RUN cd /package && bower install --allow-root
|
RUN cd /package && bower install --allow-root
|
||||||
|
|
||||||
FROM python:3.9-bullseye
|
FROM python:3.9-bullseye
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ from . import prospect_trace
|
|||||||
from . import call
|
from . import call
|
||||||
from . import pending_call
|
from . import pending_call
|
||||||
from . import user
|
from . import user
|
||||||
from . import print_report_by_operator
|
|
||||||
from .locations import city
|
from .locations import city
|
||||||
from .locations import department
|
from .locations import department
|
||||||
|
|
||||||
@@ -29,7 +28,6 @@ def register():
|
|||||||
prospect_trace.MakeCallAskTask,
|
prospect_trace.MakeCallAskTask,
|
||||||
prospect.ReassignProspectByOperatorStart,
|
prospect.ReassignProspectByOperatorStart,
|
||||||
prospect.ReassignProspectByProspectStart,
|
prospect.ReassignProspectByProspectStart,
|
||||||
print_report_by_operator.PrintReportByOperatorStart,
|
|
||||||
module='sale_opportunity_management', type_='model')
|
module='sale_opportunity_management', type_='model')
|
||||||
Pool.register(
|
Pool.register(
|
||||||
prospect_trace.ScheduleCall,
|
prospect_trace.ScheduleCall,
|
||||||
@@ -37,7 +35,6 @@ def register():
|
|||||||
prospect_trace.MakeCall,
|
prospect_trace.MakeCall,
|
||||||
prospect.ReassignProspectByOperator,
|
prospect.ReassignProspectByOperator,
|
||||||
prospect.ReasignProspectByProspect,
|
prospect.ReasignProspectByProspect,
|
||||||
print_report_by_operator.PrintReportByOperator,
|
|
||||||
module='sale_opportunity_management', type_='wizard')
|
module='sale_opportunity_management', type_='wizard')
|
||||||
Pool.register(
|
Pool.register(
|
||||||
module='sale_opportunity_management', type_='report')
|
module='sale_opportunity_management', type_='report')
|
||||||
|
|||||||
@@ -1,24 +0,0 @@
|
|||||||
# This file is part of Tryton. The COPYRIGHT file at the top level of
|
|
||||||
# this repository contains the full copyright notices and license terms.
|
|
||||||
# from trytond.model import ModelSQL, ModelView, fields
|
|
||||||
from trytond.wizard import Wizard, StateView, Button # , StateReport
|
|
||||||
from trytond.model import fields, ModelView
|
|
||||||
|
|
||||||
|
|
||||||
class PrintReportByOperatorStart(ModelView):
|
|
||||||
'Vista inicial de reporte por operario'
|
|
||||||
__name__ = 'sale.print_report_by_operator.start'
|
|
||||||
|
|
||||||
start_date = fields.Date('Start date')
|
|
||||||
end_date = fields.Date('End date')
|
|
||||||
|
|
||||||
|
|
||||||
class PrintReportByOperator(Wizard):
|
|
||||||
'Generar reporte por operario'
|
|
||||||
__name__ = 'sale.print_report_by_operator'
|
|
||||||
|
|
||||||
start = StateView(
|
|
||||||
'sale.print_report_by_operator.start',
|
|
||||||
'sale_opportunity_management.print_report_by_operator_start_view_form',
|
|
||||||
[Button("Cancel", "end", "tryton-cancel"),
|
|
||||||
Button("Print Report", "print_report", "tryton-ok", default=True)])
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
<!-- <?xml version="1.0"?>
|
|
||||||
<!-- This file is part of Tryton. The COPYRIGHT file at the top level of
|
|
||||||
this repository contains the full copyright notices and license terms. -->
|
|
||||||
<tryton>
|
|
||||||
<data>
|
|
||||||
<record model="ir.action.wizard" id="print_report_by_operator_wizard">
|
|
||||||
<field name="name">Print report by operator</field>
|
|
||||||
<field name="wiz_name">sale.print_report_by_operator</field>
|
|
||||||
</record>
|
|
||||||
<record model="ir.ui.view" id="print_report_by_operator_start_view_form">
|
|
||||||
<field name="model">sale.print_report_by_operator.start</field>
|
|
||||||
<field name="type">form</field>
|
|
||||||
<field name="name">print_report_by_operator_start_form</field>
|
|
||||||
</record>
|
|
||||||
<data>
|
|
||||||
<tryton/> -->
|
|
||||||
@@ -51,6 +51,11 @@ class Prospect(ModelSQL, ModelView, DeactivableMixin):
|
|||||||
def default_state(cls):
|
def default_state(cls):
|
||||||
return 'unassigned'
|
return 'unassigned'
|
||||||
|
|
||||||
|
@fields.depends('prospect_trace', 'contact_methods')
|
||||||
|
def on_change_contact_methods(self):
|
||||||
|
for contact in self.contact_methods:
|
||||||
|
contact.prospect_trace = self.prospect_trace
|
||||||
|
|
||||||
@fields.depends('city', 'department')
|
@fields.depends('city', 'department')
|
||||||
def on_change_city(self):
|
def on_change_city(self):
|
||||||
if self.city:
|
if self.city:
|
||||||
|
|||||||
@@ -365,14 +365,14 @@ Crear un usuario de rol administrador::
|
|||||||
>>> admin.user_admin == True
|
>>> admin.user_admin == True
|
||||||
True
|
True
|
||||||
|
|
||||||
.. Generar reporte por operario y consolidado::
|
Agregar un nuevo método de contacto desde prospecto
|
||||||
.. >>> PrintReportByOperator = Model.get('sale.print_report_by_operato`r', type='wizard')
|
>>> contact_method = prospect1.contact_methods.new(value='0000000000', name='Nuevo', job='Puesto increíble')
|
||||||
.. >>> session_id, _, _ = PrintReportByOperator.create()
|
>>> prospect1.save()
|
||||||
|
|
||||||
.. >>> print_report_by_operator = Wizard('sale.print_report_by_operator', [])
|
>>> prospect1.contact_methods[-1].value
|
||||||
.. >>> print_report_by_operator.form.start_date = date.today()
|
'0000000000'
|
||||||
.. >>> print_report_by_operator.form.end_date = date.today()
|
>>> prospect_trace.prospect_contacts[-1].value
|
||||||
.. >>> print_report_by_operator.execute('print_report')
|
'0000000000'
|
||||||
|
|
||||||
--------
|
--------
|
||||||
Reportes
|
Reportes
|
||||||
|
|||||||
@@ -1,7 +0,0 @@
|
|||||||
<?xml version="1.0"?>
|
|
||||||
<!-- This file is part of Tryton. The COPYRIGHT file at the top level of
|
|
||||||
this repository contains the full copyright notices and license terms. -->
|
|
||||||
<tree>
|
|
||||||
<field name="start_date" expand="1"/>
|
|
||||||
<field name="end_date" expand="1"/>
|
|
||||||
</tree>
|
|
||||||
Reference in New Issue
Block a user