diff --git a/import_lots/doc/RELEASE_NOTES.md b/import_lots/doc/RELEASE_NOTES.md index c91a1ac88..6325e78fc 100644 --- a/import_lots/doc/RELEASE_NOTES.md +++ b/import_lots/doc/RELEASE_NOTES.md @@ -4,3 +4,8 @@ #### Version 17.0.1.0.0 #### ADD - Initial commit for Import Lot from Excel + +#### 05.07.2024 +#### Version 15.0.1.0.2 +##### Fix on the validation for import +- Bug Fix \ No newline at end of file diff --git a/import_lots/wizard/lots_attachment.py b/import_lots/wizard/lots_attachment.py index f8f991507..705b6415c 100644 --- a/import_lots/wizard/lots_attachment.py +++ b/import_lots/wizard/lots_attachment.py @@ -21,7 +21,7 @@ ############################################################################### from odoo import fields, models from odoo import _ -from odoo.exceptions import UserError +from odoo.exceptions import UserError, ValidationError import openpyxl import base64 from io import BytesIO @@ -29,7 +29,6 @@ from io import BytesIO class LotsAttachment(models.TransientModel): """Class for lots wizard""" - _name = 'lot.attachment' _description = "Lots Attachment" @@ -105,6 +104,9 @@ class LotsAttachment(models.TransientModel): 'type': 'ir.actions.client', 'tag': 'reload', } + else: + raise ValidationError( + _('Check whether you upload the document')) def action_download_sample(self): """For downloading a sample excel file"""