Commit f6e0ba54 by 孙亚楠

dd

parent c9933661
...@@ -8,6 +8,10 @@ module.exports = function(sequelize, DataTypes) { ...@@ -8,6 +8,10 @@ module.exports = function(sequelize, DataTypes) {
primaryKey: true, primaryKey: true,
autoIncrement: true autoIncrement: true
}, },
invoiceId: {
type: DataTypes.INTEGER(11),
field: 'invoice_id',
},
company_name: { company_name: {
type: DataTypes.STRING(255), type: DataTypes.STRING(255),
allowNull: true allowNull: true
......
...@@ -2,6 +2,9 @@ const system = require("../../../system"); ...@@ -2,6 +2,9 @@ const system = require("../../../system");
const ServiceBase = require("../../sve.base"); const ServiceBase = require("../../sve.base");
const settings = require("../../../../config/settings"); const settings = require("../../../../config/settings");
/**
* 发票列表
*/
class InvoiceService extends ServiceBase { class InvoiceService extends ServiceBase {
constructor() { constructor() {
super("all", ServiceBase.getDaoName(InvoiceService)); super("all", ServiceBase.getDaoName(InvoiceService));
...@@ -18,6 +21,10 @@ class InvoiceService extends ServiceBase { ...@@ -18,6 +21,10 @@ class InvoiceService extends ServiceBase {
}; };
} }
if(params.id_no){
where.id_no = this.trim(params.id_no);
}
if (params.invoiceType) { if (params.invoiceType) {
where.invoiceType = Number(params.invoiceType); where.invoiceType = Number(params.invoiceType);
} }
...@@ -26,6 +33,9 @@ class InvoiceService extends ServiceBase { ...@@ -26,6 +33,9 @@ class InvoiceService extends ServiceBase {
where.sign_body = params.sign_body; where.sign_body = params.sign_body;
} }
if(params.invoiceId) {
where.id = this.trim(params.invoiceId);
}
this.addWhereTime(where, 'invoice_time', params.signBegin, params.signEnd); this.addWhereTime(where, 'invoice_time', params.signBegin, params.signEnd);
var orderby = [ var orderby = [
......
const system = require("../../../system"); const system = require("../../../system");
const ServiceBase = require("../../sve.base"); const ServiceBase = require("../../sve.base");
const settings = require("../../../../config/settings"); const settings = require("../../../../config/settings");
/**
* 工作量确认单
*/
class LoadService extends ServiceBase { class LoadService extends ServiceBase {
constructor() { constructor() {
super("all", ServiceBase.getDaoName(LoadService)); super("all", ServiceBase.getDaoName(LoadService));
......
...@@ -31,6 +31,9 @@ class MerchantService extends ServiceBase { ...@@ -31,6 +31,9 @@ class MerchantService extends ServiceBase {
if (params.sign_body) { if (params.sign_body) {
where.sign_body = params.sign_body; where.sign_body = params.sign_body;
} }
if(params.id_no){
where.id_no = params.id_no;
}
this.addWhereTime(where, 'begin_time', params.signBegin, params.signEnd, true); this.addWhereTime(where, 'begin_time', params.signBegin, params.signEnd, true);
var orderby = [ var orderby = [
["id", 'desc'] ["id", 'desc']
......
...@@ -12,6 +12,13 @@ class TaxinfoService extends ServiceBase { ...@@ -12,6 +12,13 @@ class TaxinfoService extends ServiceBase {
var pageSize = Number(params.pageSize || 10); var pageSize = Number(params.pageSize || 10);
var where = {}; var where = {};
if (params.company_name) {
where.company_name = {
[this.db.Op.like]: "%" + params.company_name + "%"
};
}
if(params.sign_body){ if(params.sign_body){
where.sign_body = params.sign_body; where.sign_body = params.sign_body;
} }
......
const system = require("../../../system"); const system = require("../../../system");
const ServiceBase = require("../../sve.base"); const ServiceBase = require("../../sve.base");
const settings = require("../../../../config/settings"); const settings = require("../../../../config/settings");
/**
* 发薪列表
*/
class TransactioninService extends ServiceBase { class TransactioninService extends ServiceBase {
constructor() { constructor() {
super("all", ServiceBase.getDaoName(TransactioninService)); super("all", ServiceBase.getDaoName(TransactioninService));
} }
/**
* @param {int} invoiceId 发票ID
* @param {*} params
*
*/
async signPage(params) { async signPage(params) {
var currentPage = Number(params.currentPage || 0); var currentPage = Number(params.currentPage || 0);
var pageSize = Number(params.pageSize || 10); var pageSize = Number(params.pageSize || 10);
...@@ -23,6 +30,9 @@ class TransactioninService extends ServiceBase { ...@@ -23,6 +30,9 @@ class TransactioninService extends ServiceBase {
if(params.id_no){ if(params.id_no){
where.id_no = params.id_no where.id_no = params.id_no
} }
if(params.invoiceId){
where.invoiceId = this.trim(params.invoiceId);
}
this.addWhereTime(where, 'transaction_time', params.signBegin, params.signEnd, true); this.addWhereTime(where, 'transaction_time', params.signBegin, params.signEnd, true);
var orderby = [ var orderby = [
["id", 'desc'] ["id", 'desc']
......
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