perf: 搜索组件: 修改属性名: fieldsConfig

feature/price_manager
Lei OT 2 years ago
parent 28e2b9f6a6
commit 9fef49263b

@ -21,7 +21,7 @@ const SearchForm = ({ initialValue, onSubmit, onReset, ...props }) => {
fieldComProps: '',
hides: [],
shows: [],
...props.defaultValue,
...props.fieldsConfig,
};
const { confirmText } = props;
const readValues = { ...initialValue, ...formValues };

@ -71,7 +71,7 @@ function Index() {
initialValue={{
dates: [dayjs().subtract(2, 'M').startOf('M'), dayjs().endOf('M')],
}}
defaultValue={{
fieldsConfig={{
shows: ['referenceNo', 'dates'],
fieldProps: {
dates: { label: t('group:ArrivalDate') },

@ -88,7 +88,7 @@ function Index() {
initialValue={{
dates: [dayjs().subtract(2, 'M').startOf('M'), dayjs().endOf('M')],
}}
defaultValue={{
fieldsConfig={{
shows: ['referenceNo', 'invoiceStatus', 'dates'],
fieldProps: {
referenceNo: { col: 5},

@ -76,7 +76,7 @@ function Paid() {
initialValue={{
dates: [dayjs().subtract(2, 'M').startOf('M'), dayjs().endOf('M')],
}}
defaultValue={{
fieldsConfig={{
shows: ['referenceNo', 'dates'],
fieldProps: {
referenceNo: { col: 5 },

@ -283,7 +283,7 @@ function Index() {
initialValue={{
dates: [dayjs().startOf('year'), dayjs().endOf('year')],
}}
defaultValue={{
fieldsConfig={{
shows: ['dates'],
fieldProps: {
dates: { label: 'Select Date', col: 12 },

@ -106,7 +106,7 @@ function Newest() {
const [dataLoading, setDataLoading] = useState(false)
const [guideSelectOptions, setGuideSelectOptions] = useState([])
const formValues = useFormStore((state) => state.formValues)
const formValuesToSub = useFormStore((state) => state.formValuesToSub)
const [fetchAllGuideList, fetchReservationList, reservationList, reservationPage, cityList, selectReservation, getCityListByReservationId] =
useReservationStore((state) =>
@ -163,7 +163,7 @@ function Newest() {
//
const onSearchClick = (current=1, status=null) => {
setDataLoading(true)
fetchReservationList(formValues, current)
fetchReservationList(formValuesToSub, current)
.catch(ex => {
notification.error({
message: `Notification`,
@ -216,7 +216,7 @@ function Newest() {
// {
// }
// }
defaultValue={{
fieldsConfig={{
shows: ['referenceNo', 'dates'],
fieldProps: {
dates: { label: t('group:ArrivalDate') },
@ -224,7 +224,7 @@ function Newest() {
}}
onSubmit={(err, formVal, filedsVal) => {
setDataLoading(true)
fetchReservationList(travelAgencyId, formVal)
fetchReservationList(formVal)
.catch(ex => {
notification.error({
message: 'Notification',

Loading…
Cancel
Save