Sp_NotPayAbles.md 2.14 KB

Sp_NotPayAbles (procedure)

  • Type: PROCEDURE
  • Deterministic: NO
  • SQL data access: CONTAINS SQL

Parameters

# Mode Name Type
1 IN sSupplyGuid varchar(4000)
2 OUT bOut int
3 IN sLoginId varchar(4000)
4 IN sBrId varchar(100)
5 IN sSuId varchar(100)
6 IN bFilter varchar(5000)
7 IN sUnTaskFormId varchar(100)
8 IN pageNum int
9 IN pageSize int
10 OUT totalCount int
11 IN countCloumn varchar(5000)
12 OUT countMapJson longtext
13 IN sFilterOrderBy varchar(5000)
14 IN sGroupBy_select_sql varchar(5000)
15 IN sGroupBy_group_sql varchar(5000)

Body

Body is not pre-cached. To inspect: mysql --defaults-file=~/.my.cnf -e 'SHOW CREATE PROCEDURESpNotPayAbles'._

Narrative

Business context: KPI流程操作菜单 → 财务收付款 → 1/1 对账( 采购&外协)->付款 — paged supplier-payables warning list. Aggregates everything the company still owes a supplier per saldelivergoods-side bill (procurement, sub-contract, expense, advance, financial-adjust, receipt) into one window so AP can prioritise payments.

What it does: Reads SysAccountPeriod.tAPDate for the cutoff, then Sp_Sis_GetConst to load language-specific labels for PayInit/Advance/FinancialAdjust/Receipt. Builds p_tmp_PayablesWarning (supplier, materials, money, currency, invoice, purchase-man, due-date, reserves), assembles a UNION across each AP source view filtered by sBrId/sSuId and tCreateDate >= tAPDate, then hands the resulting SQL to Sp_Outstanding_Query for paging, bFilter splicing, countCloumn totals, and sGroupby_* rollups.

Invocation: Bound as the data-source of form gfm.sId=192116810113315318265589290 (1/1 对账( 采购&外协)->付款) via gdsconfigformmaster.sSqlStr — loaded when the user opens the supplier-payables console. Install script at script/标版/30100101/Sp_NotPayables.sql (note the case-mismatch — DB stores Sp_NotPayAbles while the file uses Sp_NotPayables).