import Ajax from "../components/ajax.js"

const opts = {
    findMaquina: (maquinaId) => {
        return {
            url: `/maquinas/${maquinaId}`,
        }
    }
}


export const findMaquina = (maquinaId) => {
    return new Promise((resolve, reject) => {
        new Ajax(opts.findMaquina(maquinaId),
            null,
            null,
            (response) => {
                resolve(response)
            },
            (error) => {
                reject(error)
            }

        ).get()
    })

}