rez-table-listing-mui 1.3.28 → 1.3.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -878,48 +878,16 @@ const FilterForm = ({
|
|
|
878
878
|
"not_empty",
|
|
879
879
|
];
|
|
880
880
|
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
dateAllowedOperators.includes(operator);
|
|
886
|
-
|
|
887
|
-
const showTextInsteadOfDate =
|
|
888
|
-
!operator ||
|
|
889
|
-
!dateAllowedOperators.includes(operator);
|
|
890
|
-
|
|
891
|
-
if (showTextInsteadOfDate) {
|
|
892
|
-
console.log(
|
|
893
|
-
"Inside showtext",
|
|
894
|
-
showTextInsteadOfDate
|
|
895
|
-
);
|
|
896
|
-
|
|
897
|
-
return (
|
|
898
|
-
<FormTextfield
|
|
899
|
-
filter={filter}
|
|
900
|
-
control={control}
|
|
901
|
-
onValueChange={updateFiltersFromForm}
|
|
902
|
-
/>
|
|
903
|
-
);
|
|
904
|
-
}
|
|
905
|
-
}
|
|
906
|
-
|
|
907
|
-
// const showDatePicker =
|
|
908
|
-
// filter?.filter_attribute_data_type === "date" &&
|
|
909
|
-
// operator &&
|
|
910
|
-
// dateAllowedOperators.includes(operator);
|
|
881
|
+
const showDatePicker =
|
|
882
|
+
filter?.filter_attribute_data_type === "date" &&
|
|
883
|
+
operator &&
|
|
884
|
+
dateAllowedOperators.includes(operator);
|
|
911
885
|
|
|
912
|
-
//
|
|
886
|
+
// Should textfield shown instead for date?
|
|
913
887
|
// const showTextInsteadOfDate =
|
|
914
888
|
// !operator ||
|
|
915
889
|
// !dateAllowedOperators.includes(operator);
|
|
916
890
|
|
|
917
|
-
// console.log("Show Date Picker:", showDatePicker);
|
|
918
|
-
// console.log(
|
|
919
|
-
// "Show Text Instead:",
|
|
920
|
-
// showTextInsteadOfDate
|
|
921
|
-
// );
|
|
922
|
-
|
|
923
891
|
// Now render exactly same logic except date override
|
|
924
892
|
if (
|
|
925
893
|
filter?.filter_attribute_data_type === "text" ||
|
|
@@ -946,26 +914,24 @@ const FilterForm = ({
|
|
|
946
914
|
}
|
|
947
915
|
|
|
948
916
|
// DATE LOGIC
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
// );
|
|
968
|
-
// }
|
|
917
|
+
if (showDatePicker) {
|
|
918
|
+
console.log("Inside Date", showDatePicker);
|
|
919
|
+
return (
|
|
920
|
+
<FormDatePicker
|
|
921
|
+
filter={filter}
|
|
922
|
+
control={control}
|
|
923
|
+
onValueChange={updateFiltersFromForm}
|
|
924
|
+
/>
|
|
925
|
+
);
|
|
926
|
+
} else {
|
|
927
|
+
return (
|
|
928
|
+
<FormTextfield
|
|
929
|
+
filter={filter}
|
|
930
|
+
control={control}
|
|
931
|
+
onValueChange={updateFiltersFromForm}
|
|
932
|
+
/>
|
|
933
|
+
);
|
|
934
|
+
}
|
|
969
935
|
|
|
970
936
|
// if (showTextInsteadOfDate) {
|
|
971
937
|
// console.log(
|