跳至內容
選單
此問題已被標幟
1 回覆
1539 瀏覽次數

Hi

I have Odoo Enterprise v18 in res_partner.py

from odoo import models, fields

class ResPartner(models.Model):
_inherit = 'res.partner'

all_partner_messages = fields.One2many(
'x_discussions', # Liitännäinen malli (korjattu oikein kuvien perusteella)
'x_studio_partner_id', # Suhdekenttä, joka liittyy henkilöön tai yritykseen
string="Kaikki keskustelut",
domain="[('x_studio_partner_id.parent_id', '=', id)]",
help="Kaikki tähän yritykseen liittyvien henkilöiden keskustelut."
)

/views/res_partner_views.xml

<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<record id="view_partner_form_inherit" model="ir.ui.view">
<field name="name">res.partner.form.inherit</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="arch" type="xml">
<notebook position="inside">
<page string="Keskustelut">
<field name="all_partner_messages">
<tree>
<field name="x_studio_discussion_date_and_time" string="Ajankohta"/>
<field name="x_name" string="Kuvaus"/>
<field name="x_studio_partner_id" string="Kontakti"/>
<field name="x_studio_user_id" string="Vastuuhenkilö"/>
</tree>
</field>
</page>
</notebook>
</field>
</record>
</odoo>
頭像
捨棄
作者

I don't understand why this forum eats the first portion of my message for the second time? Let me try again as a reply.

I have Odoo Enterprise v18 in Odoo.sh. I'm trying to install my first custom module, but it doesn't show up in Apps, after Odoo rebuild, "Update Apps list" steps.

I have tried my custom module folder in /src/user and in /src/user/addons -paths. I can see from odoo log that the /src/user is not in Odoo addons path.

2025-01-20 21:00:12,996 292 INFO ? odoo: Odoo version 18.0
2025-01-20 21:00:12,996 292 INFO ? odoo: Using configuration file at /home/odoo/.config/odoo/odoo.conf
2025-01-20 21:00:12,996 292 INFO ? odoo: addons paths: ['/home/odoo/src/odoo/odoo/addons', '/home/odoo/data/addons/18.0', '/home/odoo/src/odoo/addons', '/home/odoo/src/enterprise', '/home/odoo/src/themes']

How can I work around this problem?

Best regards
  Janne

最佳答案

Hi,
Did you have manifest file for your app and addons path added properly in conf file ?
Thanks

頭像
捨棄
作者

Thanks Niyas. After digging deeper into documentation and experimenting with other third-party plugins I realized, that my manifest file was not correct. Odoo.sh seems to add the /src/user/... path into addons path automatically when the manifest file is correct.

相關帖文 回覆 瀏覽次數 活動
2
8月 25
323
4
7月 25
576
2
3月 25
6409
1
2月 25
1114
1
10月 24
1940