Diagram view error: field names 'wkf_id', 'act_from' and 'act_to' are hard-coded in client

Bug #932805 reported by Francois Degrave
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Web (MOVED TO GITHUB)
Fix Released
Low
OpenERP R&D Web Team

Bug Description

Hi!

I try to create a diagram view of my own object, as I used to do it in the past.

The view itself works OK (although it is way less powerful than the one in the previous client, but whatever). But if I click on "new node", I get the following error (in the js console):

Uncaught TypeError: Cannot read property 'modifiers' of undefined
http://localhost:8069/web_diagram/static/src/js/diagram.js?debug=1329316330.14:252

It seems it is because the field 'wkf_id' is not found in the view. But of course, my field is not called 'wkf_id' !

Instead of 'wkf_id' the name should be the name of the field chosen to reference the object for which the diagram view is created, defined on the object chosen to represent the nodes.

The same problem will arise with 'act_from' and 'act_to': they should be replaced with the names of the fields referencing respectively the source node and destination node, defined on the object chosen to represent the arrows.

Related branches

Revision history for this message
Vaibhav Darji (vaibhav-openerp) wrote :

Hello Francois,

Diagram view is improved in
https://code.launchpad.net/~openerp-dev/openerp-web/trunk-diagram-draw2d
It will be merge soon in trunk branch.

Thanks.

Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

Using the marketing_campaign module it seems I cannot create a new campaign activity using the campaign diagram view indeed.
The related error in debug mode is:

 form_controller.fields[fld] is undefined
  at form_controller.fields[fld].modifiers.readonly = true; (diagram.js - line 252)

Changed in openerp-web:
assignee: nobody → OpenERP R&D Web Team (openerp-dev-web)
importance: Undecided → Low
milestone: none → 6.1
status: New → Confirmed
Revision history for this message
Xavier (Open ERP) (xmo-deactivatedaccount) wrote :

Should be fixed as of revision <email address hidden>

the diagram view now correctly uses arrow/@source and arrow/@destination for the transitions and `node_parent_field` value returned by graph_get for the link to the model in the diagram view.

Changed in openerp-web:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.