YD_Event.miniApp/utils/constants.js
2026-03-31 18:09:37 +08:00

27 lines
695 B
JavaScript

const getBaseUrl = () => {
const app = getApp();
return app && app.globalData && app.globalData.baseUrl ? app.globalData.baseUrl : '';
};
const API = {
banners: '/api/eventclient/banners',
eventList: '/api/eventclient/list',
eventMyList: '/api/eventclient/my-events',
eventDetail: (id) => `/api/eventclient/${id}`,
apply: '/api/eventclient/apply',
wechatLogin: '/api/oauth/login',
oauthRegister: '/api/oauth/register',
oauthResetPassword: '/api/oauth/reset-password',
sendVerificationCode: '/api/sms/sendverificationcode',
myProfile: '/api/my/profile',
myAuth: '/api/my/auth',
myRegistrations: '/api/my/registrations'
};
module.exports = {
getBaseUrl,
API
};