1
 Follower
59
 Likes

Select part of an action flow and "Refactor to action"

Implemented
on 04 Jan 2018
OutSystems 10

Allow creating an action from the selected section of a flow. The action would get the required inputs and outputs, and the flow from where it was extracted should automatically fill the action parameters with the local variables it was using

Created on 13 May 2010
Comments (25)
13 May 2010
That would be a nice refactoring tool,



like this option!
20 Jul 2010

Nice - perhaps it could be called the 'refactoring rubberband?'
Thumbs up! : )
Merged this idea with 'Select part of the flow chart and display the "Create Action" (Refactory)' (created on 2011-12-01 17:16:36 by Carlos Abreu)
1 Dec 2011
Select part of the flow chart and display the "Create Action" (Refactory)

Merged from 'Select part of the flow chart and display the "Create Action" (Refactory)' (idea created on 2011-12-01 17:16:36 by Carlos Abreu), on 2017-02-25 10:39:02 by Goncalo Borrega
8 Dec 2011
I haven't got a clue what you're talking about. Some explanation please?

Merged from 'Select part of the flow chart and display the "Create Action" (Refactory)' (idea created on 2011-12-01 17:16:36 by Carlos Abreu), on 2017-02-25 10:39:02 by Goncalo Borrega
13 Dec 2011
What he means is, you select a certain part of a (screen)action, for example a complete for-loop,

then create a custom action for it.


just making life easier, instead of creating an action.
copy/cut the for-loop
paste it in the newly created action.
solve the errors.
link the action in the previous action, so it actually gets called.
etc.


Merged from 'Select part of the flow chart and display the "Create Action" (Refactory)' (idea created on 2011-12-01 17:16:36 by Carlos Abreu), on 2017-02-25 10:39:02 by Goncalo Borrega
1 Oct 2015
- Select a number of (valid) actions from flow
- right click->group or keyboard shortcut
- creates a new action + input/output parameters required to use it


Merged from 'Create Action based on selection' (idea created on 2015-10-01 09:41:08 by Markus Henschel), on 2017-02-25 10:39:29 by Goncalo Borrega
2 Oct 2015
This is an AMAZING idea, thank you! It should also immediately replace the selection with a call to the new Action! Instant refactor!

J.Ja


Merged from 'Create Action based on selection' (idea created on 2015-10-01 09:41:08 by Markus Henschel), on 2017-02-25 10:39:29 by Goncalo Borrega
5 Oct 2015
Yeah, +1 from me. Comes in handy when refactoring.

Merged from 'Create Action based on selection' (idea created on 2015-10-01 09:41:08 by Markus Henschel), on 2017-02-25 10:39:29 by Goncalo Borrega
5 Oct 2015
Awesome! it looks pretty innovative. I've never seen something similar in other programming languages.

Merged from 'Create Action based on selection' (idea created on 2015-10-01 09:41:08 by Markus Henschel), on 2017-02-25 10:39:29 by Goncalo Borrega
23 Feb 2017

Not sure if this is new, but have been in my head in a long time now.

In some good IDE's there is an option that allows developers to better write code by not allowing it to be very big, at least at screen level actions. 

This feature should allow you to:

- select a sub-set from our logic flow, 

- create a new Server action with the selected flow inside;

- All the unreachable variables inside that action, should becamean Input variable;

- All the needed variables (in the original flow) should becomethe Output variables from the new screen action and the variables replaced bythose Output vars from the action; 

 

That will provide us with a much faster refactoring with noErrors, allowing every developer to properly follow the best practices andsimplify the logic inside the actions and screen actions.


This is the idea:

https://refactoring.com/catalog/extractMethod.html



Merged from '"Extract flow to Action" operation that allows faster encapsulation of logic' (idea created on 2017-02-23 10:59:09 by José Queirós), on 2017-02-25 10:35:40 by Goncalo Borrega
3 Apr 2017

It would be nice when I have a bigger action, that I can select some if-clauses, queries etc, press right mouse click 'Create subaction' and that it create a subaction with that logic. 

It would be even better if it automatically generates the right input and output parameters. 



Merged from 'Refactoring: Create a subaction from selected logic-blocks' (idea created on 2017-04-03 12:28:21 by Hans Dollen), on 2017-05-25 10:54:44 by Goncalo Borrega
4 Apr 2017

Hi Hans, 


This idea is the same as: http://www.outsystems.com/ideas/106/select-part-of-an-action-flow-and-refactor-to-action



Merged from 'Refactoring: Create a subaction from selected logic-blocks' (idea created on 2017-04-03 12:28:21 by Hans Dollen), on 2017-05-25 10:54:44 by Goncalo Borrega
15 Sep 2017

Sometimes you want to extract certain logic into a reusable server action. 

It would be nice if there was an option in the designer context menu that would allow this. 

The following should happen when the option is selected:

  • Create a new server action that contains the logic selected
  • In/out parameters should be determined automatically
  • The start and end nodes should link correctly to the logic flow
  • Replace the selected logic in the original screen with the new server action
  • Connector lines should automatically reconnect correctly
  • Set the parameters as needed for the new action call


Merged from 'Extract selected logic to action' (idea created on 2017-09-15 22:35:45 by Hanno Coetzee), on 2017-09-20 04:10:42 by Leonardo Fernandes
18 Sep 2017

This idea is the same as https://www.outsystems.com/ideas/106/select-part-of-an-action-flow-and-refactor-to-action.



Merged from 'Extract selected logic to action' (idea created on 2017-09-15 22:35:45 by Hanno Coetzee), on 2017-09-20 04:10:42 by Leonardo Fernandes
18 Sep 2017

Thanks Pedro. I did do a search but couldn't find any existing ideas   


Moderators, please merge with this idea.



Merged from 'Extract selected logic to action' (idea created on 2017-09-15 22:35:45 by Hanno Coetzee), on 2017-09-20 04:10:42 by Leonardo Fernandes
18 Sep 2017

Great idea.

Hi guys,

As promised in our Service Studio's gifts post, I'm happy to announce that a new Extract to Action command was introduced in 10.0.0.716 version. It will allow you to extract and reuse complicated logic that you created in a different place. Just select the piece of logic and click! Your action is now reusable :)

Hope you enjoy the feature :)

Thanks a lot for your feedback, please keep influencing and improving the product. Also, thanks to the MVPs that pre-tested the feature!

Really cool and handy!

Hi guys,

Yesterday we found a bug in Extract to Action feature, even after being tested and validated by dozens of Beta users, including some of our MVPs... Unfortunately, these things happen :(

We removed 10.0.0.716 version from the download list and there is already a new version (10.0.0.717) with this problem fixed (available here: https://www.outsystems.com/home/downloads/)

Please, go get it (and sorry for the inconvenience).

Hell yeah! 


I believe that is long overdue. I think that is a core feature for everyone that wishes to enforce encapsulation and good architecture in a Low Code platform. 


Well done!

Hey José,

Glad you enjoyed the feature ;)

Oh heck, yes!

I've been itching to use this for the past week, and today, I had something with giant actions that could really do with refactoring. Perfect!

If I may make one small suggestion: place the End where the next node after the refactoring was...

The new End gets put here:

It would be nice - if it's possible - to put it where the next node after the split was, e.g.

views
401
Followers
1