增加菜单页面,增加小程序管理页面,增加店铺员工页面

This commit is contained in:
2025-02-17 10:03:35 +08:00
parent 4adee9121e
commit 960bbada59
29 changed files with 2508 additions and 280 deletions

View File

@@ -0,0 +1,256 @@
import request from "@/utils/request";
import { Account_BaseUrl } from "@/api/config";
const baseURL = Account_BaseUrl + "/admin/shopStaff";
const ShopStaffApi = {
getList(params: getListRequest) {
return request<any, getListResponse>({
url: `${baseURL}`,
method: "get",
params: params,
});
},
get(id: number | string) {
return request<any>({
url: `${baseURL}/detail`,
method: "get",
params: { id }
});
},
add(data: addRequest) {
return request<any>({
url: `${baseURL}`,
method: "post",
data,
});
},
edit(data: editRequest) {
return request<any>({
url: `${baseURL}`,
method: "put",
data,
});
},
delete(id: number | string) {
return request<any>({
url: `${baseURL}`,
method: "delete",
data: {
id
}
});
},
};
export default ShopStaffApi;
export interface getListRequest {
/**
* 员工编号
*/
code?: string;
/**
* 账号名
*/
name?: string;
[property: string]: any;
}
/**
* 分页数据
*
* CzgResult«Page«ShopStaff»»
*/
export interface getListResponse {
code?: number | null;
data?: PageShopStaff;
msg?: null | string;
[property: string]: any;
}
/**
* Page«ShopStaff»
*/
export interface PageShopStaff {
/**
* 每页数据数量最大限制。
*/
maxPageSize?: number | null;
/**
* 是否优化分页查询 COUNT 语句。
*/
optimizeCountQuery?: boolean | null;
/**
* 当前页码。
*/
pageNumber?: number | null;
/**
* 每页数据数量。
*/
pageSize?: number | null;
/**
* 当前页数据。
*/
records?: ShopStaff[] | null;
/**
* 总页数。
*/
totalPage?: number | null;
/**
* 总数据数量。
*/
totalRow?: number | null;
[property: string]: any;
}
/**
* 店铺员工 实体类。
*
* ShopStaff
*/
export interface ShopStaff {
/**
* 员工编号
*/
code?: null | string;
createTime?: null | string;
/**
* 优惠类型 1 折扣 0 金额
*/
discountType?: null | string;
/**
* 使用系统用户 sys_user id
*/
id?: number | null;
/**
* 是否允许管理端登录 0不允许1允许
*/
isManage?: number | null;
/**
* 是否允许pc端登录 0不允许1允许
*/
isPc?: number | null;
/**
* 最大优惠金额
*/
maxDiscountAmount?: number | null;
/**
* 员工名称
*/
name?: null | string;
/**
* shopId
*/
shopId?: number | null;
/**
* 1启用0不启用
*/
status?: boolean | null;
/**
* master商户账号staff员工
*/
type?: null | string;
updateTime?: null | string;
[property: string]: any;
}
/**
* 添加信息
*
* ShopStaffAddDTO
*/
export interface addRequest {
/**
* 登录账号
*/
accountName: null | string;
/**
* 登录密码
*/
accountPwd: null | string;
/**
* 员工编号
*/
code: null | string;
/**
* 优惠类型 1 折扣 0 金额
*/
discountType?: number | null;
/**
* 是否允许管理端登录
*/
isManage?: number | null;
/**
* 是否允许pc登录
*/
isPc?: number | null;
/**
* 最大优惠金额
*/
maxDiscountAmount?: number | null;
/**
* 员工姓名
*/
name?: null | string;
/**
* 手机号
*/
phone: null | string;
/**
* 角色id
*/
roleId: number | null;
/**
* 1启用0不启用
*/
status?: number | null;
[property: string]: any;
}
/**
* 添加信息
*
* ShopStaffEditDTO
*/
export interface editRequest {
/**
* 登录密码
*/
accountPwd?: null | string;
/**
* 员工编号
*/
code?: null | string;
/**
* 优惠类型 1 折扣 0 金额
*/
discountType?: number | null;
id: number | null;
/**
* 是否允许管理端登录
*/
isManage?: number | null;
/**
* 是否允许pc登录
*/
isPc?: number | null;
/**
* 最大优惠金额
*/
maxDiscountAmount?: number | null;
/**
* 员工姓名
*/
name?: null | string;
/**
* 手机号
*/
phone?: null | string;
/**
* 角色id
*/
roleId?: number | null;
/**
* 1启用0不启用
*/
status?: number | null;
[property: string]: any;
}