| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- import request from "@/utils/request";
- export interface ServiceProviderTable {
- id?: number;
- name?: string;
- scopeLabel?: string;
- appId?: string;
- serverUrl?: string;
- signType?: string;
- format?: string;
- charset?: string;
- providerStatus?: string;
- description?: string;
- appPrivateKeyHint?: string;
- alipayPublicKeyHint?: string;
- createdTime?: string;
- updatedTime?: string;
- }
- export interface ServiceProviderListResult {
- total: number;
- items: ServiceProviderTable[];
- }
- export interface ServiceProviderCreateForm {
- name: string;
- scopeLabel: string;
- appId: string;
- appPrivateKey: string;
- alipayPublicKey: string;
- serverUrl?: string;
- signType?: string;
- format?: string;
- charset?: string;
- description?: string;
- }
- export interface ServiceProviderUpdateForm {
- name?: string;
- scopeLabel?: string;
- appId?: string;
- appPrivateKey?: string;
- alipayPublicKey?: string;
- serverUrl?: string;
- signType?: string;
- format?: string;
- charset?: string;
- description?: string;
- }
- export interface ServiceProviderOption {
- id: number;
- name: string;
- scopeLabel: string;
- }
- const API = {
- list: (params: any) =>
- request.get("/system/service-provider/list", { params }),
- detail: (id: number) =>
- request.get(`/system/service-provider/detail/${id}`),
- create: (data: ServiceProviderCreateForm) =>
- request.post("/system/service-provider/create", data),
- update: (id: number, data: ServiceProviderUpdateForm) =>
- request.put(`/system/service-provider/update/${id}`, data),
- delete: (ids: number[]) =>
- request.delete("/system/service-provider/delete", { data: ids }),
- toggle: (id: number) =>
- request.patch(`/system/service-provider/toggle/${id}`),
- options: () =>
- request.get("/system/service-provider/options"),
- };
- export default API;
|