Our state of the art Gantt chart


Post by isadogan »

Hi,

In the task edit resources tab;

First, I added a "Frontend Developer" resource.

Second, I clicked again the "+" button.

Then, "Seviye" column behaves like selecting automatically the preselected data. But I didn't choose it yet.

Also If I leave "Seviye" column like this and select a resource, sync request fail. Because "Seviye" isn't included in the JSON.

Dou you have any idea what I'm wrong here?

Attachments
ss2.png
ss2.png (27.47 KiB) Viewed 342 times

Post by marcio »

Hey isadogan,

Could you please share how you set up the "Seviye" field? With that will be a lot easier to assist you on this.

Best regards,
Márcio


Post by isadogan »

Hi marcio,

Thank you for your response.

This example will be similar to you :)

Here is an example by using your advanced demo:

features : {
        baselines : {
            disabled : true
        },
        dependencyEdit : true,
        filter         : true,
        labels         : {
            left : {
                field  : 'name',
                editor : {
                    type : 'textfield'
                }
            }
        },
        parentArea : {
            disabled : true
        },
        progressLine : {
            disabled   : true,
            statusDate : new Date(2019, 0, 25)
        },
        rollups : {
            disabled : true
        },
        rowReorder : {
            showGrip : true
        },
        timeRanges : {
            showCurrentTimeLine : true
        },
        fillHandle    : true,
        cellCopyPaste : true,
        taskCopyPaste : {
            allowNativeClipboard : true
        },
taskEdit: {
          items: {
            resourcesTab: {
              items: {
                grid: {
                  columns: {
                    data: {
                      titleLevel: {
                        text: "SEVİYE",
                        field: "titleLevelId",
                        renderer: (props) => {
                          // display the name in the cell
                          const value = props.column.editor.store.data.find(
                            (item) => item.id === props.value
                          );
                          return value?.name;
                        },
                        editor: {
                          type: "combo",
                          valueField: "id",
                          displayField: "name",
                          required: true,
                          store: {
                            idField: "id",
                            data: [{id:1, name:"test 1"}, {id:2, name:"test 2"}],
                          },
                        },
                      },
                    },
                  },
                },
              },
            },
          },
        },

},


Post by marcio »

Hey isadogan,

That sounds like a bug, I created a ticket to verify https://github.com/bryntum/support/issues/6543

Best regards,
Márcio


Post by mats »

Your renderer code should be:

renderer: (props) => {
                          // display the name in the cell
                          const value = props.column.editor.store.data.find(
                            (item) => item.id === props.value
                          );
                          return value?.name || '';
                        },

Does that fix it?


Post by isadogan »

Hi mats,

Yes, it is.

Thanks,
Sefa DOĞAN


Post Reply