Sp_Supply_reLevel (procedure)
@author:zhucx
@date: 2022/12/02
@describe: 供应商信息-重新评级
- 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 PROCEDURESpSupply_reLevel'._
Narrative
Business context: 基础资料 → 供应商与外协加工商 → 供应商信息 — 重新评级 (re-rate) toolbar action. Reverses Sp_Supply_setLevel and clears the rating fields so the supplier needs to re-enter the evaluation flow.
What it does: Parses $.params[*].value[*].sSlaveId from sProInParam plus $.changeValue[0].valueKey (comma-separated columns to reset) and changeValue.textareaValue (reason). Splices each <col>=<val> into p_setSql, always appends sLevelMemo=<reason>, then executes UPDATE elesupply SET <p_setSql> WHERE sId=p_sId AND sBrandsId/sSubsidiaryId. Errors with localised paramsErro when sProInParam is empty.
Invocation: Dispatched dynamically by GenericProcedureCallServiceImpl.doGenericProcedureCall() — 供应商信息 grid's 重新评级 button. Install script: script/标版/30100101/Sp_Supply_reLevel.sql. Author tag: @author:zhucx @date: 2022/12/02. Caveat: like its sibling Sp_Supply_setLevel, the body retains a SELECT @sSqlStmt debug echo before PREPARE.