import List from './components/List.vue';
|
import Timestamp from './components/Timestamp.vue';
|
import TimeRange from './components/TimeRange.vue';
|
import { ChartTypeEnum } from '../../../types';
|
import StringInput from '../recordSetTable/components/StringInput.vue'
|
export const enum RecordSetParamsType {
|
Step = 'time_step',
|
|
TimeRange = 'time_range',
|
StringInput='string',
|
|
}
|
|
export type BaseParam = {
|
title:string;
|
id:string
|
};
|
|
export type ListParamListItem = {
|
title: string;
|
value: string;
|
};
|
export type StepParam = {
|
type: RecordSetParamsType.Step;
|
value: string;
|
list: ListParamListItem[];
|
origin: any;
|
} & BaseParam;
|
|
export type TimeRangeParamValue = {
|
startTime: string;
|
endTime: string;
|
};
|
export type TimeRangeParam = {
|
type: RecordSetParamsType.TimeRange;
|
value: [string,string];
|
origin: any;
|
} & BaseParam;
|
|
export type RecordSetParamsItem = StepParam | TimeRangeParam;
|
export type RecordSet = {
|
params?: RecordSetParamsItem[];
|
chartType?: ChartTypeEnum;
|
};
|
|
export const recordSetMapCom = {
|
[RecordSetParamsType.Step]: List,
|
[RecordSetParamsType.TimeRange]: TimeRange,
|
[RecordSetParamsType.StringInput]:StringInput
|
};
|
|
export const scoreMap = {
|
'0': '未评估',
|
'1': '坏',
|
'2': '中',
|
'3': '良',
|
'4': '优',
|
};
|