lims_planning_automatic: fix user message
This commit is contained in:
parent
a4bda788ff
commit
db275acef8
|
@ -14,3 +14,7 @@ msgctxt ""
|
||||||
"model:ir.action.act_window.domain,name:act_lims_planification_list_domain_automatic"
|
"model:ir.action.act_window.domain,name:act_lims_planification_list_domain_automatic"
|
||||||
msgid "Automatic"
|
msgid "Automatic"
|
||||||
msgstr "Automática"
|
msgstr "Automática"
|
||||||
|
|
||||||
|
msgctxt "model:ir.message,text:msg_user_no_professional"
|
||||||
|
msgid "This user is not associated with any professional"
|
||||||
|
msgstr "Este usuario no está asociado a ningún profesional"
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0"?>
|
||||||
|
<tryton>
|
||||||
|
<data grouped="1">
|
||||||
|
<record model="ir.message" id="msg_user_no_professional">
|
||||||
|
<field name="text">This user is not associated with any professional</field>
|
||||||
|
</record>
|
||||||
|
</data>
|
||||||
|
</tryton>
|
|
@ -17,7 +17,8 @@ class AnalysisSheet(metaclass=PoolMeta):
|
||||||
super().activate(sheets)
|
super().activate(sheets)
|
||||||
professional_id = LaboratoryProfessional.get_lab_professional()
|
professional_id = LaboratoryProfessional.get_lab_professional()
|
||||||
if not professional_id:
|
if not professional_id:
|
||||||
raise UserError(gettext('lims_rack.msg_user_no_professional'))
|
raise UserError(gettext(
|
||||||
|
'lims_planning_automatic.msg_user_no_professional'))
|
||||||
|
|
||||||
for s in sheets:
|
for s in sheets:
|
||||||
s.professional = professional_id
|
s.professional = professional_id
|
||||||
|
|
|
@ -8,3 +8,4 @@ extras_depend:
|
||||||
xml:
|
xml:
|
||||||
planification.xml
|
planification.xml
|
||||||
laboratory.xml
|
laboratory.xml
|
||||||
|
message.xml
|
||||||
|
|
Loading…
Reference in New Issue