Minor fix report
This commit is contained in:
parent
ce13b246f8
commit
927e9de648
18
booking.py
18
booking.py
|
@ -1651,15 +1651,15 @@ class BookingStatusReport(Report):
|
|||
)
|
||||
records = Folio.search(dom, order=[('arrival_date', 'ASC')])
|
||||
|
||||
bookings = {}
|
||||
if data['grouped']:
|
||||
for fol in records:
|
||||
bk = fol.booking
|
||||
if bk not in bookings.keys():
|
||||
bookings[bk] = []
|
||||
bookings[bk].append(fol)
|
||||
records = bookings
|
||||
report_context['records'] = records
|
||||
_records = {}
|
||||
for fol in records:
|
||||
bk = fol.booking
|
||||
if bk not in _records.keys():
|
||||
_records[bk] = []
|
||||
_records[bk].append(fol)
|
||||
|
||||
report_context['grouped'] = data['grouped']
|
||||
report_context['records'] = _records
|
||||
report_context['company'] = Company(data['company'])
|
||||
return report_context
|
||||
|
||||
|
|
Binary file not shown.
|
@ -56,6 +56,7 @@ class Service(Workflow, ModelSQL, ModelView):
|
|||
('checked', 'Checked'),
|
||||
], 'State', readonly=True, states=STATES)
|
||||
state_string = state.translated('state')
|
||||
space = fields.Many2One('analytic_account.space', 'Space', required=False)
|
||||
description = fields.Char('Description', select=True, states=STATES)
|
||||
count_services = fields.Function(fields.Integer('Count Services',
|
||||
select=True), 'get_count_services')
|
||||
|
|
|
@ -1,19 +1,21 @@
|
|||
<?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. -->
|
||||
<form>
|
||||
<form col="6">
|
||||
<label name="kind"/>
|
||||
<field name="kind" widget="selection"/>
|
||||
<label name="company"/>
|
||||
<field name="company"/>
|
||||
<label name="number"/>
|
||||
<field name="number"/>
|
||||
<label name="service_date"/>
|
||||
<field name="service_date"/>
|
||||
<label name="company"/>
|
||||
<field name="company"/>
|
||||
<label name="space"/>
|
||||
<field name="space" widget="selection"/>
|
||||
<label name="description"/>
|
||||
<field name="description"/>
|
||||
<button name="open" string="Open" icon="tryton-forward" colspan="2"/>
|
||||
<field name="lines" colspan="4"
|
||||
<!-- <button name="open" string="Open" icon="tryton-forward" colspan="2"/> -->
|
||||
<field name="lines" colspan="6"
|
||||
view_ids="hotel.service_line_view_tree"/>
|
||||
|
||||
<group col="5" colspan="4" id="buttons">
|
||||
|
|
Loading…
Reference in New Issue