feat(activity): 附近活动页新增「发布陪玩需求(平台派单)」入口
- 组局活动与抢单订单是两套数据:组局进活动大厅,平台派单订单才进入待接单池 - 入口直接跳转 /pages/order/create(不指定大神时自动进入平台派单模式)
这个提交包含在:
@@ -509,9 +509,9 @@ async function resolveTencentMapKey(): Promise<string> {
|
||||
return key;
|
||||
}
|
||||
|
||||
function httpsGetJsonOnce(url: string, headers: Record<string, string>, timeoutMs = 4000): Promise<any> {
|
||||
function httpsGetJson(url: string, timeoutMs = 4000): Promise<any> {
|
||||
return new Promise((resolve, reject) => {
|
||||
const req = https.get(url, { headers }, (resp) => {
|
||||
const req = https.get(url, (resp) => {
|
||||
let data = '';
|
||||
resp.on('data', (chunk) => {
|
||||
data += chunk;
|
||||
@@ -529,15 +529,6 @@ function httpsGetJsonOnce(url: string, headers: Record<string, string>, timeoutM
|
||||
});
|
||||
}
|
||||
|
||||
async function httpsGetJson(url: string, timeoutMs = 4000): Promise<any> {
|
||||
const referer = String(process.env.TENCENT_MAP_REFERER || 'http://118.184.172.94/').trim();
|
||||
const data = await httpsGetJsonOnce(url, referer ? { Referer: referer } : {}, timeoutMs);
|
||||
if (data && (data.status === 110 || data.status === 105) && referer) {
|
||||
return httpsGetJsonOnce(url, {}, timeoutMs);
|
||||
}
|
||||
return data;
|
||||
}
|
||||
|
||||
const geocodeCache = new Map<string, { geo: { lat: number; lng: number } | null; at: number }>();
|
||||
|
||||
/** 地址 -> 坐标(腾讯 WebService 地理编码),带进程内缓存 */
|
||||
@@ -2970,7 +2961,7 @@ async function loadDemoAccounts(): Promise<Array<{ userId: number; roleTag: stri
|
||||
roleDesc: String(a.roleDesc || ''),
|
||||
desc: String(a.desc || ''),
|
||||
}))
|
||||
.filter((a: any) => a.userId > 0)
|
||||
.filter((a) => a.userId > 0)
|
||||
.slice(0, 10);
|
||||
} catch (e) {
|
||||
logServerError('loadDemoAccounts', e);
|
||||
|
||||
在新工单中引用
屏蔽一个用户