Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,551,823
Community Members
 
Community Events
184
Community Groups

Issue with date fields

Hello! We use the Jira API for external systems. We can import issues (tickets) in the external systems, but we have an issue in one of our client with the date field (Date picker). When the user set for example 08/May/23 in the field and then import the issue, the value will be offset by 1 day, i.e. 07/May/23.

Could be a problem with time zones? I mean that in the user profile one time zone, and on his personal computer another time zone and they are different?

1 answer

0 votes
Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 03, 2023

Yes. My first guess would be timezones.

Jira stores dates as full date-time values where the time part is "00:00" (midnight). If it gets shifted only an hour earlier, then it becomes the previous day.

Check:

  1. Jira expects these in a normalized timezone, probably UTC. Check that and make sure that you pass them in UTC.
  2. Also, Jira users can choose their own preferred timezone. The value will be displayed in the timezone of the user, also check that.

@Aron Gombas _Midori_ Thank you for your response!

1) Could you please clarify a little about that answer?

2) I can check it in the user's profile? Am I right?

Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 03, 2023
  1. You wrote "import", but I am not sure which mechanism you meant exactly here:
    1. If it is the CSV import, then you should check in which timezone it expects date values. If it is the REST API, you should check the same.
    2. After you understood the expectation, you should guarantee that your date values meet that. For example, if the external system produces dates in timezone X, but the import mechanism expects them in timezone Y, then you should implement the conversion from X to Y before importing.
  2. Yes. But Jira has its configurable system-wide timezone. If a user doesn't sets his/her own timezone, then he will the system-wide timezone.

1) We have an external system, where we can "import" tickets here by calling Jira Rest API and based on the API response, create tickets in an external system. For example, a Jira ticket can have some custom field with Date picker type and value of the custom field, for example, 08/May/23. When we do "importing" aka calling Jira rest API to get all tickets and based on the response data, we create tickets in the external system, as a result, the value of the custom field in the external system will be 07/May/23, i.e. offset by 1 day. We parse the value from a response like:

new Date('08/May/23').toISOString()

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events