Commit b4dc8e77 by 王昆

dd

parent ad3841e0
const system = require("../../../system");
const ServiceBase = require("../../svems.base")
const settings = require("../../../../config/settings")
const axios = require("axios");
class SaasinvoiceService extends ServiceBase {
constructor() {
super();
......@@ -137,7 +137,14 @@ class SaasinvoiceService extends ServiceBase {
"value_added_tax": invoice.value_added_tax || 0,
"channel_id": this.DEFAULT_CHANNEL_ID
}
return await this.callms("invoice", "invoiceApply", params);
let url = settings.deliverSysApi().pushInvoiceToDeliver;
let res = await axios({
method: 'post',
url: url,
data: params
});
console.log(res.data);
}
/**
......
......@@ -200,13 +200,13 @@ class System {
order: dev + ":3103" + path,
// 发票服务
invoice: dev + ":3105" + path,
invoice: local + ":3105" + path,
// 用户服务
uc: dev + ":3106" + path,
// 交易
trade: local + ":3107" + path,
trade: dev + ":3107" + path,
}
} else {
return {
......
......@@ -90,8 +90,8 @@ var settings = {
deliverSysApi: function () {
let domain = "";
if (this.env == "dev") {
domain = "http://39.107.234.14:3002";
// domain = "http://127.0.0.1:3002";
// domain = "http://39.107.234.14:3002";
domain = "http://127.0.0.1:3002";
} else {
domain = "https://xggadmin.gongsibao.com";
}
......@@ -99,7 +99,9 @@ var settings = {
// 推送订单s
orderPushApi: domain + "/web/order/orderCtl/addSourceOrder",
//发票是试算
calcInvoice: domain + "/web/invoice/invoiceCtl/calcInvoice"
calcInvoice: domain + "/web/invoice/invoiceCtl/calcInvoice",
//推送发票申请
pushInvoiceToDeliver: domain + "/web/invoice/invoiceCtl/pushInvoiceToDeliver",
}
},
paasUrl: function () {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment