수정
This commit is contained in:
@@ -11,10 +11,13 @@ import { useStore } from '@/shared/model/store';
|
||||
export const UserManageWrap = () => {
|
||||
const { t } = useTranslation();
|
||||
const { navigate } = useNavigate();
|
||||
const midOptions = useStore.getState().UserStore.selectOptionsMids;
|
||||
const midOptionsWithoutGids = useStore.getState().UserStore.selectOptionsMidsWithoutGids;
|
||||
const userMid = useStore.getState().UserStore.mid;
|
||||
let midItem = midOptionsWithoutGids.filter((value, index) => {
|
||||
return value.value === userMid;
|
||||
});
|
||||
|
||||
const [mid, setMid] = useState<string>(userMid);
|
||||
const [mid, setMid] = useState<string>((midItem.length > 0)? userMid: '');
|
||||
const [userItems, setUserItems] = useState<Array<UserListItem>>([]);
|
||||
const [pageParam, setPageParam] = useState(DEFAULT_PAGE_PARAM);
|
||||
|
||||
@@ -38,7 +41,9 @@ export const UserManageWrap = () => {
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
callList();
|
||||
if(!!mid){
|
||||
callList();
|
||||
}
|
||||
}, [mid]);
|
||||
|
||||
return (
|
||||
@@ -52,7 +57,7 @@ export const UserManageWrap = () => {
|
||||
onChange={ (e: ChangeEvent<HTMLSelectElement>) => setMid(e.target.value)}
|
||||
>
|
||||
{
|
||||
midOptions.map((value, index) => (
|
||||
midOptionsWithoutGids.map((value, index) => (
|
||||
<option
|
||||
key={ value.value }
|
||||
value={ value.value }
|
||||
|
||||
@@ -17,9 +17,9 @@ import { useStore } from '@/shared/model/store';
|
||||
|
||||
export const RegistrationStatusWrap = () => {
|
||||
const { t } = useTranslation();
|
||||
const midOptions = useStore.getState().UserStore.selectOptionsMidsWithoutGids;
|
||||
const midOptionsWithoutGids = useStore.getState().UserStore.selectOptionsMidsWithoutGids;
|
||||
const userMid = useStore.getState().UserStore.mid;
|
||||
let midItem = midOptions.filter((value, index) => {
|
||||
let midItem = midOptionsWithoutGids.filter((value, index) => {
|
||||
return value.value === userMid;
|
||||
});
|
||||
|
||||
@@ -58,7 +58,7 @@ export const RegistrationStatusWrap = () => {
|
||||
onChange={ (e: ChangeEvent<HTMLSelectElement>) => setMid(e.target.value) }
|
||||
>
|
||||
{
|
||||
midOptions.map((value, index) => (
|
||||
midOptionsWithoutGids.map((value, index) => (
|
||||
<option
|
||||
key={ value.value }
|
||||
value={ value.value }
|
||||
|
||||
@@ -36,7 +36,7 @@ import { useStore } from '@/shared/model/store';
|
||||
|
||||
export const InfoWrap = () => {
|
||||
const { t } = useTranslation();
|
||||
const midOptions = useStore.getState().UserStore.selectOptionsMidsWithoutGids;
|
||||
const midOptions = useStore.getState().UserStore.selectOptionsMids;
|
||||
const userMid = useStore.getState().UserStore.mid;
|
||||
let midItem = midOptions.filter((value, index) => {
|
||||
return value.value === userMid;
|
||||
@@ -209,7 +209,7 @@ export const InfoWrap = () => {
|
||||
callPaymentIntallmentDetail(cardCompany);
|
||||
};
|
||||
useEffect(() => {
|
||||
if(mid){
|
||||
if(!!mid){
|
||||
callPaymentCard();
|
||||
callPaymentNonCard();
|
||||
callPaymentIntallment();
|
||||
|
||||
@@ -9,8 +9,11 @@ export const NotificationDataWrap = () => {
|
||||
const { t } = useTranslation();
|
||||
const midOptions = useStore.getState().UserStore.selectOptionsMids;
|
||||
const userMid = useStore.getState().UserStore.mid;
|
||||
let midItem = midOptions.filter((value, index) => {
|
||||
return value.value === userMid;
|
||||
});
|
||||
|
||||
const [mid, setMid] = useState<string>(userMid);
|
||||
const [mid, setMid] = useState<string>((midItem.length > 0)? userMid: '');
|
||||
const [merchantInfo, setMerchantInfo] = useState<Record<string, any>>();
|
||||
const [creditCard, setCreditCard] = useState<Record<string, any>>();
|
||||
const [accountTransfer, setAccountTransfer] = useState<Record<string, any>>();
|
||||
@@ -39,7 +42,9 @@ export const NotificationDataWrap = () => {
|
||||
});
|
||||
};
|
||||
useEffect(() => {
|
||||
callPaymentNotificationData();
|
||||
if(!!mid){
|
||||
callPaymentNotificationData();
|
||||
}
|
||||
}, [mid]);
|
||||
|
||||
return (
|
||||
|
||||
@@ -16,10 +16,13 @@ import { snackBar } from '@/shared/lib/toast';
|
||||
export const PasswordModifyCancelPasswordPage = () => {
|
||||
const { t } = useTranslation();
|
||||
const { navigate } = useNavigate();
|
||||
const midOptions = useStore.getState().UserStore.selectOptionsMids;
|
||||
const midOptionsWithoutGids = useStore.getState().UserStore.selectOptionsMidsWithoutGids;
|
||||
const userMid = useStore.getState().UserStore.mid;
|
||||
let midItem = midOptionsWithoutGids.filter((value, index) => {
|
||||
return value.value === userMid;
|
||||
});
|
||||
|
||||
const [mid, setMid] = useState<string>(userMid);
|
||||
const [mid, setMid] = useState<string>((midItem.length > 0)? userMid: '');
|
||||
const [password, setPassword] = useState<string>('');
|
||||
const [confirmPassword, setConfirmPassword] = useState<string>('');
|
||||
|
||||
@@ -78,7 +81,7 @@ export const PasswordModifyCancelPasswordPage = () => {
|
||||
onChange={(e) => setMid(e.target.value)}
|
||||
>
|
||||
{
|
||||
midOptions.map((value) => (
|
||||
midOptionsWithoutGids.map((value) => (
|
||||
<option
|
||||
key={value.value}
|
||||
value={value.value}
|
||||
|
||||
Reference in New Issue
Block a user