lk 5 år sedan
förälder
incheckning
bcd878fea8
3 ändrade filer med 80 tillägg och 0 borttagningar
  1. 3 0
      components/menu/data.js
  2. BIN
      pages/main/index/.DS_Store
  3. 77 0
      pages/main/index/work_statistics.vue

+ 3 - 0
components/menu/data.js

@@ -158,6 +158,9 @@ export default [{
     },{
       title: "搜索数据管理",
       path: baseUrl + "user_search"
+    },{
+      title: "作品数据管理",
+      path: baseUrl + "work_statistics"
     }
     ]
   },

BIN
pages/main/index/.DS_Store


+ 77 - 0
pages/main/index/work_statistics.vue

@@ -0,0 +1,77 @@
+<template>
+  <div>
+    <div style="margin-top: 20px">
+      <el-table :data="tableData" border style="width: 100%">
+        <el-table-column
+          prop=""
+          label="日期">
+          <template slot-scope="scope">
+            {{ scope.row.time_name }}
+          </template>
+        </el-table-column>
+        <el-table-column prop="create_time" label="作品总数">
+          <template slot-scope="scope">
+            <span>{{ scope.row.work_num !== '0' ? scope.row.work_num : '-' }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="create_time" label="优质作品总数">
+          <template slot-scope="scope">
+            <span>{{ scope.row.work_quality_num !== '0' ? scope.row.work_quality_num : '-' }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="create_time" label="github转载数">
+          <template slot-scope="scope">
+            <span>{{ scope.row.github_num !== '0' ? scope.row.github_num : '-' }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="create_time" label="gitee转载数">
+          <template slot-scope="scope">
+            <span>{{ scope.row.gitee_num !== '0' ? scope.row.gitee_num : '-' }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="create_time" label="Dribbble转载数">
+          <template slot-scope="scope">
+            <span>{{ scope.row.dribbble_num !== '0' ? scope.row.dribbble_num : '-' }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="create_time" label="zool转载数">
+          <template slot-scope="scope">
+            <span>{{ scope.row.zool_num !== '0' ? scope.row.zool_num : '-' }}</span>
+          </template>
+        </el-table-column>
+
+      </el-table>
+
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  name: "user_search",
+  data() {
+    return {
+      page: 1,
+      total: 0,
+      loading: false,
+      tableData: [],
+    }
+  },
+  mounted() {
+    this.getData();
+  },
+  methods: {
+    async getData() {
+      let res = await this.$post("/api/admin/userWorks/getWorkStatistics", {});
+      debugger
+      if (res && res.status === 1) {
+        this.tableData = res.data.list || [];
+      }
+    }
+  }
+}
+</script>
+
+<style scoped>
+
+</style>