@@ -1349,9 +1349,7 @@ export function forecastBusinessPlan(input: BusinessFinancialPlanInput) {
|
||||
|
||||
const presentationCurrency = input.presentationCurrency || input.currency;
|
||||
if (!validCurrency(presentationCurrency))
|
||||
throw new Error(
|
||||
'Seleccione uma moeda de apresentação ISO suportada.',
|
||||
);
|
||||
throw new Error('Seleccione uma moeda de apresentação ISO suportada.');
|
||||
let fxRate: bigint | null = null;
|
||||
if (presentationCurrency !== input.currency) {
|
||||
if (!input.fxRate || !input.fxDate || !input.fxSource?.trim())
|
||||
@@ -1417,7 +1415,7 @@ export function forecastBusinessPlan(input: BusinessFinancialPlanInput) {
|
||||
product.unitVariableCost,
|
||||
`Custo variável do produto ${index + 1}`,
|
||||
);
|
||||
const productInventoryOpening = useProductInventorySchedule
|
||||
const _productInventoryOpening = useProductInventorySchedule
|
||||
? cents(
|
||||
product.productInventoryOpening ?? '',
|
||||
`Opening inventory for ${product.label}`,
|
||||
@@ -1458,7 +1456,7 @@ export function forecastBusinessPlan(input: BusinessFinancialPlanInput) {
|
||||
),
|
||||
};
|
||||
});
|
||||
const productStockInputs = input.products.map((product, index) => {
|
||||
const productStockInputs = input.products.map((product, _index) => {
|
||||
if (!useProductInventorySchedule)
|
||||
return { opening: null, orders: null };
|
||||
const opening = cents(
|
||||
@@ -1863,7 +1861,7 @@ export function forecastBusinessPlan(input: BusinessFinancialPlanInput) {
|
||||
const periodPayrollPayment = payrollPaymentsByPeriod[month - 1];
|
||||
const revenue = revenueByPeriod[month - 1];
|
||||
const costOfSales = costOfSalesByPeriod[month - 1];
|
||||
const opening = cash;
|
||||
const _opening = cash;
|
||||
const openingInventory = inventoryBalance;
|
||||
let inventoryShortfall: bigint | null = null;
|
||||
let closingInventory: bigint | null = null;
|
||||
@@ -3087,8 +3085,7 @@ export function exportBusinessPlanCsv(
|
||||
row.openingReceivablesBalance ?? '',
|
||||
row.openingPayablesPayments ?? '',
|
||||
row.openingPayablesBalance ?? '',
|
||||
row.otherCollections ??
|
||||
'incluídas nas cobranças manuais',
|
||||
row.otherCollections ?? 'incluídas nas cobranças manuais',
|
||||
row.profitBeforeTax ?? '',
|
||||
row.netCashFlow ?? '',
|
||||
row.closingCash ?? '',
|
||||
|
||||
Reference in New Issue
Block a user