This repository has been archived on 2026-06-20. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
wsh5485 7e47ce238b chore: 添加多个图片和资源文件
添加了管理后台所需的图片资源、Excel文件、安装程序以及设计相关的图片文件
2025-06-15 13:04:37 +08:00

43 lines
967 B
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/**
@NamelayuiAdmin 公共业务
@Author:贤心
@Sitehttp://www.layui.com/admin/
@LicenseLPPL
*/
layui.define(function(exports){
var $ = layui.$
,layer = layui.layer
,laytpl = layui.laytpl
,setter = layui.setter
,view = layui.view
,admin = layui.admin
//公共业务的逻辑处理可以写在此处,切换任何页面都会执行
//……
//退出
admin.events.logout = function(){
//执行退出接口
admin.req({
url: layui.setter.base + 'json/user/logout.js'
,type: 'get'
,data: {}
,done: function(res){ //这里要说明一下:done 是只有 response 的 code 正常才会执行。而 succese 则是只要 http 为 200 就会执行
//清空本地记录的 token,并跳转到登入页
admin.exit(function(){
location.href = 'user/login.html';
});
}
});
};
//对外暴露的接口
exports('common', {});
});