Browse Source

fixup! fixup! [ADD] new module module_analysis

12.0
Sylvain LE GAL 6 years ago
committed by OCA-git-bot
parent
commit
9e743e9edb
  1. 1
      .travis.yml
  2. 5
      module_analysis/README.rst
  3. 6
      module_analysis/models/ir_module_module.py
  4. 5
      module_analysis/readme/USAGE.rst
  5. BIN
      module_analysis/static/description/analysis_pie.png
  6. 0
      module_analysis/static/description/analysis_pivot.png
  7. 11
      module_analysis/views/view_ir_module_module.xml

1
.travis.yml

@ -10,6 +10,7 @@ addons:
apt:
packages:
- expect-dev # provides unbuffer utility
- cloc # module_analysis
env:
global:

5
module_analysis/README.rst

@ -96,7 +96,10 @@ Usage
Open the stats to analyze the detail of the code installed
.. image:: https://raw.githubusercontent.com/legalsylvain/server-tools/12.0-ADD-module_analysis/module_analysis/static/description/analysis.png
.. image:: https://raw.githubusercontent.com/legalsylvain/server-tools/12.0-ADD-module_analysis/module_analysis/static/description/analysis_pivot.png
.. image:: https://raw.githubusercontent.com/legalsylvain/server-tools/12.0-ADD-module_analysis/module_analysis/static/description/analysis_pie.png
Bug Tracker
===========

6
module_analysis/models/ir_module_module.py

@ -104,10 +104,10 @@ class IrModuleModule(models.Model):
values = self._prepare_values_from_json(json_res)
module.write(values)
except Exception as e:
except Exception:
_logger.warning(
'Failed to execute the cloc command on module %s',
module.name, e.message())
'Failed to execute the cloc command on module %s' % (
module.name))
@api.model
def _get_analyzed_languages(self):

5
module_analysis/readme/USAGE.rst

@ -2,4 +2,7 @@
Open the stats to analyze the detail of the code installed
.. image:: ../static/description/analysis.png
.. image:: ../static/description/analysis_pivot.png
.. image:: ../static/description/analysis_pie.png

BIN
module_analysis/static/description/analysis_pie.png

After

Width: 374  |  Height: 404  |  Size: 16 KiB

0
module_analysis/static/description/analysis.png → module_analysis/static/description/analysis_pivot.png

Before

Width: 578  |  Height: 404  |  Size: 34 KiB

After

Width: 578  |  Height: 404  |  Size: 34 KiB

11
module_analysis/views/view_ir_module_module.xml

@ -41,13 +41,22 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
</field>
</record>
<record id="view_ir_module_module_graph" model="ir.ui.view">
<field name="model">ir.module.module</field>
<field name="arch" type="xml">
<graph type="pie">
<field name="module_type_id" type="row"/>
</graph>
</field>
</record>
<record id="action_ir_module_module_by_type" model="ir.actions.act_window">
<field name="name">Installed Modules by Types</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">ir.module.module</field>
<field name="domain">[('state', '=', 'installed')]</field>
<field name="view_type">form</field>
<field name="view_mode">pivot</field>
<field name="view_mode">pivot,graph</field>
</record>
<menuitem id="menu_module_by_type"

Loading…
Cancel
Save