# `Sp_productionPlanInfo_BtnEventUrgent` (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_productionPlanInfo_BtnEventUrgent`'`._

## Narrative

**Business context:** 生产管理 → 生产计划管理 → 生产排程 — toolbar handler "机台计划：加急" (mark rush) on `mftproductionplanslave`. Flags selected schedule rows for priority handling so APS or the gantt view bumps them ahead of the regular queue.

**What it does:** Per dash-split `sId`: reads `bFrozen`, `sState`. If frozen, sets `sCode=1` and writes `sProductionMainPlanChildOrderDj`. Otherwise reads `sWorkOrderNo`/`sPartsName`/`sProcessName`/`sDecompose`/`sWorkOrderId`, then `UPDATE mftproductionplanslave SET bUrgent=1 WHERE sId=p_sIdOne AND tenant matches`. Logs a 加急 row to `syslog` with `sFormId='101251240115016110217762400'`.

**Invocation:** Dispatched dynamically by `GenericProcedureCallServiceImpl.doGenericProcedureCall()` — 生产排程 form's "加急" button. Inverse: `Sp_productionPlanInfo_BtnEventUnUrgent`. xly-src ships `script/标版/30100101/schedule/Sp_productionPlanInfo_BtnEventUrgent.sql`.
