Versions in dropdown all have the same timestamp

default discord avatar
allanc
5 months ago
7

Hi, does anyone get an issue when trying to compare versions that they all display the same timestamp?


Screenshotted is


[myUrl]/admin/collections/[myCollection]/[docId]/versions


versus

[myUrl]/admin/collections/[myCollection]/[docId]/versions/[versionIdToCompareWithOthers]


Second screenshot, where I'm getting the bug:



The versions are awesome, i'm willing to give a shot at a PR for this if it's reproducible by others ๐Ÿ™‚

  • default discord avatar
    Jarrod
    5 months ago

    Looks like this line should be using

    updatedAt

    instead of

    createdAt

    :

    https://github.com/payloadcms/payload/blob/master/src/admin/components/views/Version/Compare/index.tsx#L79


    Check out our contributing doc to get started locally ๐Ÿ™‚

    https://github.com/payloadcms/payload/blob/master/contributing.md#code

    Let me know if you run into anything!

  • default discord avatar
    allanc
    5 months ago

    Thanks @Jarrod, i'll give it a shot



    hey @Jarrod, what's the process for creating a new branch? should i create an issue first?

  • default discord avatar
    Jarrod
    5 months ago

    Yeah I think creating an issue first sounds good! The issue template will ask you to fork the repo, but in your case I you can skip that part and just explain whatโ€™s happening, link this discord thread in the issue too.



    Then you can clone this repo down, create a branch and make a PR. Since you are wanting to fix the issue you can likely wait to create the issue until you have a branch with a fix ready. Sound good?

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!

Star

Connect with the Payload Community on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.