📄 cashflowstatement.bsh
字号:
/* * Copyright (C) 2006 Open Source Strategies, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA * * @author Leon Torres (leon@opensourcestrategies.com */import java.util.*;import org.ofbiz.entity.*;import org.ofbiz.entity.util.*;import org.ofbiz.base.util.*;import org.ofbiz.service.*;organizationPartyId = context.get("organizationPartyId");glFiscalTypeId = context.get("glFiscalTypeId");fromDate = context.get("fromDate");thruDate = context.get("thruDate");if (fromDate == null || thruDate == null) return;input = UtilMisc.toMap("organizationPartyId", organizationPartyId, "glFiscalTypeId", glFiscalTypeId, "userLogin", userLogin);input.put("fromDate", fromDate);input.put("thruDate", thruDate);result = dispatcher.runSync("getCashFlowStatementForDates", input);if (ServiceUtil.isError(result)) return;context.put("beginningCashAmount", result.get("beginningCashAmount"));context.put("endingCashAmount", result.get("endingCashAmount"));context.put("operatingCashFlow", result.get("operatingCashFlow"));context.put("investingCashFlow", result.get("investingCashFlow"));context.put("financingCashFlow", result.get("financingCashFlow"));context.put("netCashFlow", result.get("netCashFlow"));context.put("netIncome", result.get("netIncome"));context.put("beginningCashAccountBalances", result.get("beginningCashAccountBalances"));context.put("endingCashAccountBalances", result.get("endingCashAccountBalances"));context.put("operatingCashFlowAccountBalances", result.get("operatingCashFlowAccountBalances"));context.put("investingCashFlowAccountBalances", result.get("investingCashFlowAccountBalances"));context.put("financingCashFlowAccountBalances", result.get("financingCashFlowAccountBalances"));context.put("operatingAccounts", EntityUtil.orderBy(result.get("operatingCashFlowAccountBalances").keySet(), UtilMisc.toList("glAccountId")));context.put("investingAccounts", EntityUtil.orderBy(result.get("investingCashFlowAccountBalances").keySet(), UtilMisc.toList("glAccountId")));context.put("financingAccounts", EntityUtil.orderBy(result.get("financingCashFlowAccountBalances").keySet(), UtilMisc.toList("glAccountId")));
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -