Skip to content

Commit

Permalink
Merge a23e21c into 5700d0f
Browse files Browse the repository at this point in the history
  • Loading branch information
mikevhe18 committed Sep 11, 2019
2 parents 5700d0f + a23e21c commit 66dc887
Show file tree
Hide file tree
Showing 79 changed files with 2,677 additions and 0 deletions.
49 changes: 49 additions & 0 deletions l10n_id_djbc_kite_common/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
.. 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

===================================
Indonesia - Common Feature for KITE
===================================



Installation
============

To install this module, you need to:

1. Clone the branch 8.0 of the repository https://github.com/open-synergy/opnsynid-l10n-indonesia
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 *Indonesia - Common Feature for KITE*
6. Install the module

Bug Tracker
===========

Bugs are tracked on `GitHub Issues
<https://github.com/open-synergy/opnsynid-l10n-indonesia/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://opensynergy-indonesia.com/logo.png
:alt: OpenSynergy Indonesia
:target: https://opensynergy-indonesia.com

This module is maintained by the OpenSynergy Indonesia.
6 changes: 6 additions & 0 deletions l10n_id_djbc_kite_common/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import models
# from . import reports
27 changes: 27 additions & 0 deletions l10n_id_djbc_kite_common/__openerp__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
# pylint: disable=locally-disabled, manifest-required-author
{
"name": "Indonesia - Common Feature for KITE",
"version": "8.0.1.0.0",
"category": "localization",
"website": "https://opensynergy-indonesia.com",
"author": "OpenSynergy Indonesia",
"license": "AGPL-3",
"installable": True,
"depends": [
"l10n_id_djbc_app",
"product_m2mcategories",
"stock_adjustment_operation",
],
"data": [
"security/ir.model.access.csv",
"data/product_category_data.xml",
"menu.xml",
"views/djbc_kite_movement_type_views.xml",
"views/stock_picking_type_views.xml",
"views/product_category_views.xml",
"views/product_template_views.xml",
],
}
110 changes: 110 additions & 0 deletions l10n_id_djbc_kite_common/data/product_category_data.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2019 OpenSynergy Indonesia
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->

<openerp>
<data>

<record id="product_categ_kite_root" model="product.category">
<field name="name">KITE</field>
<field name="type">view</field>
</record>

<record id="product_categ_kite_bahan_baku" model="product.category">
<field name="name">Bahan Baku</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_bahan_penolong" model="product.category">
<field name="name">Bahan Penolong</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_barang_modal" model="product.category">
<field name="name">Barang Modal</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
</record>

<record id="product_categ_kite_peralatan_modal" model="product.category">
<field name="name">Peralatan Untuk Pembangunan, Perluasan, atau Konstruksi KITE</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_barang_modal"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_mesin" model="product.category">
<field name="name">Mesin</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_barang_modal"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_cetakan" model="product.category">
<field name="name">Cetakan Moulding</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_barang_modal"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_sparepart" model="product.category">
<field name="name">Sparepart</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_barang_modal"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_peralatan_kantor" model="product.category">
<field name="name">Peralatan Kantor</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_barang_contoh" model="product.category">
<field name="name">Barang Contoh</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_wip" model="product.category">
<field name="name">Barang WIP</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_hasil_produksi" model="product.category">
<field name="name">Hasil Produksi</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_scrap" model="product.category">
<field name="name">Scrap/Waste</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_pengemas" model="product.category">
<field name="name">Pengemas &amp; Alat Bantu Pengemas</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>

<record id="product_categ_kite_konsumsi" model="product.category">
<field name="name">Barang Untuk Konsumsi</field>
<field name="type">view</field>
<field name="parent_id" ref="product_categ_kite_root"/>
<field name="djbc_kite_ok" eval="1"/>
</record>
</data>
</openerp>
17 changes: 17 additions & 0 deletions l10n_id_djbc_kite_common/menu.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2019 OpenSynergy Indonesia
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->

<openerp>
<data>

<menuitem
id="djbc_reporting_kite_menu"
name="KITE"
sequence="1"
parent="l10n_id_djbc_app.djbc_reporting_menu"
/>


</data>
</openerp>
10 changes: 10 additions & 0 deletions l10n_id_djbc_kite_common/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import (
djbc_kite_movement_type,
stock_picking_type,
product_template,
product_category,
)
25 changes: 25 additions & 0 deletions l10n_id_djbc_kite_common/models/djbc_kite_movement_type.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from openerp import models, fields


class DjbcKiteMovementType(models.Model):
_name = "l10n_id.djbc_kite_movement_type"
_description = "DJBC KITE Movement Type"

name = fields.Char(
string="Name",
required=True,
)
code = fields.Char(
string="Code",
)
active = fields.Boolean(
string="Active",
default=True,
)
note = fields.Text(
string="Note",
)
13 changes: 13 additions & 0 deletions l10n_id_djbc_kite_common/models/product_category.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from openerp import models, fields


class ProductCategory(models.Model):
_inherit = "product.category"

djbc_kite_ok = fields.Boolean(
string="Category for DJBC KITE",
)
27 changes: 27 additions & 0 deletions l10n_id_djbc_kite_common/models/product_template.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from openerp import models, fields, api


class ProductTemplate(models.Model):
_inherit = "product.template"

@api.multi
@api.depends(
"categ_ids"
)
def _compute_djbc_kite_ok(self):
for template in self:
djbc_ok = False
for categ in template.categ_ids:
if categ.djbc_kite_ok:
djbc_ok = True
template.djbc_kite_ok = djbc_ok

djbc_kite_ok = fields.Boolean(
string="Can be Used for DJBC KITE",
compute="_compute_djbc_kite_ok",
store=True,
)
18 changes: 18 additions & 0 deletions l10n_id_djbc_kite_common/models/stock_picking_type.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# -*- coding: utf-8 -*-
# Copyright 2018 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from openerp import models, fields


class StockPickingType(models.Model):
_inherit = "stock.picking.type"

djbc_kite_movement_type_id = fields.Many2one(
string="DJBC's Kite Movement Type",
comodel_name="l10n_id.djbc_kite_movement_type"
)
djbc_kite_scrap = fields.Boolean(
string="DJBC's KITE Scrap?",
default=False,
)
5 changes: 5 additions & 0 deletions l10n_id_djbc_kite_common/reports/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright 2019 OpenSynergy Indonesia
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import lap_kite_mutasi_common

0 comments on commit 66dc887

Please sign in to comment.