Fix : Error of API integration
This commit is contained in:
@@ -8,7 +8,7 @@ import NextImage from "next/image";
|
|||||||
import logo from '@/app/image/logo.jpg';
|
import logo from '@/app/image/logo.jpg';
|
||||||
import changePwdImage from '@/app/image/changepw.png';
|
import changePwdImage from '@/app/image/changepw.png';
|
||||||
import CaptchaImage from './CaptchaImage';
|
import CaptchaImage from './CaptchaImage';
|
||||||
import { IconEye, IconEyeOff } from '@tabler/icons-react';
|
import { IconEye, IconEyeOff, IconLogout } from '@tabler/icons-react';
|
||||||
|
|
||||||
export default function ChangeLoginPwd() {
|
export default function ChangeLoginPwd() {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
@@ -18,11 +18,15 @@ export default function ChangeLoginPwd() {
|
|||||||
const [confirmPassword, setConfirmPassword] = useState("");
|
const [confirmPassword, setConfirmPassword] = useState("");
|
||||||
const [captchaInput, setCaptchaInput] = useState('');
|
const [captchaInput, setCaptchaInput] = useState('');
|
||||||
const [captchaError, setCaptchaError] = useState('');
|
const [captchaError, setCaptchaError] = useState('');
|
||||||
|
|
||||||
|
|
||||||
const [confirmVisible, setConfirmVisible] = useState(false);
|
const [confirmVisible, setConfirmVisible] = useState(false);
|
||||||
const toggleConfirmVisibility = () => setConfirmVisible((v) => !v);
|
const toggleConfirmVisibility = () => setConfirmVisible((v) => !v);
|
||||||
|
|
||||||
|
async function handleLogout(e: React.FormEvent) {
|
||||||
|
e.preventDefault();
|
||||||
|
localStorage.removeItem("access_token");
|
||||||
|
router.push("/login")
|
||||||
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
generateCaptcha();
|
generateCaptcha();
|
||||||
}, []);
|
}, []);
|
||||||
@@ -141,6 +145,15 @@ export default function ChangeLoginPwd() {
|
|||||||
alt="ebanking"
|
alt="ebanking"
|
||||||
style={{ width: "100%", height: "100%" }}
|
style={{ width: "100%", height: "100%" }}
|
||||||
/>
|
/>
|
||||||
|
<Button style={{
|
||||||
|
position: 'absolute',
|
||||||
|
top: '50%',
|
||||||
|
left: '90%',
|
||||||
|
color: 'white',
|
||||||
|
textShadow: '1px 1px 2px black',
|
||||||
|
fontSize: "20px"
|
||||||
|
}}
|
||||||
|
leftSection={<IconLogout color='white' />} variant="subtle" onClick={handleLogout}>Logout</Button>
|
||||||
</Box>
|
</Box>
|
||||||
<div style={{ marginTop: '10px' }}>
|
<div style={{ marginTop: '10px' }}>
|
||||||
|
|
||||||
|
@@ -8,7 +8,7 @@ import NextImage from "next/image";
|
|||||||
import logo from '@/app/image/logo.jpg';
|
import logo from '@/app/image/logo.jpg';
|
||||||
import changePwdImage from '@/app/image/changepw.png';
|
import changePwdImage from '@/app/image/changepw.png';
|
||||||
import CaptchaImage from './CaptchaImage';
|
import CaptchaImage from './CaptchaImage';
|
||||||
import { IconEye, IconEyeOff } from '@tabler/icons-react';
|
import { IconEye, IconEyeOff, IconLogout } from '@tabler/icons-react';
|
||||||
|
|
||||||
export default function ChangeTransactionPwd() {
|
export default function ChangeTransactionPwd() {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
@@ -21,6 +21,12 @@ export default function ChangeTransactionPwd() {
|
|||||||
const [confirmVisible, setConfirmVisible] = useState(false);
|
const [confirmVisible, setConfirmVisible] = useState(false);
|
||||||
const toggleConfirmVisibility = () => setConfirmVisible((v) => !v);
|
const toggleConfirmVisibility = () => setConfirmVisible((v) => !v);
|
||||||
|
|
||||||
|
async function handleLogout(e: React.FormEvent) {
|
||||||
|
e.preventDefault();
|
||||||
|
localStorage.removeItem("access_token");
|
||||||
|
router.push("/login")
|
||||||
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
generateCaptcha();
|
generateCaptcha();
|
||||||
}, []);
|
}, []);
|
||||||
@@ -139,6 +145,16 @@ export default function ChangeTransactionPwd() {
|
|||||||
alt="ebanking"
|
alt="ebanking"
|
||||||
style={{ width: "100%", height: "100%" }}
|
style={{ width: "100%", height: "100%" }}
|
||||||
/>
|
/>
|
||||||
|
<Button style={{
|
||||||
|
position: 'absolute',
|
||||||
|
top: '50%',
|
||||||
|
left: '90%',
|
||||||
|
color: 'white',
|
||||||
|
textShadow: '1px 1px 2px black',
|
||||||
|
fontSize: "20px"
|
||||||
|
}}
|
||||||
|
leftSection={<IconLogout color='white' />} variant="subtle" onClick={handleLogout}>Logout
|
||||||
|
</Button>
|
||||||
</Box>
|
</Box>
|
||||||
<div style={{ marginTop: '10px' }}>
|
<div style={{ marginTop: '10px' }}>
|
||||||
<Box style={{ display: "flex", justifyContent: "center", alignItems: "center", columnGap: "5rem" }} bg="#c1e0f0">
|
<Box style={{ display: "flex", justifyContent: "center", alignItems: "center", columnGap: "5rem" }} bg="#c1e0f0">
|
||||||
|
Binary file not shown.
Before Width: | Height: | Size: 17 KiB |
@@ -40,7 +40,7 @@ export default function Login() {
|
|||||||
|
|
||||||
async function handleLogin(e: React.FormEvent) {
|
async function handleLogin(e: React.FormEvent) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
setIsLogging(false);
|
setIsLogging(true);
|
||||||
|
|
||||||
const onlyDigit = /^\d{11}$/;
|
const onlyDigit = /^\d{11}$/;
|
||||||
if (!onlyDigit.test(CIF)) {
|
if (!onlyDigit.test(CIF)) {
|
||||||
@@ -144,7 +144,7 @@ export default function Login() {
|
|||||||
⚠️ Always login to our Net Banking site directly or through Banks website.
|
⚠️ Always login to our Net Banking site directly or through Banks website.
|
||||||
⚠️ Do not disclose your UserId and Password to any third party and keep Your UserId and Password strictly confidential.
|
⚠️ Do not disclose your UserId and Password to any third party and keep Your UserId and Password strictly confidential.
|
||||||
⚠️ KCC Bank never asks for UserId,Passwords and Pins through email or phone.
|
⚠️ KCC Bank never asks for UserId,Passwords and Pins through email or phone.
|
||||||
⚠️ Be ware of Phishing mails with links to fake bank's websites asking for personal information are in circulation.
|
⚠️ Be ware of Phishing mails with links to fake bank's websites asking for personal information are in circulation.
|
||||||
⚠️ Please DO NOT Click on the links given in the emails asking for personal details like bank account number, userID and password.
|
⚠️ Please DO NOT Click on the links given in the emails asking for personal details like bank account number, userID and password.
|
||||||
⚠️ If you had shard your UserId and Password through such mails or links, please change your Password immediately.
|
⚠️ If you had shard your UserId and Password through such mails or links, please change your Password immediately.
|
||||||
⚠️ Inform the Bank/branch in which your account is maintained for resetting your password.
|
⚠️ Inform the Bank/branch in which your account is maintained for resetting your password.
|
||||||
|
Reference in New Issue
Block a user