liuhj 1 year ago
parent
commit
f0ebcad44a

+ 28 - 0
package-lock.json

@@ -17,6 +17,7 @@
         "@fullcalendar/timegrid": "^6.1.4",
         "@fullcalendar/vue": "^6.1.4",
         "axios": "^1.3.4",
+        "echarts": "^5.4.0",
         "element-ui": "^2.15.13",
         "pinyin-pro": "^3.17.0",
         "tippy.js": "^6.3.7",
@@ -4689,6 +4690,20 @@
         "stream-shift": "^1.0.0"
       }
     },
+    "node_modules/echarts": {
+      "version": "5.4.0",
+      "resolved": "https://registry.npmjs.org/echarts/-/echarts-5.4.0.tgz",
+      "integrity": "sha512-uPsO9VRUIKAdFOoH3B0aNg7NRVdN7aM39/OjovjO9MwmWsAkfGyeXJhK+dbRi51iDrQWliXV60/XwLA7kg3z0w==",
+      "dependencies": {
+        "tslib": "2.3.0",
+        "zrender": "5.4.0"
+      }
+    },
+    "node_modules/echarts/node_modules/tslib": {
+      "version": "2.3.0",
+      "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.0.tgz",
+      "integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
+    },
     "node_modules/ee-first": {
       "version": "1.1.1",
       "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz",
@@ -15769,6 +15784,19 @@
       "resolved": "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz",
       "integrity": "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==",
       "dev": true
+    },
+    "node_modules/zrender": {
+      "version": "5.4.0",
+      "resolved": "https://registry.npmjs.org/zrender/-/zrender-5.4.0.tgz",
+      "integrity": "sha512-rOS09Z2HSVGFs2dn/TuYk5BlCaZcVe8UDLLjj1ySYF828LATKKdxuakSZMvrDz54yiKPDYVfjdKqcX8Jky3BIA==",
+      "dependencies": {
+        "tslib": "2.3.0"
+      }
+    },
+    "node_modules/zrender/node_modules/tslib": {
+      "version": "2.3.0",
+      "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.0.tgz",
+      "integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
     }
   }
 }

+ 1 - 0
package.json

@@ -19,6 +19,7 @@
     "@fullcalendar/timegrid": "^6.1.4",
     "@fullcalendar/vue": "^6.1.4",
     "axios": "^1.3.4",
+    "echarts": "^5.4.0",
     "element-ui": "^2.15.13",
     "pinyin-pro": "^3.17.0",
     "tippy.js": "^6.3.7",

+ 6 - 1
src/components/OP/Groupedit.vue

@@ -90,6 +90,9 @@
                     <el-form-item label-width="120px" label="其他需求:">
                         <el-input type="textarea" v-model="ruleForm.otherneeds"></el-input>
                     </el-form-item>
+                    <el-form-item label-width="120px" label="公务需求:">
+                        <el-input type="textarea" v-model="ruleForm.Officialneeds"></el-input>
+                    </el-form-item>
                 </el-form>
                 <el-form class="approval-box">
                     <el-form-item label-width="160px" label="出国任务审批部门名称:">
@@ -177,6 +180,7 @@ export default {
                 purposevisit: '',
                 specialneeds: '',
                 otherneeds: '',
+                Officialneeds:'',
                 approvalname: '',
                 approvalnumber1: '',
                 approvalnumber2: '',
@@ -405,6 +409,7 @@ export default {
                         that.ruleForm.purposevisit = datagroup.visitPurpose;
                         that.ruleForm.specialneeds = datagroup.specialNeeds;
                         that.ruleForm.otherneeds = datagroup.otherNeeds;
+                        that.ruleForm.Officialneeds = datagroup.officialneeds;//公务需求
                         that.ruleForm.approvalname = datagroup.cgrwspbmmc;
                         that.ruleForm.approvalnumber1 = datagroup.cgrwspwh;
                         that.ruleForm.censorshipdepartment = datagroup.zzscbmmc;
@@ -414,7 +419,6 @@ export default {
                         that.ruleForm.OP = datagroup.teamDid;
                         that.ruleForm.grades = datagroup.teamLevSId;
                         that.ruleForm.person = datagroup.jietuanOperator;
-                        debugger
                         that.ruleForm.opRoyaltyLv = parseInt(datagroup.opRoyaltyLv);
                         that.ruleForm.opRoyaltyRemark = datagroup.opRoyaltyRemark;
                     }
@@ -460,6 +464,7 @@ export default {
                     visitPurpose: that.ruleForm.purposevisit,
                     specialNeeds: that.ruleForm.specialneeds,
                     otherNeeds: that.ruleForm.otherneeds,
+                    officialneeds:that.ruleForm.Officialneeds,//公务需求
                     cgrwspbmmc: that.ruleForm.approvalname,
                     cgrwspwh: that.ruleForm.approvalnumber1,
                     zzscbmmc: that.ruleForm.censorshipdepartment,

+ 56 - 0
src/components/statistics/Statistically.vue

@@ -0,0 +1,56 @@
+<template>
+    <div>
+        <div class="statistically-all">
+            <div id="statisticallyone" style="width: 100%;height:400px;">
+
+            </div>
+        </div>
+    </div>
+</template>
+<script>
+import * as echarts from 'echarts';
+export default {
+    data () {
+        return {
+            aaa:[
+                    ['product', '2015', '2016', '2017'],
+                    ['Matcha Latte', 43.3, 85.8, 93.7],
+                    ['Milk Tea', 83.1, 73.4, 55.1],
+                    ['Cheese Cocoa', 86.4, 65.2, 82.5],
+                    ['Walnut Brownie', 72.4, 53.9, 39.1]
+                ],
+        }
+    },
+    methods: {
+        statisone(){
+                console.log(21)
+                var myChart = echarts.init(document.getElementById('statisticallyone'));
+                myChart.setOption({
+                    legend: {},
+                    tooltip: {},
+                    dataset: {
+                        source: this.aaa
+                    },
+                    xAxis: { type: 'category' },
+                    yAxis: {},
+                    // Declare several bar series, each will be mapped
+                    // to a column of dataset.source by default.
+                    series: [{ type: 'bar' }, { type: 'bar' }, { type: 'bar' }]
+                });
+            }
+    },
+    mounted(){
+        this.statisone()
+    }
+}
+</script>
+<style>
+.statistically-all{
+    background-color: #fff;
+    padding: 10px;
+    box-shadow: 0 0 5px #0005;
+    border-radius: 10px;
+    height: 100%;
+    min-height: 830px;
+}
+</style>

+ 3 - 0
src/main.js

@@ -17,6 +17,9 @@ Vue.use(VueQuillEditor);
 // import CKEditor from '@ckeditor/ckeditor5-vue2'
 // Vue.use( CKEditor );
 
+import * as echarts from 'echarts';
+Vue.use(echarts);
+
 Vue.use(VueTypedJs)
 import axios from 'axios';
 axios.defaults.baseURL = 'http://132.232.92.186:8888';

+ 6 - 1
src/router/index.js

@@ -98,7 +98,7 @@ import TaskList from '@/components/system/TaskList';
 import AssignTasks from '@/components/system/AssignTasks';
 import MyTasksinif from '@/components/system/MyTasksinif';
 import test from '@/components/child/test';
-
+import Statistically from '@/components/statistics/Statistically';
 
 
 Vue.use(Router)
@@ -578,6 +578,11 @@ export default new Router({
           name: 'test',
           component: test
         },
+        {
+          path: '/home/Statistically',
+          name: 'Statistically',
+          component: Statistically
+        },
       ]
     },
     {