kwabs22 commited on
Commit
7f61e6c
·
1 Parent(s): 64073bc

Refactor Proto Assist accordion to absorb mess

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -364,15 +364,15 @@ def show_elements_json_input(json_input):
364
  "developernotes": json.loads(current_values[i*num_current_unique_fields + 5])
365
  }
366
  updated_data["masterlocation1"]["end"] = masterlocation1["end"]
367
- return json.dumps(updated_data, indent=2), json.dumps(updated_data, default=lambda o: o.__dict__, indent=2)
368
 
369
  update_button = gr.Button("Update JSON")
370
  json_output = gr.Textbox(label="Updated JSON", lines=10)
371
  json_output_code = gr.Code(lines=10)
372
 
373
- update_button.click(update_json, inputs=outputs, outputs=[json_output, json_output_code])
374
 
375
- return outputs + [update_button, json_output, json_output_code]
376
 
377
  def create_media_component(file_path):
378
  print(file_path)
 
364
  "developernotes": json.loads(current_values[i*num_current_unique_fields + 5])
365
  }
366
  updated_data["masterlocation1"]["end"] = masterlocation1["end"]
367
+ return json.dumps(updated_data, indent=2), #json.dumps(updated_data, default=lambda o: o.__dict__, indent=2)
368
 
369
  update_button = gr.Button("Update JSON")
370
  json_output = gr.Textbox(label="Updated JSON", lines=10)
371
  json_output_code = gr.Code(lines=10)
372
 
373
+ update_button.click(update_json, inputs=outputs, outputs=[json_output_code]) #, json_output_code])
374
 
375
+ return outputs + [update_button, json_output_code] #, json_output_code]
376
 
377
  def create_media_component(file_path):
378
  print(file_path)