"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getReceivableDuplicates = exports.getReceivableDuplicatesFull = void 0;
const excel_helper_1 = require("../../helpers/excel.helper");
const receivables_db_1 = require("../../db/receivables.db");
const getReceivableDuplicatesFull = async (params) => {
    const data = await (0, exports.getReceivableDuplicates)(params);
    const header = getReceivableDuplicatesHeader();
    return (0, excel_helper_1.addHeaderToData)(header, data);
};
exports.getReceivableDuplicatesFull = getReceivableDuplicatesFull;
const getReceivableDuplicates = async (params) => {
    const { bbcDateId } = params;
    return (0, receivables_db_1.getDuplicates)(bbcDateId.toString());
};
exports.getReceivableDuplicates = getReceivableDuplicates;
const getReceivableDuplicatesHeader = () => {
    return {
        _id: 'Index',
    };
};
