{ "widgettype": "VBox", "options": { "width": "100%", "padding": "16px" }, "subwidgets": [ { "widgettype": "HBox", "options": { "width": "100%", "alignItems": "center", "marginBottom": "16px" }, "subwidgets": [ { "widgettype": "Title4", "options": { "text": "供应商配置", "fontWeight": "600" } }, { "widgettype": "Filler" }, { "widgettype": "Button", "options": { "label": "返回列表" }, "binds": [ { "wid": "self", "event": "click", "actiontype": "urlwidget", "target": "app.rl_content", "options": { "url": "{{entire_url('vendor_config_manage.ui')}}" }, "mode": "replace" } ] } ] }, { "widgettype": "VScrollPanel", "options": { "height": "600px" }, "subwidgets": [ { "widgettype": "VBox", "options": { "padding": "16px", "spacing": 12 }, "subwidgets": [ { "widgettype": "Form", "id": "vendor_config_form", "options": { "submit_url": "{{entire_url('api/rl_vendor_config_create.dspy')}}", "fields": [ { "uitype": "str", "name": "vendor", "label": "供应商标识", "placeholder": "如 volcengine", "required": true }, { "uitype": "str", "name": "vendor_title", "label": "供应商名称", "placeholder": "如火山引擎" }, { "uitype": "code", "name": "upappid", "label": "上位系统(uapi)", "dataurl": "{{entire_url('api/get_upapp_list.dspy')}}", "data_field": "value", "text_field": "text", "required": true }, { "uitype": "text", "name": "api_mapping", "label": "API映射(JSON)", "rows": 8, "placeholder": '{\"create_session\":\"CreateVisualValidateSession\",\"get_result\":\"GetVisualValidateResult\",\"upload_asset\":\"CreateAsset\",\"get_asset\":\"GetAsset\",\"list_assets\":\"ListAssets\",\"list_groups\":\"ListAssetGroups\",\"delete_asset\":\"DeleteAsset\",\"delete_group\":\"DeleteAssetGroup\"}' }, { "uitype": "code", "name": "status", "label": "状态", "dataurl": "{{entire_url('api/get_status_list.dspy')}}", "data_field": "value", "text_field": "text" }, { "uitype": "str", "name": "callback_url", "label": "回调URL", "placeholder": "https://your-domain.com/reallife_asset/api/rl_callback.dspy" } ] } }, { "widgettype": "HBox", "options": { "gap": "12px", "marginTop": "16px" }, "subwidgets": [ { "widgettype": "Button", "options": { "label": "提交" }, "binds": [ { "wid": "self", "event": "click", "actiontype": "script", "target": "self", "script": "var f=bricks.getWidgetById('vendor_config_form',bricks.app);if(f)f.submit()" } ] }, { "widgettype": "Button", "options": { "label": "重置" }, "binds": [ { "wid": "self", "event": "click", "actiontype": "script", "target": "self", "script": "var f=bricks.getWidgetById('vendor_config_form',bricks.app);if(f)f.reset()" } ] } ] } ] } ] } ] }