[IMP] rma_sale: portal improvents

- Now it's possible to open several RMAs in a sale order from the portal
- A new comment button has been added to allow the portal user to enter
relevant information like serial numbers o issue description.
- If the requested operation isn't set no RMA will be opened
- The RMA product qty is now a numeric control with limits according to
the qty available to return

[FIX] rma,rma_sale: fix linter errors

[UPD] Update rma.pot

rma 12.0.1.4.0

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: rma-12.0/rma-12.0-rma
Translate-URL: https://translation.odoo-community.org/projects/rma-12-0/rma-12-0-rma/
This commit is contained in:
david
2020-08-28 16:54:59 +02:00
committed by Antoni Marroig Campomar
parent 665ab617a4
commit 9794aa4a11
8 changed files with 63 additions and 58 deletions

View File

@@ -3,7 +3,7 @@
{
"name": "Return Merchandise Authorization Management",
"summary": "Return Merchandise Authorization (RMA)",
"version": "12.0.1.3.1",
"version": "12.0.1.4.0",
"development_status": "Beta",
"category": "RMA",
"website": "https://github.com/OCA/rma",

View File

@@ -28,7 +28,7 @@ msgid "${object.company_id.name} RMA (Ref ${object.name or 'n/a' })"
msgstr "${object.company_id.name} RMA (Ref ${object.name or 'n/a' })"
#. module: rma
#: code:addons/rma/models/rma_team.py:44
#: code:addons/rma/models/rma_team.py:46
#, python-format
msgid "%s (copy)"
msgstr "%s (copia)"
@@ -536,7 +536,7 @@ msgid "Draft RMA"
msgstr "RMA en estado Borrador"
#. module: rma
#: code:addons/rma/models/rma.py:1097
#: code:addons/rma/models/rma.py:1098
#, python-format
msgid ""
"E-mail subject: %s\n"
@@ -639,7 +639,7 @@ msgstr ""
"sin eliminarlo."
#. module: rma
#: code:addons/rma/models/rma.py:1101
#: code:addons/rma/models/rma.py:1102
#, python-format
msgid "Incoming e-mail"
msgstr "Correo electrónico entrante"
@@ -746,7 +746,7 @@ msgstr "Nombre"
#. module: rma
#: code:addons/rma/models/rma.py:31 code:addons/rma/models/rma.py:495
#: code:addons/rma/models/rma.py:1100
#: code:addons/rma/models/rma.py:1101
#, python-format
msgid "New"
msgstr "Nuevo"
@@ -767,13 +767,13 @@ msgid "Next Activity Type"
msgstr "Siguiente tipo de actividad"
#. module: rma
#: code:addons/rma/models/rma.py:772
#: code:addons/rma/models/rma.py:773
#, python-format
msgid "None of the selected RMAs can perform a replacement."
msgstr "Ninguno de los RMAs seleccionados puede realizar un reemplazo."
#. module: rma
#: code:addons/rma/models/rma.py:755
#: code:addons/rma/models/rma.py:756
#, python-format
msgid "None of the selected RMAs can perform a return."
msgstr "Ninguno de los RMAs seleccionados puede realizar una devolución."
@@ -954,7 +954,7 @@ msgid "Quantity to extract"
msgstr "Cantidad a extraer"
#. module: rma
#: code:addons/rma/models/rma.py:805
#: code:addons/rma/models/rma.py:806
#, python-format
msgid ""
"Quantity to extract cannot be greater than remaining delivery quantity (%s "
@@ -1132,7 +1132,7 @@ msgid "Reference of the document that generated this RMA."
msgstr "Referencia al documento que generó este RMA."
#. module: rma
#: code:addons/rma/models/rma.py:693
#: code:addons/rma/models/rma.py:694
#: model:ir.model.fields,field_description:rma.field_rma__refund_id
#: model_terms:ir.ui.view,arch_db:rma.rma_view_form
#: model:rma.operation,name:rma.rma_operation_refund
@@ -1188,7 +1188,7 @@ msgid "Replaced"
msgstr "Reemplazado"
#. module: rma
#: code:addons/rma/models/rma.py:1010
#: code:addons/rma/models/rma.py:1011
#, python-format
msgid ""
"Replacement: Move <a href=\"#\" data-oe-model=\"stock.move\" data-oe-id=\"%d"
@@ -1200,7 +1200,7 @@ msgstr ""
"picking\" data-oe-id=\"%d\">%s</a>) ha sido creado."
#. module: rma
#: code:addons/rma/models/rma.py:1021
#: code:addons/rma/models/rma.py:1022
#, python-format
msgid ""
"Replacement:<br/>Product <a href=\"#\" data-oe-model=\"product.product\" "
@@ -1224,7 +1224,7 @@ msgid "Requested operation"
msgstr "Operación solicitada"
#. module: rma
#: code:addons/rma/models/rma.py:736
#: code:addons/rma/models/rma.py:737
#, python-format
msgid "Required field(s):%s"
msgstr "Campo(s) requerido(s):%s"
@@ -1253,7 +1253,7 @@ msgid "Return to customer"
msgstr "Devolver al cliente"
#. module: rma
#: code:addons/rma/models/rma.py:971
#: code:addons/rma/models/rma.py:972
#, python-format
msgid ""
"Return: <a href=\"#\" data-oe-model=\"stock.picking\" data-oe-id=\"%d\">%s</"
@@ -1341,7 +1341,7 @@ msgid "Split RMA"
msgstr "Dividir RMA"
#. module: rma
#: code:addons/rma/models/rma.py:889
#: code:addons/rma/models/rma.py:890
#, python-format
msgid ""
"Split: <a href=\"#\" data-oe-model=\"rma\" data-oe-id=\"%d\">%s</a> has been "
@@ -1447,7 +1447,7 @@ msgstr ""
"inicial porque el movimiento está enlazado a un RMA (%s)."
#. module: rma
#: code:addons/rma/models/rma.py:793
#: code:addons/rma/models/rma.py:794
#, python-format
msgid "The quantity to return is greater than remaining quantity."
msgstr "La cantidad a devolver es mayor que la cantidad restante del RMA."
@@ -1463,19 +1463,19 @@ msgstr ""
"cantidad especificada en el RMA asociado."
#. module: rma
#: code:addons/rma/models/rma.py:782
#: code:addons/rma/models/rma.py:783
#, python-format
msgid "This RMA cannot be split."
msgstr "Este RMA no puede ser dividido."
#. module: rma
#: code:addons/rma/models/rma.py:769
#: code:addons/rma/models/rma.py:770
#, python-format
msgid "This RMA cannot perform a replacement."
msgstr "Este RMA no puede realizar un reemplazo."
#. module: rma
#: code:addons/rma/models/rma.py:752
#: code:addons/rma/models/rma.py:753
#, python-format
msgid "This RMA cannot perform a return."
msgstr "Este RMA no puede realizar una devolución."
@@ -1599,7 +1599,7 @@ msgid "Website communication history"
msgstr "Historial de comunicaciones del sitio web"
#. module: rma
#: code:addons/rma/models/rma.py:516
#: code:addons/rma/models/rma.py:517
#, python-format
msgid "You cannot delete RMAs that are not in draft state"
msgstr "No puede eliminar RMAs que no estén en estado borrador"

View File

@@ -27,7 +27,7 @@ msgid "${object.company_id.name} RMA (Ref ${object.name or 'n/a' })"
msgstr "${object.company_id.name} RMA (Ref ${object.name or 'n/a' })"
#. module: rma
#: code:addons/rma/models/rma_team.py:44
#: code:addons/rma/models/rma_team.py:46
#, python-format
msgid "%s (copy)"
msgstr "%s (Cópia)"
@@ -535,7 +535,7 @@ msgid "Draft RMA"
msgstr "Rascunho do RMA"
#. module: rma
#: code:addons/rma/models/rma.py:1097
#: code:addons/rma/models/rma.py:1098
#, python-format
msgid ""
"E-mail subject: %s\n"
@@ -638,7 +638,7 @@ msgstr ""
"sem removê-lo."
#. module: rma
#: code:addons/rma/models/rma.py:1101
#: code:addons/rma/models/rma.py:1102
#, python-format
msgid "Incoming e-mail"
msgstr "E-mail recebido"
@@ -745,7 +745,7 @@ msgstr "Nome"
#. module: rma
#: code:addons/rma/models/rma.py:31 code:addons/rma/models/rma.py:495
#: code:addons/rma/models/rma.py:1100
#: code:addons/rma/models/rma.py:1101
#, python-format
msgid "New"
msgstr "Novo(a)"
@@ -766,13 +766,13 @@ msgid "Next Activity Type"
msgstr "Tipo da Próxima Atividade"
#. module: rma
#: code:addons/rma/models/rma.py:772
#: code:addons/rma/models/rma.py:773
#, python-format
msgid "None of the selected RMAs can perform a replacement."
msgstr "Nenhum dos RMAs selecionados pode executar uma substituição."
#. module: rma
#: code:addons/rma/models/rma.py:755
#: code:addons/rma/models/rma.py:756
#, python-format
msgid "None of the selected RMAs can perform a return."
msgstr "Nenhum dos RMAs selecionados pode executar uma devolução."
@@ -953,7 +953,7 @@ msgid "Quantity to extract"
msgstr "Quantidade a extrair"
#. module: rma
#: code:addons/rma/models/rma.py:805
#: code:addons/rma/models/rma.py:806
#, python-format
msgid ""
"Quantity to extract cannot be greater than remaining delivery quantity (%s "
@@ -1130,7 +1130,7 @@ msgid "Reference of the document that generated this RMA."
msgstr "Referência do documento que gerou este RMA."
#. module: rma
#: code:addons/rma/models/rma.py:693
#: code:addons/rma/models/rma.py:694
#: model:ir.model.fields,field_description:rma.field_rma__refund_id
#: model_terms:ir.ui.view,arch_db:rma.rma_view_form
#: model:rma.operation,name:rma.rma_operation_refund
@@ -1186,7 +1186,7 @@ msgid "Replaced"
msgstr "Substituído"
#. module: rma
#: code:addons/rma/models/rma.py:1010
#: code:addons/rma/models/rma.py:1011
#, python-format
msgid ""
"Replacement: Move <a href=\"#\" data-oe-model=\"stock.move\" data-oe-id=\"%d"
@@ -1198,7 +1198,7 @@ msgstr ""
"data-oe-id=\"%d\">%s</a> foi criada."
#. module: rma
#: code:addons/rma/models/rma.py:1021
#: code:addons/rma/models/rma.py:1022
#, python-format
msgid ""
"Replacement:<br/>Product <a href=\"#\" data-oe-model=\"product.product\" "
@@ -1222,7 +1222,7 @@ msgid "Requested operation"
msgstr "Operação Solicitada"
#. module: rma
#: code:addons/rma/models/rma.py:736
#: code:addons/rma/models/rma.py:737
#, python-format
msgid "Required field(s):%s"
msgstr "Campo(s) Solicitado(s):%s"
@@ -1251,7 +1251,7 @@ msgid "Return to customer"
msgstr "Retornar ao cliente"
#. module: rma
#: code:addons/rma/models/rma.py:971
#: code:addons/rma/models/rma.py:972
#, python-format
msgid ""
"Return: <a href=\"#\" data-oe-model=\"stock.picking\" data-oe-id=\"%d\">%s</"
@@ -1339,7 +1339,7 @@ msgid "Split RMA"
msgstr "Dividir RMA"
#. module: rma
#: code:addons/rma/models/rma.py:889
#: code:addons/rma/models/rma.py:890
#, python-format
msgid ""
"Split: <a href=\"#\" data-oe-model=\"rma\" data-oe-id=\"%d\">%s</a> has been "
@@ -1444,7 +1444,7 @@ msgstr ""
"inicial, porque a movimentação do estoque está vinculada a uma RMA (%s)."
#. module: rma
#: code:addons/rma/models/rma.py:793
#: code:addons/rma/models/rma.py:794
#, python-format
msgid "The quantity to return is greater than remaining quantity."
msgstr "A quantidade a retornar é maior que a quantidade restante."
@@ -1460,19 +1460,19 @@ msgstr ""
"especificada na sua RMA vinculada."
#. module: rma
#: code:addons/rma/models/rma.py:782
#: code:addons/rma/models/rma.py:783
#, python-format
msgid "This RMA cannot be split."
msgstr "Esta RMA não pode ser dividida."
#. module: rma
#: code:addons/rma/models/rma.py:769
#: code:addons/rma/models/rma.py:770
#, python-format
msgid "This RMA cannot perform a replacement."
msgstr "Esta RMA não pode executar uma substituição."
#. module: rma
#: code:addons/rma/models/rma.py:752
#: code:addons/rma/models/rma.py:753
#, python-format
msgid "This RMA cannot perform a return."
msgstr "Este RMA não pode executar uma devolução."
@@ -1596,7 +1596,7 @@ msgid "Website communication history"
msgstr "Histórico de Comunicação Através do Site"
#. module: rma
#: code:addons/rma/models/rma.py:516
#: code:addons/rma/models/rma.py:517
#, python-format
msgid "You cannot delete RMAs that are not in draft state"
msgstr "Você não pode apagar RMAs que não estejam na situação \"Rascunho\""

View File

@@ -24,7 +24,7 @@ msgid "${object.company_id.name} RMA (Ref ${object.name or 'n/a' })"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma_team.py:44
#: code:addons/rma/models/rma_team.py:46
#, python-format
msgid "%s (copy)"
msgstr ""
@@ -486,7 +486,7 @@ msgid "Draft RMA"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:1097
#: code:addons/rma/models/rma.py:1098
#, python-format
msgid "E-mail subject: %s\n"
"\n"
@@ -576,7 +576,7 @@ msgid "If the active field is set to false, it will allow you to hide the RMA Te
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:1101
#: code:addons/rma/models/rma.py:1102
#, python-format
msgid "Incoming e-mail"
msgstr ""
@@ -684,7 +684,7 @@ msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:31
#: code:addons/rma/models/rma.py:495
#: code:addons/rma/models/rma.py:1100
#: code:addons/rma/models/rma.py:1101
#, python-format
msgid "New"
msgstr ""
@@ -705,13 +705,13 @@ msgid "Next Activity Type"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:772
#: code:addons/rma/models/rma.py:773
#, python-format
msgid "None of the selected RMAs can perform a replacement."
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:755
#: code:addons/rma/models/rma.py:756
#, python-format
msgid "None of the selected RMAs can perform a return."
msgstr ""
@@ -875,7 +875,7 @@ msgid "Quantity to extract"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:805
#: code:addons/rma/models/rma.py:806
#, python-format
msgid "Quantity to extract cannot be greater than remaining delivery quantity (%s %s)"
msgstr ""
@@ -1049,7 +1049,7 @@ msgid "Reference of the document that generated this RMA."
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:693
#: code:addons/rma/models/rma.py:694
#: model:ir.model.fields,field_description:rma.field_rma__refund_id
#: model_terms:ir.ui.view,arch_db:rma.rma_view_form
#: model:rma.operation,name:rma.rma_operation_refund
@@ -1105,13 +1105,13 @@ msgid "Replaced"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:1010
#: code:addons/rma/models/rma.py:1011
#, python-format
msgid "Replacement: Move <a href=\"#\" data-oe-model=\"stock.move\" data-oe-id=\"%d\">%s</a> (Picking <a href=\"#\" data-oe-model=\"stock.picking\" data-oe-id=\"%d\">%s</a>) has been created."
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:1021
#: code:addons/rma/models/rma.py:1022
#, python-format
msgid "Replacement:<br/>Product <a href=\"#\" data-oe-model=\"product.product\" data-oe-id=\"%d\">%s</a><br/>Quantity %f %s<br/>This replacement did not create a new move, but one of the previously created moves was updated with this data."
msgstr ""
@@ -1127,7 +1127,7 @@ msgid "Requested operation"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:736
#: code:addons/rma/models/rma.py:737
#, python-format
msgid "Required field(s):%s"
msgstr ""
@@ -1156,7 +1156,7 @@ msgid "Return to customer"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:971
#: code:addons/rma/models/rma.py:972
#, python-format
msgid "Return: <a href=\"#\" data-oe-model=\"stock.picking\" data-oe-id=\"%d\">%s</a> has been created."
msgstr ""
@@ -1240,7 +1240,7 @@ msgid "Split RMA"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:889
#: code:addons/rma/models/rma.py:890
#, python-format
msgid "Split: <a href=\"#\" data-oe-model=\"rma\" data-oe-id=\"%d\">%s</a> has been created."
msgstr ""
@@ -1314,7 +1314,7 @@ msgid "The quantity done for the product '%s' must be equal to its initial deman
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:793
#: code:addons/rma/models/rma.py:794
#, python-format
msgid "The quantity to return is greater than remaining quantity."
msgstr ""
@@ -1326,19 +1326,19 @@ msgid "There is at least one invoice lines whose quantity is less than the quant
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:782
#: code:addons/rma/models/rma.py:783
#, python-format
msgid "This RMA cannot be split."
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:769
#: code:addons/rma/models/rma.py:770
#, python-format
msgid "This RMA cannot perform a replacement."
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:752
#: code:addons/rma/models/rma.py:753
#, python-format
msgid "This RMA cannot perform a return."
msgstr ""
@@ -1462,7 +1462,7 @@ msgid "Website communication history"
msgstr ""
#. module: rma
#: code:addons/rma/models/rma.py:516
#: code:addons/rma/models/rma.py:517
#, python-format
msgid "You cannot delete RMAs that are not in draft state"
msgstr ""

View File

@@ -503,6 +503,7 @@ class Rma(models.Model):
vals["team_id"] = self.env["rma.team"].search([], limit=1).id
return super().create(vals)
@api.multi
def copy(self, default=None):
team = super().copy(default)
for follower in self.message_follower_ids:

View File

@@ -1,7 +1,7 @@
# Copyright 2020 Tecnativa - Ernesto Tejeda
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import _, fields, models
from odoo import _, api, fields, models
class RmaTeam(models.Model):
@@ -37,7 +37,9 @@ class RmaTeam(models.Model):
string='Team Members',
)
@api.multi
def copy(self, default=None):
self.ensure_one()
if default is None:
default = {}
if not default.get('name'):

View File

@@ -1,7 +1,7 @@
# Copyright 2020 Tecnativa - Ernesto Tejeda
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import fields, models
from odoo import api, fields, models
class StockPicking(models.Model):
@@ -16,7 +16,9 @@ class StockPicking(models.Model):
for rec in self:
rec.rma_count = len(rec.move_lines.mapped('rma_ids'))
@api.multi
def copy(self, default=None):
self.ensure_one()
if self.env.context.get('set_rma_picking_type'):
location_dest_id = default['location_dest_id']
warehouse = self.env['stock.warehouse'].search(

View File

@@ -279,7 +279,7 @@
</field>
</record>
<record id="rma.rma_orders_menu" model="ir.ui.menu">
<record id="rma_orders_menu" model="ir.ui.menu">
<field name="action" ref="rma_action"/>
</record>
</odoo>