통합 거래내역 필터
This commit is contained in:
@@ -37,8 +37,14 @@ main {
|
||||
|
||||
}
|
||||
|
||||
header{
|
||||
.ptr.wrapper{
|
||||
padding-top: env(safe-area-inset-top) !important;
|
||||
padding-bottom: env(safe-area-inset-bottom) !important;
|
||||
}
|
||||
|
||||
/*
|
||||
header{
|
||||
|
||||
}
|
||||
main {
|
||||
padding-top: calc(50px + env(safe-area-inset-top)) !important;
|
||||
@@ -46,5 +52,6 @@ main {
|
||||
}
|
||||
.bottom-tabbar{
|
||||
height: calc(70px + env(safe-area-inset-bottom)) !important;
|
||||
padding-bottom: env(safe-area-inset-bottom) !important;
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
@@ -32,7 +32,7 @@ const NiceCalendar = ({
|
||||
};
|
||||
|
||||
const onClickToClose = () => {
|
||||
setCalendarOpen(false);
|
||||
// setCalendarOpen(false);
|
||||
};
|
||||
const setMinMaxValueDate = () => {
|
||||
if(calendarType === CalendarType.Start){
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
import { ChangeEvent } from 'react';
|
||||
import { ChangeEvent, useState } from 'react';
|
||||
|
||||
export interface FilterSelectInputProps {
|
||||
title: string;
|
||||
selectValue: string;
|
||||
selectSetter: (value: any) => void;
|
||||
selectValue: string | undefined;
|
||||
selectSetter?: (value: any) => void;
|
||||
selectOptions: Array<Record<string, string>>;
|
||||
inputValue: string;
|
||||
inputSetter: (value: any) => void;
|
||||
inputValue: string | undefined;
|
||||
inputSetter?: (value: any) => void;
|
||||
};
|
||||
export const FilterSelectInput = ({
|
||||
title,
|
||||
@@ -16,7 +16,9 @@ export const FilterSelectInput = ({
|
||||
inputValue,
|
||||
inputSetter
|
||||
}: FilterSelectInputProps) => {
|
||||
|
||||
const [selectVal, setSelectVal] = useState();
|
||||
const [inputVal, setInputVal] = useState();
|
||||
|
||||
const getSelectOptions = () => {
|
||||
let rs = [];
|
||||
for(let i=0;i<selectOptions.length;i++){
|
||||
@@ -30,6 +32,20 @@ export const FilterSelectInput = ({
|
||||
return rs;
|
||||
};
|
||||
|
||||
const onChangeSelect = (e: ChangeEvent<HTMLSelectElement>) => {
|
||||
let value = e.target.value;
|
||||
if(!!selectSetter){
|
||||
selectSetter(value);
|
||||
}
|
||||
};
|
||||
|
||||
const onChangeInput = (e: ChangeEvent<HTMLInputElement>) => {
|
||||
let value = e.target.value;
|
||||
if(!!inputSetter){
|
||||
inputSetter(value);
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<>
|
||||
<div className="opt-field">
|
||||
@@ -38,7 +54,7 @@ export const FilterSelectInput = ({
|
||||
<select
|
||||
className="w-110"
|
||||
value={ selectValue }
|
||||
onChange={ (e: any) => selectSetter(e.target.value)}
|
||||
onChange={ onChangeSelect }
|
||||
>
|
||||
{ getSelectOptions() }
|
||||
</select>
|
||||
@@ -47,7 +63,7 @@ export const FilterSelectInput = ({
|
||||
type="text"
|
||||
placeholder=""
|
||||
value={ inputValue }
|
||||
onChange={ (e: ChangeEvent<HTMLInputElement>) => inputSetter(e.target.value)}
|
||||
onChange={ onChangeInput }
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user