# `Sp_PlanListQualificat_BtnEventUnCheck` (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_PlanListQualificat_BtnEventUnCheck`'`._

## Narrative

**Business context:** 销售管理 → 销售订单 — main-plan grid uncheck (反审核) handler for the 资质审核 column `bCheckQualificat` on `salsalesordermaster`. Lets the operator roll back a qualification-audit decision on a sales-order row without invalidating the order itself.

**What it does:** Parses `$.params[*].value[*].sId` from `sProInParam`. For each `sId` it looks up `viw_salsalesdevplan.sSlaveId` (to verify the row is reachable from the plan view) and then `UPDATE salsalesordermaster SET bCheckQualificat=0, tCheckQualificatDate=NULL, sCheckQualificatPerson=NULL`. Supports an optional `changeValue.valueKey` payload, splitting it by comma to compose extra `SET col = JSON_EXTRACT(...)` clauses (the dynamic-set scaffold is built but `p_where` is not actually applied in the final update — the standard plan-grid uncheck behaviour ignores those extras).

**Invocation:** Dispatched dynamically by `GenericProcedureCallServiceImpl.doGenericProcedureCall()` from the 主计划 grid's 反资质审核 toolbar button. Not bound on `gdsmodule.sProcName` or any form-master sSqlStr — name resolved from the grid action config. No xly-src install script located.
