# `Sp_BtnRepairUpdateCheckMemo` (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_BtnRepairUpdateCheckMemo`'`._ ## Narrative **Business context:** 质量事故 — bulk "批量修改" dialog handler that lets a QC reviewer record an inspection memo `sCheckMemo` on selected `mftqualityaccidentMaster` rows, stamping reviewer + review date alongside. **What it does:** Parses `$.params[*].value[*].sId` and `$.changeValue.textareaValue` from `sProInParam`. For each master id, opens a cursor against `mftqualityaccidentMaster` scoped by `sBrandsId=sBrId AND sSubsidiaryId=sSuId`, and per row sets `sCheckMemo = p_textareaValue, sCkPerson = sMakePerson, tCKDate = NOW()`. Cursor loop is structurally degenerate (always one row, since the key is already `sId = p_sId`), but the tenancy guard inside the cursor query is the proc's tenant-safety filter. **Invocation:** Dispatched dynamically by `GenericProcedureCallServiceImpl.doGenericProcedureCall()` (POST `/procedureCall/doGenericProcedureCall`) — front-end "复核备注" dialog on the 质量事故 grid registers this procedure name. Note the unusual naming (`Sp_BtnRepair` not `Sp_BtnRepair_`): older naming convention than the `Sp_BtnRepair_*` family. Sibling of `Sp_BtnRepairUpdateJzMemo` (集中-meeting memo counterpart on the same table).