#
luxiaotao1123
2024-11-09 20aa51767d2bcc0baf30e1eee5ccce05ace9a6fe
zy-acs-flow/src/map/http.js
@@ -24,7 +24,10 @@
        const { code, msg, data: { rcsStatus, common, point } } = res.data;
        if (code === 200) {
            setRcsStatus(rcsStatus);
            const mapItemList = [...eval(common), ...eval(point)];
            const commonList = common ? eval(common) : [];
            const pointList = point ? eval(point) : [];
            const mapItemList = [...commonList, ...pointList];
            mapItemList.forEach(item => {
                if (item.type !== DEVICE_TYPE.AGV) {
                    const sprite = Tool.generateSprite(item.type);
@@ -46,7 +49,7 @@
                        // support
                        switch (item.type) {
                            case DEVICE_TYPE.POINT:
                                sprite.scale.set(0.65, 0.65);
                                sprite.scale.set(0.85, 0.85);
                                break
                            default:
                                break
@@ -75,7 +78,7 @@
    mapContainer.children.forEach(child => {
        if (child.data?.uuid) {
            const { type, uuid, no, ...property } = child.data;
            if (type !== DEVICE_TYPE.AGV && type !== DEVICE_TYPE.POINT) {
            if (type !== DEVICE_TYPE.AGV && type !== DEVICE_TYPE.POINT && type !== DEVICE_TYPE.ROUTE) {
                sprites.push({
                    // graph
                    positionX: child.position.x,
@@ -241,3 +244,19 @@
        console.error(error.message);
    })
}
export const getFakeSign = async (param, callback) => {
    await request.get('/fake/sign').then((res) => {
        const { code, msg, data } = res.data;
        if (code === 200) {
            if (callback) {
                callback(data)
            }
        } else {
            notify.error(msg);
        }
    }).catch((error) => {
        notify.error(error.message);
        console.error(error.message);
    })
}