mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-05-05 13:39:24 +08:00
fix: missing date input field in filter operation on mobile (#5786)
This commit is contained in:
parent
38365a5023
commit
79743f0948
@ -27,6 +27,17 @@ AssociationFieldMobile.InternalSelect = AssociationField.InternalSelect;
|
|||||||
AssociationFieldMobile.ReadPretty = AssociationField.ReadPretty;
|
AssociationFieldMobile.ReadPretty = AssociationField.ReadPretty;
|
||||||
AssociationFieldMobile.FileSelector = AssociationField.FileSelector;
|
AssociationFieldMobile.FileSelector = AssociationField.FileSelector;
|
||||||
|
|
||||||
|
const DatePickerMobile = (props) => {
|
||||||
|
const { designable } = useDesignable();
|
||||||
|
if (designable !== false) {
|
||||||
|
return <DatePicker {...props} />;
|
||||||
|
} else {
|
||||||
|
return <MobileDateTimePicker {...props} />;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
DatePickerMobile.FilterWithPicker = DatePicker.FilterWithPicker;
|
||||||
|
DatePickerMobile.RangePicker = DatePicker.RangePicker;
|
||||||
|
|
||||||
const mobileComponents = {
|
const mobileComponents = {
|
||||||
Button: MobileButton,
|
Button: MobileButton,
|
||||||
Select: (props) => {
|
Select: (props) => {
|
||||||
@ -37,14 +48,7 @@ const mobileComponents = {
|
|||||||
return <MobilePicker {...props} />;
|
return <MobilePicker {...props} />;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
DatePicker: (props) => {
|
DatePicker: DatePickerMobile,
|
||||||
const { designable } = useDesignable();
|
|
||||||
if (designable !== false) {
|
|
||||||
return <DatePicker {...props} />;
|
|
||||||
} else {
|
|
||||||
return <MobileDateTimePicker {...props} />;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
UnixTimestamp: MobileDateTimePicker,
|
UnixTimestamp: MobileDateTimePicker,
|
||||||
Modal: MobileDialog,
|
Modal: MobileDialog,
|
||||||
AssociationField: AssociationFieldMobile,
|
AssociationField: AssociationFieldMobile,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user