odoo-ide / pycharm-odoo

PyCharm plugin for Odoo
https://plugins.jetbrains.com/plugin/13499-odoo
Other
44 stars 5 forks source link

Unresolved external id references to records declared inside field tags #423

Closed jcfernandez-890825 closed 11 months ago

jcfernandez-890825 commented 11 months ago

odoo/addons/l10n_be/data/account_tax_template_data.xml image

But this record (Selected in blue) tax_report_line_03_tag does exist here: odoo/addons/l10n_be/data/account_tax_report_data.xml image

trinhanhngoc commented 11 months ago

Hi @jcfernandez-890825 . Thank you very much! I didn't know that Odoo supports declaring records inside field tags. I will soon add support for this feature.

trinhanhngoc commented 11 months ago

Hi @jcfernandez-890825 ,

The new version 2023.9.4 has been released with support for nested record definitions.

jcfernandez-890825 commented 11 months ago

Awesome, this will help me a lot. Thanks, you rock, as usual.

jcfernandez-890825 commented 11 months ago

@trinhanhngoc

A thing that I spotted after upgrading, if you do Ctrl+Click on tax_report_line_03_tag definition you get No usages found in Project Files: image

However this works the other way around: image

if you do Ctrl+Click on ref('tax_report_line_03_tag'), you will get sent back to its definition, as it should.

Can the 1st be fixed?

trinhanhngoc commented 11 months ago

@jcfernandez-890825 ,

This bug is already on my to-do list to fix soon! A workaround is to press Ctrl+Click at the start of the tag instead of at the id attribute value, e.g: <cursor><record id="..."