reallife_asset/wwwroot/upload_asset.ui
yumoqing 2f1974ae8f feat: upload form shows name for auth groups, file input with media type validation
- get_org_groups.dspy: show name if available, fallback to vendor_group_id
- upload_asset.ui: change source_url from text textarea to file input (accept image/audio/video)
- rl_upload.dspy: auto-detect asset_type from file extension, server-side media type validation
2026-05-30 10:15:50 +08:00

83 lines
3.4 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{
"widgettype": "VBox",
"options": {
"width": "100%",
"padding": "16px"
},
"subwidgets": [
{
"widgettype": "Title4",
"options": {
"text": "上传素材",
"fontWeight": "600",
"marginBottom": "16px"
}
},
{
"widgettype": "VScrollPanel",
"options": {
"height": "600px"
},
"subwidgets": [
{
"widgettype": "VBox",
"options": {
"padding": "16px",
"spacing": 12
},
"subwidgets": [
{
"widgettype": "Form",
"id": "upload_form",
"options": {
"submit_url": "{{entire_url('api/rl_upload.dspy')}}",
"fields": [
{
"uitype": "code",
"name": "vendor",
"label": "供应商",
"dataurl": "{{entire_url('api/get_vendor_list.dspy')}}",
"data_field": "value",
"text_field": "text",
"required": true
},
{
"uitype": "code",
"name": "vendor_group_id",
"label": "认证组合",
"dataurl": "{{entire_url('api/get_org_groups.dspy')}}",
"data_field": "value",
"text_field": "text",
"required": true
},
{
"uitype": "file",
"name": "source_url",
"label": "素材文件",
"accept": "image/*,audio/*,video/*",
"required": true
},
{
"uitype": "code",
"name": "asset_type",
"label": "素材类型",
"dataurl": "{{entire_url('api/get_asset_type_list.dspy')}}",
"data_field": "value",
"text_field": "text"
},
{
"uitype": "str",
"name": "name",
"label": "素材名称",
"placeholder": "可选默认使用URL最后一部分"
}
]
}
}
]
}
]
}
]
}