Commit ac52af9e by 王昆

gsb

parent 3754c1f9
...@@ -61,6 +61,7 @@ class APIBase extends DocBase { ...@@ -61,6 +61,7 @@ class APIBase extends DocBase {
var lst = [ var lst = [
"test.testApi", "test.testApi",
"test.test", "test.test",
"op.invoiceApi",
]; ];
var x = lst.indexOf(fullname); var x = lst.indexOf(fullname);
return x >= 0; return x >= 0;
......
var APIBase = require("../../api.base");
var system = require("../../../system");
class TestAPI extends APIBase {
constructor() {
super();
// this.orderSve = system.getObject("service.order.orderSve");
// this.platformUtils = system.getObject("util.businessManager.opPlatformUtils");
this.invoiceSve = system.getObject("service.invoice.invoiceSve");
}
async test(pobj, query, req) {
// var tmp = await this.orderSve.createLicense(pobj.action_body);
//获取验证码
// await this.platformUtils.fetchVCode(pobj.action_body.mobile);
//创建用户
// var result = await this.platformUtils.createUserInfo("13075556691", "13075556693", "9366");
//创建用户
// var result = await this.platformUtils.login("13075556691", "9366");
var result = {};
try {
await this.invoiceSve.sendInvoiceToDz({id: "11665025426002758"});
} catch (e) {
console.log(e);
}
return result;
}
exam() {
return "";
}
classDesc() {
return {
groupName: "",
groupDesc: "",
name: "",
desc: "",
exam: "",
};
}
methodDescs() {
return [
{
methodDesc: "",
methodName: "",
paramdescs: [
{
paramDesc: "",
paramName: "",
paramType: "",
defaultValue: "",
}
],
rtnTypeDesc: "",
rtnType: ""
}
];
}
}
module.exports = TestAPI;
\ No newline at end of file
...@@ -548,9 +548,9 @@ class InvoiceService extends ServiceBase { ...@@ -548,9 +548,9 @@ class InvoiceService extends ServiceBase {
// 1090办理完成 // 1090办理完成
if (pobj.nextStatus == "1090") { if (pobj.nextStatus == "1090") {
console.log(pobj);
this.sendInvoiceToDz(pobj); this.sendInvoiceToDz(pobj);
} }
return rs; return rs;
} else { } else {
return system.getResult(null, rs.msg); return system.getResult(null, rs.msg);
...@@ -576,8 +576,9 @@ class InvoiceService extends ServiceBase { ...@@ -576,8 +576,9 @@ class InvoiceService extends ServiceBase {
] ]
}; };
let apiurl = "https://nga-api.gongsibao.com/nga-sass//billInfo/uploadFileForAliyun"; let apiurl = "https://nga-api.gongsibao.com/nga-sass//billInfo/uploadFileForAliyun";
let rs = await this.restClient.execPost(params, apiurl); console.log(apiurl, params);
console.log(rs, "11111111111111111111111111111111111111111111111"); // let rs = await this.restClient.execPost(params, apiurl);
// console.log(rs, "11111111111111111111111111111111111111111111111");
return rs; return rs;
} }
......
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