| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178 |
- import { ResPage, StoreUser } from "@/api/interface/index";
- import { PORT_NONE } from "@/api/config/servicePort";
- import http from "@/api";
- /**
- * @name 商铺用户模块
- */
- // 获取商铺用户列表
- export const getThaliList = params => {
- return http.get<ResPage<StoreUser.ResStoreUserList>>(PORT_NONE + `/PcGroupBuy/getThaliList`, params);
- };
- export const saveStoreInfo = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/info/saveStoreInfo`, params);
- };
- export const getUserByPhone = params => {
- return http.get(PORT_NONE + `/store/user/getUserByPhone`, params);
- };
- export const getDetail = params => {
- return http.get(PORT_NONE + `/store/info/getDetail`, params);
- };
- export const getMenuByStoreId = params => {
- return http.get(PORT_NONE + `/menuPlatform/getMenuByStoreId`, params);
- };
- // 新增商家端用户
- export const addStoreUser = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/user/addStoreUser`, params);
- };
- // 修改商家端用户
- export const editStoreUser = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/user/editStoreUser`, params);
- };
- // 重置商家端用户密码及支付密码
- export const resetStoreUserPassword = (params: { id: string }) => {
- return http.put(PORT_NONE + `/store/user/resetStoreUserPassword`, params);
- };
- // 删除商家端用户
- export const deleteStoreUser = (params: { id: string }) => {
- return http.delete(PORT_NONE + `/store/user/deleteStoreUser`, params);
- };
- // 切换商家端用户状态
- export const switchingStates = (params: { id: string }) => {
- return http.put(PORT_NONE + `/store/user/switchingStates`, params);
- };
- // 获取商铺列表
- export const getStoreInfoList = (params: StoreUser.ReqUserParams) => {
- return http.get<ResPage<StoreUser.ResStoreUserList>>(PORT_NONE + `/store/info/getStorePage`, params);
- };
- //获取商铺经营板块列表
- export const getBusinessSection = () => {
- return http.get(PORT_NONE + `/store/info/getBusinessSection`);
- };
- //获取商铺经营种类列表
- export const getBusinessSectionTypes = (params: { parentId: string }) => {
- return http.get<ResPage<StoreUser.ResStoreUserList>>(PORT_NONE + `/store/info/getBusinessSectionTypes`, params);
- };
- //获取未绑定的商家端账号
- export const getUnboundAccountList = (params: { id: string }) => {
- return http.get(PORT_NONE + `/store/info/getUnboundAccountList`, params);
- };
- //新增经营板块
- export const addBusinessSectionAndTypes = (params: {
- businessSectionName: string;
- businessTypeValue: string;
- businessTypesList: [];
- }) => {
- return http.post(PORT_NONE + `/store/info/addBusinessSectionAndTypes`, params);
- };
- //新增商铺信息
- //获取商铺明细信息
- export const getStoreDetail = (params: StoreUser.ReqUserParams) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/store/info/getStoreDetail`, params);
- };
- //新增商铺信息
- export const editStoreInfo = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/info/editStoreInfo`, params);
- };
- // 删除商铺信息
- export const deleteStoreInfo = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/info/deleteStoreInfo`, params);
- };
- //审批商户
- export const approveStoreInfo = (params: { id: string; approvalStatus: number; reason: string }) => {
- return http.get(PORT_NONE + `/store/info/approveStoreInfo`, params);
- };
- //审批商户续约
- export const updateContractImageStatus = (params: { id: string; approvalStatus: number }) => {
- return http.post(PORT_NONE + `/store/info/updateContractImageStatus`, params);
- };
- //审批经营许可证变更
- export const updatefoodLicenceImageStatus = (params: { id: string; approvalStatus: number }) => {
- return http.post(PORT_NONE + `/store/info/updatefoodLicenceImageStatus`, params);
- };
- // 重置商户或者用户密码
- export const resetStoreUserPassWord = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/info/restPassword`, params);
- };
- // 获取店铺状态
- export const getStoreAuditStatus = (params: { id: string }) => {
- return http.post(PORT_NONE + `/store/info/getStoreAuditStatus`, params);
- };
- //商铺页面导出excel
- export const exportExcel = (params: {}) => {
- return http.get(PORT_NONE + `/store/info/exportExcel`, params);
- };
- //商铺过期查询页面导出excel
- export const exportExcelExpirationTime = (params: {}) => {
- return http.get(
- PORT_NONE +
- `/store/info/exportExcelExpirationTime
- `,
- params
- );
- };
- //商铺用户页面导出excel
- export const exportUserExcel = (params: {}) => {
- return http.get(
- PORT_NONE +
- `/store/user/exportExcel
- `,
- params
- );
- };
- //根据详细信息获取经纬度名称
- export const getInputPrompt = (params: StoreUser.ReqUserParams) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/gaode/getInputPrompt`, params);
- };
- //获取行政区域信息
- export const getDistrict = (params: StoreUser.ReqUserParams) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/gaode/getDistrict`, params);
- };
- // 更改店铺抽成百分比
- export const updateStoreCommissionRate = (params: { id: string; commissionRate: any }) => {
- return http.post(PORT_NONE + `/store/info/updateStoreCommissionRate`, params);
- };
- // 节假日列表
- export const getHolidayList = (params: any) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/couponPlatform/getHolidayList`, params);
- };
- // 节假日列表
- export const saveHoliday = (params: any) => {
- return http.post<StoreUser.ResStoreUserList>(PORT_NONE + `/coupon/saveHoliday`, params);
- };
- //删除节假日
- export const delHoliday = (params: any) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/coupon/delHoliday`, params);
- };
- // 按年份删除节假日
- export const delHolidayByYear = (params: any) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/coupon/delHolidayByYear`, params);
- };
- //启用禁用节假日
- export const openCloseHoliday = (params: any) => {
- return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/coupon/openCloseHoliday`, params);
- };
|