Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@pingleware/bestbooks-reports

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pingleware/bestbooks-reports - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

test/test_trialbalance.js

4

balance-sheet.js
"use strict"
const { Model } = require('@pingleware/bestbooks-core');
const Report = require('./report');
const BaseReport = require('./report');
class BalanceSheet extends Report {
class BalanceSheet extends BaseReport {
constructor() {

@@ -8,0 +8,0 @@ super();

"use strict"
const { Model } = require('@pingleware/bestbooks-core');
const Report = require('./report');
const BaseReport = require('./report');
class IncomeStatement extends Report {
class IncomeStatement extends BaseReport {
constructor() {

@@ -8,0 +8,0 @@ super();

"use strict"
const { Model } = require('@pingleware/bestbooks-core');
const Report = require('./report');
const BaseReport = require('./report');
class NoteToFinancialStatements extends Report {
class NoteToFinancialStatements extends BaseReport {
constructor() {

@@ -8,0 +8,0 @@ super();

{
"name": "@pingleware/bestbooks-reports",
"version": "1.0.4",
"version": "1.0.5",
"description": "Reports module for BestBooks Accounting Application Framework",

@@ -25,4 +25,4 @@ "main": "index.js",

"dependencies": {
"@pingleware/bestbooks-core": "^1.1.8"
"@pingleware/bestbooks-core": "^1.1.9"
}
}
"use strict"
class Report {
class BaseReport {
constructor() {}
createReport(startDate,endDate,format) {}
retrieveReportData(startDate,endDate) {}
}
}
module.exports = BaseReport;

@@ -17,5 +17,5 @@ "use strict"

const { Model } = require('@pingleware/bestbooks-core');
const Report = require('./report');
const BaseReport = require('./report');
class StatementCashFlows extends Report {
class StatementCashFlows extends BaseReport {
constructor() {

@@ -22,0 +22,0 @@ super();

"use strict"
const { Model } = require('@pingleware/bestbooks-core');
const Report = require('./report');
const BaseReport = require('./report');
class StatementChangeInEquity extends Report {
class StatementChangeInEquity extends BaseReport {
constructor() {

@@ -8,0 +8,0 @@ super();

"use strict"
const { Model } = require('@pingleware/bestbooks-core');
const Report = require('./report');
const { Report } = require('@pingleware/bestbooks-core');
const BaseReport = require('./report');
class TrialBalance extends Report {
class TrialBalance extends BaseReport {
constructor() {

@@ -12,18 +12,17 @@ super();

createReport(startDate,endDate,format) {
var data = this.retrieveReportData(startDate, endDate);
if (format == "array") {
return data;
} else {
// process other formats
}
this.retrieveReportData(startDate, endDate).then(function(data){
if (format == "array") {
return data;
} else {
// process other formats
}
});
}
retrieveReportData(startDate,endDate) {
var sql = `SSELECT account_code AS code, account_name AS name,accounts.base_type AS type,debit,credit,
CASE WHEN (SELECT SUM(debit)=SUM(credit) FROM ledger)
THEN 'in_balance' ELSE 'out_of_balance' END AS trial_balance
FROM ledger JOIN accounts ON accounts.name=ledger.account_name;`;
const model = new Model();
return model.querySync(sql);
var report = new Report();
report.trialBalance(startDate,endDate,function(results){
console.log(results);
return results;
});
}

@@ -30,0 +29,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc