I work with file storage module and need to upload files to module. In my definition i use
class TestClass(models.TransientModel):
_name = "module_name.test_class"
attachment_id = fields.Many2one(
comodel_name='ir.attachment',
string="newFileVersion",
index=True,
copy=False
)
When i use in xml
<field name="attachment_id"/>
it shows input dropdown item with alredy loaded in DB files, but I need to choose files from my local computer. What I did wrong. (Sorry for bad english)