fix: 主包孤儿文件 api/order.ts 迁入分包(pingxiang-order),消除真机代码质量告警
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
64ac69db93
commit
e1801f1026
@@ -1,11 +0,0 @@
|
|||||||
import { post } from './request'
|
|
||||||
import { BASE_URL } from '../config'
|
|
||||||
import type { CreateOrderParams, CreateOrderResult, PrepayParams, PrepayResult } from './types'
|
|
||||||
|
|
||||||
export function createOrder(params: CreateOrderParams) {
|
|
||||||
return post<CreateOrderResult>(`${BASE_URL}/open-api/pingXiang/createOrder`, params)
|
|
||||||
}
|
|
||||||
|
|
||||||
export function prepay(params: PrepayParams) {
|
|
||||||
return post<PrepayResult>(`${BASE_URL}/open-api/pingXiang/prepay`, params)
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
// xuchao: 萍乡超级玩家卡下单/预支付接口(open-api 渠道)。原为主包 api/order.ts,
|
||||||
|
// 因仅被本分包页面引用导致主包整包扫描告警,迁入分包;与本地 order.ts(/order/* 旧接口)不是同一组接口,勿混用。
|
||||||
|
import { post } from '../../../api/request'
|
||||||
|
import { BASE_URL } from '../../../config'
|
||||||
|
import type { CreateOrderParams, CreateOrderResult, PrepayParams, PrepayResult } from '../../../api/types'
|
||||||
|
|
||||||
|
export function createOrder(params: CreateOrderParams) {
|
||||||
|
return post<CreateOrderResult>(`${BASE_URL}/open-api/pingXiang/createOrder`, params)
|
||||||
|
}
|
||||||
|
|
||||||
|
export function prepay(params: PrepayParams) {
|
||||||
|
return post<PrepayResult>(`${BASE_URL}/open-api/pingXiang/prepay`, params)
|
||||||
|
}
|
||||||
@@ -50,7 +50,7 @@ import { onLoad, onShareAppMessage, onShareTimeline } from '@dcloudio/uni-app'
|
|||||||
import { post, getToken } from '../../../api/request'
|
import { post, getToken } from '../../../api/request'
|
||||||
import { BASE_URL } from '../../../config'
|
import { BASE_URL } from '../../../config'
|
||||||
import { useUserStore } from '../../../store/user'
|
import { useUserStore } from '../../../store/user'
|
||||||
import { createOrder, prepay } from '../../../api/order'
|
import { createOrder, prepay } from '../api/pingxiang-order'
|
||||||
import type { BannerItem } from '../../../api/types'
|
import type { BannerItem } from '../../../api/types'
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
|
|||||||
Reference in New Issue
Block a user