Sp_Cashier_SumJournalTodayMoney (procedure)
- Type: PROCEDURE
- Deterministic: NO
- SQL data access: CONTAINS SQL
Parameters
| # | Mode | Name | Type |
|---|---|---|---|
| 1 | IN | tStartDate |
datetime |
| 2 | IN | tEndDate |
datetime |
| 3 | IN | sBrId |
varchar(100) |
| 4 | IN | sSuId |
varchar(100) |
| 5 | IN | sLoginId |
varchar(100) |
| 6 | IN | bFilter |
varchar(5000) |
| 7 | IN | pageNum |
int |
| 8 | IN | pageSize |
int |
| 9 | OUT | totalCount |
int |
| 10 | IN | countCloumn |
varchar(5000) |
| 11 | OUT | countMapJson |
longtext |
| 12 | IN | sFilterOrderBy |
varchar(5000) |
| 13 | IN | sGroupby_select_sql |
varchar(5000) |
| 14 | IN | sGroupby_group_sql |
varchar(5000) |
Body
Body is not pre-cached. To inspect: mysql --defaults-file=~/.my.cnf -e 'SHOW CREATE PROCEDURESpCashier_SumJournalTodayMoney'._
Narrative
Business context: 财务管理 → 出纳 — today-money variant of Sp_Cashier_SumJournal. Builds the same per-account opening / in / out / closing summary across sisbank plus the synthetic cash row, intended for the AI assistant's "today's cash position" briefing.
What it does: Mirrors Sp_Cashier_SumJournal line-for-line through the join phase: reads SysAccountPeriod.tCashierDate cutoff, seeds temp Cash with one row per active sisbank + a 'cash' row, joins CahWasteBook for in/out totals in the window, applies CahCashierInit.dMoney opening balances, layers in pre-period delta, relabels cash → 现金, and computes dBalanceMoney. Difference from Sp_Cashier_SumJournal: this variant has no final SELECT / pagination call — the caller is expected to consume the temporary Cash table directly within the same session.
Invocation: Called by Sp_Task_TodayMoneySmallai (xiaoyang.ai daily cashier-briefing task). Status: appears partially orphaned — no form-master, gdsmodule hook, or Java caller other than the install script and Sp_Task_TodayMoneySmallai. The missing terminal SELECT (compared to Sp_Cashier_SumJournal) suggests this is a templated helper consumed only by the task proc; flag if you find a UI form bound to it.