Skip to content

version-control-platform: add test to show wrong total on org#6

Open
sebastienbeau wants to merge 1 commit into
OCA:18.0from
akretion:18.0-wrong-total-orga
Open

version-control-platform: add test to show wrong total on org#6
sebastienbeau wants to merge 1 commit into
OCA:18.0from
akretion:18.0-wrong-total-orga

Conversation

@sebastienbeau
Copy link
Copy Markdown
Member

Hi @etobella

The total on the partner company are not correct. Right now if a user from ORG 2 add a comment on a PR open by the ORG 1 the statistic will be counted for the ORG 1.

For now I just have added a test to show you the issue.

To fix it I propose:

  • adding a o2m on the res.partner to be able to store the historical company of a res.partner (with a table res.partner.history with start_date, end_date, company_id)

  • adding a computing field on the vcp.review / vcp.comment to compute the related company

For simple case the company of the partner is simply the parent_id of the partner that have done the contribution, in some advanced case (like Yannick Payot who was working at Camptocamp and then as Ascone) we can use the historical company mapping to be able to set the right company on the contribution.

What do you think ? If it's ok I will do it

@etobella
Copy link
Copy Markdown
Member

@sebastienbeau this is expected.

We akready comented that we don't know the real organization of a user, so the only solution was to handle like received comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants