mirror of
https://ghfast.top/https://github.com/aeroxw/tick-stock-panel.git
synced 2026-09-12 23:44:16 +08:00
fix: 完善自定义分钟数据源配置与异常处理
- 补齐资产类型和周期参数在 API、YAML 与前端编辑器中的保存回读 - 权限判断和分时监控统一复用安全的数据源解析边界 - 增加配置往返及解析异常回归测试
This commit is contained in:
@@ -821,6 +821,8 @@ export interface DatasetConfig {
|
||||
symbols_param?: string
|
||||
start_param?: string
|
||||
end_param?: string
|
||||
asset_type_param?: string | null
|
||||
freq_param?: string | null
|
||||
}
|
||||
|
||||
export interface AuthConfig {
|
||||
|
||||
@@ -395,6 +395,27 @@ function DatasetDetail({
|
||||
</Field>
|
||||
</div>
|
||||
|
||||
{datasetKey === 'minute' && (
|
||||
<div className="grid grid-cols-1 sm:grid-cols-2 gap-2">
|
||||
<Field label="资产类型参数">
|
||||
<input
|
||||
value={cfg.asset_type_param ?? ''}
|
||||
onChange={e => onUpdate({ asset_type_param: e.target.value || null })}
|
||||
placeholder="asset_type"
|
||||
className={`${INPUT_CLS} w-full`}
|
||||
/>
|
||||
</Field>
|
||||
<Field label="周期参数">
|
||||
<input
|
||||
value={cfg.freq_param ?? ''}
|
||||
onChange={e => onUpdate({ freq_param: e.target.value || null })}
|
||||
placeholder="period"
|
||||
className={`${INPUT_CLS} w-full`}
|
||||
/>
|
||||
</Field>
|
||||
</div>
|
||||
)}
|
||||
|
||||
<div>
|
||||
<div className="flex items-center justify-between mb-2">
|
||||
<div className="text-[10px] uppercase tracking-widest text-muted">字段映射</div>
|
||||
|
||||
Reference in New Issue
Block a user