打包版本
@ -0,0 +1,24 @@
|
||||
# screen
|
||||
|
||||
## 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/).
|
@ -0,0 +1,5 @@
|
||||
module.exports = {
|
||||
presets: [
|
||||
'@vue/cli-plugin-babel/preset'
|
||||
]
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
{
|
||||
"name": "screen",
|
||||
"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",
|
||||
"echarts": "^5.0.0",
|
||||
"element-ui": "^2.15.5",
|
||||
"file-saver": "^2.0.5",
|
||||
"gridmanager-vue": "^1.10.1",
|
||||
"qs": "^6.10.1",
|
||||
"vue": "^2.6.12",
|
||||
"vue-router": "^3.2.0",
|
||||
"vue-table-dynamic": "^0.4.6",
|
||||
"vuex": "^3.4.0",
|
||||
"vxe-table": "^4.0.25",
|
||||
"xe-utils": "^3.3.1",
|
||||
"xlsx": "^0.16.9"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@vue/cli-plugin-babel": "^4.5.0",
|
||||
"@vue/cli-plugin-eslint": "^4.5.0",
|
||||
"@vue/cli-plugin-router": "^4.5.0",
|
||||
"@vue/cli-plugin-vuex": "^4.5.0",
|
||||
"@vue/cli-service": "^4.5.0",
|
||||
"babel-eslint": "^10.1.0",
|
||||
"eslint": "^6.7.2",
|
||||
"eslint-plugin-vue": "^6.2.2",
|
||||
"node-sass": "^4.14.1",
|
||||
"sass-loader": "^8.0.2",
|
||||
"vue-template-compiler": "^2.6.11"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 4.2 KiB |
@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<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">
|
||||
<!-- <script type="text/javascript" src="https://api.map.baidu.com/api?v=3.0&&ak=BjhDt6PxSA6fd3vCH9aN9Z1MnTa6IPhF"></script> -->
|
||||
<title>孙记报表中心</title>
|
||||
</head>
|
||||
<body>
|
||||
<noscript>
|
||||
<strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
|
||||
</noscript>
|
||||
<div id="app"></div>
|
||||
<!-- built files will be auto injected -->
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,36 @@
|
||||
<template>
|
||||
<div id="app">
|
||||
<router-view/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style lang="scss">
|
||||
html,
|
||||
body {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
margin: 0 !important;
|
||||
}
|
||||
#app {
|
||||
font-family: Avenir, Helvetica, Arial, sans-serif;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
text-align: center;
|
||||
color: #2c3e50;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
#nav {
|
||||
padding: 30px;
|
||||
|
||||
a {
|
||||
font-weight: bold;
|
||||
color: #2c3e50;
|
||||
|
||||
&.router-link-exact-active {
|
||||
color: #42b983;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 38 KiB |
After Width: | Height: | Size: 4.5 KiB |
After Width: | Height: | Size: 6.7 KiB |
After Width: | Height: | Size: 59 KiB |
After Width: | Height: | Size: 4.5 KiB |
After Width: | Height: | Size: 30 KiB |
@ -0,0 +1,27 @@
|
||||
import Vue from 'vue'
|
||||
import App from './App.vue'
|
||||
import router from './router'
|
||||
import store from './store'
|
||||
// import echarts from 'echarts'
|
||||
var echarts = require('echarts');
|
||||
import ElementUI from 'element-ui';
|
||||
import 'element-ui/lib/theme-chalk/index.css';
|
||||
|
||||
|
||||
import FileSaver from 'file-saver'
|
||||
import XLSX from 'xlsx'
|
||||
// 将excel表格模板设置全局
|
||||
Vue.prototype.$FileSaver = FileSaver;
|
||||
Vue.prototype.$XLSX = XLSX;
|
||||
|
||||
Vue.use(ElementUI);//引入 elementUI
|
||||
|
||||
Vue.prototype.$echarts = echarts
|
||||
Vue.config.productionTip = false
|
||||
new Vue({
|
||||
router,
|
||||
store,
|
||||
render: h => h(App)
|
||||
}).$mount('#app')
|
||||
|
||||
|
@ -0,0 +1,15 @@
|
||||
|
||||
require("echarts/dist/extension/bmap.js");
|
||||
export const createEcharts = {
|
||||
created: function () {
|
||||
|
||||
},
|
||||
methods: {
|
||||
getModel(dom) {
|
||||
return this.$echarts.init(document.getElementById(dom));
|
||||
},
|
||||
initCreate: function (dom, option) {
|
||||
return this.$echarts.init(document.getElementById(dom)).setOption(option)
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,40 @@
|
||||
import Vue from 'vue'
|
||||
import VueRouter from 'vue-router'
|
||||
|
||||
Vue.use(VueRouter)
|
||||
|
||||
const routes = [
|
||||
//
|
||||
{
|
||||
path: '/',
|
||||
name: 'home',
|
||||
component: () => import('../views/home')
|
||||
},
|
||||
{
|
||||
path: '/payment',
|
||||
// name: 'payment',
|
||||
component: () => import('../views/payment')
|
||||
},
|
||||
{
|
||||
path: '/sale',
|
||||
name: 'sale',
|
||||
component: () => import('../views/sale')
|
||||
},
|
||||
{
|
||||
path: '/sale_summary',
|
||||
// name: 'sale_summary',
|
||||
component: () => import('../views/sale_summary')
|
||||
},
|
||||
|
||||
|
||||
|
||||
]
|
||||
|
||||
const router = new VueRouter({
|
||||
mode: 'hash',
|
||||
// mode: 'history',
|
||||
// base: process.env.BASE_URL,
|
||||
routes
|
||||
})
|
||||
|
||||
export default router
|
@ -0,0 +1,15 @@
|
||||
import Vue from 'vue'
|
||||
import Vuex from 'vuex'
|
||||
|
||||
Vue.use(Vuex)
|
||||
|
||||
export default new Vuex.Store({
|
||||
state: {
|
||||
},
|
||||
mutations: {
|
||||
},
|
||||
actions: {
|
||||
},
|
||||
modules: {
|
||||
}
|
||||
})
|
@ -0,0 +1,211 @@
|
||||
.pr {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.wh100 {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.topWarn {
|
||||
font-size: 15px;
|
||||
font-weight: 700;
|
||||
color: white;
|
||||
margin-bottom: 15px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.main {
|
||||
background: #021056;
|
||||
// #000a3b;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.product {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
padding: 0 20px 20px 20px;
|
||||
box-sizing: border-box;
|
||||
|
||||
.top {
|
||||
width: 100%;
|
||||
height: 62px;
|
||||
background: url(../assets/top.png) no-repeat;
|
||||
background-size: 100% 100%;
|
||||
font-size: 34px;
|
||||
color: #01c4f7;
|
||||
line-height: 62px;
|
||||
margin-bottom: 22px;
|
||||
font-weight: bold;
|
||||
|
||||
.navTool {
|
||||
width: 143px;
|
||||
height: 28px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.echartsDom {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: url('../assets/modelBg.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
position: relative;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.echartsDom_title {
|
||||
background: url('../assets/biankuang.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
position: absolute;
|
||||
color: #02D9FD;
|
||||
font-size: 20px;
|
||||
width: 221px;
|
||||
height: 34px;
|
||||
line-height: 34px;
|
||||
left: calc(50% - 110px);
|
||||
top: -16px;
|
||||
z-index: 9999;
|
||||
}
|
||||
|
||||
.content {
|
||||
width: 100%;
|
||||
height: calc(100% - 84px);
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.content_left {
|
||||
width: 26%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.content_left_top {
|
||||
width: 100%;
|
||||
height: calc(70% - 15px);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.content_left_top_one {
|
||||
width: 100%;
|
||||
height: calc(50% - 15px);
|
||||
}
|
||||
|
||||
.content_left_top_two {
|
||||
width: 100%;
|
||||
height: calc(50% - 15px);
|
||||
}
|
||||
}
|
||||
|
||||
.content_left_bottom {
|
||||
width: 100%;
|
||||
height: calc(30% - 15px);
|
||||
}
|
||||
}
|
||||
|
||||
.content_center {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
margin: 0 20px;
|
||||
|
||||
.content_center_top {
|
||||
width: 100%;
|
||||
height: calc(70% - 15px);
|
||||
padding: 30px 20px 20px 20px;
|
||||
box-sizing: border-box;
|
||||
|
||||
.map {
|
||||
width: 100%;
|
||||
height: calc(100% - 40px);
|
||||
}
|
||||
}
|
||||
|
||||
.content_left_bottom {
|
||||
width: 100%;
|
||||
height: calc(30% - 15px);
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
||||
.left {
|
||||
width: 73%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.consume {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.right {
|
||||
width: 25%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.content_right {
|
||||
width: 26%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.content_right_top {
|
||||
width: 100%;
|
||||
height: calc(70% - 15px);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.content_right_top_one {
|
||||
width: 100%;
|
||||
height: calc(50% - 15px);
|
||||
}
|
||||
|
||||
.content_right_top_two {
|
||||
padding: 20px;
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
height: calc(50% - 15px);
|
||||
}
|
||||
|
||||
#content_right_top_two {
|
||||
height: calc(100% - 40px);
|
||||
}
|
||||
}
|
||||
|
||||
.procurementModel {
|
||||
height: calc(30% - 15px) !important;
|
||||
|
||||
.content_right_top_one {
|
||||
width: 100%;
|
||||
height: calc(100% - 15px);
|
||||
}
|
||||
}
|
||||
|
||||
.content_right_bottom {
|
||||
width: 100%;
|
||||
height: calc(30% - 15px);
|
||||
}
|
||||
|
||||
.dashboard {
|
||||
height: 70% !important;
|
||||
}
|
||||
}
|
||||
|
||||
// 采购数据 s
|
||||
.procurment_overdue {
|
||||
height: 100% !important;
|
||||
|
||||
#content_right_top_two {
|
||||
height: 100% !important;
|
||||
}
|
||||
}
|
||||
|
||||
// 采购数据 e
|
@ -0,0 +1,80 @@
|
||||
import axios from "axios";
|
||||
import qs from "qs";
|
||||
|
||||
axios.defaults.timeout = 5000; //响应时间
|
||||
axios.defaults.baseURL = "https://erp-test.ffcygl.com"; //配置接口地址
|
||||
// axios.defaults.baseURL = "http://localhost:8070"; //配置接口地址
|
||||
// axios.defaults.baseURL = "http://mode.spicycloud.cn"; //配置接口地址
|
||||
//
|
||||
//POST传参序列化(添加请求拦截器)
|
||||
axios.interceptors.request.use(
|
||||
config => {
|
||||
//在发送请求之前做某件事
|
||||
// config.headers['accesstoken'] = 'c41ee46ef177f02a5c652ef57899610ce8952891';
|
||||
// config.headers['X-Openerp-Session-Id'] = '3a54d3a8ce177278c1f873bf83f32c1656763d63';
|
||||
if (config.method === "post") {
|
||||
config.data = qs.stringify(config.data);
|
||||
}
|
||||
return config;
|
||||
},
|
||||
error => {
|
||||
console.log("错误的传参");
|
||||
return Promise.reject(error);
|
||||
}
|
||||
);
|
||||
|
||||
//返回状态判断(添加响应拦截器)
|
||||
axios.interceptors.response.use(
|
||||
res => {
|
||||
//对响应数据做些事
|
||||
if (!res.data.success) {
|
||||
return Promise.resolve(res);
|
||||
}
|
||||
return res;
|
||||
},
|
||||
error => {
|
||||
console.log("网络异常");
|
||||
return Promise.reject(error);
|
||||
}
|
||||
);
|
||||
|
||||
//返回一个Promise(发送post请求)
|
||||
export function fetchPost(url, params) {
|
||||
return new Promise((resolve, reject) => {
|
||||
axios
|
||||
.post(url, params)
|
||||
.then(
|
||||
response => {
|
||||
resolve(response);
|
||||
},
|
||||
err => {
|
||||
reject(err);
|
||||
}
|
||||
)
|
||||
.catch(error => {
|
||||
reject(error);
|
||||
});
|
||||
});
|
||||
}
|
||||
////返回一个Promise(发送get请求)
|
||||
export function fetchGet(url, param) {
|
||||
return new Promise((resolve, reject) => {
|
||||
axios
|
||||
.get(url, { params: param })
|
||||
.then(
|
||||
response => {
|
||||
resolve(response);
|
||||
},
|
||||
err => {
|
||||
reject(err);
|
||||
}
|
||||
)
|
||||
.catch(error => {
|
||||
reject(error);
|
||||
});
|
||||
});
|
||||
}
|
||||
export default {
|
||||
fetchPost,
|
||||
fetchGet
|
||||
};
|
@ -0,0 +1,55 @@
|
||||
<template>
|
||||
<section style="background-color: #f2f2f2;height: 100%;padding:4rem">
|
||||
<!-- <header class="content__title">
|
||||
<h1 style="font-size: 3rem;color:#ba000b">孙记集团报表中心</h1>
|
||||
</header> -->
|
||||
|
||||
<div class="widget-visitors__stats">
|
||||
<div style="background-color: #ba000b;" @click="link_to_payment">
|
||||
<strong>收银汇总表</strong>
|
||||
<small>Payment Report</small>
|
||||
</div>
|
||||
|
||||
<div style="background-color: #ba000b;" @click="link_to_sale">
|
||||
<strong>销售排行表</strong>
|
||||
<small>Sale Report</small>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="widget-visitors__stats">
|
||||
<div style="background-color: #ba000b;" @click="link_to_sale_summary">
|
||||
<strong>菜品销售汇总表</strong>
|
||||
<small>Sale Summary Report</small>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
|
||||
methods: {
|
||||
//跳转人事成本
|
||||
link_to_payment() {
|
||||
window.location.href = '#/payment'
|
||||
|
||||
},link_to_sale() {
|
||||
window.location.href = '#/sale'
|
||||
|
||||
},
|
||||
link_to_sale_summary() {
|
||||
window.location.href = '#/sale_summary'
|
||||
|
||||
},
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
<style src='../style/app.min.css'></style>
|
@ -0,0 +1,32 @@
|
||||
/*
|
||||
* @Descripttion: 前端开发
|
||||
* @version: 1.0
|
||||
* @Author: ls
|
||||
* @Date: 2019-11-26 18:09:54
|
||||
* @LastEditors: ls
|
||||
* @LastEditTime: 2020-08-15 09:52:51
|
||||
*/
|
||||
module.exports = {
|
||||
lintOnSave: false,
|
||||
publicPath: './',
|
||||
css: {
|
||||
|
||||
},
|
||||
productionSourceMap: false,
|
||||
chainWebpack: config => {
|
||||
// 其他配置
|
||||
configureWebpack: config => {
|
||||
config.entry.app = ["babel-polyfill", "./src/main.js"];
|
||||
}
|
||||
// 其他配置
|
||||
},
|
||||
// devServer: {
|
||||
// proxy: {
|
||||
// '/api': {
|
||||
// target: 'http://mode.spicycloud.cn',
|
||||
// secure: false,
|
||||
// changeOrigin: true
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|