You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
199 lines
4.3 KiB
199 lines
4.3 KiB
import http from "@/utils/request";
|
|
|
|
export function getQuestionModule() {
|
|
return http.get("/my/questionModule");
|
|
}
|
|
|
|
export function getMenus() {
|
|
return http.get("/my/getPersonalCenterMenu");
|
|
}
|
|
|
|
export function getCopyrightInfo() {
|
|
return http.get("/login/get_copyright", null, {
|
|
moduleName: "admin"
|
|
});
|
|
}
|
|
|
|
export function getUserBaseData() {
|
|
return http.get("/my/base_data_api", null);
|
|
}
|
|
|
|
export function validLoginStatus() {
|
|
return http.get("/index/login_user");
|
|
}
|
|
|
|
export function userLogin(data) {
|
|
return http.post("/login/check", data);
|
|
}
|
|
|
|
export function smsLogin(data, isWeChat = false) {
|
|
return http.post(isWeChat ? '/index/login' : '/login/phone_check', data);
|
|
}
|
|
export function appleLogin(data) {
|
|
return http.post("/login/apple", data);
|
|
}
|
|
|
|
|
|
export function getAuthCode(phone) {
|
|
return http.post('/auth_api/code', {
|
|
phone
|
|
});
|
|
}
|
|
|
|
export function registerAccount(data) {
|
|
return http.post('/login/register', data);
|
|
}
|
|
|
|
export function changePwd(data) {
|
|
return http.post('/login/register', data, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function saveUserInfo(data) {
|
|
return http.post("/my/save_user_info", data, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function logout() {
|
|
return http.get("/my/logout", null, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function validateCode(phone, code) {
|
|
return http.get("/my/validate_code", {
|
|
phone,
|
|
code
|
|
}, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function bindUserPhone(phone, code, type) {
|
|
return http.get("/my/save_phone", {
|
|
phone,
|
|
code,
|
|
type
|
|
}, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getSignInfoApi() {
|
|
return http.get("/my/sign_in_api", null, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getBillList(index, first, limit) {
|
|
return http.get("/auth_api/user_balance_list", {
|
|
index, first, limit
|
|
}, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getGoldList(index, first, limit) {
|
|
return http.get("/auth_api/user_gold_num_list", {
|
|
index, first, limit
|
|
}, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getCoinData() {
|
|
return http.get("/my/gold_coin_api", null, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getAddress() {
|
|
return http.get("/my/address_api", null, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function setDefaultAddress(addressId) {
|
|
return http.get("/auth_api/set_user_default_address", { addressId }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function removeUserAddress(addressId) {
|
|
return http.get("/auth_api/remove_user_address", { addressId }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getUserAddressInfo(addressId, cartId = '') {
|
|
return http.get("/my/edit_address_api", { addressId, cartId }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function updateUserAddressInfo(data) {
|
|
return http.post(
|
|
"/auth_api/edit_user_address",
|
|
data,
|
|
{
|
|
requireAuth: true
|
|
}
|
|
);
|
|
}
|
|
|
|
export function getAboutUsInfo() {
|
|
return http.get("/my/about_us_api", null, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getExpressOrderData(uni) {
|
|
return http.get("/my/express_api", { uni }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getExpressData(delivery_id) {
|
|
return http.get("/auth_api/query", { delivery_id }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getOrderList(params) {
|
|
return http.get("/my/get_order_list", params, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getOrderReplyData(unique) {
|
|
return http.get("/my/order_reply_api", { unique }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function saveProductComment(unique, data) {
|
|
return http.post("/auth_api/user_comment_product?unique=" + unique, data, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
|
|
export function getOrderRefundData(order_id) {
|
|
return http.get("/my/refund_apply_api", { order_id }, {
|
|
requireAuth: true
|
|
});
|
|
}
|
|
export function routineLogin(data){
|
|
return http.post("/login/routine_auth", data);
|
|
};
|
|
export function wechath5Login(data){
|
|
return http.get("/login/wechatindex", data);
|
|
};
|
|
|
|
export function getAppid(){
|
|
return http.get("/login/getappid");
|
|
}
|
|
export function isForceBinding(){
|
|
return http.get("/login/get_isforce_binding");
|
|
} |