From 06d14b11ba6e52cbc873d09956719e1af82915be Mon Sep 17 00:00:00 2001 From: maochaoying <925670706@qq.com> Date: Sun, 10 Sep 2023 09:34:55 +0800 Subject: [PATCH] command --- src/mock/command.js | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/src/mock/command.js b/src/mock/command.js index b11a579..6b337d2 100644 --- a/src/mock/command.js +++ b/src/mock/command.js @@ -247,3 +247,53 @@ export const getAllFormulaJSON = { command: 'getAllFormula', messageId: 'getAllFormula', } + +// 更新配方字段 +export const updateFormulaJSON = (column, val, id) => { + return { + command: 'updateFormula', + messageId: 'updateFormula', + column, + val, + id, + } +} + +// 删除配方 +export const delFormulaJSON = id => { + return { + command: 'delFormula', + messageId: 'delFormula', + id, + } +} + +// 添加配方 是不是少了log +export const addFormulaJSON = ( + formula_id, + stoped_gs, + continued_gs, + stoped_satur, + continued_satur, + stoped_humi, + continued_humi, + injection_pump_speed, +) => { + return { + command: 'addFormula', + messageId: 'addFormula', + formula_id, + stoped_gs, + continued_gs, + stoped_satur, + continued_satur, + stoped_humi, + continued_humi, + injection_pump_speed, + } +} + +// 执行配方 +export const startFormulaJSON = id => { + return { command: 'startFormula', messageId: 'startFormula', id } +}