제공한 날짜 및 시간을 선택한 형식으로 반환합니다. 이 기능은 날짜의 기본 출력(jiraDateTime)을 읽기 쉬운 형식으로 변환하는데 유용합니다. 이 페이지에 나열된 모든 날짜의 끝에 날짜 형식을 추가할 수 있습니다.
전체 형식 목록은 다음과 같습니다 :
포맷
1979년 11월 1일 목요일 오전 6:23:12 EST
기본값(지정되지 않음)
Nov 1, 1979 6:23:12 AM
jiraDate
1979-11-01
jiraDateTime
1979-11-01T06:23:12.0-0500
jqlDate
1979-11-01
jqlDateTime
1979-11-01 06:23
shortDate
11/1/79
shortTime
6:23 AM
shortDateTime
11/1/79 6:23 AM
mediumDate
Nov 1, 1979
mediumTime
6:23:12 AM
mediumDateTime
Nov 1, 1979 6:23:12 AM
longDate
November 1, 1979
longTime
6:23:12 AM EST
longDateTime
November 1, 1979 6:23:12 AM EST
fullDate
Thursday, November 1, 1979
fullTime
6:23:12 AM EST
fullDateTime
Thursday, November 1, 1979 6:23:12 AM EST
형식("<pattern>") (예: 형식("dd/MM/yyy"))
01/11/1979
예제
{{now.jiraDate}}
//returns
2020-08-18
This issue was created on {{issue.created.format("dd/MM/yyyy")}}
//returns
This issue was created on 18/08/2020
This issue was updated at {{issue.updated.shortTime}}.
//returns
This issue was updated at 2:40 AM.
{{[date1].diff([date2]).[unit]}}
Returns the amount of time between date1 and date2, in the unit specified. If date2 is earlier than date1, the value returned will be negative. You can combine this with the smart value to return a positive value.
The units that can be used with this smart value are:
millis
seconds
minutes
hours
days
weeks
months
years
businessDays
You can also change the format of the output using the following:
prettyPrint - displays the difference in words, e.g.: 2 days 3 hours.
{{now.diff(issue.created).weeks}}
//returns
-4
This issue was created {{now.diff(issue.created).weeks.abs}} weeks ago.
//returns
This issue was created 4 weeks ago.
{{[date1].isAfter([date2])}}
Returns true if date1 is after date2, and false if not.
Example
{{now.isAfter(issue.created)}}
//returns
true
{{[date1].isBefore([date2])}}
Returns true if date1 is before date2, and false if not.
Example
{{now.isBefore(issue.created)}}
//returns
false
{{[date1].isEquals[(date2)]}}
Returns true if date1 and date2 are the same, and false if not.
0 Comments