Browse Source

拉取备份

zhuxinbo 5 years ago
parent
commit
3c938e658c

+ 142 - 126
src/views/dashboard/Analysis.vue

@@ -1,3 +1,8 @@
+<style>
+    .only-there .ant-tabs-bar{
+        background: white;
+    }
+</style>
 <template>
   <div class="page-header-index-wide">
     <!-- <div v-if="roleCode == 'operator' || roleCode == 'touTiaoOperationManager'">
@@ -143,156 +148,167 @@
         </a-col>
       </a-row>
     </div> -->
-    <newHome v-if="roleCode == 'admin' ||roleCode == 'operator' || roleCode == 'touTiaoOperationManager'" />
+
+    <newHome v-if="roleCode == 'operator' || roleCode == 'touTiaoOperationManager'" />
     <statistics v-else-if="roleCode == 'kuaishouOperationManager'" />
     <statistics v-else-if="roleCode == 'sale'||roleCode=='saleDirector'" />
-    <!-- <statistics v-else-if="roleCode == 'admin'" /> -->
+
     <Workbench v-else-if="roleCode == 'clip'" />
     <Workbench v-else-if="roleCode == 'plane'" />
 
-    
-     <newHome v-else-if="roleCode == 'admin'" />
+    <a-tabs default-active-key="1" v-else-if="roleCode == 'admin'" class="only-there">
+      <a-tab-pane key="1" tab="快手">
+        <statistics />
+      </a-tab-pane>
+      <a-tab-pane key="2" tab="头条">
+        <newHome />
+      </a-tab-pane>
+
+    </a-tabs>
   </div>
 </template>
 
 <script>
-import ChartCard from '@/components/ChartCard'
-import ACol from 'ant-design-vue/es/grid/Col'
-import ATooltip from 'ant-design-vue/es/tooltip/Tooltip'
-import MiniArea from '@/components/chart/MiniArea'
-import MiniBar from '@/components/chart/MiniBar'
-import MiniProgress from '@/components/chart/MiniProgress'
-import RankList from '@/components/chart/RankList'
-import Bar from '@/components/chart/Bar'
-import LineChartMultid from '@/components/chart/LineChartMultid'
-import HeadInfo from '@/components/tools/HeadInfo.vue'
+  import ChartCard from '@/components/ChartCard'
+  import ACol from 'ant-design-vue/es/grid/Col'
+  import ATooltip from 'ant-design-vue/es/tooltip/Tooltip'
+  import MiniArea from '@/components/chart/MiniArea'
+  import MiniBar from '@/components/chart/MiniBar'
+  import MiniProgress from '@/components/chart/MiniProgress'
+  import RankList from '@/components/chart/RankList'
+  import Bar from '@/components/chart/Bar'
+  import LineChartMultid from '@/components/chart/LineChartMultid'
+  import HeadInfo from '@/components/tools/HeadInfo.vue'
 
-import Trend from '@/components/Trend'
-import { getLoginfo, getVisitInfo } from '@/api/api'
-import newHome from '@/views/modules/Statistics/newHome.vue'
-import Workbench from '@/views/dashboard/Workbench.vue'
-import Statistics from '@/views/modules/Statistics/Statistics.vue'
-const rankList = []
-for (let i = 0; i < 7; i++) {
-  rankList.push({
-    name: '白鹭岛 ' + (i + 1) + ' 号店',
-    total: 1234.56 - i * 100
-  })
-}
-const barData = []
-for (let i = 0; i < 12; i += 1) {
-  barData.push({
-    x: `${i + 1}月`,
-    y: Math.floor(Math.random() * 1000) + 200
-  })
-}
-export default {
-  name: 'Analysis',
-  components: {
-    ATooltip,
-    ACol,
-    ChartCard,
-    MiniArea,
-    MiniBar,
-    MiniProgress,
-    RankList,
-    Bar,
-    Trend,
-    LineChartMultid,
-    HeadInfo,
-    newHome,
-    Workbench,
-    Statistics
-  },
-  data() {
-    return {
-      loading: true,
-      center: null,
-      rankList,
-      barData,
-      loginfo: {},
-      visitFields: ['ip', 'visit'],
-      visitInfo: [],
-      indicator: <a-icon type="loading" style="font-size: 24px" spin />,
-      roleCode: localStorage.getItem('roleCode')
-    }
-  },
-  created() {
-    setTimeout(() => {
-      this.loading = !this.loading
-    }, 1000)
-    this.initLogInfo()
-  },
-  methods: {
-    initLogInfo() {
-      getLoginfo(null).then(res => {
-        if (res.success) {
-          Object.keys(res.result).forEach(key => {
-            res.result[key] = res.result[key] + ''
-          })
-          this.loginfo = res.result
-        }
-      })
-      getVisitInfo().then(res => {
-        if (res.success) {
-          console.log('aaaaaa', res.result)
-          this.visitInfo = res.result
-        }
-      })
+  import Trend from '@/components/Trend'
+  import {
+    getLoginfo,
+    getVisitInfo
+  } from '@/api/api'
+  import newHome from '@/views/modules/Statistics/newHome.vue'
+  import Workbench from '@/views/dashboard/Workbench.vue'
+  import Statistics from '@/views/modules/Statistics/Statistics.vue'
+  const rankList = []
+  for (let i = 0; i < 7; i++) {
+    rankList.push({
+      name: '白鹭岛 ' + (i + 1) + ' 号店',
+      total: 1234.56 - i * 100
+    })
+  }
+  const barData = []
+  for (let i = 0; i < 12; i += 1) {
+    barData.push({
+      x: `${i + 1}月`,
+      y: Math.floor(Math.random() * 1000) + 200
+    })
+  }
+  export default {
+    name: 'Analysis',
+    components: {
+      ATooltip,
+      ACol,
+      ChartCard,
+      MiniArea,
+      MiniBar,
+      MiniProgress,
+      RankList,
+      Bar,
+      Trend,
+      LineChartMultid,
+      HeadInfo,
+      newHome,
+      Workbench,
+      Statistics
+    },
+    data() {
+      return {
+        loading: true,
+        center: null,
+        rankList,
+        barData,
+        loginfo: {},
+        visitFields: ['ip', 'visit'],
+        visitInfo: [],
+        // indicator: < a - icon type = "loading"style = "font-size: 24px"spin / > ,
+        roleCode: localStorage.getItem('roleCode')
+      }
+    },
+    created() {
+      setTimeout(() => {
+        this.loading = !this.loading
+      }, 1000)
+      this.initLogInfo()
+    },
+    methods: {
+      initLogInfo() {
+        getLoginfo(null).then(res => {
+          if (res.success) {
+            Object.keys(res.result).forEach(key => {
+              res.result[key] = res.result[key] + ''
+            })
+            this.loginfo = res.result
+          }
+        })
+        getVisitInfo().then(res => {
+          if (res.success) {
+            console.log('aaaaaa', res.result)
+            this.visitInfo = res.result
+          }
+        })
+      }
     }
   }
-}
 </script>
 
 <style lang="scss" scoped>
-.circle-cust {
-  position: relative;
-  top: 28px;
-  left: -100%;
-}
+  .circle-cust {
+    position: relative;
+    top: 28px;
+    left: -100%;
+  }
 
-.extra-wrapper {
-  line-height: 55px;
-  padding-right: 24px;
+  .extra-wrapper {
+    line-height: 55px;
+    padding-right: 24px;
 
-  .extra-item {
-    display: inline-block;
-    margin-right: 24px;
+    .extra-item {
+      display: inline-block;
+      margin-right: 24px;
 
-    a {
-      margin-left: 24px;
+      a {
+        margin-left: 24px;
+      }
     }
   }
-}
 
-/* 首页访问量统计 */
-.head-info {
-  position: relative;
-  text-align: left;
-  padding: 0 32px 0 0;
-  min-width: 125px;
+  /* 首页访问量统计 */
+  .head-info {
+    position: relative;
+    text-align: left;
+    padding: 0 32px 0 0;
+    min-width: 125px;
 
-  &.center {
-    text-align: center;
-    padding: 0 32px;
-  }
+    &.center {
+      text-align: center;
+      padding: 0 32px;
+    }
 
-  span {
-    color: rgba(0, 0, 0, 0.45);
-    display: inline-block;
-    font-size: 0.95rem;
-    line-height: 42px;
-    margin-bottom: 4px;
-  }
+    span {
+      color: rgba(0, 0, 0, 0.45);
+      display: inline-block;
+      font-size: 0.95rem;
+      line-height: 42px;
+      margin-bottom: 4px;
+    }
 
-  p {
-    line-height: 42px;
-    margin: 0;
+    p {
+      line-height: 42px;
+      margin: 0;
 
-    a {
-      font-weight: 600;
-      font-size: 1rem;
+      a {
+        font-weight: 600;
+        font-size: 1rem;
+      }
     }
   }
-}
-</style>
+</style>

+ 1 - 1
src/views/modules/Statistics/CompareData.vue

@@ -676,7 +676,7 @@ export default {
   margin-bottom: 10px;
 }
 .showbox {
-  padding: 10px 0;
+  padding: 24px 0;
   display: flex;
   justify-content: space-between;
   .costcompare {

+ 2 - 2
src/views/modules/Statistics/videoStatics/vSummary.vue

@@ -692,8 +692,8 @@ export default {
     })
 
     //进入页面默认展示昨天到今天的数据
-    this.dateRange=[moment().subtract(1,'days'),moment()]
-    this.timedata=[moment().subtract(1,'days').format('YYYY-MM-DD'),moment().format('YYYY-MM-DD')]
+    this.dateRange=[moment().subtract(7,'days'),moment()]
+    this.timedata=[moment().subtract(7,'days').format('YYYY-MM-DD'),moment().format('YYYY-MM-DD')]
     // this.loading=true;
    
         this.HttpPost()

+ 2 - 2
vue.config.js

@@ -64,7 +64,7 @@ module.exports = {
          }
        },*/
       '/jeecg-boot': {
-        // target: 'http://39.97.120.42:8080', //请求本地 需要jeecg-boot后台项目  生产环境
+        target: 'http://39.97.120.42:8080', //请求本地 需要jeecg-boot后台项目  生产环境
         // target: 'http://39.106.184.70:8080', //请求本地 需要jeecg-boot后台项目
         // target: 'http://192.168.1.13:8080', //请求本地 需要jeecg-boot后台项目  蒙蒙
         // target: 'http://192.168.1.22:8080', //请求本地 需要jeecg-boot后台项目  英豪
@@ -72,7 +72,7 @@ module.exports = {
         // target: 'http://192.168.1.103:8080', //请求本地 需要jeecg-boot后台项目
         // target: 'http://192.168.2.115:8080', //请求本地 需要jeecg-boot后台项目  祚云
         // target: 'http://192.168.1.54:8080', //请求本地 需要jeecg-boot后台项目  孙震
-        target: 'http://192.168.1.165:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
+        // target: 'http://192.168.1.165:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
         ws: false,
         changeOrigin: true
       },