mozilla/mediawiki-bugzilla

Display item count when fields of type array (eg attachments) are specified in include_fields

edmorley opened this issue · 0 comments

For this markup:

<bugzilla>
{
"component": "Treeherder",
"resolution": "FIXED",
"include_fields": "id, priority, summary, attachments, assigned_to",
"order": "priority"
}
</bugzilla>

The resultant bug table includes an "attachments" column, however it contains things like:

"Array, Array, Array"
""
"Array"
"Array, Array"

This also presumably affects any of the other array fields listed on https://wiki.mozilla.org/Bugzilla:BzAPI:Objects#Bug (ie: cc, comments, flags, groups, ...).

We should convert this to a count of array items (ie number of attachments in the example above) and optionally allow the field to instead enumerate the values (eg list the flag names or emails addresses for 'flags' or 'cc').

screenshot