補充一:JIRA不完全手冊
關鍵字: jira database renderer
1.格式化description和comment
需要用到jira中一個叫做renderer的外掛程式,這個外掛程式已經預設安裝了(3.13)
具體步驟是
1)Administration-field configuration,選擇需要配置的那個configuration點擊configure進去
2)Comment這個field後面有個Renderer的連結,點擊後選擇wiki style render就有強大的格式了。預設的Default Text Renderer只能給JRA-111這種JIRA key加上連結
wiki style renderer有很多格式,具體參見
http://www.atlassian.com/software/jira/docs/v3.13.2/configurerenderers.html
http://www.atlassian.com/software/jira/docs/v3.13.2/renderers_overview.html#wiki_macros
2.component lead
在項目配置介面中有一個Select assignees for components ,select這個詞上有個連結,進去選擇適合的人就可以了
3. assign screen cannot be configured
這是JIRA需要改進的一個地方,見官方JIRA
http://jira.atlassian.com/browse/JRA-8874
4. 編輯custom field中的select list 類型的options
目前JIRA無法實現這個功能,見
http://jira.atlassian.com/browse/JRA-2983
但是可以通過手工改資料庫資料來實現。
steps below maybe can help you:
1).update customfieldoption set customvalue='new value' where customvalue='old value';
2).update customfieldvalue set stringvalue='new value' where stringvalue='old value';
3).restart JIRA, jira load these options in memory
4). reindex
JIRA中Closed issues是沒法修改的,所以經常需要到資料庫手工修改資料,修改前切記備份好資料!
JIRA的資料庫設計很規範、工整,所以修改起來應該是得心應手的,具體的資料庫設計文檔見
http://confluence.atlassian.com/display/JIRA/Database+Schema
5.更改resolution.
resolution可以通過Edit來修改,但是一般Resolution是必輸的,對於沒有resolution的issue用Edit將帶來問題,所以最好通過sql來修改:
update jiraissue set resolution='x' where id='xxx'
resolition的定義存放在resolutio表中,以下是經過我修改過和原有的一些resolution id:
IDSEQUENCEpname
11Fixed
22Won't Fix
33Duplicate
44Need more Info
55Cannot Reproduce
66Not Fixed
77Not Bug
6.修改fix version/s
Sql代碼
- select * from jiraissue where pkey='JRA-xx'
- --返回issue的id,填入以下insert語句的source_node_id中
-
- select * from projectversion where vname='xxx'
- --返回version id,填入以下insert語句的sink_node_id中
-
- insert into nodeassociation
- (source_node_id,source_node_entity,sink_node_id,sink_node_entity,association_type)
- values (11492,'Issue',10020,'Version','IssueFixVersion');
-
- --insert之後需要到jira中re-inex一下
select * from jiraissue where pkey='JRA-xx'--返回issue的id,填入以下insert語句的source_node_id中select * from projectversion where vname='xxx'--返回version id,填入以下insert語句的sink_node_id中insert into nodeassociation (source_node_id,source_node_entity,sink_node_id,sink_node_entity,association_type) values (11492,'Issue',10020,'Version','IssueFixVersion');--insert之後需要到jira中re-inex一下
7.對一個closed issue的custom field進行編輯
修改custom field分為兩種情況:
1)某個issue的custom field值為空白,那就得insert一條記錄:
修改customfieldvalue表,這張表的主鍵id是自增長的,所以要小心賦一個不存在的比現有最大id小的id,然後執行如下sql:
Sql代碼
- insert into customfieldvalue (id,issue,customfield,numbervalue)
- values (10090,11327,10040,223)
insert into customfieldvalue (id,issue,customfield,numbervalue)values (10090,11327,10040,223)
2)custom field有值,需要update這個值
Sql代碼
- select * from jiraissue where pkey='JRA-2'
- --返回issue id
- update customfieldvalue set numbervalue=265 where issue=11390 and numbervalue=266
- --根據值就能判斷需要更新哪個欄位哪條記錄,如果不能定位則加一個條件customfield=xxx
原文:http://eyejava.javaeye.com/blog/286021