Cédric Krier
5c062ebeea
Always rebuild MPTT tree in case of nested creation
...
because _update_tree can not find children with left/right.
issue5095
review24571002
2015-11-02 11:41:04 +01:00
Cédric Krier
edf80492d9
Update translations
2015-10-31 11:01:24 +01:00
Cédric Krier
b8a6573cc7
Fix test_view to use the right model for inherited view
...
If the view inherit from a different model, it should be used for the test
instead of the inherited view.
issue5088
review18751002
2015-10-31 10:47:10 +01:00
Cédric Krier
3a02e1d54e
Don't import obsolete translations
...
issue5055
review23561003
2015-10-21 18:20:57 +02:00
Cédric Krier
10af0ea078
Reset MPTT fields when copying records
...
The left/right fields must be reset to their default values to allow to compute
the correct new values. As it is common to forget this requirement when
implementing, it is safer to enforce this behaviour directly in the
ModelStorage.copy method.
issue5049
review16741002
2015-10-18 16:50:41 +02:00
Cédric Krier
0e467f1b5d
Fix order when searching view in ModelView
...
When id is given, there is no need to perform a search otherwise only root
views or inherited views from other model should be considered.
Instead of explicitly define orders, it is better for modularity to use the
default one defined on the view model.
issue2041
review21461002
2015-10-15 10:44:30 +02:00
Cédric Krier
5ced670050
Correctly handle all empty value of menu action
...
Empty action for the reference field can be None or an negative id.
issue4915
review22511002
2015-10-10 17:46:14 +02:00
Raimon Esteve
24c499737e
Remove trailing style_content attribute
...
changeset 45e423bd93fe has not completely removed all references to
style_content.
issue5003
review24441002
2015-10-04 22:56:53 +02:00
Cédric Krier
d71ea868b2
Remove '_' in button string
...
issue5012
review24441004
2015-10-04 19:46:58 +02:00
Cédric Krier
f01f0d5871
Fix child_of domain on empty MPTT
...
When the MPTT search returns no row, the SQL query generated has an invalid
syntax because it uses an empty Or() clause. We replace this empty Or() by a
Literal(False) to select nothing.
issue5011
review18651002
2015-10-03 11:50:56 +02:00
Cédric Krier
87f9fbea6e
Add test for all field methods
...
The test check if all defined field methods are linked to an existing field.
issue4991
review23441002
2015-10-01 22:37:13 +02:00
Cédric Krier
c7829b15f7
Sync model data with only the filesystem values
...
It must not update the previous values as some field could have been removed.
Also there is no problem with module override because this button is called
during normal run and not the update module process, so the filesystem value
contains all the overridden values.
issue4992
review22451002
2015-10-01 17:09:14 +02:00
Korbinian Preisler
c849f0be8b
Allow to import overridden translations from different po-file
...
issue4971
review18581002
2015-09-26 15:23:43 +02:00
Cédric Krier
5b18894602
Add newline before email
...
Since changeset 45e423bd93fe and the removal of style, the email label and
field are no more aligned.
2015-09-24 15:50:06 +02:00
Cédric Krier
fe52324943
Improve SQL expression for child_of on Many2One with MPTT
...
issue4984
review22441002
2015-09-24 15:48:45 +02:00
Cédric Krier
a9c760139a
Rename ActionMixin default_action into _default_action
...
ActionMixin._default_action is not a real default field method, so it must be
renamed to prevent Model.default_get to use it by mistake.
issue4979
review22431002
2015-09-22 22:55:54 +02:00
Cédric Krier
e43bda21bc
Wrong parameter passed to __raise_integrity_error
2015-09-21 10:30:25 +02:00
Cédric Krier
e0379a9d5b
Log inactivation failure instead of crashing
...
When a record XML is removed and it can not be deleted, it could also not be
allowed to inactivate it.
issue4964
review17491002
2015-09-21 10:28:53 +02:00
Cédric Krier
cd47b8cf85
Use specific test 'elem is None' to remove lxml warning
...
FutureWarning: The behavior of this method will change in future
versions. Use specific 'len(elem)' or 'elem is not None' test instead.
2015-09-15 14:52:03 +02:00
Cédric Krier
9bc7174254
Backed out changeset 0fd061e7c87f
2015-09-15 14:51:13 +02:00
Cédric Krier
228a8ca7d9
Use specific test 'elem is not None' to remove lxml warning
...
FutureWarning: The behavior of this method will change in future
versions. Use specific 'len(elem)' or 'elem is not None' test instead.
2015-09-14 12:00:43 +02:00
Cédric Krier
c18ec6ba74
Add support for float and integer on Property fields
...
issue4942
review18531002
2015-09-14 10:37:38 +02:00
Cédric Krier
8299e1c133
Validate XML generated by ModelView.fields_view_get
...
- Add missing attributes to {form,tree}.rn{c,g}
- Add validatation to test_view
- Prevent fields_view_get to set attribute to the wrong view type
issue4944
review19421002
2015-09-04 12:04:07 +02:00
Cédric Krier
0574e90f5b
Remove foreign-key on create_uid and write_uid
...
Instead prevent delete of any user to keep logging information.
issue4925
review24301002
2015-09-04 11:52:53 +02:00
Cédric Krier
109d0ef64f
Manage PostgreSQL schema
...
Replace usage of pg_catalog tables by information_schema to take care of user
access.
Ensure to fetch the columns information from the right schema.
Prevent to update default column values if it did not change.
Comment table and column only if the current user is the owner.
issue4924
review24291002
2015-09-04 11:16:09 +02:00
Cédric Krier
14d5de6ac9
Add Hungarian
...
issue4874
review19321002
2015-09-02 13:49:26 +02:00
Cédric Krier
9765d8456a
Use PYSONDecoder to validate Trigger.condition
...
Replace Python by PYSON in help and error message about Trigger.condition
issue4940
review24311002
2015-09-01 11:38:19 +02:00
Cédric Krier
b54afe3892
progressbar needs now float between 0 and 1
...
issue4929
review18511002
2015-08-28 10:54:50 +02:00
Cédric Krier
7a223d3b5e
Remove colors attribute on tree view
...
issue4861
review16551002
2015-08-22 09:00:14 +02:00
Cédric Krier
b19e93e3a9
Remove style on Report
...
issue4904
review18481002
2015-08-21 18:03:44 +02:00
Cédric Krier
a6c0702bd1
Add StateReport to Wizard
...
issue4896
review19361002
2015-08-14 17:58:47 +02:00
Cédric Krier
09345debbd
Add missing Check and Unique in __all__
2015-07-30 16:21:31 +02:00
Sergi Almacellas Abellana
9ac3fec4dd
Explicity raise error when creating/writing/deleting models with table_query
...
issue4822
review16351002
2015-07-29 10:56:30 +02:00
Cédric Krier
c6c6c7e268
Fix join target_search for history
...
search_domain must not override the main table with the history instance if
tables is provided by the caller. In such case, it must assume the caller will
pass the right table.
The join search on Many2One must use the history table if the Target is
historized and a _datetime is set in the context.
issue4798
review12251002
2015-07-28 14:54:03 +02:00
Cédric Krier
6cd05ed6fe
Add has_multirow_insert
...
There are still many databases that doesn't support this SQL-92 syntax.
issue4881
review19331002
2015-07-28 08:04:29 +02:00
Cédric Krier
a19d1b7614
Use autocommit transaction for webdav
...
issue4858
review23291002
2015-07-28 07:53:19 +02:00
Cédric Krier
7652df0be4
Allow to override ModelSQL._table
...
issue4774
review15431002
2015-07-16 01:13:45 +02:00
Cédric Krier
ba40cb71d1
Get all eligible records when writting many values
...
The call to trigger_write_get_eligibles must be done with all the records and
not only the first set.
issue4863
review23311002
2015-07-14 00:06:13 +02:00
Cédric Krier
dad49fa98b
Always test field presence in initial value when computed changed values
...
The value could be None which is also the default value returned by dict.get.
So it will fail to detect change in such case.
issue4839
review23281002
2015-07-14 00:04:08 +02:00
Cédric Krier
2f4bf93817
Remove boolean expression in order
...
issue4852
review15541002
2015-07-13 23:56:52 +02:00
Cédric Krier
f455a9b6ed
Add Italian
...
issue4840
review18331003
2015-07-09 15:41:53 +02:00
Cédric Krier
e4c8f59b80
Allow to import backend from entry points
...
issue4841
review20301002
2015-07-09 15:40:21 +02:00
Cédric Krier
390aebef15
Simplify the SQL query for domain on property
...
- Remove useless CASE test
- Simplify double negation
issue4835
review21271002
2015-07-09 15:38:44 +02:00
Cédric Krier
808580e2ea
Improve domain queries of xxx2Many
...
Avoid using double select of ids and origin.
issue4821
review15521002
2015-07-09 15:37:03 +02:00
Nicolas Évrard
03d2e3fa9a
Add reversed operators to PYSON expressions
...
review8201002
issue4856
2015-07-07 12:48:28 +02:00
Cédric Krier
7459aab3d1
Use CURRENT_TIMESTAMP instead of NOW
...
CURRENT_TIMESTAMP is the correct SQL standard way.
issue4837
review15531002
2015-07-01 19:41:49 +02:00
Cédric Krier
1f18f65c33
Ensure first argument of DatabaseIntegrityError is a string
...
issue4836
review8191003
2015-07-01 19:39:25 +02:00
Cédric Krier
e4546c3459
Add missing alias on selected columns
...
This is required by python-sql, if the rownum limit flavor is used, to retrieve
only the selected columns.
issue4838
review12231002
2015-07-01 19:34:48 +02:00
Nicolas Évrard
34acc0885b
Allow to replace view's root node with an XPATH
...
issue4802
review19291002
2015-06-23 17:12:18 +02:00
Cédric Krier
46e27a8f3e
Add Spanish Mexico
...
issue4813
review12221002
2015-06-22 22:19:01 +02:00