Migrate web_diagram from repository Odoo 13 to OCA repository Odoo 18

Open
#3,489 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
20/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
javascript
Domain
web-dev

Research direction

Read the linked migration PRs for Odoo 14–18 and the OpenUpgrade PR to understand the migration work already proposed. The issue also raises replacing Raphael.js and deciding where web_diagram_builder belongs, but gives no decided scope or acceptance criteria; clarify those before estimating completion.

Written by the indexing model from the issue text.

Description

enhancement

I did the migration of module web_diagram from Odoo 13 repository for each version to Odoo 18.

Original source: https://github.com/odoo/odoo/tree/6.1/addons/web_diagram
Final version source : https://github.com/odoo/odoo/tree/13.0/addons/web_diagram

PR odoo 14 https://github.com/OCA/web/pull/3490
PR odoo 15 https://github.com/OCA/web/pull/3491
PR odoo 16 https://github.com/OCA/web/pull/3492
PR odoo 17 https://github.com/OCA/web/pull/3493
PR odoo 18 https://github.com/OCA/web/pull/3494

Q1. Are we going to merge all the repositories from 14 to 18, and adapt OpenUpgrade?

https://github.com/OCA/OpenUpgrade/pull/3232

Q2. Last commit of Raphael.js is 2019

https://github.com/DmitryBaranovskiy/raphael

Maybe we can change the library.

Comparison
❌ Raphael.js ✅ Cytoscape.js ⚠️ D3.js ⚠️ Mermaid ⚠️ Vis.js Network
Maintenance ❌ Abandoned (~2020) ✅ Very active ✅ Very active ✅ Very active ✅ Active
Performance ⚠️ ~100 nodes ✅ 10k+ nodes ✅ 10k+ nodes ⚠️ ~200 nodes ✅ 5k+ nodes
Auto layout ❌ Manual ✅ Built-in (dagre, cola, elk…) ⚠️ Third-party plugins ❌ Declarative only ✅ Built-in force-directed
Interactivity ✅ Yes ✅ Full ✅ Full (must be coded) ❌ Static ✅ Full
License MIT ✅ MIT ✅ ISC ✅ MIT ✅ Apache 2.0 / MIT ✅
Bundle size ~100 KB ~200 KB ~50 KB (core) ~600 KB ~700 KB
Learning curve Medium Medium ⚠️ High Low Low
Use case General SVG graphics Graph / network Data visualization Declarative diagrams Interactive networks
GitHub DmitryBaranovskiy/raphael cytoscape/cytoscape.js d3/d3 mermaid-js/mermaid visjs/vis-network

Q3. web_diagram_builder

I create the application to show diagram on selected model with domain builder for Odoo 18. Maybe web_diagram_builder is more appropriate to be on repository https://github.com/oca/server-tools ?
Project in development https://github.com/TechnoLibre/web/tree/18.0_imp_web_diagram_builder
This module depend on web_diagram for example usage.

Can manage multiple diagram :

Image

Can use template, choose model and recursive field, filter domain :

Image

Show diagram of selected data :

Image
Dominant language
JavaScript
Stars
1.2k
Forks
2.2k
Avg merge
3d 15h
Merged PRs (30d)
30

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from OCA/web

All issues in OCA/web

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.