缩短b_did长度

This commit is contained in:
al 2024-07-24 15:32:23 +08:00
parent 7e6b07910b
commit 0ce42b7506
5 changed files with 8 additions and 5 deletions

View File

@ -2,6 +2,7 @@ import { get } from "@/utils/storeInfo";
import requireAPI from "@/utils/requireAPI";
import { Toast } from "antd-mobile";
import { JSEncrypt } from "jsencrypt";
import baseRequest from "@/utils/baseRequest";
//关注和取关功能
export const handleLogout = async () => {
const account = get("account");
@ -168,7 +169,7 @@ export const createOrder = async (type = "alipay_h5") => {
return;
}
const base = webviewBaseRequest();
const base = baseRequest();
const body = {
...base,
product_id: customCoin.selected ? "h5_custom_coin" : selectedPrice.id,

View File

@ -95,9 +95,10 @@ export default function Wallet() {
// title: "充值中心",
// uri: process.env.EXPO_PUBLIC_WEB_URL + "/pay",
// })
{console.log("base,base",base);
router.push(
`/webView/${encodeURIComponent(`pay?mid=${encodeURIComponent(JSON.stringify(base))}`)}`
)
`/webView/${encodeURIComponent(`pay?base=${encodeURIComponent(JSON.stringify(base))}`)}`
)}
}
className="flex justify-between items-center py-4 w-full"
>

View File

@ -158,7 +158,7 @@ const ZoneItem = ({ data, showMore, link,search }) => {
return (
<List.Item
className="!p-0"
onClick={() => {router.push(`/search?search=${search}`);router.push(link);}}
onClick={() => {router.push(link)}}
key={data.id}
arrow={false}
>

View File

@ -11,6 +11,7 @@ export default function baseRequest() {
b_ch: "h5",
b_ts: b_ts,
b_token: token,
b_did: navigator?.userAgent.slice(0,32),
};
// console.log("baseRequest",baseRequest)
return baseRequest;

View File

@ -5,7 +5,7 @@ export default function webviewBaseRequest() {
const b_ts = new Date().getTime();
const baseRequest = {
b_mid: parseInt(cookies.b_mid),
b_did: navigator.userAgent,
b_did: window && window.navigator?.userAgent.slice(0,65),
b_ver: cookies.b_ver,
b_dt: parseInt(cookies.b_dt),
b_model: cookies.b_model,