改造后台权限和APP权限

This commit is contained in:
super
2026-04-19 15:06:09 +08:00
parent ef0e0df0ac
commit 4b6295dd44
35 changed files with 1487 additions and 85 deletions

View File

@@ -117,6 +117,21 @@
</form>
</div>
<script>
function clearAppPermissionCaches() {
try {
var keysToRemove = [];
for (var i = 0; i < localStorage.length; i++) {
var key = localStorage.key(i);
if (key && key.indexOf('app_column_permissions:') === 0) {
keysToRemove.push(key);
}
}
keysToRemove.forEach(function(key) {
localStorage.removeItem(key);
});
} catch (e) {}
}
(function() {
fetch('/api/auth/check', { credentials: 'same-origin' })
.then(function(r) { return r.json(); })
@@ -142,6 +157,7 @@
.then(function(r) { return r.json(); })
.then(function(res) {
if (res.success) {
clearAppPermissionCaches();
window.location.href = res.redirect || '/home';
} else {
var errEl = document.querySelector('.error-msg');