luobisheng
2022-11-09 f7bdedf1f3f7600c73f6d5beb46c1d1f4d518822
src/api/system/portal/teamConstruction.js
@@ -1,62 +1,25 @@
import { getToken } from "@/utils/helper";
import request from "@/utils/request";
const TEAM_CONSTRUCTION_URL = '/sccg/team_construction';
const TOKEN = {
    'Authorization': getToken()
}
import http from "@/http";
export function addTeam(params) {
    return request({
        method: 'post',
        url: TEAM_CONSTRUCTION_URL + '/addition',
        headers: { ...TOKEN },
        params
    });
    return http.post('/sccg/team_construction/addition', params);
}
export function deleteTeam(params) {
    return request({
        method: 'delete',
        url: TEAM_CONSTRUCTION_URL + '/deletion',
        headers: { ...TOKEN },
        params
    });
    return http.delete('/sccg/team_construction/deletion', params);
}
export function exportTeamInfo(params) {
    return request({
        method: 'post',
        url: TEAM_CONSTRUCTION_URL + '/export',
        headers: { ...TOKEN },
        params,
        responseType: 'blob'
    });
    return http.post('/sccg/team_construction/export', {}, params);
}
export function importTeamInfo(data) {
    return request({
        method: 'post',
        url: TEAM_CONSTRUCTION_URL + '/import',
        headers: { ...TOKEN, 'Content-Type': 'multipart/form-data' },
        data: data,
    });
    return http.post('/sccg/team_construction/import', data);
}
export function updateTeamInfo(params) {
    return request({
        method: 'put',
        url: TEAM_CONSTRUCTION_URL + '/modification',
        headers: { ...TOKEN },
        params
    });
    return http.put('/sccg/team_construction/modification', params);
}
export function searchTeamInfo(params) {
    return request({
        method: 'get',
        url: TEAM_CONSTRUCTION_URL + '/query',
        headers: { ...TOKEN },
        params
    });
    return http.get('/sccg/team_construction/query', params);
}