12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 |
- import { BannerRep } from "@/api/home";
- import { server } from "@/utils/client";
- type SwitchType = 1 | 2; // 1开启 2关闭
- export interface ConfigType {
- show_free_game: SwitchType;
- show_again_game: SwitchType;
- identity_verify: IdentityVerify;
- }
- export interface IdentityVerify {
- /**
- * 充值实名,1开启 2关闭
- */
- deposit: SwitchType;
- /**
- * 注册实名,1开启 2关闭
- */
- register: SwitchType;
- /**
- * 提现实名,1开启 2关闭
- */
- withdraw: SwitchType;
- }
- export const getConfigApi = async () => {
- return server
- .request<ConfigType>({
- url: "/v1/api/front/system/configs",
- method: "POST",
- })
- .then((res) => {
- return res.data;
- });
- };
- export const getShareApi = async (params: { channel_url: string }) => {
- return server.request({
- url: `/v1/api/user/channel/add_click`,
- method: "get",
- params,
- });
- };
- /**
- * @description
- * 获取邮箱联系列表
- * POST /v1/api/front/links/contacts
- * 接口ID:257797888
- * 接口地址:https://app.apifox.com/link/project/4790544/apis/api-257797888
- */
- export interface ContactType {
- /**
- * 邮箱地址
- */
- email: string;
- /**
- * 名称
- */
- name: string;
- /**
- * 侧边栏显示,1显示 2不显示
- */
- show_bar: SwitchType;
- /**
- * 首页显示,1显示 2不显示
- */
- show_home: SwitchType;
- }
- export const getContactsApi = async () => {
- return server.request<ContactType[]>({
- url: `/v1/api/front/links/contacts`,
- method: "POST",
- });
- };
- /**
- * @description
- * 获取侧边栏
- * POST /v1/api/front/sidebar
- * 接口ID:258235334
- * 接口地址:https://app.apifox.com/link/project/4790544/apis/api-258235334
- */
- export const getSidebarActivitiesApi = async () => {
- return server.request<BannerRep[]>({
- url: `/v1/api/front/sidebar`,
- method: "POST",
- });
- };
|