import request from '../util/request.js';

export function controlGate(command) {
    const warehouseId  = localStorage.getItem('#warehouseId');
    return request({
        url: '/api/GateResource/controlGate?command=' + command + '&warehouseId=' + warehouseId,
        method: 'get',
    });
}

// 大件运输开关
export function controlGateByBigInv(command) {
    const warehouseId  = localStorage.getItem('#warehouseId');
    return request({
        url: '/api/GateResource/controlGateByBigInv?command=' + command  + '&warehouseId=' + warehouseId,
        method: 'get',
    });
}

// 获取闸机状态
export function getGateStatus() {
    const warehouseId = localStorage.getItem('#warehouseId');
    return request({
        url: '/api/GateResource/getStatus?warehouseId=' + warehouseId,
        method: 'get',
    });
}