Sp_OEE_ConvertThisMachine (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 | sMachineId |
varchar(100) |
| 4 | IN | sBrId |
varchar(100) |
| 5 | IN | sSuId |
varchar(100) |
| 6 | OUT | sReturn |
varchar(1000) |
| 7 | OUT | sCode |
int |
Body
Body is not pre-cached. To inspect: mysql --defaults-file=~/.my.cnf -e 'SHOW CREATE PROCEDURESpOEE_ConvertThisMachine'._
Narrative
Business context: OEE管理 — toolbar "转本机台" (move-to-this-machine) button on an OEE production-task grid. Lets the foreman reassign selected mftproductionplanslave rows from their original machine to the OEE workstation that's currently in front of the user, so an idle machine can pick up another machine's queued work.
What it does: Parses $.params[*].value[*].sSlaveId from sProInParam and walks each entry: looks up the slave's sWorkOrderNo / sPartsName / sProcessName / sDecompose / sWorkOrderId / sMachineName from mftproductionplanslave, joins to elemachine by sMachineId to read the new machine's sMachineName / sCostCenterId / sCostCenterName, then updates the slave to point at the new machine (and propagates the cost-center change). Validates with Sp_Sis_GetConst('paramsErro', …) if the JSON payload is too short.
Invocation: Dispatched dynamically by GenericProcedureCallServiceImpl.doGenericProcedureCall() — standard Sp_<Module>_BtnEvent* action slot. Install scripts at script/标版/30100101/Sp_OEE_ConvertThisMachine.sql and a 30100101/schedule sibling. No gdsconfigformmaster/gdsmodule row in the current DB names the proc, so its toolbar wiring lives only in the form-config payloads that ship the OEE screens.