Commit 14d5466c by 王昆

dd

parent 94691345
var system = require("../../../system")
const CtlBase = require("../../ctlms.base");
class SaasnvoiceCtl extends CtlBase {
constructor() {
super();
this.saasmerchantSve = system.getObject("service.merchant.saasmerchantSve");
}
/**
* 发票信息管理
* @param {*} pobj2
* @param {*} pobj2
* @param {*} req
*/
async merchantTitleAddrPage (pobj1, pobj2, req){
try {
return this.saasmerchantSve.merchantTitleAddrPage(pobj1);
} catch (error) {
console.log(error);
return system.getResult(null, `系统错误`);
}
}
/**
* 发票信息修改
* @param {*} pobj2
* @param {*} pobj2
* @param {*} req
*/
async updateMerchantTitleAndAddr(pobj1, pobj2, req){
try {
if(!pobj1.id){
return system.getResult(null,`参数错误 ID 不能为空`);
}
return this.saasmerchantSve.updateMerchantTitleAndAddr(pobj1);
} catch (error) {
console.log(error);
return system.getResult(null, `系统错误`);
}
}
/**
* query invoice title&addr information
* @param {*} pobj1
* @param {*} pobj2
* @param {*} req
*/
async queryInvoiceTitleAndAddr(pobj1, pobj2, req){
try {
return this.saasmerchantSve.queryInvoiceTitleAndAddr(pobj1);
} catch (error) {
console.log(error);
return system.getResult(null, `系统错误`);
}
}
/**
* query invoice title&addr information
* @param {*} pobj1
* @param {*} pobj2
* @param {*} req
*/
async updateOrSaveTitleAndAddr(pobj1, pobj2, req){
try {
return this.saasmerchantSve.updateOrSaveTitleAndAddr(pobj1);
} catch (error) {
console.log(error);
return system.getResult(null, `系统错误`);
}
}
}
module.exports = SaasnvoiceCtl;
\ No newline at end of file
var system = require("../../../system")
const CtlBase = require("../../ctlms.base");
class InvoiceCtl extends CtlBase {
constructor() {
super();
this.orderSve = system.getObject("service.saas.orderSve");
}
async platformInfo(params, pobj2, req) {
try {
return await this.orderSve.platformInfo(params);
} catch (error) {
return system.getResult(null, `系统错误 错误信息 ${error}`);
}
}
async info(params, pobj2, req) {
try {
return await this.orderSve.info(params);
} catch (error) {
return system.getResult(null, `系统错误 错误信息 ${error}`);
}
}
async page(params, pobj2, req) {
try {
return await this.orderSve.page(params);
} catch (error) {
return system.getResult(null, `系统错误 错误信息 ${error}`);
}
}
async audit(params, pobj2, req) {
if (params.audit_status != "20" && params.audit_status != "30") {
return system.getResult(null, "审核状态错误");
}
try {
return await this.orderSve.audit(params);
} catch (error) {
return system.getResult(null, `系统错误 错误信息 ${error}`);
}
}
async deliver(params, pobj2, req) {
try {
return await this.orderSve.deliver(params);
} catch (error) {
return system.getResult(null, `系统错误 错误信息 ${error}`);
}
}
}
module.exports = InvoiceCtl;
\ No newline at end of file
const system=require("../../../system");
const ServiceBase=require("../../svems.base");
var settings=require("../../../../config/settings");
class SaasInvoiceService extends ServiceBase{
constructor(){
super();
}
/**
* 发票信息管理
* @param {*} params
*/
async merchantTitleAddrPage(params){
return await this.callms("merchant","merchantTitleAddrPage",params);
}
/**
* 发票信息修改
* @param {*} params
*/
async updateMerchantTitleAndAddr(params){
return await this.callms("merchant","updateMerchantTitleAndAddr",params);
}
/**
* query invoice title&addr information
* @param {*} params
*/
async queryInvoiceTitleAndAddr(params){
return await this.callms("merchant","queryInvoiceTitleAndAddr",params);
}
/**
* 更新添加title&addr
* @param {*} params
*/
async updateOrSaveTitleAndAddr(params){
return await this.callms("merchant","updateOrSaveTitleAndAddr",params);
}
}
module.exports=SaasInvoiceService;
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