@@ -112,18 +112,26 @@ const submitHandle = async () => {
112112 dialogVisible .value = false
113113 })
114114 } else if (props .source === SourceTypeEnum .KNOWLEDGE ) {
115- if (detail .value . type === 2 ) {
116- KnowledgeApi . putLarkKnowledge ( detail . value . id , obj , loading ).then (() => {
115+ if (isBatch .value ) {
116+ ToolApi . putMulMoveTool ( obj , loading ).then (() => {
117117 MsgSuccess (t (' common.saveSuccess' ))
118- emit (' refresh' , detail . value )
118+ emit (' refresh' )
119119 dialogVisible .value = false
120120 })
121121 } else {
122- KnowledgeApi .putKnowledge (detail .value .id , obj , loading ).then (() => {
123- MsgSuccess (t (' common.saveSuccess' ))
124- emit (' refresh' , detail .value )
125- dialogVisible .value = false
126- })
122+ if (detail .value .type === 2 ) {
123+ KnowledgeApi .putLarkKnowledge (detail .value .id , obj , loading ).then (() => {
124+ MsgSuccess (t (' common.saveSuccess' ))
125+ emit (' refresh' , detail .value )
126+ dialogVisible .value = false
127+ })
128+ } else {
129+ KnowledgeApi .putKnowledge (detail .value .id , obj , loading ).then (() => {
130+ MsgSuccess (t (' common.saveSuccess' ))
131+ emit (' refresh' , detail .value )
132+ dialogVisible .value = false
133+ })
134+ }
127135 }
128136 } else if (props .source === SourceTypeEnum .TOOL ) {
129137 if (isBatch .value ) {
@@ -140,11 +148,19 @@ const submitHandle = async () => {
140148 })
141149 }
142150 } else if (props .source === SourceTypeEnum .APPLICATION ) {
143- ApplicationApi .moveApplication (detail .value .id , obj .folder_id , loading ).then ((res ) => {
144- MsgSuccess (t (' common.saveSuccess' ))
145- emit (' refresh' , detail .value )
146- dialogVisible .value = false
147- })
151+ if (isBatch .value ) {
152+ ApplicationApi .putMulMoveApplication (obj , loading ).then (() => {
153+ MsgSuccess (t (' common.saveSuccess' ))
154+ emit (' refresh' )
155+ dialogVisible .value = false
156+ })
157+ } else {
158+ ApplicationApi .moveApplication (detail .value .id , obj .folder_id , loading ).then ((res ) => {
159+ MsgSuccess (t (' common.saveSuccess' ))
160+ emit (' refresh' , detail .value )
161+ dialogVisible .value = false
162+ })
163+ }
148164 }
149165 } else {
150166 MsgError (t (' components.folder.requiredMessage' ))
0 commit comments