{"size": 658, "ext": "js", "max_stars_repo_path": "src/glod/crudl/admin/connectors/transactions.js", "max_stars_repo_name": "gordon-elliott/glod", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/glod/crudl/admin/connectors/transactions.js", "max_issues_repo_name": "gordon-elliott/glod", "max_issues_repo_issues_event_min_datetime": "2021-03-10T16:48:34.000Z", "max_issues_repo_issues_event_max_datetime": "2021-03-10T16:48:34.000Z", "max_forks_repo_path": "src/glod/crudl/admin/connectors/transactions.js", "max_forks_repo_name": "gordon-elliott/glod", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 1, "max_forks_count": null, "avg_line_length": 38.7058823529, "max_line_length": 143, "alphanum_fraction": 0.7857142857}
import { DEFAULT_PAGE_LENGTH } from '../constants'
import { createResourceConnector, createOptionsConnector } from '../connectors'
import continuousPagination from '../connectors/middleware/continuousPagination'

// TODO include counterparty
const transactions = createResourceConnector('transactions', `
    id, referenceNo, publicCode, year, month, day, paymentMethod, description, amount, subject{id, name}, incomeExpenditure, FY, fund{id, name}
`)
.use(continuousPagination(DEFAULT_PAGE_LENGTH))

const transactionOptions = createOptionsConnector('transactionOptions', 'id', 'reference_no')

module.exports = {
    transactions,
    transactionOptions
}
