Commit 93c48fe7 authored by 吴永生#A02208's avatar 吴永生#A02208

feat: 监控状态

parent d16c0cda
...@@ -41,6 +41,8 @@ interface IProps extends ReactFlowProps { ...@@ -41,6 +41,8 @@ interface IProps extends ReactFlowProps {
setTasks?: (val: ITask[]) => void; setTasks?: (val: ITask[]) => void;
/** 点击流程node 节点 返回唯一标识符 */ /** 点击流程node 节点 返回唯一标识符 */
onFlowNodeClick?: (val: string) => void; onFlowNodeClick?: (val: string) => void;
/** 监听事件的状态 */
ListenState?: boolean;
} }
const Flow = (props: IProps) => { const Flow = (props: IProps) => {
...@@ -52,6 +54,7 @@ const Flow = (props: IProps) => { ...@@ -52,6 +54,7 @@ const Flow = (props: IProps) => {
type: flowType = "default", type: flowType = "default",
setTasks, setTasks,
onFlowNodeClick, onFlowNodeClick,
ListenState = true,
...other ...other
} = props; } = props;
/** 自定义的节点类型 */ /** 自定义的节点类型 */
...@@ -126,7 +129,7 @@ const Flow = (props: IProps) => { ...@@ -126,7 +129,7 @@ const Flow = (props: IProps) => {
/** 删除批节点或者线 */ /** 删除批节点或者线 */
const deleteSelectBatchNode = useCallback( const deleteSelectBatchNode = useCallback(
(e: any) => { (e: any) => {
if (e.keyCode === 8) { if (e.keyCode === 8 && ListenState) {
/** 删除批节点逻辑 */ /** 删除批节点逻辑 */
if (inSideBatchNodeId) { if (inSideBatchNodeId) {
const newVal = const newVal =
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 吴永生#A02208 yongsheng.wu@wholion.com * @Author: 吴永生#A02208 yongsheng.wu@wholion.com
* @Date: 2022-06-21 20:03:56 * @Date: 2022-06-21 20:03:56
* @LastEditors: 吴永生#A02208 yongsheng.wu@wholion.com * @LastEditors: 吴永生#A02208 yongsheng.wu@wholion.com
* @LastEditTime: 2022-07-15 16:35:59 * @LastEditTime: 2022-07-15 18:44:41
* @FilePath: /bkunyun/src/views/Project/ProjectSubmitWork/index.tsx * @FilePath: /bkunyun/src/views/Project/ProjectSubmitWork/index.tsx
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
...@@ -224,6 +224,7 @@ const WorkFlowEdit = observer((props: IProps) => { ...@@ -224,6 +224,7 @@ const WorkFlowEdit = observer((props: IProps) => {
setTasks={setTemplateConfigInfo} setTasks={setTemplateConfigInfo}
type="edit" type="edit"
onFlowNodeClick={handleNodeClick} onFlowNodeClick={handleNodeClick}
ListenState={!saveFormDialog}
/> />
</div> </div>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment