fix(web-antdv-next): 统一日期范围和分组组件引用方式
parent
d7b23d67ce
commit
2aa2c8676f
|
|
@ -3,7 +3,7 @@ import type { Dayjs } from 'dayjs';
|
|||
|
||||
import { onMounted, ref } from 'vue';
|
||||
|
||||
import { DatePicker, Radio, RadioGroup } from 'antdv-next';
|
||||
import { DateRangePicker, Radio, RadioGroup } from 'antdv-next';
|
||||
import dayjs from 'dayjs';
|
||||
|
||||
import { getRangePickerDefaultProps } from '#/utils/rangePickerProps';
|
||||
|
|
@ -88,7 +88,7 @@ onMounted(() => {
|
|||
{{ option.label }}
|
||||
</Radio>
|
||||
</RadioGroup>
|
||||
<DatePicker.RangePicker
|
||||
<DateRangePicker
|
||||
v-model:value="times"
|
||||
:format="rangePickerProps.format"
|
||||
:value-format="rangePickerProps.valueFormat"
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import { ref, watch } from 'vue';
|
|||
import {
|
||||
Button,
|
||||
Checkbox,
|
||||
CheckboxGroup,
|
||||
DatePicker,
|
||||
Input,
|
||||
InputNumber,
|
||||
|
|
@ -309,7 +310,7 @@ watch(
|
|||
</RadioGroup>
|
||||
</div>
|
||||
<div v-if="cronMode[f.key] === 'appoint'">
|
||||
<Checkbox.Group
|
||||
<CheckboxGroup
|
||||
v-model:value="cronAppoint[f.key]"
|
||||
:key="`group-${f.key}`"
|
||||
>
|
||||
|
|
@ -320,7 +321,7 @@ watch(
|
|||
>
|
||||
{{ pad(n - 1) }}
|
||||
</Checkbox>
|
||||
</Checkbox.Group>
|
||||
</CheckboxGroup>
|
||||
</div>
|
||||
</TabPane>
|
||||
</Tabs>
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import { DICT_TYPE } from '@vben/constants';
|
|||
import { getDictOptions } from '@vben/hooks';
|
||||
import { formatDateTime } from '@vben/utils';
|
||||
|
||||
import { Timeline } from 'antdv-next';
|
||||
import { Timeline, TimelineItem } from 'antdv-next';
|
||||
|
||||
import { CronTab } from '#/components/cron-tab';
|
||||
import { DictTag } from '#/components/dict-tag';
|
||||
|
|
@ -239,7 +239,7 @@ export function useDetailSchema(): DescriptionItemSchema[] {
|
|||
}
|
||||
return h(Timeline, {}, () =>
|
||||
val?.map((time: Date) =>
|
||||
h(Timeline.Item, {}, () => formatDateTime(time)),
|
||||
h(TimelineItem, {}, () => formatDateTime(time)),
|
||||
),
|
||||
);
|
||||
},
|
||||
|
|
|
|||
|
|
@ -14,7 +14,14 @@ import {
|
|||
import { IconifyIcon } from '@vben/icons';
|
||||
import { formatDateTime } from '@vben/utils';
|
||||
|
||||
import { Button, DatePicker, Select, SelectOption, Space, Tag } from 'antdv-next';
|
||||
import {
|
||||
Button,
|
||||
DateRangePicker,
|
||||
Select,
|
||||
SelectOption,
|
||||
Space,
|
||||
Tag,
|
||||
} from 'antdv-next';
|
||||
|
||||
import { useVbenVxeGrid } from '#/adapter/vxe-table';
|
||||
import { getDeviceMessagePairPage } from '#/api/iot/device/device';
|
||||
|
|
@ -24,8 +31,6 @@ const props = defineProps<{
|
|||
thingModelList: ThingModelApi.ThingModel[];
|
||||
}>();
|
||||
|
||||
const RangePicker = DatePicker.RangePicker;
|
||||
|
||||
/** 查询参数 */
|
||||
const queryParams = reactive({
|
||||
identifier: '',
|
||||
|
|
@ -224,7 +229,7 @@ defineExpose({
|
|||
</div>
|
||||
<div class="flex items-center gap-2">
|
||||
<span>时间范围:</span>
|
||||
<RangePicker
|
||||
<DateRangePicker
|
||||
v-model:value="queryParams.times"
|
||||
format="YYYY-MM-DD HH:mm:ss"
|
||||
show-time
|
||||
|
|
|
|||
|
|
@ -14,7 +14,14 @@ import {
|
|||
import { IconifyIcon } from '@vben/icons';
|
||||
import { formatDateTime } from '@vben/utils';
|
||||
|
||||
import { Button, DatePicker, Select, SelectOption, Space, Tag } from 'antdv-next';
|
||||
import {
|
||||
Button,
|
||||
DateRangePicker,
|
||||
Select,
|
||||
SelectOption,
|
||||
Space,
|
||||
Tag,
|
||||
} from 'antdv-next';
|
||||
|
||||
import { useVbenVxeGrid } from '#/adapter/vxe-table';
|
||||
import { getDeviceMessagePairPage } from '#/api/iot/device/device';
|
||||
|
|
@ -24,8 +31,6 @@ const props = defineProps<{
|
|||
thingModelList: ThingModelApi.ThingModel[];
|
||||
}>();
|
||||
|
||||
const RangePicker = DatePicker.RangePicker;
|
||||
|
||||
/** 查询参数 */
|
||||
const queryParams = reactive({
|
||||
identifier: '',
|
||||
|
|
@ -238,7 +243,7 @@ defineExpose({
|
|||
</div>
|
||||
<div class="flex items-center gap-2">
|
||||
<span>时间范围:</span>
|
||||
<RangePicker
|
||||
<DateRangePicker
|
||||
v-model:value="queryParams.times"
|
||||
format="YYYY-MM-DD HH:mm:ss"
|
||||
show-time
|
||||
|
|
|
|||
Loading…
Reference in New Issue