Predecessors (ss, fs, days etc.) localization


#1

Hi there,
I need to translate the predecessors to pt (portuguese) in your inline mode (https://docs.dhtmlx.com/gantt/samples/07_grid/12_inline_edit_key_nav.html). So SS is going to be II, FS is TI and so on.
The approach that I was thinking was to capture the predecessor event so I could switch the SS for II, FS for TI, day for dia and so on, but I did not find anywhere on your documentation that shows me how to capture this event, therefore I would appreciate your help. However, if there is a better way, simpler, of doing this please advise.
Thanks


#2

Hello Pedro,
You can change the string names for predecessors in the link formatter configuration:
https://docs.dhtmlx.com/gantt/desktop__formatters_ext.html#linkformatter
You just need to add the names in the labels property:

var linksFormatter = gantt.ext.formatters.linkFormatter({
  durationFormatter: formatter,
  labels: {
    finish_to_finish: "TT",
    finish_to_start: "TI",
    start_to_start: "II",
    start_to_finish: "IT"
  }
});

Here is an example:
http://snippet.dhtmlx.com/5/c44ff80a8