You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.1 KiB
TypeScript
44 lines
1.1 KiB
TypeScript
import axios from 'axios';
|
|
|
|
// 公共路径
|
|
const urlPrefix = '/api/v1/bpms-workbench';
|
|
|
|
// 我的组件
|
|
export function getMyComponentList(params) {
|
|
return axios.get(`${urlPrefix}/componentBase/list`, { params });
|
|
}
|
|
|
|
// 协作组件
|
|
export function getCooperationComponentList(params) {
|
|
return axios.get(`${urlPrefix}/componentBase/page/collaborator`, { params });
|
|
}
|
|
|
|
// 获取标签列表
|
|
export function getTagList() {
|
|
return axios.get(`${urlPrefix}/componentBase/tags`);
|
|
}
|
|
|
|
// 校验项目标识
|
|
export function compProjectValidate(projectId) {
|
|
return axios.post(`${urlPrefix}/componentBase/validate?projectId=${projectId}`);
|
|
}
|
|
|
|
// 组件信息提交/更新
|
|
export function compSubmit(params) {
|
|
return axios.post(`${urlPrefix}/componentBase/submit`, params);
|
|
}
|
|
|
|
// 组件删除
|
|
export const remove = (ids) => {
|
|
return axios.post(`${urlPrefix}/componentBase/remove?ids=${ids}`);
|
|
};
|
|
|
|
// 组件导出
|
|
export const exportComponent = (id) => {
|
|
return axios.get(`${urlPrefix}/componentBase/export?id=${id}`);
|
|
};
|
|
|
|
// 复制代码和设计
|
|
export const copyAll = (params) => {
|
|
return axios.post(`${urlPrefix}/componentBase/copy`, params);
|
|
}; |