Commit 72ed9bae by 肖康

x

parents
.DS_Store
node_modules
/dist
# local env files
.env.local
.env.*.local
# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
# cloudsystem
## Project setup
```
npm install
```
### Compiles and hot-reloads for development
```
npm run serve
```
### Compiles and minifies for production
```
npm run build
```
### Lints and fixes files
```
npm run lint
```
### Customize configuration
See [Configuration Reference](https://cli.vuejs.org/config/).
module.exports = {
presets: [
'@vue/cli-plugin-babel/preset'
],
'plugins': [
[
'component',
{
'libraryName': 'element-ui',
'styleLibraryName': 'theme-chalk'
}
]
]
}
This diff could not be displayed because it is too large.
{
"name": "cloudsystem",
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint"
},
"dependencies": {
"axios": "^0.21.1",
"core-js": "^3.6.5",
"element-ui": "^2.15.1",
"qs": "^6.10.1",
"vue": "^2.6.11",
"vue-router": "^3.2.0"
},
"devDependencies": {
"@vue/cli-plugin-babel": "~4.5.0",
"@vue/cli-plugin-eslint": "~4.5.0",
"@vue/cli-plugin-router": "~4.5.0",
"@vue/cli-service": "~4.5.0",
"@vue/eslint-config-prettier": "^6.0.0",
"babel-eslint": "^10.1.0",
"babel-plugin-component": "^1.1.1",
"eslint": "^6.7.2",
"eslint-plugin-prettier": "^3.3.1",
"eslint-plugin-vue": "^6.2.2",
"less": "^3.0.4",
"less-loader": "^5.0.0",
"prettier": "^2.2.1",
"vue-template-compiler": "^2.6.11"
},
"eslintConfig": {
"root": true,
"env": {
"node": true
},
"extends": [
"plugin:vue/essential",
"eslint:recommended",
"@vue/prettier"
],
"parserOptions": {
"parser": "babel-eslint"
},
"rules": {}
},
"browserslist": [
"> 1%",
"last 2 versions",
"not dead"
]
}
No preview for this file type
<!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.0">
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<title><%= htmlWebpackPlugin.options.title %></title>
</head>
<body>
<noscript>
<strong>网络异常,请稍后加载</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
</body>
</html>
<template>
<div id="app">
<keep-alive exclude="index">
<router-view class="router-view"></router-view>
</keep-alive>
</div>
</template>
<script>
export default {
name: 'app'
}
</script>
\ No newline at end of file
body{
font-size: 20px;
}
\ No newline at end of file
body{font-size:20px}
\ No newline at end of file
body{
background: #ccc;
}
\ No newline at end of file
body{background:#ccc}
\ No newline at end of file
export default {
bind(el, binding) {
el.addEventListener('click', function () {
var t = document.querySelector('.container-wrap').scrollTop
var step=(t/100).toFixed(0);
var timer=setInterval(function(){
t=t-step;
if(t<=0){
t=0;
clearInterval(timer);
}
document.querySelector('.container-wrap').scrollTop = t;
},1)
}, false);
},
}
\ No newline at end of file
import Vue from 'vue'
import BackTopDirective from './backTop';
export default {
install (Vue) {
Vue.directive('backTop', BackTopDirective);
}
}
/**
* 格式化日期
* @param value
* @returns {string}
*/
export const dateTimeFormate = (value, params) => {
var time = new Date(value * 1000);
function timeAdd0(str) {
if (str < 10) {
str = '0' + str;
}
return str
}
var y = time.getFullYear();
var m = time.getMonth() + 1;
var d = time.getDate();
var h = time.getHours();
var mm = time.getMinutes();
var s = time.getSeconds();
return y + '-' + timeAdd0(m) + '-' + timeAdd0(d) + ' ' + timeAdd0(h) + ':' + timeAdd0(mm) + ':' + timeAdd0(s);
}
export const dateTimeFormate1 = (value, params) => {
var time = new Date(value * 1000);
function timeAdd0(str) {
if (str < 10) {
str = '0' + str;
}
return str
}
var y = time.getFullYear();
var m = time.getMonth() + 1;
var d = time.getDate();
var h = time.getHours();
var mm = time.getMinutes();
var s = time.getSeconds();
return y + '-' + timeAdd0(m) + '-' + timeAdd0(d);
}
import {dateTimeFormate,dateTimeFormate1} from './formate';
export default {
dateTimeFormate,
dateTimeFormate1,
};
import Vue from "vue";
import App from "./App.vue";
import router from "./router";
import filters from './filters'
import directive from './directive'
//本地环境开启提示信息
Vue.config.productionTip = false;
//加载全局样式
import '@/assets/css/public/common.min.css'
//过滤器遍历
Object.keys(filters).forEach(key => Vue.filter(key, filters[key]));
//自定义指令
Vue.use(directive);
new Vue({
router,
render: (h) => h(App),
}).$mount("#app");
import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter)
const routes = [
//首页
{
path: '/',
name: 'Index',
meta: {
title: '猎芯网 - 云芯系统',
back: true
},
component: () => import('../views/Index/index.vue')
},
/**错误页面重定向到首页**/
{
path: '*',
redirect: '/',
}
]
const router = new VueRouter({
mode: 'hash',
base: process.env.BASE_URL,
routes
})
export default router
export default {
sayHellow(){
alert("hello")
return true;
}
}
<template>
<div>我是首页</div>
</template>
\ No newline at end of file
module.exports = {
lintOnSave:false,//关闭eslint
productionSourceMap: false
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment