-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by andhit-r
- Loading branch information
Showing
9 changed files
with
173 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg | ||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html | ||
:alt: License: AGPL-3 | ||
|
||
=========================== | ||
Company Capital Information | ||
=========================== | ||
|
||
|
||
Installation | ||
============ | ||
|
||
To install this module, you need to: | ||
|
||
1. Clone the branch 14.0 of the repository https://github.com/open-synergy/ssi-partner | ||
2. Add the path to this repository in your configuration (addons-path) | ||
3. Update the module list | ||
4. Go to menu *Setting -> Modules -> Local Modules* | ||
5. Search For *Company Capital Information* | ||
6. Install the module | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues | ||
<https://github.com/open-synergy/ssi-partner/issues>`_. | ||
In case of trouble, please check there if your issue has already been reported. | ||
If you spotted it first, help us smashing it by providing a detailed | ||
and welcomed feedback. | ||
|
||
|
||
Credits | ||
======= | ||
|
||
Contributors | ||
------------ | ||
|
||
* Michael Viriyananda <viriyananda.michael@gmail.com> | ||
* Andhitia Rama <andhitia.r@gmail.com> | ||
|
||
Maintainer | ||
---------- | ||
|
||
.. image:: https://simetri-sinergi.id/logo.png | ||
:alt: PT. Simetri Sinergi Indonesia | ||
:target: https://simetri-sinergi.id.com | ||
|
||
This module is maintained by the PT. Simetri Sinergi Indonesia. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# Copyright 2024 OpenSynergy Indonesia | ||
# Copyright 2024 PT. Simetri Sinergi Indonesia | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from . import models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Copyright 2023 OpenSynergy Indonesia | ||
# Copyright 2023 PT. Simetri Sinergi Indonesia | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
{ | ||
"name": "Company Capital Information", | ||
"version": "14.0.1.0.0", | ||
"website": "https://simetri-sinergi.id", | ||
"author": "PT. Simetri Sinergi Indonesia, OpenSynergy Indonesia", | ||
"license": "AGPL-3", | ||
"installable": True, | ||
"application": False, | ||
"depends": [ | ||
"ssi_master_data_mixin", | ||
"ssi_partner", | ||
], | ||
"data": [ | ||
"security/ir.model.access.csv", | ||
"views/res_partner_views.xml", | ||
], | ||
"demo": [], | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Copyright 2024 OpenSynergy Indonesia | ||
# Copyright 2024 PT. Simetri Sinergi Indonesia | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from . import ( | ||
res_partner, | ||
company_shareholder, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Copyright 2023 OpenSynergy Indonesia | ||
# Copyright 2023 PT. Simetri Sinergi Indonesia | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import fields, models | ||
|
||
|
||
class CompanyShareholder(models.Model): | ||
_name = "company.shareholder" | ||
_description = "Company Shareholder" | ||
_order = "partner_id, sequence, id" | ||
|
||
partner_id = fields.Many2one( | ||
string="Partner", | ||
comodel_name="res.partner", | ||
required=True, | ||
ondelete="cascade", | ||
) | ||
sequence = fields.Integer( | ||
string="Sequence", | ||
required=True, | ||
default=10, | ||
) | ||
shareholder_id = fields.Many2one( | ||
string="Shareholder", | ||
comodel_name="res.partner", | ||
required=True, | ||
) | ||
number_of_share = fields.Integer( | ||
string="Num. Of Share", | ||
required=True, | ||
default=1, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Copyright 2024 OpenSynergy Indonesia | ||
# Copyright 2024 PT. Simetri Sinergi Indonesia | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
|
||
from odoo import fields, models | ||
|
||
|
||
class ResPartner(models.Model): | ||
_name = "res.partner" | ||
_inherit = "res.partner" | ||
|
||
shareholder_ids = fields.One2many( | ||
string="Shareholders", | ||
comodel_name="company.shareholder", | ||
inverse_name="partner_id", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink | ||
access_company_shareholder_configurator,company.shareholder - configurator,model_company_shareholder,ssi_partner.contacts_configurator_group,1,1,1,1 | ||
access_company_shareholder_all,company.shareholder - all,model_company_shareholder,,1,0,0,0 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<?xml version="1.0" encoding="UTF-8" ?> | ||
<odoo> | ||
<record model="ir.ui.view" id="res_partner_view_form"> | ||
<field name="name">res.partner form - Creditor Debtor</field> | ||
<field name="model">res.partner</field> | ||
<field name="inherit_id" ref="base.view_partner_form" /> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//page[@name='sales_purchases']" position="after"> | ||
<page | ||
name="capital" | ||
string="Capital" | ||
attrs="{'invisible': [('is_company','=',False)]}" | ||
> | ||
<field name="shareholder_ids"> | ||
<tree editable="bottom"> | ||
<field name="sequence" widget="handle" /> | ||
<field | ||
name="shareholder_id" | ||
domain="[('parent_id','=',False),('id','!=',parent.id)]" | ||
/> | ||
<field name="number_of_share" /> | ||
</tree> | ||
<form> | ||
<group name="shareholder_1" colspan="4" col="2"> | ||
<field name="sequence" /> | ||
<field | ||
name="shareholder_id" | ||
domain="[('parent_id','=',False),('id','!=',parent.id)]" | ||
/> | ||
<field name="number_of_share" /> | ||
</group> | ||
</form> | ||
</field> | ||
</page> | ||
</xpath> | ||
</field> | ||
</record> | ||
</odoo> |