jhzh
2024-09-28 1cdd7b754a7b112d36c4e84bb45309dc81f4505e
src/main.js
@@ -33,6 +33,7 @@
import "lib-flexible";
// import md5 from 'js-md5'
import * as filters from "@/utils/utils";
import * as filter from "@/utils/filter";
import * as allocation from "@/utils/allocation";
import animated from "animate.css"; // npm install animate.css --save安装,在引入
@@ -41,8 +42,6 @@
import echarts from "echarts";
Vue.prototype.$echarts = echarts;
Vue.prototype.$USD = allocation.$USD;
Vue.prototype.$USDT = allocation.$USDT;
Vue.prototype.$moment = moment;
// import VueTouch from 'vue-touch'
Vue.use(Swipe);
@@ -73,8 +72,10 @@
Object.keys(filters).forEach(key => {
  Vue.filter(key, filters[key]);
});
Object.keys(filter).forEach(key => {
  Vue.filter(key, filter[key]);
});
Object.keys(allocation).forEach(key => {
  console.log(allocation, "====");
  Vue.prototype[key] = allocation[key];
});
Vue.prototype.$state = state;
@@ -137,7 +138,8 @@
  document.title = to.meta.title;
  console.log(store.state, "store.state", !!store.state.token);
  if (to.meta.requireAuth && !!!store.state.token) {
    next("/login");
    // next("/login");
    //点击管理后台分享的二维码 进入注册页面 会识别未登录 导致进入登录页面
  }
  // if (!to.query.url && from.query.url) {
  //   to.query.url = from.query.url