Yes you can set the platform to exit your position and cancel any working orders at a time you specify.
To do this, expand the Equity and P/L dropdown in the top navigation:
The Configuration Modal will allow you to enable/disable this function and set the time of the current calendar date you would like to flatten:
When it executes, Positions will be exited and working orders will be canceled:
Once executed, the function will be “disabled” so you can enable this for each session you would like.