[IMP] base,**: rewrite some error messages
Maintain the playful tone whilst avoiding nonsensical phrasing. I will not take comment at this time, thank you. Task-🤔🙃😬💅😐🤓 closes odoo/odoo#138302 Signed-off-by: Bouvy Damien (dbo) <dbo@odoo.com>
This commit is contained in:
@@ -757,7 +757,7 @@ class AccountAccount(models.Model):
|
||||
account_name = partner_prop_acc.get_by_record().display_name
|
||||
raise UserError(
|
||||
_("You can't delete the account %s, as it is used on a contact.\n\n"
|
||||
"Imagine that a customer’s receivables evaporate; your CFO might not like it :)"
|
||||
"Think of it as safeguarding your customer's receivables; your CFO would appreciate it :)"
|
||||
, account_name)
|
||||
)
|
||||
|
||||
|
||||
@@ -1563,7 +1563,7 @@ class AccountMoveLine(models.Model):
|
||||
def _unlink_except_posted(self):
|
||||
# Prevent deleting lines on posted entries
|
||||
if not self._context.get('force_delete') and any(m.state == 'posted' for m in self.move_id):
|
||||
raise UserError(_("You can't delete a posted journal item. Don’t play Jenga with your accounting records; reset the journal entry to draft before deleting it."))
|
||||
raise UserError(_("You can't delete a posted journal item. Don’t play games with your accounting records; reset the journal entry to draft before deleting it."))
|
||||
|
||||
@api.ondelete(at_uninstall=False)
|
||||
def _prevent_automatic_line_deletion(self):
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
<header>
|
||||
<button name="action_launch" type="object" class="oe_highlight" string="Send"
|
||||
invisible="state in ('in_queue', 'sending', 'done')" data-hotkey="q"
|
||||
confirm="Once you send these emails, they'll be barking in all the inboxes like there's no tomorrow!"
|
||||
confirm="Once you send these emails, they'll be making a grand entrance in all the inboxes, creating quite the buzz!"
|
||||
confirm-title="Ready to unleash emails?" confirm-label="Send to all"
|
||||
/>
|
||||
<button name="action_schedule" type="object" class="btn-secondary" string="Schedule"
|
||||
|
||||
@@ -1478,10 +1478,10 @@ class MrpProduction(models.Model):
|
||||
|
||||
def button_unplan(self):
|
||||
if any(wo.state == 'done' for wo in self.workorder_ids):
|
||||
raise UserError(_("Some work orders have already been done, so you cannot unplan this manufacturing order.\n\n"
|
||||
raise UserError(_("Some work orders are already done, so you cannot unplan this manufacturing order.\n\n"
|
||||
"It’d be a shame to waste all that progress, right?"))
|
||||
elif any(wo.state == 'progress' for wo in self.workorder_ids):
|
||||
raise UserError(_("Some work orders have already been started, so you cannot unplan this manufacturing order.\n\n"
|
||||
raise UserError(_("Some work orders have already started, so you cannot unplan this manufacturing order.\n\n"
|
||||
"It’d be a shame to waste all that progress, right?"))
|
||||
|
||||
self.workorder_ids.leave_id.unlink()
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
<a type="action" class="btn btn-primary me-1" data-bs-dismiss="modal"
|
||||
data-o-hide-banner="true" t-att-data-model="close_model" t-att-data-method="close_method"
|
||||
>
|
||||
Get that out of my sight!
|
||||
Get them out of my sight!
|
||||
</a>
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Cancel</button>
|
||||
</div>
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
<t t-if="!hasContent and !isFetching">
|
||||
<div t-if="state.needle" class="o_nocontent_help">
|
||||
<p class="o_empty_folder_image">No images found.</p>
|
||||
<p class="o_empty_folder_subtitle">Psst! Want to impress your screen? Upload from the button in the top right corner!</p>
|
||||
<p class="o_empty_folder_subtitle">Wow, it feels a bit empty in here. Upload from the button in the top right corner!</p>
|
||||
</div>
|
||||
<div t-else="" class="o_we_search_prompt">
|
||||
<h2>Discover a world of awesomeness in our copyright-free image haven. No legal drama, just nice images!</h2>
|
||||
|
||||
@@ -204,7 +204,7 @@ class IrRule(models.Model):
|
||||
"Sorry, %s doesn't have '%s' access to:", user_description, operations[operation])
|
||||
failing_model = _("- %s (%s)", description, model)
|
||||
|
||||
resolution_info = _("If you really, really need access, go bribe your friendly administrator.")
|
||||
resolution_info = _("If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies.")
|
||||
|
||||
if not self.user_has_groups('base.group_no_one') or not self.env.user.has_group('base.group_user'):
|
||||
records.invalidate_recordset()
|
||||
@@ -232,7 +232,7 @@ class IrRule(models.Model):
|
||||
failing_rules = _("Blame the following rules:\n%s", rules_description)
|
||||
|
||||
if company_related:
|
||||
failing_rules += "\n\n" + _('Note: this might be a multi-company issue.')
|
||||
failing_rules += "\n\n" + _('Note: this might be a multi-company issue. Switching company may help - in Odoo, not in real life!')
|
||||
|
||||
# clean up the cache of records prefetched with display_name above
|
||||
records_sudo.invalidate_recordset()
|
||||
|
||||
@@ -203,7 +203,7 @@ class TestIRRuleFeedback(Feedback):
|
||||
Sorry, %s (id=%s) doesn't have 'write' access to:
|
||||
- %s (%s)
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record._name))
|
||||
# debug mode
|
||||
self.debug_mode()
|
||||
@@ -219,7 +219,7 @@ Sorry, %s (id=%s) doesn't have 'write' access to:
|
||||
Blame the following rules:
|
||||
- rule 0
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
ChildModel = self.env['test_access_right.inherits']
|
||||
@@ -235,7 +235,7 @@ Sorry, %s (id=%s) doesn't have 'write' access to:
|
||||
Blame the following rules:
|
||||
- rule 0
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
def test_locals(self):
|
||||
@@ -255,7 +255,7 @@ Blame the following rules:
|
||||
- rule 0
|
||||
- rule 1
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
def test_globals_all(self):
|
||||
@@ -275,7 +275,7 @@ Blame the following rules:
|
||||
- rule 0
|
||||
- rule 1
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
def test_globals_any(self):
|
||||
@@ -297,7 +297,7 @@ Sorry, %s (id=%s) doesn't have 'write' access to:
|
||||
Blame the following rules:
|
||||
- rule 0
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
def test_combination(self):
|
||||
@@ -320,7 +320,7 @@ Blame the following rules:
|
||||
- rule 2
|
||||
- rule 3
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
def test_warn_company_no_access(self):
|
||||
@@ -343,9 +343,9 @@ Sorry, %s (id=%s) doesn't have 'write' access to:
|
||||
Blame the following rules:
|
||||
- rule 0
|
||||
|
||||
Note: this might be a multi-company issue.
|
||||
Note: this might be a multi-company issue. Switching company may help - in Odoo, not in real life!
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id))
|
||||
|
||||
def test_warn_company_no_company_field(self):
|
||||
@@ -377,9 +377,9 @@ Sorry, %s (id=%s) doesn't have 'read' access to:
|
||||
Blame the following rules:
|
||||
- rule 0
|
||||
|
||||
Note: this might be a multi-company issue.
|
||||
Note: this might be a multi-company issue. Switching company may help - in Odoo, not in real life!
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, child_record._description, child_record.display_name, child_record._name, child_record.id))
|
||||
|
||||
def test_warn_company_access(self):
|
||||
@@ -402,9 +402,9 @@ Sorry, %s (id=%s) doesn't have 'read' access to:
|
||||
Blame the following rules:
|
||||
- rule 0
|
||||
|
||||
Note: this might be a multi-company issue.
|
||||
Note: this might be a multi-company issue. Switching company may help - in Odoo, not in real life!
|
||||
|
||||
If you really, really need access, go bribe your friendly administrator."""
|
||||
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies."""
|
||||
% (self.user.name, self.user.id, self.record._description, self.record.display_name, self.record._name, self.record.id, self.record.sudo().company_id.display_name))
|
||||
p = self.env['test_access_right.inherits'].create({'some_id': self.record.id})
|
||||
self.env.flush_all()
|
||||
|
||||
Reference in New Issue
Block a user