Our state of the art Gantt chart


Post by icemaul »

I have gantconfig with autosync on and have few custom columns, all other columns are auto syncing fine but this one is not syncing on click
{
          htmlEncode: false,
            field: "my_checkbox",
            text: "Check",
          type: "widget",

          widgets: [
            {
              type: "checkbox",
              
            }
          ]
        }
i can see checkbox doing check and uncheck but dont see sync request being sent,can you please help ?

Post by pmiklashevich »

Your widget doesn't set value to the record. Please use CheckColumn. It has code which handles checkbox change and sets value to the record:
        {
            type  : 'check',
            field : 'my_checkbox',
            text  : 'Check'
        },

Pavlo Miklashevych
Sr. Frontend Developer


Post by pmiklashevich »

Please don't forget to describe your data field, for example:
export default class MyTask extends TaskModel {

    static get fields() {
        return [
            { name : 'my_checkbox', type : 'boolean' }
        ];
    }
}

const project = window.project = new ProjectModel({

    // Let the Project know we want to use our own Task model with custom fields / methods
    taskModelClass : MyTask,

Pavlo Miklashevych
Sr. Frontend Developer


Post Reply