# `Sp_ProductDelivergoods` (procedure)


- **Type:** PROCEDURE
- **Deterministic:** NO
- **SQL data access:** CONTAINS SQL

## Parameters

| # | Mode | Name | Type |
|---|---|---|---|
| 1 | IN | `sProInParam` | `varchar(10000)` |
| 2 | IN | `sMakePerson` | `varchar(100)` |
| 3 | IN | `sBrId` | `varchar(100)` |
| 4 | IN | `sSuId` | `varchar(100)` |
| 5 | OUT | `sReturn` | `varchar(1000)` |
| 6 | OUT | `sCode` | `int` |

## Body

_Body is not pre-cached. To inspect: `mysql --defaults-file=~/.my.cnf -e 'SHOW CREATE PROCEDURE `Sp_ProductDelivergoods`'`._

## Narrative

**Business context:** 销售管理 / 销售订单 — toolbar handler that marks selected sales-order rows as "stocked / handed off to delivery". Used on the 销售订单 grid to flip the order from "open" to "ready-to-deliver" status in bulk before the actual delivery note is created.

**What it does:** Parses `$.params[*].value[*].sId` from `sProInParam`. For each id, `UPDATE Salsalesordermaster SET sStockup='2', sSend=sMakePerson, tSend=SYSDATE() WHERE sId=p_sSrcNo AND sBrandsId=sBrId AND sSubsidiaryId=sSuId`. No status validation, no slave-row touch — purely a master-level stockup flag bump.

**Invocation:** Standard `Sp_<Module>_BtnEvent*` slot — dispatched by `GenericProcedureCallServiceImpl.doGenericProcedureCall()` when the 销售订单 grid's stockup button names this procedure. xly-src ships `script/标版/30100101/Sp_ProductDelivergoods.sql`. No form-master, gdsmodule hook, or other-proc reference — name carried in the button definition only.
