Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[12.0][ADD] add pro velo project link on resource form #120

Merged
merged 1 commit into from
Dec 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions provelo_analytic_account/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
"views/resource_location_views.xml",
"views/account_invoice_views.xml",
"views/resource_activity_type_views.xml",
"views/resource_resource_views.xml",
"views/actions.xml",
"views/menus.xml",
],
Expand Down
1 change: 1 addition & 0 deletions provelo_analytic_account/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@
from . import provelo_project
from . import account_invoice
from . import resource_activity_type
from . import resource_resource
from . import sale_order
14 changes: 14 additions & 0 deletions provelo_analytic_account/models/resource_resource.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# SPDX-FileCopyrightText: 2024 Coop IT Easy SC
#
# SPDX-License-Identifier: AGPL-3.0-or-later

from odoo import fields, models


class ResourceResource(models.Model):
_inherit = "resource.resource"

pv_project_id = fields.Many2one(
"pv.project",
string="Pro Velo Project",
)
23 changes: 23 additions & 0 deletions provelo_analytic_account/views/resource_resource_views.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8" ?>
<!--
SPDX-FileCopyrightText: 2024 Coop IT Easy SC

SPDX-License-Identifier: AGPL-3.0-or-later
-->
<odoo>

<record id="resource_planning_resource_form" model="ir.ui.view">
<field name="name">resource.planning.resource.form</field>
<field name="model">resource.resource</field>
<field
name="inherit_id"
ref="resource_planning.resource_planning_resource_form"
/>
<field name="arch" type="xml">
<field name="location" position="after">
<field name="pv_project_id" />
</field>
</field>
</record>

</odoo>
Loading