Changes between Version 18 and Version 19 of EpochFieldPlugin
- Timestamp:
- Apr 9, 2015, 12:08:28 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
EpochFieldPlugin
v18 v19 23 23 [[TicketQuery(component=EpochFieldPlugin,group=type,format=progress)]] 24 24 25 == Get A Plugin or Source25 == Download 26 26 27 27 Download the zipped source from [download:epochfieldplugin here].[[BR]] 28 29 == Source 30 28 31 You can check out EpochFieldPlugin from [http://trac-hacks.org/svn/epochfieldplugin here] using Subversion, or [source:epochfieldplugin browse the source] with Trac.[[BR]] 29 32 入手は[download:epochfieldplugin zip], [http://trac-hacks.org/svn/epochfieldplugin Subversion], [source:epochfieldplugin Trac]でどうぞ。 … … 47 50 === Epoch report === #report 48 51 49 In t rac.ini specifyfield-names you want to translate from epoch to datetime-string in regular-expressions as follows: / trac.ini で 日時表記したいカラム名を正規表現で指定して:52 In the `trac.ini` file specify the field-names you want to translate from epoch to datetime-string in regular-expressions as follows: / trac.ini で 日時表記したいカラム名を正規表現で指定して: 50 53 {{{ 51 54 #!ini … … 59 62 {{{ 60 63 #!sql 61 selectid, summary, ticket.time,64 SELECT id, summary, ticket.time, 62 65 a.time as accepted_datetime, 63 66 c.time as closed_datetime, 64 67 c.author as Closer 65 from ticket 68 FROM ticket 69 LEFT JOIN ( 70 SELECT ticket, author, newvalue AS status, MAX(time) AS time 71 FROM ticket_change 72 WHERE field = 'status' AND newvalue = 'accepted' 73 GROUP BY ticket, newvalue, author 74 ) AS a ON (a.ticket = ticket.id AND a.status = 'accepted') 66 75 left join ( 67 SELECT ticket, author, newvalue AS status, max(time) AS time 68 FROM ticket_change WHERE field = 'status' and newvalue = 'accepted' 76 SELECT ticket, author, newvalue AS status, MAX(time) AS time 77 FROM ticket_change 78 WHERE field = 'status' AND newvalue = 'closed' 69 79 GROUP BY ticket, newvalue, author 70 ) AS a on (a.ticket = ticket.id and a.status = 'accepted') 71 left join ( 72 SELECT ticket, author, newvalue AS status, max(time) AS time 73 FROM ticket_change WHERE field = 'status' and newvalue = 'closed' 74 GROUP BY ticket, newvalue, author 75 ) AS c on (c.ticket = ticket.id and c.status = 'closed') 80 ) AS c ON (c.ticket = ticket.id AND c.status = 'closed') 76 81 }}} 77 82