123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- import App from './App'
- import uView from "uview-ui";
- import verify from './common/graceChecker.js' //数据校验证
- import http from './common/http.js'
- import util from './common/util.js' //工具类
- Vue.use(uView);
- // #ifndef VUE3
- import Vue from 'vue'
- Vue.config.productionTip = false
- App.mpType = 'app'
- Vue.prototype.verify = verify;
- Vue.prototype.http = http;
- Vue.prototype.util = util;
- Vue.prototype.getUser = function() {
- return uni.getStorageSync('info');
- }
- Vue.prototype.hasAuth = () => {
- let user = uni.getStorageSync('info');
- console.log("asd:"+user.auth);
- if (user.auth == '0') {
- return false
- } else {
- return true
- }
- }
- const app = new Vue({
- ...App
- })
- app.$mount()
- // #endif
- // #ifdef VUE3
- import {
- createSSRApp
- } from 'vue'
- export function createApp() {
- const app = createSSRApp(App)
- return {
- app
- }
- }
- // #endif
|