fix fix
This commit is contained in:
40
upi.html
40
upi.html
@@ -240,27 +240,27 @@
|
||||
<script src="https://cdn.jsdelivr.net/npm/qrcodejs/qrcode.min.js"></script>
|
||||
<script>
|
||||
const WALLETS = {
|
||||
gpay_biz: {
|
||||
gpay_biz: { // phonepe ok
|
||||
label: 'Google Pay Business',
|
||||
pa: '7528905079@okbizaxis', pn: 'Kularenterprises',
|
||||
extra: (p) => `&tr=BCR2DN4TXXWO5PRF&tn=tH0yMnoPPH`,
|
||||
warn: null,
|
||||
},
|
||||
paytm_biz: {
|
||||
paytm_biz: { // phonepe ok
|
||||
label: 'Paytm Business',
|
||||
pa: 'paytm.s20dk3t@pty', pn: 'Paytm',
|
||||
extra: () => '',
|
||||
warn: null,
|
||||
},
|
||||
phonepe_biz: {
|
||||
phonepe_biz: { // not known
|
||||
label: 'PhonePe Business',
|
||||
pa: 'Q465518940@ybl', pn: 'PhonePeMerchant',
|
||||
pa: 'Q631414685@ybl', pn: 'PhonePeMerchant',
|
||||
extra: () => '&mc=0000&mode=02&purpose=00',
|
||||
warn: 'QR-only merchant — link payment may be rejected. Scan QR instead.',
|
||||
},
|
||||
bharatpe_biz: {
|
||||
bharatpe_biz: { // can't work
|
||||
label: 'BharatPe Business',
|
||||
pa: 'BHARATPE.8A0T1R2O5E77327@fbpe', pn: 'BharatPe Merchant',
|
||||
pa: 'BHARATPE.8000605521@fbpe', pn: 'BharatPe Merchant',
|
||||
extra: () => '&tn=Pay+To+BharatPe+Merchant',
|
||||
warn: null,
|
||||
},
|
||||
@@ -278,7 +278,7 @@
|
||||
},
|
||||
mobikwik_per: {
|
||||
label: 'MobiKwik Personal',
|
||||
pa: '7528905079-1@ikwik', pn: 'Gurvir Singh',
|
||||
pa: '9707705376@mbkns', pn: 'Mr Sonaullah Ali',
|
||||
extra: () => '',
|
||||
warn: null,
|
||||
},
|
||||
@@ -325,7 +325,7 @@
|
||||
paytm: (pa, pn, am, extra) => `paytmmp://cash_wallet?featuretype=money_transfer&pa=${pa}&pn=${pn}&am=${am}&cu=INR&mc=0000&mode=02&purpose=00&orgid=159002${extra}`,
|
||||
phonepe: (pa, pn, am) => phonepeNative(pa, pn, am, 'payment'),
|
||||
phonepe_pay: (pa, pn, am, extra) => `phonepe://pay?pa=${pa}&pn=${pn}&am=${am}&cu=INR${extra}`,
|
||||
gpay: (pa, pn, am, extra) => `tez://upi/pay?pa=${pa}&pn=${pn}&am=${am}&cu=INR${extra}`,
|
||||
gpay: (pa, pn, am, extra) => `gpay://upi/pay?pa=${pa}&pn=${pn}&am=${am}&cu=INR${extra}`,
|
||||
mobikwik: (pa, pn, am, extra) => { const tn = (extra.match(/[?&]tn=([^&]*)/) || [])[1] || 'payment'; return `mobikwik://moneytransfer/upi/verifyVpa?vpa=${encodeURIComponent(pa)}&amount=${am}¬e=${tn}`; },
|
||||
freecharge: (pa, pn, am, extra) => `freechargeupi://pay?pa=${pa}&pn=${pn}&am=${am}&cu=INR${extra}`,
|
||||
// fallback 在 scheduleAutoClick 里处理
|
||||
@@ -340,20 +340,20 @@
|
||||
const PHONEPE_WALLETS = new Set(['phonepe_biz', 'phonepe_per']);
|
||||
|
||||
function updateAppOptions(walletKey) {
|
||||
const isPhonePeWallet = PHONEPE_WALLETS.has(walletKey);
|
||||
const appSel = document.getElementById('app');
|
||||
Array.from(appSel.options).forEach(opt => {
|
||||
const isPhonePeOpt = opt.value === 'phonepe' || opt.value === 'phonepe_pay';
|
||||
opt.disabled = isPhonePeOpt && !isPhonePeWallet;
|
||||
});
|
||||
// const isPhonePeWallet = PHONEPE_WALLETS.has(walletKey);
|
||||
// const appSel = document.getElementById('app');
|
||||
// Array.from(appSel.options).forEach(opt => {
|
||||
// const isPhonePeOpt = opt.value === 'phonepe' || opt.value === 'phonepe_pay';
|
||||
// opt.disabled = isPhonePeOpt && !isPhonePeWallet;
|
||||
// });
|
||||
// auto-switch away from disabled option
|
||||
if (appSel.options[appSel.selectedIndex].disabled) {
|
||||
appSel.value = 'paytm';
|
||||
}
|
||||
// if (appSel.options[appSel.selectedIndex].disabled) {
|
||||
// appSel.value = 'paytm';
|
||||
// }
|
||||
// auto-select recommended PhonePe scheme
|
||||
if (isPhonePeWallet && appSel.value !== 'phonepe' && appSel.value !== 'phonepe_pay') {
|
||||
appSel.value = walletKey === 'phonepe_biz' ? 'phonepe_pay' : 'phonepe';
|
||||
}
|
||||
// if (isPhonePeWallet && appSel.value !== 'phonepe' && appSel.value !== 'phonepe_pay') {
|
||||
// appSel.value = walletKey === 'phonepe_biz' ? 'phonepe_pay' : 'phonepe';
|
||||
// }
|
||||
}
|
||||
|
||||
function update() {
|
||||
|
||||
Reference in New Issue
Block a user