ciyidogan commited on
Commit
17e2f84
·
verified ·
1 Parent(s): 6737cf0

Update flare-ui/src/app/dialogs/api-edit-dialog/api-edit-dialog.component.ts

Browse files
flare-ui/src/app/dialogs/api-edit-dialog/api-edit-dialog.component.ts CHANGED
@@ -51,6 +51,12 @@ export default class ApiEditDialogComponent implements OnInit {
51
  responseMappingVariables: string[] = [];
52
  activeTabIndex = 0;
53
 
 
 
 
 
 
 
54
  httpMethods = ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'];
55
  retryStrategies = ['static', 'exponential'];
56
  variableTypes = ['str', 'int', 'float', 'bool', 'date'];
@@ -65,6 +71,10 @@ export default class ApiEditDialogComponent implements OnInit {
65
  @Inject(MAT_DIALOG_DATA) public data: any
66
  ) {}
67
 
 
 
 
 
68
  ngOnInit() {
69
  this.initializeForm();
70
  this.loadIntentParameters();
 
51
  responseMappingVariables: string[] = [];
52
  activeTabIndex = 0;
53
 
54
+ variablePanelsExpanded: { [key: string]: boolean } = {
55
+ 'body_template': false,
56
+ 'auth.token_request_body': false,
57
+ 'auth.token_refresh_body': false
58
+ };
59
+
60
  httpMethods = ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'];
61
  retryStrategies = ['static', 'exponential'];
62
  variableTypes = ['str', 'int', 'float', 'bool', 'date'];
 
71
  @Inject(MAT_DIALOG_DATA) public data: any
72
  ) {}
73
 
74
+ toggleVariablePanel(field: string): void {
75
+ this.variablePanelsExpanded[field] = !this.variablePanelsExpanded[field];
76
+ }
77
+
78
  ngOnInit() {
79
  this.initializeForm();
80
  this.loadIntentParameters();