Commit 140406c8 by Sxy

fix: 推送财税 参数 转换

parent 5d11bc40
......@@ -59,7 +59,7 @@ const postToFtBySign = async (url, data, headers = {}) => {
let tenantInfo = await getChannelCompany(data.companyId);
data.companyId = tenantInfo.id;
let sign = system.signValid(data, tenantInfo.signSecret);
var res = postRequest(`${ftConfig.url}${url}`, { ...data, sign }, headers = {});
var res = await postRequest(`${ftConfig.url}${url}`, { ...data, sign }, headers = {});
console.log("postToFtBySign:res--------------------------------------" + JSON.stringify(res));
return res;
}
......@@ -85,7 +85,7 @@ const getChannelCompany = async (id) => {
throw new Error("查不到租户信息");
}
}
console.log("getChannelCompany:companyData------------------------------------------"+ companyData);
console.log("getChannelCompany:companyData------------------------------------------" + companyData);
return companyData;
}
......@@ -100,9 +100,8 @@ const addCusAccApplyInfo = async (deliverData, pobj) => {
"企业会计准则": 2
}
const valueAddedTax = {
"小规模纳税人": 0,
"一般纳税人": 1,
"个体工商户": 2
"smallScaleTaxpayer": 0,
"generalTaxpayer": 1,
}
let reqData = {
accountStandard: accountStandard[pobj.accountingType],
......@@ -153,9 +152,9 @@ const feedbackToRys = async (data) => {
},
requestId: uuidv4()
});
console.log("resData--------------------------",JSON.stringify(resData));
console.log("resData--------------------------", JSON.stringify(resData));
if (resData.status !== 0) {
console.log("resData.msg--------------------------" +resData.msg + "-------------------------msg");
console.log("resData.msg--------------------------" + resData.msg + "-------------------------msg");
throw new Error(resData.msg)
}
}
......
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