Преглед на файлове

Update ir_attachment.py

erickabrego преди 7 месеца
родител
ревизия
55a2a1e1a5
променени са 1 файла, в които са добавени 1 реда и са изтрити 0 реда
  1. 1 0
      custom_sat_connection/models/ir_attachment.py

+ 1 - 0
custom_sat_connection/models/ir_attachment.py

@@ -57,6 +57,7 @@ class IrAttachment(models.Model):
             'company_id': self.env.company.id
         }
         attachment = self.env['ir.attachment'].sudo().create(data)
+        self.unlink()
         return self.download_zip(file_name_zip, attachment.id)
 
     def download_zip(self, filename, id_file):