<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Odoo/addons/portal/wizard, branch 14.0</title>
<subtitle>The current checkout of upstream Odoo</subtitle>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/'/>
<entry>
<title>[FIX] portal: translate email to partner's language</title>
<updated>2021-03-19T15:39:18+00:00</updated>
<author>
<name>nie</name>
<email>nie@odoo.com</email>
</author>
<published>2021-03-16T14:53:29+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=e446233a1b454ab1aa883609fd0b8a588fec9f00'/>
<id>e446233a1b454ab1aa883609fd0b8a588fec9f00</id>
<content type='text'>
Steps:
- Install Projects
- Go to Settings / Translations / Languages
- Install Dutch
- Go to Settings / Users &amp; Companies / Users
- Edit demo:
  - Language: Dutch
- Go to Projects
- Click the three dots on the first project in the dashboard
- Click Share
- Select demo as recipient
- Send
- Go to Settings / Technical / Email / Emails
- Click the email you just sent

Bug:
The email is not translated in the partner's language

Explanation:
The context of the template didn't take the current partner's language
into account since it was out of the partners loop.
The subject of the email wasn't aware of the partner's language as the
context hadn't been changed.

Wrapping the translations with the right `lang` context value fixes the
issue.

Also, the subject used the formatted string as the translation source.
This makes it impossible to find a matching translation since the source
is different every time.

opw:2475398

closes odoo/odoo#68140

X-original-commit: ef81516f807ad69954787c2180c384887776f840
Signed-off-by: backspac &lt;backspac@users.noreply.github.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Steps:
- Install Projects
- Go to Settings / Translations / Languages
- Install Dutch
- Go to Settings / Users &amp; Companies / Users
- Edit demo:
  - Language: Dutch
- Go to Projects
- Click the three dots on the first project in the dashboard
- Click Share
- Select demo as recipient
- Send
- Go to Settings / Technical / Email / Emails
- Click the email you just sent

Bug:
The email is not translated in the partner's language

Explanation:
The context of the template didn't take the current partner's language
into account since it was out of the partners loop.
The subject of the email wasn't aware of the partner's language as the
context hadn't been changed.

Wrapping the translations with the right `lang` context value fixes the
issue.

Also, the subject used the formatted string as the translation source.
This makes it impossible to find a matching translation since the source
is different every time.

opw:2475398

closes odoo/odoo#68140

X-original-commit: ef81516f807ad69954787c2180c384887776f840
Signed-off-by: backspac &lt;backspac@users.noreply.github.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] portal: internal &amp; portal groups are largely exclusive</title>
<updated>2020-11-07T12:50:05+00:00</updated>
<author>
<name>Xavier Morel</name>
<email>xmo@odoo.com</email>
</author>
<published>2020-11-07T12:50:05+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=c0964b3f54d2be8c8c5acda46c4203c8d18e88ab'/>
<id>c0964b3f54d2be8c8c5acda46c4203c8d18e88ab</id>
<content type='text'>
Prevent mistakenly adding "portal" to existing internal users through
the portal wizard as that can lead to odd behaviors (to the extent
that since 12.0 the "user type" uses radio buttons so it's not
possible to easily set a user as both internal and portal).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Prevent mistakenly adding "portal" to existing internal users through
the portal wizard as that can lead to odd behaviors (to the extent
that since 12.0 the "user type" uses radio buttons so it's not
possible to easily set a user as both internal and portal).
</pre>
</div>
</content>
</entry>
<entry>
<title>[REM] core, *: deprecate &lt;act_window&gt; and &lt;report&gt;</title>
<updated>2020-07-28T13:03:13+00:00</updated>
<author>
<name>Xavier Morel</name>
<email>xmo@odoo.com</email>
</author>
<published>2020-07-16T09:49:10+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=6835aeb0de6895f7f4d6b23e0b4654465ef21d6a'/>
<id>6835aeb0de6895f7f4d6b23e0b4654465ef21d6a</id>
<content type='text'>
Convert deprecated tags through the codebase.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Convert deprecated tags through the codebase.</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] *: correct all or improve code translation lookup</title>
<updated>2020-06-30T10:19:59+00:00</updated>
<author>
<name>Martin Trigaux</name>
<email>mat@odoo.com</email>
</author>
<published>2020-06-26T07:21:33+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=400cc4f14ed12bce8d11ea515041253a9271f5a5'/>
<id>400cc4f14ed12bce8d11ea515041253a9271f5a5</id>
<content type='text'>
This commit fixes all issues detected by the new pylint
gettext-variable test.
It converts some calls to the new syntax
  _("Foo %s", bar)

to progressively migrate the code to the new syntax.

A few calls were not technically incorrect but still detected by the
linter.

  _("Foo" +
    "Bar")

has been converted to

  _("Foo"
    "Bar")

as it has the same effect and make sure the argument is of type
asteroid.Const instead of BinOp).

closes odoo/odoo#53683

Related: odoo/enterprise#11467
Signed-off-by: Raphael Collet (rco) &lt;rco@openerp.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit fixes all issues detected by the new pylint
gettext-variable test.
It converts some calls to the new syntax
  _("Foo %s", bar)

to progressively migrate the code to the new syntax.

A few calls were not technically incorrect but still detected by the
linter.

  _("Foo" +
    "Bar")

has been converted to

  _("Foo"
    "Bar")

as it has the same effect and make sure the argument is of type
asteroid.Const instead of BinOp).

closes odoo/odoo#53683

Related: odoo/enterprise#11467
Signed-off-by: Raphael Collet (rco) &lt;rco@openerp.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[ADD] *: add ir.model.access on all transient models</title>
<updated>2020-02-04T16:54:18+00:00</updated>
<author>
<name>Martin Trigaux</name>
<email>mat@odoo.com</email>
</author>
<published>2020-01-14T12:49:55+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=65530dfd6a0486f44134917f5cc42a2c30b95762'/>
<id>65530dfd6a0486f44134917f5cc42a2c30b95762</id>
<content type='text'>
Following changes needing ir.model.access on transient models too.
Remove groups declaration on the action to move it to ir.model.access
when possible.
Rules are strict by default with no unlink access by default and high
priviledge asked. Adaptations may be needed later.
Write access is given as a wizard may need to be modified in case the
action triggers an error and the user has to correct a value

account*: use account.group_account_user for all transient by default
	  remove account.print.journal relic
stock*: use stock.group_stock_user by default
survey: survey user can send invitations
mail: allow any employee to execute wizards
      additional verifications are made to ensure they are executed
      only on the documents the user has access to you
      give portal access to mail.compose.message as portal still does
      some actions like posting messages on the forum
      add ir.rule to avoid reading somebody else messages
      increase the query count because of undeterminist count
crm: saleman for lead2opp, manager for massmailing
     partner manager for actions linked to partners
     avoid a write in test_lead_lost
sms: any employee can send sms
mrp: mrp user can execute wizards
     give unlink access as making write during do_produce operation
base_import: employees can import files
delivery: stock user can deliver
event_sale: sale user can configure the wizards
	    event user inherit from  sale rights
gamification: employee can give badge
google_service: resolve FIXME
hr: add specific rights
    manager can set a plan according to group on button
    anyone who can write on an employee can register a departure
hr_expense: set rights based on buttons
hr_holidays: an approver can make a summary report
hr_recruitment: recruiter can refuse a candidate
hr_timesheet: can use the wizard if can create a timesheet
l10n_eu_service: managers can create fiscal positions
mass_mailing: same group as on mass.mailing.list
membership: accountant can create invoice from membership
payment: accountant can create a link
	 as the source is an account.move
	 keep the payment.acquirer.onboarding.wizard to system user
	 only as it is called during company configuration
point_of_sale: PoS manager only can use wizards
	       never create closing_balance_confirm_wizard records
product_expiry: stock user has rights on stock.picking
product_margin: access from accounting menus
repair: same rules as for above models
sale: set ir.rule for self wizard only
      add rule from model introduced in payment to add salesman group
sale_crm: saleman can create a quotation from a lead
sale_coupon: any saleman can generate coupon
	     add self ir.rule
sale_product_configurator: salesman can select product variants
snailmail: employee can send letters
website: designers can write on website
website_crm_partner_assign: same rule as group on action
website_sale: sale ACL as for payment.acquirer.onboarding.wizard
website_slides: anyone can send invitation

base: base.language.*: allow employee (cf lang_install)
      change.password.user: can not read change password wizard of
      other users
      test.*: no access is needed

Courtesy of Damien Bouvy, William Andre and Antoine Prieëls for review
of acl
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Following changes needing ir.model.access on transient models too.
Remove groups declaration on the action to move it to ir.model.access
when possible.
Rules are strict by default with no unlink access by default and high
priviledge asked. Adaptations may be needed later.
Write access is given as a wizard may need to be modified in case the
action triggers an error and the user has to correct a value

account*: use account.group_account_user for all transient by default
	  remove account.print.journal relic
stock*: use stock.group_stock_user by default
survey: survey user can send invitations
mail: allow any employee to execute wizards
      additional verifications are made to ensure they are executed
      only on the documents the user has access to you
      give portal access to mail.compose.message as portal still does
      some actions like posting messages on the forum
      add ir.rule to avoid reading somebody else messages
      increase the query count because of undeterminist count
crm: saleman for lead2opp, manager for massmailing
     partner manager for actions linked to partners
     avoid a write in test_lead_lost
sms: any employee can send sms
mrp: mrp user can execute wizards
     give unlink access as making write during do_produce operation
base_import: employees can import files
delivery: stock user can deliver
event_sale: sale user can configure the wizards
	    event user inherit from  sale rights
gamification: employee can give badge
google_service: resolve FIXME
hr: add specific rights
    manager can set a plan according to group on button
    anyone who can write on an employee can register a departure
hr_expense: set rights based on buttons
hr_holidays: an approver can make a summary report
hr_recruitment: recruiter can refuse a candidate
hr_timesheet: can use the wizard if can create a timesheet
l10n_eu_service: managers can create fiscal positions
mass_mailing: same group as on mass.mailing.list
membership: accountant can create invoice from membership
payment: accountant can create a link
	 as the source is an account.move
	 keep the payment.acquirer.onboarding.wizard to system user
	 only as it is called during company configuration
point_of_sale: PoS manager only can use wizards
	       never create closing_balance_confirm_wizard records
product_expiry: stock user has rights on stock.picking
product_margin: access from accounting menus
repair: same rules as for above models
sale: set ir.rule for self wizard only
      add rule from model introduced in payment to add salesman group
sale_crm: saleman can create a quotation from a lead
sale_coupon: any saleman can generate coupon
	     add self ir.rule
sale_product_configurator: salesman can select product variants
snailmail: employee can send letters
website: designers can write on website
website_crm_partner_assign: same rule as group on action
website_sale: sale ACL as for payment.acquirer.onboarding.wizard
website_slides: anyone can send invitation

base: base.language.*: allow employee (cf lang_install)
      change.password.user: can not read change password wizard of
      other users
      test.*: no access is needed

Courtesy of Damien Bouvy, William Andre and Antoine Prieëls for review
of acl
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] portal : fix error on user creation</title>
<updated>2019-12-24T14:31:07+00:00</updated>
<author>
<name>helly kapatel</name>
<email>hpl@odoo.com</email>
</author>
<published>2019-12-03T05:53:11+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=02913c99201da10636576b01b9c2a7b1f1c9fb8c'/>
<id>02913c99201da10636576b01b9c2a7b1f1c9fb8c</id>
<content type='text'>
Leftover typo from #36804.

The company_id key in the context was removed and replaced
by the generic with_company mechanism, we therefore have to use self.env.company
(and not self.env.company_id which doesn't exist).

closes odoo/odoo#42348

X-original-commit: 4a627816e9c803ff414e6d5a5267b6f44aa25e72
Signed-off-by: Victor Feyens (vfe) &lt;vfe@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Leftover typo from #36804.

The company_id key in the context was removed and replaced
by the generic with_company mechanism, we therefore have to use self.env.company
(and not self.env.company_id which doesn't exist).

closes odoo/odoo#42348

X-original-commit: 4a627816e9c803ff414e6d5a5267b6f44aa25e72
Signed-off-by: Victor Feyens (vfe) &lt;vfe@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] portal: remove company_id context key.</title>
<updated>2019-11-18T12:25:05+00:00</updated>
<author>
<name>Victor Feyens</name>
<email>vfe@odoo.com</email>
</author>
<published>2019-10-07T10:30:40+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=d52f8ce8b030159f05bacb7d07ed042b862274dd'/>
<id>d52f8ce8b030159f05bacb7d07ed042b862274dd</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] mail, portal: use formataddr to format email</title>
<updated>2019-10-18T14:17:45+00:00</updated>
<author>
<name>Thibault Delavallée</name>
<email>tde@odoo.com</email>
</author>
<published>2019-10-08T15:16:45+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=2535a521779d5803e9cbb89941d61a919e45ccdf'/>
<id>2535a521779d5803e9cbb89941d61a919e45ccdf</id>
<content type='text'>
Somehow followup of dbb6cfdbf803d2ab86ba11450b5928abf5ab658b . Purpose is
to use formataddr from tools instead of manually handcrafting the full
email address format. Indeed the tools one correctly encapsulates and
format name and email.

Task ID 2068986</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Somehow followup of dbb6cfdbf803d2ab86ba11450b5928abf5ab658b . Purpose is
to use formataddr from tools instead of manually handcrafting the full
email address format. Indeed the tools one correctly encapsulates and
format name and email.

Task ID 2068986</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] portal: avoid crashing if active_model or active_id not in context</title>
<updated>2019-10-11T09:59:22+00:00</updated>
<author>
<name>RomainLibert</name>
<email>rli@odoo.com</email>
</author>
<published>2019-10-11T07:39:04+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=629258cf2b5a1573343a690458eae09030125c37'/>
<id>629258cf2b5a1573343a690458eae09030125c37</id>
<content type='text'>
closes odoo/odoo#38488

X-original-commit: 89270ee39c0daa46ae8e2e3e57d7e512a1a65ddf
Signed-off-by: Romain Libert (rli) &lt;rli@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
closes odoo/odoo#38488

X-original-commit: 89270ee39c0daa46ae8e2e3e57d7e512a1a65ddf
Signed-off-by: Romain Libert (rli) &lt;rli@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[REM] *: calls to @api.multi</title>
<updated>2019-07-17T12:13:12+00:00</updated>
<author>
<name>Adrian Torres</name>
<email>adt@odoo.com</email>
</author>
<published>2019-07-10T12:59:37+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=4b38cc6590abcb58a0ca102a06063eb3db7ac1f4'/>
<id>4b38cc6590abcb58a0ca102a06063eb3db7ac1f4</id>
<content type='text'>
Multi is the default api for methods, it is not necessary to explicitly
decorate methods with it, adds clutter and most people use it because
they see that the rest of the code uses it.

Done with `find . -type f -name '*.py' | xargs sed -i '/@api.multi/d'`
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Multi is the default api for methods, it is not necessary to explicitly
decorate methods with it, adds clutter and most people use it because
they see that the rest of the code uses it.

Done with `find . -type f -name '*.py' | xargs sed -i '/@api.multi/d'`
</pre>
</div>
</content>
</entry>
</feed>
