/*
 * @Author: zc
 * @description 辅助功能-区域管理
 */
import request from '@/utils/request';
/**
 * @description 获取省市区树形
 */
export const treeArea = () => {
    return request({
        url: `/api/v1/Sys/area/tree`,
        method: 'get',
    });
};

/**
 * @description 新增省市区树形
 * @param {object} data
 */
export const treeAreaAdd = (data:object) => {
    return request({
        url: `/api/v1/Sys/area`,
        method: 'post',
        data
    });
};
/**
 * @description 编辑省市区树形
 * @param {object} data
 */
export const treeAreaEdit = (data:object) => {
    return request({
        url: `/api/v1/Sys/area`,
        method: 'put',
        data
    });
};
/**
 * @description 删除省市区树形
 * @param {string} id
 */
export const treeAreaDelete = (id:object) => {
    return request({
        url: `/api/v1/Sys/area/${id}`,
        method: 'delete'
    });
};
/**
 * @description 省市区详情
 * @param {string} id
 */
export const treeAreaDetail = (id:object) => {
    return request({
        url: `/api/v1/Sys/area/${id}`,
        method: 'get'
    });
};