Greasy Fork

24 Hour Converter for Jira

Convert 12 hour time formats in Jira to a more sensible format

< 脚本24 Hour Converter for Jira的反馈

评价:差评 - 脚本失效或无法使用

§
发表于:2024-02-07
编辑于:2024-02-07

It doesn't work for my jira instance ... also there is some script in background replacing times continuously, I don't have time to find that shit, so I just refresh every 300ms;-) You need to change:
@match -> to your domain name
"\d+\/...\/\d+ \d+:\d+ [ap]m" -> regex of your system time settings (mine is in this format: 06/Feb/24 10:18 PM) and appropriate "DD/MMM/YY hh:mm a"

BTW, it is really sad atlassian wasn't able to fix this fucking issue for 18 years now (as of 2024) .... https://jira.atlassian.com/browse/JRASERVER-10613
https://jira.atlassian.com/browse/JRACLOUD-10613


// ==UserScript==
// @name JIRA ISO time
// @match https://*.corp.com/jira/*
// @require https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.4/moment.min.js
// ==/UserScript==

window.setInterval(function(){var as = document.getElementsByTagName("time"); for (var i = 0; i < as.length; i++) as[i].innerText = as[i].innerText.replace(/(\d+\/...\/\d+ \d+:\d+ [ap]m)/gim, function (match){return moment(match, "DD/MMM/YY hh:mm a").format("YYYY-MM-DD HH:mm:ss")});}, 300);

发表回复

登录以发表回复。