库opn打开服务器而不是客户端

时间:2018-10-23 18:04:43

标签: node.js angular

我正在尝试在执行asp页面并希望在客户端上运行的angular和nodeJS代码上执行。 使用此代码,该库在服务器上运行,打开IExplore。

他们知道如何使该库在客户端上运行。

我在生成生产版本时意识到了这一点。

请问我的英语:P

我的代码NODEJS:

 if (res.statusCode === 200) {
        opn(url, {
            app: 'iexplore',
            wait: false
        }).then(function(cp) {
            // console.log('child process:', cp);
            console.log('Funcionando!' + seleccion);
            return;
        }).catch(function(err) {
            console.error(err);
            return;
        });
        return res.status(200).json({
            ok: true,
            mensaje: 'IExplorer levantado',
        });
    } else {
        return res.status(res.statusCode).json({
            ok: false,
            mensaje: 'Error cargando evento: ',
            errors: res.statusCode
        });
    }    

语言代码:

let url = URL_SERVICIOS + '/opnLink/admcambSolicitudes/' + urlvariable;    
return this.http.get (url);

0 个答案:

没有答案