Commit Graph
128 Commits
Author SHA1 Message Date
Jérémy Hennecart 054fb95d73 [IMP] crm: remove default PLS fields
The purpose is to ease the onboarding for the default CRM settings.
Now, we do not include any field by default and tags become an option
in the choice of fields apply to the computation.

task-2196200

closes odoo/odoo#48124

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-11-05 11:07:11 +00:00
Thibault Delavallée 5f37bad75d [FIX] crm: remove unnecessary warning in phone format
In this commit we remove the warning logger when not being able to format
a phone number. Indeed this does not indicate there was a real issue.
It simply indicates that either the phone number is not parsable or not
matching given country format.

It happens in a lot of situation that phone numbers are not valid: bad
encoding, country mismatch due to {lead, task, ticket} / partner not always
being the same, ... This should not raise a server warning.

When using frontend SMS composer for phone number, a warning is displayed
to the user telling the number is probably incorrect. This is considered
as sufficient from UX point of view as it warns users. We do not think
we should warn admins that some data is incoherent in database.

This commit also

  * Revert "[FIX] crm: avoid linking demo leads with an unrelated partner"
    This reverts commit 2c94c4c81ffa171158586cd64828d27c537cd1d6
    -> having "invalid" data should be a valid use case of real life

  * Revert "[FIX] crm: get correct country for phone validation"
    This reverts commit a58f9fc154c038d72031b281e2bec2c0fc2915ba
    -> country of a lead comes from its partner if set but can be different.
    Same for phone numbers. Values on a lead after a compute are considered
    as complete. Sales persons could effectively have incoherent data on their
    form view but that is the result of what has been encoded.

Task ID-2325228

X-original-commit: cecc4ca6f02e599e193c3fa688bfcbd02ac0580b
2020-09-28 10:12:23 +00:00
Christophe Simonis f726ad6898 [FIX] crm: avoid linking demo leads with an unrelated partner
Using this partner will copy his phone number on the lead.
However, the lead and the partner don't have the same country, which
will lead to ad invalid phone number (for the lead country).

It avoids a warning emitted by the `phone_validator` module, while
browsing the lead.

closes odoo/odoo#58352

X-original-commit: 2c94c4c81ffa171158586cd64828d27c537cd1d6
Signed-off-by: Christophe Simonis <chs@odoo.com>
2020-09-23 13:45:05 +00:00
David Beguin 1938552782 [IMP] crm: Disable pls cron and autoincrement frequencies when won/lost
Purpose
=======

Get rid of the cron.
Always have an up to date frequency table to compute lead probability.
Clean PLS code and ensure to remove unnecessary code

Specifications
==============

Disable the cron:
- Increment won and lost count for lead PLS params from frequency table at
  each won/lost
- The complete set of leads won't be recomputed anymore every day
- A lead probability will only be recomputed if one of the PLS parameter will
  be modified (stage_id, team_id + the ones checked in settings)
- No more onboarding phase : as frequency table is always up to date and only
  the modified leads are recomputed, we can drop this. (So even on onboarding,
  winning or losing a lead won't impact other leads, except the ones we modify
  manually afterwards)
- Add an button to force the recompute of all the lead probabilities
  (kind of reset) in the settings.

The cron has been disabled by default.
Users can know choose to reactivate it if they want to continue updating their
lead probabilities on a daily basis.

Code have been reorganised for better structure and understanding.
Some code parts have been factorised to be usable in both Live Increment and
Full Rebuild mode.

In this commit, we also update probabilities using only computes

Before this commit, _update_probability was called during write and create,
to ensure both probability and automated_probability were correct. That was
necessary because of onchanges and readonly field (automated_probability
was not given to the write method while saving after a change on the lead).

After this commit, we use the force_save tag on the readonly field
automated_probability. So we ensure that write always receives the new
automated_probability value and everything can be handled directly by the
compute. Also, we force the lead to start in automated probability mode.
So when creating a new lead, both probability and automated probability are
computed and aligned.
Finally, when winning a lead, we ensure that both probabilities are aligned
(=100), so that if user take the lead back to a previous stage, the
probabilities are correctly recomputed, and the lead will not be stuck to
100%.

Also, this commit applies some fix and minor changes listed here under:
- Ensure to have always positive frequencies
- Fix lost counts for team not set in pls computation
- optimise set_won : write only once per values

Finally, include tag in frequency table even if less than 50 occurences:

Due to refactoring in which we increment frequency table at each won/lost
instead of rebuilding the frequency table each day, the tags are never added
in frequency table.
This is due to the 50 occurence conditions that avoid to create the frequency
if we have less than 50 won or lost for a tag.

After this commit, we include the tag_ids in the frequency table, no matter
the number of occurences. But, during the PLS computation, we skip the tag
frequencies if the number of occurences for this tag is under 50.
This allows to have a complete vision on the tag frequencies, even for
small number of occurences.

Task ID : 2254543

X-original-commit: cd291b79eb2d2df80899867263ec71438ab8fe87
2020-09-14 15:54:27 +00:00
Dharmraj Jhala 610ba98539 [FIX] mail, crm: do not display body in creation message when having a subtype
Right now on few business objects (like leads, invoices, tasks, helpdesk
tickets etc) creation message contains
  * subtype description;
  * generic creation message;

This looks like multiple creation message on chatter after creation of the
record as you generally have "Task Created - Task created" (subtype description
then generic message).

This happens when we provide custom subtype on creation by by overriding
`_creation_subtype` method.

This commit fixes the issue by only using provided creation subtype and
removing default body. If creation subtype is not provided default creation
message is posted as before.

In this commit we also fix subtype for Lead/Opportunity creation and make
it generic ('Lead/Opportunity created') to avoid inconsistent behavior.

Finally some cleaning is made in method naming. Semi followup of 92e9e84b63

LINKS

Task ID-2288458
PR odoo/odoo#56631
PR odoo/enterprise#12707

closes odoo/odoo#56688

X-original-commit: 2ebbeb4b5443c6405dd9a3b202a1eee9c5c67ebb
Related: odoo/enterprise#12728
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-08-28 07:59:24 +00:00
Patrick Hoste a54f3852d6 [IMP] crm: add recurring revenues feature
PURPOSE

Allow users to configure contract recurrences and Monthly Recurring Revenues
on Opportunities they're trying to close. One short revenues are not sufficient
to cover real life use cases of CRM revenu analysis.

SPECIFICATIONS

Adds an option in the settings to activate the recurring revenue feature.
This feature is set on an opportunity to indicate a revenue that could be
perceived over time. This time indicator is set by the crm.recurring.plan
model in which the number of months is determined.

By default some plans are added in data. When using plans, revenues are
computed across the plan months.

LINKS

Task ID-2283052
odoo/odoo#54194
odoo/enterprise#12423
odoo/upgrade#1463

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-08-14 12:59:30 +00:00
Patrick Hoste 8066ab4348 [REF] crm: update revenue fields names
PURPOSE

Link field name with their content.

SPECIFICATIONS

This commit changes the field name "expected_revenue" into "prorated_revenue"
and the field name "planned_revenue" into "expected_revenue".

Indeed content of those fields evolved since their first naming. Their content
is not what the field name indicates. Better rename those fields to understand
code flow inside CRM.

LINKS

Task ID-2283052
odoo/odoo#54194
odoo/enterprise#12423
odoo/upgrade#1463
2020-08-14 12:59:27 +00:00
Anousone Phaysomphot ac00b8030f [IMP] crm: add new digest tips
PURPOSE

Review the tips and digest layout design to make sure they have a WOW effect
and increase trial conversion/retention.

SPECIFICATIONS

“Did you know Odoo has built-in lead mining?”
“Opportunity win rate is predicted with AI”
“Manage your pipeline”
“Do not waste time recording user's data”
“Turn a selection of opportunities into a map”

See code for specifications.

LINKS

Task ID-2274264
COM PR: odoo/odoo#53580
ENT PR: odoo/enterprise#1139

X-original-commit: 93c7aa19397ae7a25e88e760f44d24a0b4f0dd9a
2020-08-12 12:22:59 +00:00
Lavish Chhatwani c5d98aeccb [FIX] crm: set 'info' alias to default data salesteam
This commit sets 'info' alias on the default sales team and sets 'admin' as a
default user for the same. After a long debate on default alias configuration
"it will work on SaaS and other people will be careful when deploying" won.

Task ID-2284840

closes odoo/odoo#54943

X-original-commit: 46d616643ba684596b709cd7e65536781dfa5d51
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-07-27 08:03:42 +00:00
Elisabeth DickinsonandThibault Delavallée 2503a66c42 [IMP] crm: make tips bioutifoul, and add moar tips
PURPOSE

Make digest email and tips more appealing. The goals of these tips are

  * to encourage the adoption of other apps (Did you know ?);
  * to make Odoo look more fun (Fun tips and tricks, young and dynamic style);
  * to show social proof and increase trust (emphasis on already existing
    projects / customers to);

SPECIFICATIONS

Improve existing tips to be more inlined with new digest styling.

Add new tips, notably

  * use lead enrichment;
  * use lead mining;

LINKS

Task ID 2197417
PR odoo/odoo#51619

Co-Authored-By: Elisabeth Dickinson <edi@odoo.com>
Co-Authored-By: Thibault Delavallée <tde@odoo.com>
2020-06-04 15:20:14 +00:00
Thibault Delavallée bc86d8c57d [IMP] crm: lint data and menu entries
PURPOSE

Prepare enhancements of sales team membership.

SPECIFICATIONS

Lint crm data and demo, notably about sales team and file organization.
Also move crm menu entries declaration in a single file and remove some
menu entries not imported anymore.

LINKS

Task ID 2086889 (sales team enhancements)
Task ID 2234698 (preparation lint)
Community PR odoo/odoo#49520
2020-04-14 11:52:46 +00:00
Rémy Baranx (bar) fd4798195d [IMP] crm, sales: add crm tags on sale orders
As the crm.lead.tags model shall be used in CRM and/or Sales apps,
it has been moved to the sales_team module, which is a depedency
of the CRM and Sales apps.

As these tags becomes more generic than just "lead tags", the model
has been renamed from crm.lead.tags to crm.tags.

Tags on sale orders were already present but not visible. They are
now visible in the "Other Info" section, and optionally in sale order
tree views.

When a quotation is created from an opportunity (CRM app), existing tags
are populated from the opportunity to the sale order (Sales app).

Views and demo data of several modules have been updated accordingly.

Task ID 2191276
2020-03-23 09:08:47 +00:00
Thibault Delavallée b1037eb2d1 [IMP] digest, various: add name on tips to ease their understanding
PURPOSE

Ease edition of digest tips by adding a name.

SPECIFICATIONS

Add a name on digest tips. Even if technical and not send to customers it
allows to see them at a glance in list view without having to guess their
content.

LINKS

Task ID 2214325
Com PR odoo/odoo#47416

Related: odoo/upgrade#933
Related: odoo/enterprise#9167
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-03-11 16:24:32 +00:00
Krupal Oza 6f1ec915cf [FIX] crm: fix demo data
Purpose: Replace user's role by partner in the chatter of lead.

Currently the discussion in the chatter of the lead is incorrect as both
are users.The message is sent by user to demo user instead of partner.

This commit fixes the behavior by setting the author of mail message to
partner instead of user and if there is no partner selected then the message
is sent by the contact email.

Task 2180228

closes odoo/odoo#44253

Closes: https://github.com/odoo/odoo/pull/44253
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-03-04 12:31:06 +00:00
Jérémy Hennecart bf1e3a6cf3 [IMP] crm: update demo data for utm fields
Update demo data on leads to make more senses
with the utm fields, tags and the lead itself.

task-2189667

closes odoo/odoo#44832

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-02-13 08:11:50 +00:00
Victor Feyens d4e0fe018d [IMP] *: use ref= instead of eval="ref(' in xml field tags.
* Code cleanup
* Avoid a safe evaluation of the field value when loading those records.

closes odoo/odoo#44883

Related: odoo/enterprise#8283
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2020-02-11 13:07:06 +00:00
Hiral Bhavsar 4c06e4f893 [IMP] crm: add demo mail template
Add new activity type 'Email with Template' for demo purpose and add a mail
template for it.

task-1887986

closes odoo/odoo#38944

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-01-07 11:10:41 +00:00
Kevin Baptiste 6cbe824871 [REV] web: reverts update to fontawesome 5.11.2
This reverts commit ff1c35513a.

closes odoo/odoo#41480

X-original-commit: 116057b26e71db4692280463669f3e80d813ddcc
Related: odoo/enterprise#7110
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-12-09 10:33:36 +00:00
Kevin Baptiste ff1c35513a [IMP] web: update to fontawesome 4.7.0 to 5.11.2
FontAwesome 5 introduced new names for some icons as described on
https://fontawesome.com/how-to-use/on-the-web/setup/upgrading-from-version-4#name-changes

This commit replaces the old names to the new ones.

closes odoo/odoo#35826

Taskid: 2050241
Related: odoo/enterprise#5180
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-11-28 10:05:12 +00:00
David Beguin a07324af17 [IMP] crm : add PLS rebuild threshold for onboarding purpose
When there are only few leads, marking a lead as won or lost changes
a lot the won/lost repartition. For onboarding purpose, the cron is launched
if the threshold PLS config param is not reached.
When the number of lead in the database reaches the PLS threshold,
the config parameter is set to 0 to avoid the useless check
of the number of lead in the dabase in the future

Task ID: 2044539
PR #37413
2019-09-25 14:42:31 +00:00
David Beguin da87a63d63 [FIX-IMP] crm : remove probability default value and modify default pls start date
This commit
- removes probability default value in order to activate
  Bayes predictive lead scoring by default
- set the default pls start date to today - 8 days
  to include all demo data in PLS computation

Task ID: 2044539
PR #37413
2019-09-25 14:42:31 +00:00
David Beguin cd72fd9a3f [FIX] crm : fix and add data for pls settings and use null value instead of empty for phone and email state fields
This commit applies multiples things:
- Fix PLS settings that were not loaded correctly (was not using technical field names)
- Add data for PLS settings to check all optional fields and set the start date.
- use null value instead of empty for phone and email state fields to lessen the DB storage
- set pls start date required

Task ID: 2044539
PR #37413
2019-09-25 14:42:31 +00:00
Yannick Tivisse dea1add336 [FIX] crm: Harmonize some demo data 2019-09-23 09:03:44 +00:00
Florent Lejoly 4aa1749699 [IMP] crm: improve stage messages, some strings and fix some typos
As part of the back2basics, the stage messages were modified to be clearer

* when an opportunity is lost previously 2 separated messages where
created in the chatter (one for the reason, one for the active state)
now, one message is created with both infos;
* new message when an opportunity is restored;

There where also some fixes to typos, and an the probability of a lead
to be successful received a new title "estimated by Odoo".

Task 2026297

closes odoo/odoo#35308

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-08-22 09:17:42 +00:00
David Beguin 3977e28baf [MOV-IMP] crm : move crm.lead.lang_id from enterprise to community
Since introduction of website_visitor,
we don't need to identifiy the lead with a lead_id cookie.
The visitor is identified and if a lead is created with the
contact form, the lead is created and linked to the visitor.

To avoid losing data, each time a visitor send a contact form,
it creates a new lead. All those leads are linked between them
via the website_visitor.

As the website_visitor already has the lang set on itself,
there is no reason to keep the lang_id of crm_lead at enterprise
side. So that lang_id on crm.lead has been moved to community.

This commit is directly linked to another one in enterprise
See https://github.com/odoo/enterprise/pull/4834 to get more details.

Task ID : 2028059
PR #34624
2019-08-19 06:34:20 +00:00
qmo-odoo 0d2be38333 [IMP] crm,sale,*: Improve UX
This commit improves the ux in CRM by changing a few things:
  - Restore the use_leads and use_quotations fields
    along with their features as they were in 12.0.
  - Hide the email alias if use_upportunities and use_leads
    are unchecked.
  - Show a link to the general settings instead of the alias_domain
    if no alias_domain has been configured.
  - fixes the "unassigned lead(s)" link so that
    it redirects the user to the actually unassigned leads

Task: #1962182
PR: #32372
2019-07-30 11:46:30 +00:00
David Beguin e20cc70d08 [IMP] crm : add and apply Predictive Lead Scoring
This new Predictive Lead Scoring (aka PLS) replaces the stage based probability mechanism.
It uses Naive Bayes probability computation theorem.

The lead probability is now computated automatically based on multiple criteria (= frequency fields).
Some are mandatory and will always be used, some are optional and can be activated
in the settings.
- Mandatory fields :
    - team_id
    - stage_id
    - tag_ids

- Optional fields :
    - email_state (validity of the email_from field: correct / incorrect or empty if email_from is empty)
    - phone_state (validity of the phone field !! not the mobile one !!: correct / incorrect or empty if phone is empty)
    - country_id
    - state_id
    - source_id (UTM Source)

PLS uses a start date to consider only the lead created after that date to generate the frequency table
and to recompute the lead probability. This date is also configurable in the CRM settings.
Default start date is date.todays() (at module install).

The settings for PLS are NOT company related :
PLS Fields = Many2many to a model that store only the fields allowed for PLS computation.
PLS Start Date = Date
As Date and Many2many fields are not allowed for config_parameters,
Char fields are used to store the configuration
and Date and m2m fields are used to ease the configuration by the user in the config panel.
Date and m2m fields are both computed fields based on their corresponding Char fields.
Char field for Date store a strigified date.
char field for Many2many store a comma separated string which is a list of activated fields.

Each mandatory field is used in a specific way
- Team_id : the frequency table is split for every team_id, plus once for leads that don't have a team_id.
Considering Lead A from Team 1 and Lead B from Team 2.
Even if Lead A and Lead B have the exact same attributes (country, phone, email,stage, ...),
their probability will most likely not be the same.
That's because each teams compute their leads' probability based on their own won/lost leads.

- Stage_id : if no optional fields are activated and if there is no tag on the lead,
this will make PLS work quite the same way as it was working with removed stage based probability,
as only the stage will count in the computation.
But here, instead of fixing manually the probability for each stage,
this stage related probability is automatically computed based on past experience (won and lost leads).

- Tag_ids : each tag is considered separatelly, as if the lead had only one tag.
(no link between tag on same lead is made). To avoid that a tag take to much importance if his subset is too
small, we include the tag frequencies in the frequency table only if at least 50 won or lost leads had this tag.

The frequency table is a table where all won and lost leads are aggregated by fields
(mandatory or optional if activated). For each team_id / field couple, we store the number of
won and lost leads that has that fields values.
For example: Lead A is assigned to team 1 and client comes from France and has been won.
If we consider only this lead A, the frequency table will looks like :
   id   |  variable   | value | won_count | lost_count | team_id
--------+-------------+-------+-----------+------------+---------
    1     country_id     FR         1           0            1

To computed the probability of a lead, we get all the records for the frequency table
that match all fields (per team_id) and we compute a won score and a lost score.
The probability is computed and normalized based on those scores
- P = S(Won) / (S(Won) + S(Lost))

Considering two variables A and B :
- S(Won) ∝ P(A∩B | Won)*P(Won) = P(A|Won) * P(B|Won) * P(Won)
- S(Lost) ∝ P(A∩B | Lost)*P(Lost) = P(A|Lost) * P(B|Lost) * P(Lost)

To overcome the 'zero frequency problem',
we do not start at 0 for the won or lost count for each variable / value combination.
It suggested to start at 1, but to avoid that a small subset take to much weight compared to
a larger one, we start at 0.1.

For example :
If we start at 1 : If team 1 has few records from France,
it can get high probability to win even if every lead where lost.

  variable   | value | won_count | lost_count | team_id | Probability
-------------+-------+-----------+------------+---------+-------------
 country_id     FR         1           7            1         0.125
 country_id     FR        198         7306          2         0.0263

If we start at 0.1 :

  variable   | value | won_count | lost_count | team_id | Probability
-------------+-------+-----------+------------+---------+-------------
 country_id     FR         0.1         6.1          1         0.0161
 country_id     FR        197.1       7305.1        2         0.0263

The more we have records for each couple, the more the computation become precise.

The allow the user to decide himself which probability should be set on the lead,
a manual probabiltiy system has been implemented using 2 stored fields + 1 computed field :
- probability (stored): Probability set on the lead, can be set manually in the lead form.
- automated_probability (stored): Probability computed by PLS.
- is_automated_probability (computed): If both previous fields are equal, the probability is considered
as automatic. and each time the automated_probability is updated, the probability is aligned.
If both are not equal, the probability is considered as manual. The automated_probability is still
updated but the probability is not aligned. The user can reset the probability in automatic mode
by clicking on the estimated probability displayed in edit mode in the lead form.

probability and automated_probability are not computed fields as they are manually computed at write and create.
The computation is triggered if one of the activated frequency fields is modified or set.
To trigger also the computation when modifying the lead values on the lead views (form and kanban),
_onchange methods have been added for each frequency field.

Also, a cron has been added to run every day to rebuild the frequency table and to recompute all active
and pending leads (not won nor lost) probability.

Task ID : 1925439
PR #33589

remove rerun cron on action lost and won
2019-06-11 07:04:33 +00:00
David Beguin 8e540558ee [IMP-REM] crm, * : remove stage based probability and add won_stage bool field on crm.stage
This commit prepares the next Predictive Lead Scoring (aka PLS) ones.
With the new PLS implementation, stage based probablility is not relevant anymore
as the probability will be computed based on multiple criteria
following the Naive Bayes probabilist theorem.
To determine if the stage is a won stage, a new 'won_stage' boolean field replaces
the old probability field that is now removed.
won_stage = True is equivalent to stage.probability = 100.

Task ID : 1925439
PR #33589
2019-06-11 07:04:33 +00:00
Thanh Dodeur c212cfe899 [REF] *: removes datas_fname from ir.attachment
This commit removes the field `datas_fname` from `ir.attachment` as
it was unnecessary and most of the time the duplicate of `name` or
`url`.

Task #1909865

closes odoo/odoo#32976

Signed-off-by: Martin Geubelle (mge) <mge@openerp.com>
2019-06-05 09:12:13 +00:00
Christophe Simonis 8dd5a85267 [MERGE] forward port branch saas-12.3 up to 60e71302a3 2019-05-13 15:26:12 +02:00
Christophe Simonis a97037c6d4 [MERGE] forward port branch saas-12.2 up to 78b3b650b0 2019-05-06 12:27:51 +02:00
Denis Ledoux fd0a10026c [MERGE] forward port branch saas-12.1 up to b11930047f 2019-05-02 09:45:14 +02:00
Christophe Simonis 15b8d353c7 [MERGE] forward port branch 12.0 up to 2830b93a3a 2019-04-17 19:47:37 +02:00
Julien Castiaux c42551b5d2 [FIX] crm, sale: safe override of sales team
The user can delete teams created during the installation of the Sale
Team module, both CRM and Sale modify those teams but the way they
modify the teams doesn't take their deletion into account.

This reverts commit 30a848bffb to replace
post_init_hooks by `forcecreate=False` in the datas.

closes odoo/odoo#32742

Signed-off-by: Christophe Simonis <chs@odoo.com>
2019-04-16 15:10:45 +00:00
Julien Castiaux 30a848bffb [FIX] crm, sale: safe override of sales team
The user can delete teams created during the installation of the Sale
Team module, both CRM and Sale modify those teams but the way they
modify the teams doesn't take their deletion into account.

opw-1962297

closes odoo/odoo#32412

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-04-08 13:42:52 +00:00
Raphael Collet d87443a213 [FIX] convert: enable kwargs in tag <function>
closes odoo/odoo#31417

Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2019-03-22 16:42:14 +00:00
Jeremy Kersten 199adbd0e1 [IMP] crm: revert renaming of subtype
Seems better to have wrong term for lead an correct for opportunity
that have not wrong for Lead an not wrong for Opportunity.

task-1932070 related to b6f4d97

closes odoo/odoo#30482
2019-01-23 13:59:00 +00:00
Jeremy Kersten b1f8d4fb6c [FIX] crm: track type on crm.lead
Until now, you cannot find easily if it is a lead or an opportunity that
 has been created.

"Opportunity created" is written in the log but it is in reality a Lead.

Now we track the change on the field type to know what was the type at the
creation AND when it has been converted to opportunity.

task:common-sense-in-real-life
2019-01-23 12:01:58 +00:00
qmo-odoo 1da63f0ab0 [IMP] salesteam: Simplify sales team config and improved team dashboard
Reason:
  *Sales team configuration is too complex with fields you
   don't understand and that bring no added value
  *Remove the team type, every team should be able to handle
   a POS or a website for example
Contains:
  *Removal of the team_type, use_quotations, use_leads fields
  *Removal of the graph configuration fields
  *Adapting the filters that were based on the team_type
  *Clear distinction between the team dashboard behavior in crm
   from the one in sales
  *Cleansing of now dead code due to the removal of the previously
   mentionned fields

Task: #1830105
Enterprise PR: #3006
Closes: #28063
2018-12-05 15:32:53 +00:00
Geoffroy Larue 87ab98832e [IMP] crm: usability improvements
Purpose : Various relabelling and design improvements in crm:
- opportunity, lost reason, lead, team, tag forms
- hide "convert to opportunity" button for inactive/lost
leads (actually nothing happened when clicked anyway)
- Checkbox in crm.team to hide all alias related fields
- New many2one field appearing in crm.team form to select the user to
whom lead created by alias will be assigned.
- Set the admin as leader of the initial crm.team

closes odoo/odoo#28851
2018-12-03 14:12:43 +00:00
Christophe Simonis cf52a04979 [MERGE] forward port branch saas-12.1 up to d3b8422c9c
closes odoo/odoo#30614
2019-01-28 13:58:11 +00:00
Thibault Delavallée abc212f59a [REF] mail: remove create_user_id field on activity
As activities are created using the current user there is no need anymore to
have another field to store the activity creator. We can therefore remove
create_user_id and replace its use by the magic create_uid field.

This commit is linked to task ID 1856417 and PR #27619.
2018-12-12 12:45:24 +00:00
Thibault Delavallée 678e04c19d [FIX][IMP] various: improve lang computation in mail templates
Purpose: add lang definition on templates where it is missing

Related to task 1972615
Linked to PR #32872
2019-04-23 14:26:50 +00:00
Nicolas Martinelli c15551a3f2 [FIX] crm: default CRM team
Keep the default value for the default CRM team (False) since leads are
not activated by default.

opw-1929489

closes odoo/odoo#30360
2019-01-18 14:08:22 +00:00
Mathieu Duckerts-Antoine 5141f42d0e [IMP] crm: add new leads in demo data 2018-10-02 22:03:22 +02:00
Vincent Schippefilt 1da9ed30c2 [FIX] crm: add more demo data for dashboard 2018-09-27 13:04:00 +02:00
RomainLibert 379b09e2ee [IMP] crm,sale*: change/add demo data for dashboards 2018-09-26 18:35:13 +02:00
Xavier Morel e1837721a8 [FIX] *: reassociate various demo data to admin instead of root 2018-09-24 15:55:06 +02:00
Olivier Colson 7b8b477915 [FIX] crm: demo data: properly link attachment to lead and assign main attachment field
For consistency between the behavior of the platform and the demo data.
2018-09-21 13:10:16 +02:00
Xavier Morel 68715a46d1 [FIX] *: reassign data & demo mail aliases from system to admin 2018-09-21 10:06:23 +02:00