Skip to content
This repository has been archived by the owner on Feb 17, 2024. It is now read-only.

date/time types need support for a sysdate or now default value. #758

Open
rspremulli-sf opened this issue Jul 3, 2021 · 0 comments
Open

Comments

@rspremulli-sf
Copy link

rspremulli-sf commented Jul 3, 2021

A common use case for dates on a property is to default them to whatever the current date is. A classic example of this is a property representing the creation datetime of an object. It would be defaulted to whatever the current datetime is on the system for auditing purposes. There is no way to define such a default value today however, there is no keyword that is valid for the default value facet; only a datetime is legal.

Expectation: support similar functionality to the below:

SampleType:
  properties:
    creationDate?:
      type:datetime-only
      default: now
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

1 participant