Commit Graph

55661 Commits

Author SHA1 Message Date
Launchpad Translations on behalf of openerp 6a2da1c2f7 Launchpad automatic translations update.
bzr revid: launchpad_translations_on_behalf_of_openerp-20130421053215-jdbdrur8vk4zu5tc
bzr revid: launchpad_translations_on_behalf_of_openerp-20130420064852-b6bt9syb79h1x16m
bzr revid: launchpad_translations_on_behalf_of_openerp-20130421053233-g4dbsfidsqrs301v
bzr revid: launchpad_translations_on_behalf_of_openerp-20130421053237-8jhzy2qe55bb766x
2013-04-21 05:32:37 +00:00
Olivier Dony 65ff677697 [MERGE/ADD] Many important fixes for contact/company management + new module account_report_company
This patch comes with a corresponding server-side patch (revision 4946 revid: odo@openerp.com-20130420032529-pvv6vuelp84bt26j)


- module-specific overrides of _commercial_fields() for all modules adding accounting/invoicing-related fields to res.partner

- corresponding changes to inherited views of res.partner form to hide these commercial fields when they are in fact "related fields" of their parent commercial entity. This mainly concerns 2 sections of the Partner form: the whole Accounting tab, and the bottom of the Sales&Purchase tabs with the pricelists and invoicing fields. These sections are replaced by a short message and a button to open the commercial entity to view/edit the fields

- a few fixes to properly delegate the resolution of various contact/address types to the corrected res.partner.address_get()

- changes to search views of the main business documents so that searching for a company name will also match its contacts

- a fix of the _find_accounting_partner() method that the account module uses to locate the partner to which journal entries must be linked - it will now use the same semantics as for "commercial entity"

- fix issue detected by Joël Grand-Guillaume in comment #34 of bug 1160365: when invoicing after delivery, the invoicing contact/address must be used rather than the main customer. Tests updated accordingly.

- add new 7.0 module "account_report_company": this module adds an extra stored field "commercial_partner_id" on Invoices to make reporting/aggregating by partner easier in the Invoice list and in the Invoice Analysis report. This module is expected to be merged in the main account module in the next major release. The module can be installed without any risk on any existing 7.0 databases.
This module also mitigates group_by issues on all models by adding a new stored function field `display_name` on res.partner that contains the name_get() result in the form "ACME, John Doe" and set it as the default _order for res.partner. This ensures that group_by entries for the same company will always be next to each other on all documents: "ACME" is directly followed by "ACME, John Doe", "ACME, John Anderson", etc. This field also replaces the `name` field in the list and kanban views of Partners, so that the display order matches the display labels.

- fixed unique constraints definition on some commercial fields on res.partner (l10n_ro)

lp bug: https://launchpad.net/bugs/1160365 fixed

bzr revid: odo@openerp.com-20130420034221-2wvf6rezwl7gog74
2013-04-20 05:42:21 +02:00
Olivier Dony feefb0ad36 [FIX] search views: use child_of operator for partner_id fields that can reference both companies and contacts
The goal is to match both the Company and its contacts
when searching for the Company

bzr revid: odo@openerp.com-20130420022642-6qe8pp4ifexjms65
2013-04-20 04:26:42 +02:00
Olivier Dony b91cd6127a [REVERT] account_report_company: undo override of res.partner.commercial_partner_id field to store it, as the ORM does not support it and it's not strictly necessary
It works when installing the module but would break
everytime another module that inherits from res.partner
is installed/update from command-line (e.g. -i/-u crm),
as account_report_company is low in the dependency graph
so the field is dropped when the ORM notices that
the current field definition is not stored.
This can be solved in trunk by making the field stored
directly in 'base'.

bzr revid: odo@openerp.com-20130420015003-8y48xrb14cjif60w
2013-04-20 03:50:03 +02:00
Olivier Dony 64f29cfa10 [IMP] account_report_company: use `display_name` instead of name in kanban and list views, so labels visually match order
bzr revid: odo@openerp.com-20130419171853-dvfi5jvvlof9afoo
2013-04-19 19:18:53 +02:00
Olivier Dony 5e2ce8b709 [IMP] account_report_company: add extra stored function field `display_name` on res.partner and use it for sorting
This makes name_search() results, group_by, etc. all behave as expected

bzr revid: odo@openerp.com-20130419165239-15szgi0e686k6mh9
2013-04-19 18:52:39 +02:00
niv-openerp 1f2064cb93 [FIX] pad: revert part of previous fix because it could produce problems in some cases
bzr revid: nicolas.vanhoren@openerp.com-20130419144238-0hq1rgmcacw5sw1r
2013-04-19 16:42:38 +02:00
niv-openerp ea2544e432 [FIX] pad: problem about pad title not being updated correctly, was solved by solving another, more serious, bug that didn't updated correctly the database backup of the pad
lp bug: https://launchpad.net/bugs/1155039 fixed

bzr revid: nicolas.vanhoren@openerp.com-20130419143529-jku5titoacaajft0
2013-04-19 16:35:29 +02:00
Olivier Dony 8503964216 [IMP] account_report_company: make res.partner.commercial_partner_id field stored, for further reporting needs
This is not strictly necessary, but can be useful for other
modules in order to ease SQL reporting, without even needing
to store a denormalized copy of the "commercial partner" key
on the documents themselves.

Also renamed the Python fiel to something generic since
it now inherits multiple models.

bzr revid: odo@openerp.com-20130419134335-rhsg24f2uuwl3kla
2013-04-19 15:43:35 +02:00
Launchpad Translations on behalf of openerp 230b23e6cb Launchpad automatic translations update.
bzr revid: launchpad_translations_on_behalf_of_openerp-20130419061733-j4th561m2dju73zo
bzr revid: launchpad_translations_on_behalf_of_openerp-20130419061748-4sz8agg8laqbyu4p
2013-04-19 06:17:48 +00:00
Olivier Dony 26dd9bc343 [MERGE] Sync with 7.0
bzr revid: odo@openerp.com-20130418172123-2ofzftdo2a923nj1
2013-04-18 19:21:23 +02:00
Olivier Dony 451f8df250 [FIX] sale: orders/quotations action should not force `display_address` flag
Doing so affects autocompletion of search results, etc.
while the fields on the form view are already properly
displayed anyway.

bzr revid: odo@openerp.com-20130418172022-e3lu35xq191jxcyu
2013-04-18 19:20:22 +02:00
Fabien Meghazi d94936132a [MERGE] Fixed http controllers inheritance
bzr revid: fme@openerp.com-20130418171750-7oldgiewo1eewxk7
2013-04-18 19:17:50 +02:00
Quentin (OpenERP) af33bef989 [FIX] sale: fix in the workflow of the sale order that appeared on invoice deletion
bzr revid: qdp-launchpad@openerp.com-20130418163616-ob30cd73vxkoe31a
2013-04-18 18:36:16 +02:00
Olivier Dony a9d5c2d37e [FIX] res.partner: rename commercial_id to commercial_partner_id, following corresponding change in `base`
bzr revid: odo@openerp.com-20130418154022-lt7frhp9c8f2boo0
2013-04-18 17:40:22 +02:00
niv-openerp e7aeabc834 [FIX] account: minor javascript problem that made appear a stack trace
lp bug: https://launchpad.net/bugs/1155605 fixed

bzr revid: nicolas.vanhoren@openerp.com-20130418151353-dgfawgqgvama1u84
2013-04-18 17:13:53 +02:00
Quentin (OpenERP) 27c3b6cc33 [MERGE][FIX] product: context propagating in res_currency.compute(). Courtesy of Yannick Vaucher @ Camptocamp. Thanks dude
bzr revid: qdp-launchpad@openerp.com-20130418141013-vukxknub32p7djqd
2013-04-18 16:10:13 +02:00
niv-openerp 9c9971f0c9 [FIX] problem in view editor
bzr revid: nicolas.vanhoren@openerp.com-20130418135953-l53w542hrqc0puvq
2013-04-18 15:59:53 +02:00
Quentin (OpenERP) dcfbadd97e [FIX] hr_expense, usability: added sum in tree view
bzr revid: qdp-launchpad@openerp.com-20130418135356-p017meay192awm3y
2013-04-18 15:53:56 +02:00
Quentin (OpenERP) 46e95cb136 [FIX] account, account.move.line form view: the same method was defined twice, differently, and parameters were not correctly passed in onchanges
bzr revid: qdp-launchpad@openerp.com-20130418134032-t3y4dk4sp4eu2031
2013-04-18 15:40:32 +02:00
Xavier Morel d4977dd3bb [FIX] missing translation mark in error message
lp bug: https://launchpad.net/bugs/1125159 fixed

bzr revid: xmo@openerp.com-20130418125640-87g9sdowig7w565d
2013-04-18 14:56:40 +02:00
Olivier Dony dc24794855 [FIX] web: support integer/float fields in search view via auto-completion + tests
integer/float fields were not offering auto-completion in search views,
making them unsearchable except via advanced search.
This patch adds the missing complete() function and removes the incorrect
value_from() function that did not conform to the 7.0 search view API.
It seemed to be a leftover of the 6.1 search field implementation
of get_value(), wrongly renamed for 7.0.

Also includes corresponding tests.

bzr revid: odo@openerp.com-20130418112001-388op1t8ugr0rhfn
2013-04-18 13:20:01 +02:00
Quentin (OpenERP) c46929268d [FIX] account* modules: added 'account_period_prefer_normal':True in context when trying to find the period related to a date.
This patch will be forward ported in trunk by changing the behaviour of account_period.find() in order to fetch the normal periods by default (account_period_prefer_normal will be True by default) because there are no business case i could think of where you'd like to get the opening period (except in the closure but it's held in a different way there). On the other hand, it's pretty easy to forget to put that key in the context and introduce a new bug that will select the opening period instead of the wanted one

bzr revid: qdp-launchpad@openerp.com-20130418102433-t52uj23trkpr8vnb
2013-04-18 12:24:33 +02:00
Xavier Morel 3da2aaf488 [IMP] only use name of class being created: module is incorrect for dynamically created classes
bzr revid: xmo@openerp.com-20130418094315-qk8m13s4zzvojauw
2013-04-18 11:43:15 +02:00
Xavier Morel db4d08e3a9 [FIX] Extension of controller in-place with explicit spec of same _cp_path
When extending a controller in-place (e.g. A(Controller), B(A)) and
providing the exact same _cp_path as parent (no-op) execution path
would go into handler for _cp_path overwriting and raise an assertion
error for overwriting of existing controller.

Except this is allowed (if ugly) pattern, so warn & ignore behavior
(it is harmless).

bzr revid: xmo@openerp.com-20130418092405-wrmmrd648b9koefu
2013-04-18 11:24:05 +02:00
Cedric Snauwaert b8d99e7aa3 [FIX]sale: fix workflow problem when deleting an invoice the workflow should go to invoice_exception state
bzr revid: csn@openerp.com-20130418090011-dyg175mvwrp8ilij
2013-04-18 11:00:11 +02:00
Launchpad Translations on behalf of openerp 56b5446431 Launchpad automatic translations update.
bzr revid: launchpad_translations_on_behalf_of_openerp-20130417055748-w9lnddgiwwvrfpbl
bzr revid: launchpad_translations_on_behalf_of_openerp-20130418060606-6hezu76yxwsqgc11
2013-04-18 06:06:06 +00:00
Olivier Dony d279819af7 [FIX] stock, multicompany: avoid crashing when computing inventory levels and no warehouse/locations exists for a company
This is a cherry-pick backport of the trunk fix for bug 921561,
originally merged in trunk at revid fp@openerp.com-20130224101111-zz5n34c5fmr4n8jt

lp bug: https://launchpad.net/bugs/921561 fixed

bzr revid: odo@openerp.com-20130417132021-pmf0cdvwaxrsx9ew
2013-04-17 15:20:21 +02:00
Launchpad Translations on behalf of openerp dcd398d33e Launchpad automatic translations update.
bzr revid: launchpad_translations_on_behalf_of_openerp-20130418060603-ondw9hx00c1rmh33
2013-04-18 06:06:03 +00:00
Stephane Wirtel 600513f09f [FIX] account: avoid a crash if the user does not select an existing chart.
bzr revid: stw@openerp.com-20130417145829-0juk1t6ikbcts7v8
2013-04-17 16:58:29 +02:00
Quentin (OpenERP) 51d5126fee [FIX] purchase, usability: removed default search that was hiding the RFQ's Sent
bzr revid: qdp-launchpad@openerp.com-20130417100049-r9kdsp9wyj3l58pp
2013-04-17 12:00:49 +02:00
Quentin (OpenERP) ec55a58c45 [IMP] crm: log a meeting now calls message_post and writes the meeting information in the chatter
bzr revid: qdp-launchpad@openerp.com-20130417090925-l6pdm9v5lq6ify14
2013-04-17 11:09:25 +02:00
Olivier Dony 96dd64e31f [REVERT] mail: undo model-level change that can cause issue for stable deployments
Failing to force a manual update of the mail module would cause
all composer wizards to display html contents without the WYSIWYG
editor, making it mostly unusable for regular users. Users are
not expected to always force an update of all modules after
updating to the latest source code.

bzr revid: odo@openerp.com-20130417081410-dwc33ymizlihvbng
2013-04-17 10:14:10 +02:00
Olivier Dony f6152a63e1 [MERGE] auth_signup: upon signup of new user, the company_id[s] of the corresponding partner must be used
The default was to use those of the template user,
which may not be correct in multi-company cases.

bzr revid: odo@openerp.com-20130417073311-pu18cwlus10ypw8b
2013-04-17 09:33:11 +02:00
Launchpad Translations on behalf of openerp f203d2426b Launchpad automatic translations update.
bzr revid: launchpad_translations_on_behalf_of_openerp-20130417055707-rpdalm7k5efoagz6
bzr revid: launchpad_translations_on_behalf_of_openerp-20130417055742-p9nxg3t2tb0553wn
2013-04-17 05:57:42 +00:00
Xavier Morel c19bc50648 [FIX] ids of deleted records living in shared dataset when clicking on list row
When a record is activated, the listview will do some jiggling around
assigning the ids of internal dataset to the one shared between all
views, this is mostly for the case where one switches from a "grouped"
list view, so the form view only cycles on the "current" group.

Problem is, that internal dataset is not correctly synchronized with
the shared one, so when the id is removed from the shared dataset it
is *not* removed from the internal one(s), and when the switch is made
the ids from the internal dataset are set on the shared one and
reintroduce the deleted record, leading to the form view's incorrect
state.

Fix the issue by updating the dataset's ids list when a record is
deleted from the records tree.

Also extracted some stuff from DataSetSearch's unlink callback so it
can be overridden and is more stable across datasets.

lp bug: https://launchpad.net/bugs/1161210 fixed

bzr revid: xmo@openerp.com-20130416152000-06dbwkgdb8zlf9pc
2013-04-16 17:20:00 +02:00
Cedric Snauwaert 0cae5cb047 [FIX]purchase: remove default filter that prevent to see quotations that have been sent but not yet validated
bzr revid: csn@openerp.com-20130416095622-gxmxb5gpfqgs30eh
2013-04-16 11:56:22 +02:00
Xavier Morel a455d6c2b2 [FIX] correctly handle group_by_no_leaf when no grouping applied
If there are no grouping field specified *but* group_by_no_leaf is
specified, should call read_group with no grouping fields: will
generate a single group (which can not be opened) for all of the
model.

Necessary for analysis views since individual "records" make no sense.

bzr revid: xmo@openerp.com-20130416092344-2pqog8f7xprn6hsh
2013-04-16 11:23:44 +02:00
Christophe Simonis d7b63202f3 [MERGE] [FIX] mail: mail composer: Use a text field instead of a html field
html fields are sanitized just before saving data into the database.
In the composer, this cause the sanitization of the templated
message (for mass mailing messages) before the rendering, forbidding
the use of templated html links.
The html of the message is sanitized by message_post()

bzr revid: chs@openerp.com-20130416083812-jvqeivfxhdr32djh
2013-04-16 10:38:12 +02:00
Stephane Wirtel 1a06d3d28f [MERGE] accounts: Load the charts of account from Apps whether those are not in
the local addons path.

bzr revid: stw@openerp.com-20130416080508-ujt54nh0n7bvtkl1
2013-04-16 10:05:08 +02:00
Cedric Snauwaert 6ca0770257 [REF]crm_lead, crm_meeting: minor changes to follow pep8 standard
bzr revid: csn@openerp.com-20130416074335-qx8c6f4fjueknjk9
2013-04-16 09:43:35 +02:00
Launchpad Translations on behalf of openerp e8e6f434f4 Launchpad automatic translations update.
bzr revid: launchpad_translations_on_behalf_of_openerp-20130416052741-3au0bx7ha7of6lzg
2013-04-16 05:27:41 +00:00
Olivier Dony 556e4e76c3 [FIX] l10n_ro: unique constraints on `vat` and `nrc` columns need to be updated for 7.0 model
With the 7.0 model all accounting-related fields are synchronized
from company to contacts (both are res.partner records), so the
unique check is not a trivial unique constraint. It must be updated
to use a *partial unique index* that applies only to "commercial
entities" and not to contacts. The condition for being a commercial
entity is "is_company is true or parent_id is NULL".
If companies have unique vat/nrc numbers, then their contacts
will be consistent because they are automatically synchronized,
so the uniqueness between contacts does not have to be checked.
(The auto-sync is performed by res.partner automatically and covered
by tests in the "base" module)

bzr revid: odo@openerp.com-20130415175258-l15meqin80sbhggu
2013-04-15 19:52:58 +02:00
Olivier Dony 05d0c3cb48 [FIX] auth_signup: upon signup of new user, the company_id[s] of the corresponding partner must be used
The default was to use those of the template user,
which may not be correct in multi-company cases.

bzr revid: odo@openerp.com-20130415173901-sevyy27244m6iks0
2013-04-15 19:39:01 +02:00
Stephane Wirtel f4d8ba79ec [MERGE] Upstream
bzr revid: stw@openerp.com-20130415154412-dyis8r4y48q8b1we
2013-04-15 17:44:12 +02:00
Thibault Delavallée 0110522b68 [FIX] project_issue, project_phase: fixed access rights on anonymous.
bzr revid: tde@openerp.com-20130415150107-0vny927te0m1ylsi
2013-04-15 17:01:07 +02:00
Quentin (OpenERP) 7c189942fe [MERGE] hr_recruitment: removal of group 'no one' on create_date field in tree view
bzr revid: qdp-launchpad@openerp.com-20130415152901-b3e66wetgbsuy166
2013-04-15 17:29:01 +02:00
Quentin (OpenERP) 273a82cc0d [FIX] hr: typo in welcome message + [IMP] hr_holidays: better message when a constraint is fired
bzr revid: qdp-launchpad@openerp.com-20130415150655-ltlkfqy03jj1xgxa
2013-04-15 17:06:55 +02:00
Cedric Snauwaert e38a28a2b7 [FIX]crm_lead, crm_meeting: when creating a meeting from an opportunity, add a message in open chatter
bzr revid: csn@openerp.com-20130415141507-m5arvgjcaf587a09
2013-04-15 16:15:07 +02:00
Christophe Matthieu e07cf38910 [FIX] web_kanban: hide the counter on the top of column to display option drop down when the mouse is hover.
bzr revid: chm@openerp.com-20130415114545-e557dsr4y0qkh8ff
2013-04-15 13:45:45 +02:00