mirror of
https://github.com/pirate/ArchiveBox.git
synced 2025-08-22 06:03:23 +02:00
use localStorage var
This commit is contained in:
@@ -190,12 +190,12 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
function selectSnapshotListView(){
|
function selectSnapshotListView(){
|
||||||
myStorage.setItem('currentSnapshotView', 'List');
|
localStorage.setItem('currentSnapshotView', 'List');
|
||||||
redirectWithQuery("{% url 'admin:core_snapshot_changelist' %}");
|
redirectWithQuery("{% url 'admin:core_snapshot_changelist' %}");
|
||||||
};
|
};
|
||||||
|
|
||||||
function selectSnapshotGridView(){
|
function selectSnapshotGridView(){
|
||||||
myStorage.setItem('currentSnapshotView', 'Grid');
|
localStorage.setItem('currentSnapshotView', 'Grid');
|
||||||
redirectWithQuery("{% url 'admin:grid' %}");
|
redirectWithQuery("{% url 'admin:grid' %}");
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -211,7 +211,6 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
function setupSnapshotViews() {
|
function setupSnapshotViews() {
|
||||||
myStorage = window.localStorage;
|
|
||||||
const preferredSnapshotView = localStorage.getItem('currentSnapshotView');
|
const preferredSnapshotView = localStorage.getItem('currentSnapshotView');
|
||||||
setPreferredSnapshotView(preferredSnapshotView);
|
setPreferredSnapshotView(preferredSnapshotView);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user