Hi everybody,
is it possible to customize the default settings of the Issue Statistics gadget ?
Per default the option 'Show Resolved Issue Statistics' is set to 'No'. Can this be set to 'Yes' by passing this to a application properties file or something?
After upgrading our JIRA projects from version 3.13. to 5.0 (via 4.4.) I was wondering why the total of displayed issues on the dashboard was lower than in the 3.13. version. After a couple of minutes I found out that the conversion of the portlets from JIRA 3.13. to JIRA 5.0 gadgets comes with the 'Show Resolved Issue Statistics'= 'No' option.
I want to avoid that I (and all the others user incl. our clients) would have to check all of their gadgets and adapt them manually by editing the gadget and selecting the 'Yes' option.
If possible to change the default behaviour I am in hope that conversion sets the option to 'Yes' in all of the gadgets.
Your answers are appreciated, thanks in advance.
Community moderators have prevented the ability to post new answers.
update gadgetuserpreference set userprefvalue = true where userprefkey='includeResolvedIssues' AND portletconfiguration in (select id from portletconfiguration where gadget_xml like '%stats-gadget.xml')
Don't blame me if it breaks anything else :) (it shouldn't)
Hi Renjith,
your answer was very helpful and the kick-off for the solution.
Here the steps I run to solve the prob:
1. Checking the gadget in JIRA: Total Issues:87
2. Stop JIRA
3. Checking the table gadgetuserpreference
mysql> select * from gadgetuserpreference where userprefkey='includeResolvedIssues' AND portletconfiguration in (select id from portletconfiguration where gadget_xml like '%stats-gadget.xml'); ... 4 rows in set (0.03 sec)
but my portlets were not in -> PORTLETCONFIGURATION=11692 !
4. Checking the table portletconfiguration
mysql> select * from portletconfiguration where portalpage=11692; ... 3 rows in set (0.00 sec)
5. Checking the table gadgetuserpreference by my portletconfigurations
mysql> select * from gadgetuserpreference where portletconfiguration BETWEEN 19285 AND 19287; PORTLETCONFIGURATION | USERPREFKEY 19285 | sortDirection 19285 | isConfigured 19285 | projectOrFilterId 19285 | statType 19285 | sortBy ... 15 rows in set (0.00 sec) -> 3 by 5 rows, but no 'includeResolvedIssues' key !!!
6. Inserting missing 'includeResolvedIssues' values for my portletconfigurations
7. Checking the table gadgetuserpreference by queering only for only stat-gadgets
mysql> select * from gadgetuserpreference where userprefkey='includeResolvedIssues' AND portletconfiguration in (select id from portletconfiguration where gadget_xml like '%stats-gadget.xml'); ... 7 rows in set (0.01 sec) -> my 3 rows are included now
8. Running your update statement
9. Checking the table gadgetuserpreference by queering only for only stat-gadgets
... | 12551 | 19285 | includeResolvedIssues | 1 | ... 7 rows in set (0.01 sec)
10. Re-Running you update statement by using apostrophes around 'true'
... | 12551 | 19285 | includeResolvedIssues | true | ... 7 rows in set (0.01 sec)
11. Checking the table gadgetuserpreference by queering only for only stat-gadgets
12. Start JIRA
13. Checking the gadget the gadget in JIRA: Total Issues:16110
Thank you very much,
Thomas H
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Awesome :) (don't know why the includeResolvedIssues is not present by default in the tables). Anyway good.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
awesome, indeed ...
there was another problem that came up after the import to JIRA 5.0 which was weird ...
all the JIRA Issues Calendar Gadgets that come with the JIRA Calendar plug-in were broken as well
1. Unable to retrieve gadget xml. HTTP error 404
had to repair by replacing the NULL value in the column 'gadget_xml' of the table 'portletconfiguration'
UPDATE portletconfiguration set gadget_xml = 'rest/gadgets/1.0/g/com.atlassian.jira.ext.calendar:issuescalendar-gadget/templates/plugins/jira/portlets/calendar/gadget/calendar-gadget.xml' WHERE portlet_id like 'com.atlassian.jira.ext.calendar:issuesCalander';
2. After looking at the gadget all of the Calendar Gadgets were missing their assigned 'projectOrFilterId'
so, I had to search for the properties in the tables 'propertyentry' and 'propertystring'
select propertyentry.id,propertyentry.entity_name,propertyentry.entity_id,portletconfiguration.portlet_id,propertyentry.property_key,propertystring.propertyvalue from propertyentry,propertystring,portletconfiguration where propertyentry.id like propertystring.id and propertyentry.entity_name like 'PortletConfiguration' and propertyentry.property_key like 'projectOrFilterId' and portletconfiguration.id like propertyentry.entity_id and portletconfiguration.portlet_id like '%:issuesCalander' order by propertyentry.id;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
3. for the found results I had to add 6 properties each into the 'gadgetuserpreference' table
INSERT INTO gadgetuserpreference (id,portletconfiguration,userprefkey,userprefvalue) VALUES ('12573','15822','projectOrFilterId','filter-10870'); INSERT INTO gadgetuserpreference (id,portletconfiguration,userprefkey,userprefvalue) VALUES ('12574','15822','dateFieldName','duedate'); INSERT INTO gadgetuserpreference (id,portletconfiguration,userprefkey,userprefvalue) VALUES ('12575','15822','isConfigured','true'); INSERT INTO gadgetuserpreference (id,portletconfiguration,userprefkey,userprefvalue) VALUES ('12576','15822','numOfIssueIcons','100'); INSERT INTO gadgetuserpreference (id,portletconfiguration,userprefkey,userprefvalue) VALUES ('12577','15822','displayVersions','true'); INSERT INTO gadgetuserpreference (id,portletconfiguration,userprefkey,userprefvalue) VALUES ('12578','15822','refresh','false');
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
How is the Percentage calculated in Issue Statistics Gadget?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.