pnp / List-Formatting

List Formatting Samples for use in SharePoint and Microsoft Lists
https://pnp.github.io/List-Formatting/
MIT License
1.7k stars 823 forks source link

List-Formatting/view-samples /project-gantt-chart Issue #717

Closed edqu1001 closed 9 months ago

edqu1001 commented 9 months ago

I have created all the columns with the appropiate format, and a final one named "Gantt" with the .JSON file, but it doesn´t seem to create the view.

I´ve checked:

I leave a SS. What could be the issue?

image

tecchan1107 commented 9 months ago

Hi @edqu1001 !

What could be the issue?

project-gantt-chart is a view formatting, not a column formatting. Try applying JSON to the view formatting.

image

If you want to display a Gantt chart in a column, please try generic-gantt-chart.

gdk-max commented 9 months ago

HI @edqu1001, Indeed, you should not create a column "Gantt" but use the code to format the whole view like @tecchan1107 mentioned. In this article there is a step-by-step guide https://exceltrainer.be/sharepoint/260/ It was written for the previous version of the code, si stick to your own columns and version 2 of the code and you will be fine.

Please let us know if you managed.

Geert

tecchan1107 commented 9 months ago

Thank you so much @gdk-max 🙏!!

edqu1001 commented 9 months ago

Solved! Thank you and looking forward to new updates! :) It would be nice if a commented version of the code could be made so we know how to modify small parameters as sizes, lenght, etc.

gdk-max commented 9 months ago

Hi, Yes, the comment about commenting is valid. I have tried to add a little bit of comments, but the json-code itself doesn't allow commenting. I have actually added comments to my original code, by adding the "_comment" tag, but that seems to be removed here since it is not really a comment but a label that is not supported and therefore ignored. Geert