不同环境的区别

Lvtianfang
吕天方 2 weeks ago
parent 66d0ef5162
commit 1f7b82e74a

@ -31,40 +31,41 @@ export default {
eventInfoTrue:true, eventInfoTrue:true,
} }
}, },
watch:{ //
$route:{ // watch:{
handler(route){ // $route:{
let timeOne; // handler(route){
let timeTwo; // let timeOne;
this.isTrue = true; // let timeTwo;
this.getGetErrorMsg();
//
timeOne = setInterval(()=>{
this.getGetErrorMsg();
},60000)
// clearInterval(timeTwo)
// if(route.meta.title == '') {
// this.isTrue = true; // this.isTrue = true;
// this.getGetErrorMsg(); // this.getGetErrorMsg();
// // // //
// timeOne = setInterval(()=>{ // timeOne = setInterval(()=>{
// this.getGetErrorMsg(); // this.getGetErrorMsg();
// },3600000)
// clearInterval(timeTwo)
// } else {
// clearInterval(timeTwo)
// this.isTrue = false;
// this.getLimitOneMsg();
// //
// timeTwo = setInterval(()=>{
// this.getLimitOneMsg();
// },60000) // },60000)
// clearInterval(timeOne) // // clearInterval(timeTwo)
// // if(route.meta.title == '') {
// // this.isTrue = true;
// // this.getGetErrorMsg();
// // //
// // timeOne = setInterval(()=>{
// // this.getGetErrorMsg();
// // },3600000)
// // clearInterval(timeTwo)
// // } else {
// // clearInterval(timeTwo)
// // this.isTrue = false;
// // this.getLimitOneMsg();
// // //
// // timeTwo = setInterval(()=>{
// // this.getLimitOneMsg();
// // },60000)
// // clearInterval(timeOne)
// // }
// },
// immediate:true,
// } // }
}, // },
immediate:true,
}
},
methods:{ methods:{
// //
getLimitOneMsg(){ getLimitOneMsg(){

@ -74,6 +74,7 @@ export const constantRoutes = [
// }, // },
// ] // ]
}, },
// 以下测试环境需注释掉
{ {
path: '/index', path: '/index',
component: () => import('@/views/index'), component: () => import('@/views/index'),
@ -226,6 +227,7 @@ Router.prototype.replace = function push(location) {
} }
export default new Router({ export default new Router({
// 测试环境注释掉
mode: 'history', // 去掉url中的# mode: 'history', // 去掉url中的#
scrollBehavior: () => ({ y: 0 }), scrollBehavior: () => ({ y: 0 }),
routes: constantRoutes routes: constantRoutes

@ -16,6 +16,7 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
const service = axios.create({ const service = axios.create({
// axios中请求配置有baseURL选项表示请求URL公共部分 // axios中请求配置有baseURL选项表示请求URL公共部分
baseURL: process.env.NODE_ENV === "production" ? location.origin + '/api' : process.env.VUE_APP_BASE_API, baseURL: process.env.NODE_ENV === "production" ? location.origin + '/api' : process.env.VUE_APP_BASE_API,
// 测试环境使用
// baseURL: process.env.VUE_APP_BASE_API, // baseURL: process.env.VUE_APP_BASE_API,
// 超时 // 超时
timeout: 10000 timeout: 10000

@ -95,50 +95,52 @@ export default {
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// console.log(currentDate >= targetDate); // console.log(currentDate >= targetDate);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// })
// })
// } else {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token)
// localStorage.setItem('Admin-Token',res.token)
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
})
})
} else {
login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// setToken(res.token)
localStorage.setItem('Admin-Token',res.token)
this.getList();
this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {
window.removeEventListener('resize', this.cancalDebounce); window.removeEventListener('resize', this.cancalDebounce);

@ -152,52 +152,54 @@ export default {
mounted() { mounted() {
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// localStorage.setItem('Admin-Token',res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token) localStorage.setItem('Admin-Token',res.token)
// this.$nextTick(() => { // setToken(res.token)
// this.initMap(); this.$nextTick(() => {
// }); this.initMap();
// this.getList(); });
// }) this.getList();
// }) })
// }); })
// } else { });
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ } else {
// localStorage.setItem('Admin-Token',res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// this.$nextTick(() => { localStorage.setItem('Admin-Token',res.token)
// this.initMap();
// });
// this.getList();
// })
// }
// })
this.$nextTick(() => { this.$nextTick(() => {
this.initMap(); this.initMap();
}); });
this.getList(); this.getList();
})
}
})
// 使
// this.$nextTick(() => {
// this.initMap();
// });
// this.getList();
}, },
methods:{ methods:{
mountedMethods(){ mountedMethods(){

@ -121,50 +121,52 @@ export default {
mounted(){ mounted(){
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// })
// })
// } else {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token)
// localStorage.setItem('Admin-Token',res.token)
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
})
})
} else {
login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// setToken(res.token)
localStorage.setItem('Admin-Token',res.token)
this.getList();
this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {
window.removeEventListener('resize', this.cancalDebounce); window.removeEventListener('resize', this.cancalDebounce);

@ -123,50 +123,52 @@ export default {
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// if(currentDate >= targetDate) { // if(currentDate >= targetDate) {
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// })
// })
// } else {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token)
// localStorage.setItem('Admin-Token',res.token)
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
})
})
} else {
login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// setToken(res.token)
localStorage.setItem('Admin-Token',res.token)
this.getList();
this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {
window.removeEventListener('resize', this.cancalDebounce); window.removeEventListener('resize', this.cancalDebounce);

@ -123,51 +123,52 @@ export default {
mounted(){ mounted(){
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce(); this.getList();
// window.addEventListener('resize', this.cancalDebounce); this.cancalDebounce();
// }) window.addEventListener('resize', this.cancalDebounce);
// }) })
// }) })
// } else { })
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ } else {
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {

@ -121,50 +121,52 @@ export default {
mounted(){ mounted(){
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// })
// })
// } else {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token)
// localStorage.setItem('Admin-Token',res.token)
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
})
})
} else {
login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// setToken(res.token)
localStorage.setItem('Admin-Token',res.token)
this.getList();
this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {
window.removeEventListener('resize', this.cancalDebounce); window.removeEventListener('resize', this.cancalDebounce);

@ -121,50 +121,52 @@ export default {
mounted(){ mounted(){
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// })
// })
// } else {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token)
// localStorage.setItem('Admin-Token',res.token)
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
})
})
} else {
login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// setToken(res.token)
localStorage.setItem('Admin-Token',res.token)
this.getList();
this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {
window.removeEventListener('resize', this.cancalDebounce); window.removeEventListener('resize', this.cancalDebounce);

@ -117,50 +117,52 @@ export default {
mounted(){ mounted(){
// const currentDate = new Date(); // const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0); // const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// verify().then(res=>{ // 使
// if(!res.data) { verify().then(res=>{
// this.$prompt('<div>3</div><div class="warningText">使22026111</div>', '', { if(!res.data) {
// confirmButtonText: '', this.$prompt('<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>', '提示', {
// type:"warning", confirmButtonText: '确定',
// closeOnPressEscape:false, type:"warning",
// showCancelButton: false, closeOnPressEscape:false,
// closeOnClickModal:false, showCancelButton: false,
// dangerouslyUseHTMLString:true, closeOnClickModal:false,
// showInput:true, dangerouslyUseHTMLString:true,
// showClose:false, showInput:true,
// beforeClose:(action, instance, done)=>{ showClose:false,
// if (action === 'confirm') { beforeClose:(action, instance, done)=>{
// if(instance.inputValue == "88888888") { if (action === 'confirm') {
// done(); if(instance.inputValue == "88888888") {
// } else { done();
// this.$message.error(''); } else {
// } this.$message.error('试用码错误!');
// } }
// } }
// }).then(({ value }) => { }
// verificationCode({verificationCode:value}).then(res=>{ }).then(({ value }) => {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{ verificationCode({verificationCode:value}).then(res=>{
// // setToken(res.token) login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// localStorage.setItem('Admin-Token',res.token) // setToken(res.token)
// this.getList(); localStorage.setItem('Admin-Token',res.token)
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// })
// })
// } else {
// login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// // setToken(res.token)
// localStorage.setItem('Admin-Token',res.token)
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
// })
// }
// })
this.getList(); this.getList();
this.cancalDebounce(); this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce); window.addEventListener('resize', this.cancalDebounce);
})
})
})
} else {
login("admin",encrypt("Suanfa@2024//**...")).then(res=>{
// setToken(res.token)
localStorage.setItem('Admin-Token',res.token)
this.getList();
this.cancalDebounce();
window.addEventListener('resize', this.cancalDebounce);
})
}
})
// 使
// this.getList();
// this.cancalDebounce();
// window.addEventListener('resize', this.cancalDebounce);
}, },
destroyed() { destroyed() {
window.removeEventListener('resize', this.cancalDebounce); window.removeEventListener('resize', this.cancalDebounce);

Loading…
Cancel
Save