#
vincentlu
2025-12-15 537021950096e7042cb46852b6ca7baa129837a6
zy-acs-flow/src/map/http.js
@@ -431,6 +431,38 @@
    return null;
}
export const updateAreaData = async (payload = {}) => {
    try {
        const res = await request.post('/map/area/update', payload);
        const { code, msg } = res.data;
        if (code === 200) {
            notify.success?.(msg);
            return true;
        }
        notify?.error?.(msg);
    } catch (error) {
        notify.error(error.message);
        console.error(error.message);
    }
    return false;
};
export const removeArea = async (areaId) => {
    try {
        const res = await request.post('/map/area/remove', { areaId });
        const { code, msg } = res.data;
        if (code === 200) {
            notify.success(msg);
            return true;
        }
        notify.error(msg);
    } catch (error) {
        notify.error(error.message);
        console.error(error.message);
    }
    return false;
};
export const fetchAgvListAll = async () => {
    try {
        const res = await request.post('/agv/list', {});