Commit 6af0cb1d by 王昆

Merge branch 'xgg-saas-merchant' of gitlab.gongsibao.com:jiangyong/zhichan into xgg-saas-merchant

parents 665e91e4 f831d535
# Default ignored files
/workspace.xml
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/xgg-saas-merchant.iml" filepath="$PROJECT_DIR$/.idea/xgg-saas-merchant.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/.." vcs="Git" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
\ No newline at end of file
...@@ -5,7 +5,7 @@ class InvoiceCtl extends CtlBase { ...@@ -5,7 +5,7 @@ class InvoiceCtl extends CtlBase {
super(); super();
this.orderSve = system.getObject("service.saas.orderSve"); this.orderSve = system.getObject("service.saas.orderSve");
this.tradeSve = system.getObject("service.trade.tradeSve"); this.tradeSve = system.getObject("service.trade.tradeSve");
this.merchantSve = system.getObject("service.trade.tradeSve"); this.invoiceSve = system.getObject("service.saas.invoiceSve");
} }
// 注册订单列表 // 注册订单列表
...@@ -55,6 +55,14 @@ class InvoiceCtl extends CtlBase { ...@@ -55,6 +55,14 @@ class InvoiceCtl extends CtlBase {
} }
} }
//发票列表
async saasinvoicePage(params, pobj2, req) {
try {
let rs = await this.invoiceSve.saasinvoicePage(params);
return rs;
} catch (error) {
return system.getResult(null, `系统错误 错误信息 ${error}`);
}
}
} }
module.exports = InvoiceCtl; module.exports = InvoiceCtl;
\ No newline at end of file
...@@ -30,7 +30,7 @@ class MerchantCtl extends CtlBase { ...@@ -30,7 +30,7 @@ class MerchantCtl extends CtlBase {
return system.getResult(null, `系统错误 错误信息 ${error}`); return system.getResult(null, `系统错误 错误信息 ${error}`);
} }
} }
async signPage(params, pobj2, req) { async signPage(params, pobj2, req) {
try { try {
params.is_sign = 1; params.is_sign = 1;
...@@ -48,7 +48,7 @@ class MerchantCtl extends CtlBase { ...@@ -48,7 +48,7 @@ class MerchantCtl extends CtlBase {
return system.getResult(null, `系统错误 错误信息 ${error}`); return system.getResult(null, `系统错误 错误信息 ${error}`);
} }
} }
async sign(params, pobj2, req) { async sign(params, pobj2, req) {
try { try {
params.bm_reg_price = system.y2f(params.bm_reg_price || 0); params.bm_reg_price = system.y2f(params.bm_reg_price || 0);
...@@ -67,5 +67,7 @@ class MerchantCtl extends CtlBase { ...@@ -67,5 +67,7 @@ class MerchantCtl extends CtlBase {
return system.getResult(null, `系统错误 错误信息 ${error}`); return system.getResult(null, `系统错误 错误信息 ${error}`);
} }
} }
} }
module.exports = MerchantCtl; module.exports = MerchantCtl;
\ No newline at end of file
const system = require("../../../system");
const ServiceBase = require("../../svems.base")
const settings = require("../../../../config/settings")
class InvoiceService extends ServiceBase {
constructor() {
super();
}
async saasinvoicePage(params){
var rs = await this.callms("invoice", "saasinvoicePage", params);
if (rs && rs.data && rs.data.rows) {
this.transOrderField(rs.data.rows);
}
return rs;
}
transOrderField(rows) {
if (!rows || rows.length == 0) {
return;
}
for (let row of rows) {
row.price = system.f2y(row.price);
}
}
}
module.exports = InvoiceService;
...@@ -192,4 +192,4 @@ class MerchantService extends ServiceBase { ...@@ -192,4 +192,4 @@ class MerchantService extends ServiceBase {
} }
} }
module.exports = MerchantService; module.exports = MerchantService;
\ No newline at end of file
...@@ -184,7 +184,7 @@ class System { ...@@ -184,7 +184,7 @@ class System {
order: local + ":3103" + path, order: local + ":3103" + path,
// 发票服务 // 发票服务
invoice: dev + ":3105" + path, invoice: local + ":3105" + path,
// 用户服务 // 用户服务
uc: dev + ":3106" + path, uc: dev + ":3106" + path,
...@@ -235,4 +235,4 @@ System.appidFail = 1200; ...@@ -235,4 +235,4 @@ System.appidFail = 1200;
System.signFail = 1300; System.signFail = 1300;
//获取访问token失败 //获取访问token失败
System.getAppInfoFail = 1130; System.getAppInfoFail = 1130;
module.exports = System; module.exports = System;
\ No newline at end of file
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