To stop GL journals posting to specific branches you need to restrict it in the Allowed Combinations configuration (General Ledger > Configuration > Allowed Combinations). The required Major or Minor Code can be marked inactive in GL configuration (General Ledger > Configuration > Minor or General Ledger > Configuration > Minor). This will prevent the associated branch from being available for selection.

The parameter ‘GL Minor Codes Reflect Branch Structure’ control if the minor or major code is used as the branch code.