feat(bd中心api文件): 新增接口
This commit is contained in:
parent
0e29ee8150
commit
bd7ed90065
@ -96,7 +96,31 @@ export const getBdHistoryMore = async (billBelong) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// BD 可赠送道具详情
|
// 是否有赠送礼物的权限
|
||||||
|
export const hasSendGiftsPermission = async () => {
|
||||||
|
try {
|
||||||
|
const response = await get(`/sys/bd/own-permission`)
|
||||||
|
return response
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Failed to fetch has send gifts permission:', error)
|
||||||
|
console.error('error:' + error.response.errorMsg)
|
||||||
|
throw error
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取赠送礼物的类型列表
|
||||||
|
export const getSendGiftsPermissionList = async () => {
|
||||||
|
try {
|
||||||
|
const response = await get(`/sys/bd/list-permission`)
|
||||||
|
return response
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Failed to fetch send gifts permission list:', error)
|
||||||
|
console.error('error:' + error.response.errorMsg)
|
||||||
|
throw error
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// BD 可赠送礼物详情
|
||||||
export const getBDPropsList = async (params) => {
|
export const getBDPropsList = async (params) => {
|
||||||
try {
|
try {
|
||||||
const response = await get(
|
const response = await get(
|
||||||
@ -110,19 +134,7 @@ export const getBDPropsList = async (params) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 是否有指定道具类型的权限
|
// BD 赠送礼物
|
||||||
export const hasSendGiftsPermission = async (propsType) => {
|
|
||||||
try {
|
|
||||||
const response = await get(`/sys/bd/own-permission?propsType=${propsType}`)
|
|
||||||
return response
|
|
||||||
} catch (error) {
|
|
||||||
console.error('Failed to fetch has send gifts permission:', error)
|
|
||||||
console.error('error:' + error.response.errorMsg)
|
|
||||||
throw error
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// BD 赠送道具.
|
|
||||||
export const giveProps = async (data) => {
|
export const giveProps = async (data) => {
|
||||||
try {
|
try {
|
||||||
const response = await post('/sys/bd/send', data)
|
const response = await post('/sys/bd/send', data)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user