Commit 3f15511
feat: add approval template id field for Bytebase 3.11 compatibility (#156)
* feat: add approval template id field for Bytebase 3.12 compatibility
Add support for the new ApprovalTemplate.id field introduced in
Bytebase API to support both built-in and custom approval templates.
Changes:
- Add required 'id' field to approval flow schema with validation
- Update convertToV1ApprovalSetting to set template ID
- Update flattenWorkspaceApprovalSetting to include template ID
- Update Bytebase protobuf dependencies to latest version
Built-in templates use 'bb.*' prefix (e.g., 'bb.project-owner',
'bb.workspace-dba'), while custom templates use UUIDs.
Related: bytebase/bytebase#17689
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* test: add required id field to approval flow test cases
Update all approval flow test cases to include the new required 'id' field.
Use custom flow IDs (e.g., 'test-flow', 'test-ddl-approval-flow')
instead of built-in 'bb.*' prefixed IDs for test cases.
Fixes test failures caused by adding the required id field to ApprovalTemplate.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* docs: update examples and documentation for approval template id field
Update all examples and tutorials to include the required 'id' field in
approval flow configurations. Regenerate documentation to reflect the
new schema changes.
Changes:
- Add id field to examples/setup/approval_flow.tf
- Add id field to tutorials/4-3-approval-flow.tf
- Regenerate docs/resources/setting.md with updated schema
- Regenerate docs/data-sources/setting.md with updated schema
All examples now use the built-in template ID format:
'bb.project-owner-workspace-dba-workspace-admin'
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* chore: bump version to 3.11.2
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
---------
Co-authored-by: Claude <[email protected]>1 parent a9542b5 commit 3f15511
File tree
12 files changed
+25
-9
lines changed- docs
- data-sources
- resources
- examples/setup
- provider
- tutorials
12 files changed
+25
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
| 30 | + | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
214 | 214 | | |
215 | 215 | | |
216 | 216 | | |
| 217 | + | |
217 | 218 | | |
218 | 219 | | |
219 | 220 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| 58 | + | |
58 | 59 | | |
59 | 60 | | |
60 | 61 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | | - | |
| 8 | + | |
| 9 | + | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
3 | | - | |
4 | | - | |
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
502 | 502 | | |
503 | 503 | | |
504 | 504 | | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
505 | 511 | | |
506 | 512 | | |
507 | 513 | | |
| |||
733 | 739 | | |
734 | 740 | | |
735 | 741 | | |
| 742 | + | |
736 | 743 | | |
737 | 744 | | |
738 | 745 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
371 | 371 | | |
372 | 372 | | |
373 | 373 | | |
| 374 | + | |
374 | 375 | | |
375 | 376 | | |
376 | 377 | | |
| |||
0 commit comments