1
# -*- coding: utf-8 -*-
2
##############################################
4
# Swing Entwicklung betrieblicher Informationssysteme GmbH
5
# (<http://www.swing-system.com>)
6
# Copyright (C) ChriCar Beteiligungs- und Beratungs- GmbH
8
# 26-APR-2012 (GK) created
10
# WARNING: This program as such is intended to be used by professional
11
# programmers who take the whole responsability of assessing all potential
12
# consequences resulting from its eventual inadequacies and bugs.
13
# End users who are looking for a ready-to-use solution with commercial
14
# garantees and support are strongly adviced to contract a Free Software
17
# This program is Free Software; you can redistribute it and/or
18
# modify it under the terms of the GNU General Public License
19
# as published by the Free Software Foundation; either version 3
20
# of the License, or (at your option) any later version.
22
# This program is distributed in the hope that it will be useful,
23
# but WITHOUT ANY WARRANTY; without even the implied warranty of
24
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25
# GNU General Public License for more details.
27
# You should have received a copy of the GNU General Public License
28
# along with this program; if not, see <http://www.gnu.org/licenses/> or
29
# write to the Free Software Foundation, Inc.,
30
# 59 Temple Place - Suite 330, Boston, MA 02111-1.17, USA.
32
###############################################
33
{ "name" : "Variant of field type one2many for sorted associations"
35
, "author" : "Swing Entwicklung betrieblicher Informationssysteme GmbH"
36
, "website" : "http://www.swing-system.com"
38
Variant of field type one2many for sorted associations
42
| import one2many_sorted
45
| { 'partner_ids' : one2many_sorted.one2many_sorted
48
| , 'Sorted Partner List'
49
| , order='name.upper(), title'
50
| , search=[('is_company', '=', 'False')]
51
| , set={'is_company' : False}
56
In the example above, the primary sort criteria is name (not case-sensitive), the secondary is title.
57
Only partners that are physical persons (not is_company) are selected - and only those can be added.
59
, "category" : "Tools"
60
, "depends" : ["base"]
65
, "auto_install" : False
66
, "installable" : True