getUserDefaultColumns method

Future<List<ColumnItem>> getUserDefaultColumns({
  1. String? accountId,
  2. String? username,
})

Returns the default issue table columns for the user. If accountId is not passed in the request, the calling user's details are returned.

Permissions required:

  • Administer Jira global permission, to get the column details for any user.
  • Permission to access Jira, to get the calling user's column details.

Implementation

Future<List<ColumnItem>> getUserDefaultColumns(
    {String? accountId, String? username}) async {
  return (await _client.send(
    'get',
    'rest/api/3/user/columns',
    queryParameters: {
      if (accountId != null) 'accountId': accountId,
      if (username != null) 'username': username,
    },
  ) as List<Object?>)
      .map((i) => ColumnItem.fromJson(i as Map<String, Object?>? ?? const {}))
      .toList();
}