Commit Graph

281 Commits

Author SHA1 Message Date
Martin Trigaux 4f5cc00420 Forward-port of latest saas-4, up to revision 5211 (revid fme@openerp.com-20140509164408-rtml4brrhpiv4zz9) 2014-05-12 10:05:23 +02:00
Thibault Delavallée 272b71b2a0 [MERGE] [FIX] res_partner: fixed bad display of address in form view in IE9.
lp bug: https://launchpad.net/bugs/1293523 fixed

bzr revid: tde@openerp.com-20140505145031-xgvti78aqspr5170
2014-05-05 16:50:31 +02:00
Antony Lesuisse 7e25b9ae55 [MERGE] saas-4 report_webkit missing dependency on report
bzr revid: al@openerp.com-20140501152604-4cobh5ui47dt4pem
bzr revid: al@openerp.com-20140501155633-gefnc3zqcsr2rhaz
bzr revid: al@openerp.com-20140501161156-4wbsvhh8gz4r22h3
2014-05-01 18:11:56 +02:00
Christophe Simonis e59aecca94 [MERGE] forward port of branch 7.0 up to revid 5288 mat@openerp.com-20140423150215-578nzug1glccvpwy
bzr revid: chs@openerp.com-20140424125338-26k5atvtqwmmfv4e
2014-04-24 14:53:38 +02:00
Denis Ledoux c6189d91a0 [FIX] base: in partner search view, use operator=child_of instead of filter_domain with a child_of domain
operator child_of has the advantage to do exact ID matching for many2one, and not just matching on the name

bzr revid: dle@openerp.com-20140422150736-o2t3eank6yqttlel
2014-04-22 17:07:36 +02:00
Darshan Kalola 37bf72aca5 [MERGE] [IMP] res_partner: correctly take the 'use parent address'
into account in the onchange. Slightly updated the view that was weird with this parameter.

bzr revid: tde@openerp.com-20140417145522-yte3976um2a1t0dr
2014-04-17 16:55:22 +02:00
Darshan Kalola (OpenERP) d75405572f [IMP]removed use_company_address method, added same feature in single method, to achive this added new parameter 'empty_fields' to empty all address field when use compny address is unchecked.
bzr revid: dka@tinyerp.com-20140417101219-gs68pfe64a7l97hc
2014-04-17 15:42:19 +05:30
Denis Ledoux 328ea17625 [REVERT] rev. 5097 jke@openerp.com-20140328154704-88nph9tlkd48kd1y: This field has been removed from the view because was suspected to be twice included in the view, while it isnt, this is a form view inside an other formview
bzr revid: dle@openerp.com-20140401092254-tyu2040tf90ijc49
2014-04-01 11:22:54 +02:00
Kersten Jeremy 2d0d198498 [TYPO] Remove duplicated field "supplier" from view view_partner_form
bzr revid: jke@openerp.com-20140328154704-88nph9tlkd48kd1y
2014-03-28 16:47:04 +01:00
Paramjit Singh Sahota 5de677208c [FIX] [saas-3/trunk] IE9: Bad display of the address on a contact attached to a company
lp bug: https://launchpad.net/bugs/1293523 fixed

bzr revid: psa@tinyerp.com-20140318093611-iis8wfuzgqclngnm
2014-03-18 15:06:11 +05:30
Martin Trigaux 8a3523cd97 [FIX] partner: backport of trunk revision 4882
When adding a new contact or a new company based from the partner form, use the customer value as default value (was doign it only for the supplier flag)

bzr revid: mat@openerp.com-20140311112341-9yoi1hf0ks98ju3r
2014-03-11 12:23:41 +01:00
Darshan Kalola (OpenERP) 75b6bbdda0 [MERGE]sync with trunk.
bzr revid: dka@tinyerp.com-20140207045417-8chx8psmp9ipp4na
2014-02-07 10:24:17 +05:30
jke-openerp 0d22b87f3a [FIX] Fix bug of positionning on res_partner form
bzr revid: jke@openerp.com-20140203163052-01m78wwe38974cf5
2014-02-03 17:30:52 +01:00
Darshan Kalola (OpenERP) 8c29e64c0c [MERGE]sync with trunk.
bzr revid: dka@tinyerp.com-20140124112237-997urh0yrlg34jsl
2014-01-24 16:52:37 +05:30
Denis Ledoux 9cede6794d [FIX]base: missing quote in domain of res_partner filter on name
bzr revid: dle@openerp.com-20131118155230-hvdm4yqu5fz3w5q4
2013-11-18 16:52:30 +01:00
Olivier Dony 06a3255576 [IMP] res_partner: default search field can be based on display_name + have email matching by default
This more closely matches the behavior of name_search,
until name_search is actually available in search views.

bzr revid: odo@openerp.com-20131028155600-1dwd35sjht2of63m
2013-10-28 16:56:00 +01:00
Darshan Kalola (OpenERP) 2868f916c5 [IMP]improve attrs on use_parent_address.
bzr revid: dka@tinyerp.com-20130927123020-nk04nr8o621xw31b
2013-09-27 18:00:20 +05:30
Darshan Kalola (OpenERP) 8fdc129f56 [IMP]Improve onchange behave with seperate onchange method for use parent address.
bzr revid: dka@tinyerp.com-20130924105203-6nq2755rdfscs6kb
2013-09-24 16:22:03 +05:30
Darshan Kalola be4aba7d8f [IMP]improve onchange behaviour when creating partner or contact
bzr revid: darshankalola@gmail.com-20130819084304-5jxrvmu8on3fzm2j
2013-08-19 14:13:04 +05:30
Thibault Delavallée 45780c147d [IMP] Partner View Improvement: remove history tab.
This server branch comes with an addons branch where the various
items of the history tab are removed and transformed into
contextual buttons.
Names are added to two pages of the partner notebook to be able
to reference them in future inheritance.

bzr revid: tde@openerp.com-20130614120540-5qvvh07cu2quwi71
2013-06-14 14:05:40 +02:00
Christophe Simonis a61e7cb0c8 [MERGE] forward port of branch saas-1 up to revid 4887 chs@openerp.com-20130612153934-qyp6pb3bc4za4taf
bzr revid: chs@openerp.com-20130613172414-dln3g4j0ykcwaa02
bzr revid: chs@openerp.com-20130613173900-xl7rh321nnw2b04b
2013-06-13 19:39:00 +02:00
Christophe Simonis 6f170ec732 [MERGE] forward port of branch 7.0 up to revid 5006 chs@openerp.com-20130612151912-m19okjsdkjo12qnt
bzr revid: chs@openerp.com-20130612152826-j9sj42ten9mic8s0
2013-06-12 17:28:26 +02:00
Olivier Dony 74e0201356 [MERGE] OPW 590300: make some action help texts consistent with the rest of the system
The policy is to have a one-line paragraph with
class `oe_view_nocontent_create` that directs the
user to the create button. There are exceptions
when the action is not supposed to be used to
create new records, in which case the help
text should indicate so.

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

bzr revid: odo@openerp.com-20130607162045-7di6r2fllm6k988x
2013-06-07 18:20:45 +02:00
Thibault Delavallée b545e866b1 [MERGE] Sync with trunk
bzr revid: tde@openerp.com-20130604134405-byfc98qwgyeoufrl
2013-06-04 15:44:05 +02:00
Vo Minh Thu 048b365aff [FIX] renamed Partner Catgories to Partner Tags.
bzr revid: vmt@openerp.com-20130604124003-bpga8k6lq4s7qlvp
2013-06-04 14:40:03 +02:00
Thibault Delavallée 4de42dc5a8 [MERGE] Sync with trunk
bzr revid: chm@openerp.com-20130415133654-l5b7zvga6mrv8bs3
bzr revid: tde@openerp.com-20130515082426-93tdl16rtm2kfz3a
bzr revid: tde@openerp.com-20130523133300-1el48hf8sotnvz62
2013-05-23 15:33:00 +02:00
Nimesh Contractor (OpenERP) b2c84a8310 [IMP] when create company form supplier it should be supplier by default, same for the customer and when both the company should be both customer and supplier.
bzr revid: nco@tinyerp.com-20130523052403-lk8e1ghfglwtavg5
2013-05-23 10:54:03 +05:30
Nimesh Contractor (OpenERP) be683318ef [MERGE] lp:~openerp-dev/openobject-server/trunk-bug-1128656-nco, supplier contact should be the suppier by default.
bzr revid: nco@tinyerp.com-20130523050632-bujvgr6j1lhj2or3
2013-05-23 10:36:32 +05:30
Nimesh Contractor (OpenERP) d0236bd31e [FIX] set defalut customer and add field customer to store value of customer.
bzr revid: nco@tinyerp.com-20130515075140-dql9dhnygtgi7319
2013-05-15 13:21:40 +05:30
Olivier Dony ffebb64472 [MERGE] Forward-port of 7.0 fixes up to rev. 4961
rev-id odo@openerp.com-20130425171238-dhgpqbi9nio12vxk

bzr revid: odo@openerp.com-20130424131936-5eb7omkz51arnm81
bzr revid: odo@openerp.com-20130425171444-ycu89d2393f8nnxm
2013-04-25 19:14:44 +02:00
Olivier Dony c8e8860d08 [FIX] res.partner: make use_parent_address field visible if set, even if parent is missing
This should not be needed but in the initial 7.0 branch
the default for use_parent_address was True so it was
set even on partners that had no parent company.
Now that the fields are read-only when that option
is enabled, it makes the address impossible to
edit. At least by making it visible we give the
user the opportunity of fixing it manually.

Can also be fixed at once with a single SQL
query:
UPDATE res_partner set use_parent_address = false
       WHERE parent_id IS NULL;

bzr revid: odo@openerp.com-20130425163916-ou7jjr6xbopfwvrc
2013-04-25 18:39:16 +02:00
Christophe Simonis 261dea6fec [MERGE] forward port of server v7 up to revision 4954
bzr revid: qdp-launchpad@openerp.com-20130422093655-txqmbalod6qmw1s6
bzr revid: chs@openerp.com-20130423183723-9kiexdyzdew8iuzm
2013-04-23 20:37:23 +02:00
Olivier Dony 16b38a053a [FIX] res.partner: fix invisible attrs on Contacts tab, empty o2m field results in `[]`, not `False`
bzr revid: odo@openerp.com-20130420004713-0cblmquf4t6i2n0r
2013-04-20 02:47:13 +02:00
Olivier Dony 06cd0a1c7f [FIX] res.partner: avoid hiding `parent_id` and `child_ids` fields if they are set, irregardless of the rest of the `is_company` flag
This prevents hiding real data and also allows creating more
complex/flexible structures by setting the values of these
fields before or after setting is_company, to reach the
desired result.

bzr revid: odo@openerp.com-20130416093403-9m484d30qqq5ab8l
2013-04-16 11:34:03 +02:00
Olivier Dony 2c6d69e0f1 [FIX] res.partner: propagate `is_supplier` property when creating parent or child partner for a supplier
This is not necessary for the `is_customer` flag, as it is
always True by default (customers are created more frequently).
Passing the field value via an invisible field in the mini
contact form is necessary because context `default_*` values are
automatically discarded by the ORM when creating o2m
or m2m records (as they are supposed to apply to a different model).

bzr revid: odo@openerp.com-20130416091027-y7iwvpjhowg53lry
2013-04-16 11:10:27 +02:00
Olivier Dony f985391ba0 [MERGE] Sync with 7.0
bzr revid: odo@openerp.com-20130415181836-cmq936wu0w7alwky
2013-04-15 20:18:36 +02:00
Olivier Dony 59fe76f24c [FIX] res.partner form: switch default `use_parent_address` to False in kanban contact too, replace by defaults for address fields
We should never turn the `use_parent_address` option on
unless the user explicitly wants to use it. It makes
further editing more convoluted (need to go to the
company address) and is really an advanced feature.

It was only set by via context defaults when adding
contacts to a company ; we can replace that with a
set of defaults that will copy the company address
fields to the contact. Users can still switch to
automatic synchronization if they really want it,
or simply further edit the address of the contact.

Also fixed the layout of the mini-form view, now
using a simpler vertical layout with address at
bottom, since the main info of a contact needs
to be entered first.

bzr revid: odo@openerp.com-20130410170101-t9covdj6nmyn44jf
2013-04-10 19:01:01 +02:00
Olivier Dony 5a222c8f90 [FIX] res.partner form view: remove now useless oe_inline class so `company` field can take 100% width of parent div
bzr revid: odo@openerp.com-20130410154242-kkgrthb5cb11d49d
2013-04-10 17:42:42 +02:00
Christophe Matthieu a1f1782cc0 [IMP] res_partner, res_users: small change in views
bzr revid: chm@openerp.com-20130410130145-qhtvhx6lrl3gt3x5
2013-04-10 15:01:45 +02:00
Fabien Meghazi 74997ff408 [IMP] res.partner form view, autofocus Contact notebook/page on visibility change
bzr revid: fme@openerp.com-20130409122954-mkene266qvcfe6nr
2013-04-09 14:29:54 +02:00
Quentin (OpenERP) 70fbc25d93 [IMP] base, res_partner and contacts management: improve usability and user experience.
1) whennever a contact is created from a parent record: allow to set a dedicated address
2) move the use_parent_address field near the address

bzr revid: qdp-launchpad@openerp.com-20130408155934-bk2apzq1gcktqr6m
2013-04-08 17:59:34 +02:00
Olivier Dony 2bf1034cd2 [FIX] res.partner: autosync of commercial fields and address fields + correct views accordingly + basic tests
* Commercial fields (bug 1160365)

Fix autosync of accounting/invoicing-related fields on contacts,
just as if they were actually modeled as fields.related to the
parent commercial entity.
This starts with the addition of the new functional field
`commercial_id`, to locate the commercial entity for any partner.
The commercial entity is defined as the first ancestor (starting
at the partner itself) that is either marked `is_company` or has
no parent. [This is Part A of the solution on bug 1160365].

Then, whenever a partner is created or modified:
- if it is a commercial entity, the commercial fields are synced
downstream to all its descendants, stopping at company boundaries.
- if is is not a commercial entity, the commercial fields are
synced from its parent commercial entity.
The list of fields to sync is determined by calling the new
res.partner method `_commercial_fields()` which can be easily
extended by any module that adds commercial fields on res.partner.
A utility method `open_commercial_entity()` was added to
res.partner to make it easy to include a button for editing the
parent commercial entity, to be displayed instead of now-hidden
commercial fields.
[This is part B of the solution on bug 1160365]

The res.partner.address_get() method (used to find child partners
of certain types, e.g. "invoice") was udpated to take the new
"commercial entity" notion into account: it will now look for
matches in children but also parents and siblings that are part
of the same "commercial entity". The default partner `type` is
now "contact" to reflect the new model ; "default" is
inappropriate because it is a wildcard and would stop the type
lookup early.
[This composes parts C and D of the solution on bug 1160365]

Note: This fix comes with a matching addons fix to implement
module-specific extensions of part B, as well as part E of the
solution.


* Address fields (bug 1160425)

Corrected autosync of address fields is also included in the
same branch, because those two mechanisms are closely related
and share some parts of the implementation.

The `use_parent_address` field now defaults to False (except
in the mini-kanban view of contacts on a partner form), and
the autosync of address fields has been modified to only work
downstream and never update a parent company if a child contact
is modified. Instead, the address fields are now displayed
readonly on contacts that use the parent address, with a button
to edit the parent address (new method open_parent(), similar
to open_commercial_entity() but opening the direct parent).

To make the initial creation of a contact + company pair,
a special case was added: when a new contact is created for
a company that has no other contact and no address, the
address of the contact is assumed to be that of the company
so it is moved to the company, then the `use_parent_address`
flag is enabled on the contact, and the `is_company` flag on
the company. This covers a use case where contact and
company are created on-the-fly when creating a new document.

Many logical flaws in the autosync of address fields have been
corrected and are now covered by unit tests.


* Misc related fixes

- checking `is_company` does not reset the parent_id field
anymore, to allow for multi-level structures. The field is
still hidden automatically because having an empty "Company"
field on the form view of a company is quite suprising), but
this UI behavior is easily customized;
- the `email`, `phone`, `fax`, `mobile`, `lang`, etc. that
were sometimes synced when changing parent company are now
properly left alone;
- the `use_parent_address` field is now always visible next
to the parent_id field when a parent is set

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

bzr revid: odo@openerp.com-20130408013742-tm8w0w0nmunanokk
2013-04-08 03:37:42 +02:00
Thibault Delavallée 2ab15ddeaf [MERGE] Sync with trunk.
bzr revid: tde@openerp.com-20130405110750-1dd4y02xz3wb6ill
bzr revid: tde@openerp.com-20130405133237-n7k66b3w0b3a17o3
2013-04-05 15:32:37 +02:00
Vo Minh Thu 307ca374d6 [MERGE] forward merge 7.0 until revision 4919.
bzr revid: vmt@openerp.com-20130404130704-24vsmczw34cssytd
2013-04-04 15:07:04 +02:00
Thibault Delavallée bef293af4b [IMP] res_partner: customers is now sequence 2, because salesteam will be 1.
bzr revid: tde@openerp.com-20130404115719-glq8uqgvyvhm0ukd
2013-04-04 13:57:19 +02:00
Christophe Matthieu a423e08fee [IMP] res_partner: remove has_user_ids
bzr revid: chm@openerp.com-20130402082052-99wun0xuf6g4heh4
2013-04-02 10:20:52 +02:00
Christophe Matthieu 0cf0cf4f4c [IMP] res_users,res_partner: login = email
bzr revid: chm@openerp.com-20130326130127-974jagzvhon0biiy
2013-03-26 14:01:27 +01:00
Ravish (Open ERP) 5d4b0d3a62 [IMP]applied arrow to the specified form
bzr revid: rmu@tinyerp.com-20130322101430-hwkp4m97vst5ii8n
2013-03-22 15:44:30 +05:30
Christophe Matthieu b860c00593 [IMP] res_partner: remove help for quick create of user_id
bzr revid: chm@openerp.com-20130304130632-ym2iax2b3p89ifn3
2013-03-04 14:06:32 +01:00
Christophe Matthieu a90ef98704 [MERGE] from trunk
bzr revid: chm@openerp.com-20130226105813-1mi6tg4h7460vyj2
2013-02-26 11:58:13 +01:00