File tree Expand file tree Collapse file tree 3 files changed +12
-4
lines changed
admin/src/components/ShopItemCard Expand file tree Collapse file tree 3 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,9 @@ const ShopItemCard: React.FC<ShopItemCardProps> = ({
31
31
} ;
32
32
33
33
if ( isSuccess ) {
34
- window . location . reload ( ) ;
34
+ setTimeout ( ( ) => {
35
+ window . location . reload ( ) ;
36
+ } , 1000 ) ;
35
37
toast . success ( '상품 개수가 1개 차감되었습니다.' ) ;
36
38
}
37
39
Original file line number Diff line number Diff line change @@ -38,13 +38,17 @@ const RankingHeader: React.FC<RankingHeaderProps> = ({
38
38
} ;
39
39
40
40
if ( isSuccess ) {
41
+ setTimeout ( ( ) => {
42
+ location . reload ( ) ;
43
+ } , 1000 ) ;
41
44
toast . success ( '이미지 등록에 성공했습니다.' ) ;
42
- location . reload ( ) ;
43
45
}
44
46
45
47
if ( isError ) {
48
+ setTimeout ( ( ) => {
49
+ location . reload ( ) ;
50
+ } , 1000 ) ;
46
51
toast . error ( '잘못된 파일 유형입니다.' ) ;
47
- location . reload ( ) ;
48
52
}
49
53
50
54
return (
Original file line number Diff line number Diff line change @@ -51,8 +51,10 @@ const ShopModal: React.FC<ShopModalProps> = ({ selectedList }) => {
51
51
52
52
if ( isError ) {
53
53
if ( error && error . response ?. status === 400 ) {
54
+ setTimeout ( ( ) => {
55
+ location . reload ( ) ;
56
+ } , 1000 ) ;
54
57
toast . error ( '마일리지가 부족합니다.' ) ;
55
- location . reload ( ) ;
56
58
}
57
59
}
58
60
You can’t perform that action at this time.
0 commit comments