StaticJsCMS / static-cms

A Git-based CMS for Static Site Generators
https://staticjscms.netlify.app/
MIT License
591 stars 53 forks source link

date fields won't display in summaries (or as sortable fields) #1089

Open mimecine opened 7 months ago

mimecine commented 7 months ago

Title says it all.

    summary: "{{title}} - {{venue | upper | truncate(10,'...')}} - {{start}} to {{end | date('yyyy')}}"
    summary_fields: ["title","venue","start","end"]
    sortable_fields: 
      fields: ["title","venue","start","end"]
      default:
        field: "end"
        direction: Descending

The above exposes another problem: format filters do nothing. I did try to prefix the fields like {{fields.start}} but there was no difference in behavior.

KaneFreeman commented 5 months ago

What version are you using?

mimecine commented 5 months ago

I just tried with 4.3.0 from cdn and it has the same problems. I would love to dive into it and provide a PR (if I manage to fix anything), but I have a hard time finding where the code is.