Merge pull request #873 from expsa/dev_odex25_transactions
Dev odex25 transactions
This commit is contained in:
commit
7173707988
|
|
@ -59,8 +59,8 @@ class ForwardTransactionWizard(models.TransientModel):
|
|||
# 'res_id': transaction.id,
|
||||
# })
|
||||
attachment = self.env['ir.attachment'].create({
|
||||
'name': self.filename,
|
||||
'datas': self.attachment_id,
|
||||
'name': 'Forward Attachment',
|
||||
'datas': self.forward_attachment_id,
|
||||
'type': 'binary',
|
||||
'res_model': 'cm.attachment.rule', # ضع هنا اسم النموذج الذي تقوم بحفظ المرفق له
|
||||
'res_id': transaction.id, # المعرف المرتبط بالسجل الأساسي الذي تريد ربط المرفق به
|
||||
|
|
@ -69,7 +69,7 @@ class ForwardTransactionWizard(models.TransientModel):
|
|||
'file_save': [(4, attachment.id)], # ربط المرفق الذي تم إنشاؤه
|
||||
# 'name': transaction.id,
|
||||
'description': self.att_description,
|
||||
'attachment_filename': self.filename,
|
||||
'attachment_': self.filename,
|
||||
})
|
||||
# transaction.file_save = [(4, attachment.id)] # Link the created attachment
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue