提交 d262915c 作者: 毛细亚

同步代码

上级 650c4fd3
<!doctype html><html lang=""><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="icon" href="favicon.ico"><title>company_app</title><script src="https://g.alicdn.com/dingding/dinglogin/0.0.5/ddLogin.js"></script><script defer="defer" src="static/js/chunk-vendors.c5338b55.js"></script><script defer="defer" src="static/js/app.493a4164.js"></script><link href="static/css/chunk-vendors.34a02360.css" rel="stylesheet"><link href="static/css/app.da449827.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but company_app doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div></body></html> <!doctype html><html lang=""><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="icon" href="favicon.ico"><title>company_app</title><script src="https://g.alicdn.com/dingding/dinglogin/0.0.5/ddLogin.js"></script><script defer="defer" src="static/js/chunk-vendors.00c87327.js"></script><script defer="defer" src="static/js/app.c202da53.js"></script><link href="static/css/chunk-vendors.34a02360.css" rel="stylesheet"><link href="static/css/app.0819b696.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but company_app doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div></body></html>
\ No newline at end of file \ No newline at end of file
<template> <template>
<!-- 开发模式触发区域 - 隐藏的点击区域 --> <!-- 开发模式触发区域 - 隐藏的点击区域 -->
<div class="debug-container">
<div class="dev-mode-trigger" @click="handleDevModeClick" title="开发模式触发区域"></div> <div class="dev-mode-trigger" @click="handleDevModeClick" title="开发模式触发区域"></div>
<div class="dev-mode-cookie" @click="cleanCookie" title="清除所有 cookie"></div>
</div>
</template> </template>
<script> <script>
import devModeManager from '@/utils/devMode' import devModeManager from '@/utils/devMode'
import Cookies from 'js-cookie'
export default { export default {
name: 'Debug', name: 'Debug',
methods: { methods: {
handleDevModeClick() { handleDevModeClick() {
devModeManager.handleClick() devModeManager.handleClick()
},
cleanCookie() {
// 清除所有 cookie
Cookies.remove('token')
Cookies.remove('userid')
Cookies.remove('corp_id')
Cookies.remove('cser_id')
Cookies.remove('accountSelect')
Cookies.remove('signData')
this.$message.success('清除所有 cookie 成功')
} }
} }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.debug-container{
width: 100%;
height: 5px;
position: absolute;
top: 0;
left: 0;
z-index: 999;
}
/* 开发模式触发区域 */ /* 开发模式触发区域 */
.dev-mode-trigger { .dev-mode-trigger {
position: absolute; position: absolute;
top: 5px; top: 0px;
left: 5px; left: 0px;
width: 50px; width: 50px;
height: 50px; height: 20px;
background: transparent; background: transparent;
cursor: pointer; cursor: pointer;
z-index: 999; z-index: 999;
...@@ -33,4 +55,15 @@ export default { ...@@ -33,4 +55,15 @@ export default {
background: rgba(0, 191, 138, 0.1); background: rgba(0, 191, 138, 0.1);
border-radius: 4px; border-radius: 4px;
} }
.dev-mode-cookie{
position: absolute;
top: 0px;
right: 0px;
width: 50px;
height: 20px;
}
.dev-mode-cookie:hover {
background: rgba(138, 2, 162, 0.1);
border-radius: 4px;
}
</style> </style>
\ No newline at end of file
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论