Skip to content

Commit

Permalink
Merge pull request silverstripe#539 from creative-commoners/pulls/2.8…
Browse files Browse the repository at this point in the history
…/revert

Revert "Switch to listing views of subsite-filtered sections"
  • Loading branch information
GuySartorelli authored Sep 6, 2023
2 parents 4049f7a + e020766 commit 4e292b8
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions client/javascript/LeftAndMain_Subsites.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,7 @@
$('#SubsitesSelect').entwine({
onadd:function(){
this.on('change', function(){
// Switch to listing views of subsite-filtered sections (eg: pages/ & assets/)
let newLocHref = window.location.href
.split('edit/show/').shift() // remove [pages/]edit/etc
.split('settings/show/').shift() // remove [pages/]settings/etc
.split('history/show/').shift() // remove [pages/]history/etc
.split('show/').shift(); // remove [assets/]show/102/edit/etc (last as 'show' is broad)
window.location.href = newLocHref + $.query.set('SubsiteID', $(this).val()).toString();
window.location.search=$.query.set('SubsiteID', $(this).val());
});
}
});
Expand Down

0 comments on commit 4e292b8

Please sign in to comment.