Skip to content

Commit 11df4fe

Browse files
committed
Add options field to project columns in GraphQL query for detailed output
1 parent 8db8655 commit 11df4fe

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

.github/workflows/get-project-column-ids.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,10 @@ jobs:
122122
if (columnsResult.node && columnsResult.node.fields.nodes.length) {
123123
columns[projectName] = columnsResult.node.fields.nodes.map(field => ({
124124
id: field.id,
125-
name: field.name
125+
name: field.name,
126+
options: field.options ? field.options.map(option => ({
127+
id: option.id,
128+
name: option.name
126129
}));
127130
}
128131
}
@@ -132,6 +135,12 @@ jobs:
132135
console.log(`Project "${projectName}" Columns:`);
133136
columns.forEach(column => {
134137
console.log(` Column "${column.name}" = Column ID: "${column.id}"`);
138+
if (column.options.length) {
139+
console.log(` Options:`);
140+
column.options.forEach(option => {
141+
console.log(` Option "${option.name}" = Option ID: "${option.id}"`);
142+
});
143+
}
135144
});
136145
});
137146

0 commit comments

Comments
 (0)