zhaozhipeng 3 years ago
parent
commit
d1be301377

+ 2 - 2
src/App.vue

@@ -14,8 +14,8 @@ export default {
   html, body, #app {
     -webkit-font-smoothing: antialiased;
     -moz-osx-font-smoothing: grayscale;
-    width: 100%;
-    height: 100%;
+    width: 100vw;
+    height: 100vh;
     margin: 0px;
     font-family: 'Avenir', Helvetica, Arial, sans-serif;
     font-size: 14px;

+ 11 - 10
src/permission.js

@@ -1,5 +1,5 @@
 import router from './router'
-import {getToken} from '@/utils/auth'
+// import {getToken} from '@/utils/auth'
 import store from '@/store'
 import ViewUI from 'view-design'
 
@@ -10,15 +10,16 @@ router.beforeEach((to, from, next) => {
   // 设置顶部标题
   store.state.common.pageTitle = to.name
   // Token 校验验证
-  if (getToken()) {
-    if (to.matched.length === 0) {
-      next('/404')
-    } else {
-      next()
-    }
-  } else {
-     next()
-  }
+  // if (getToken()) {
+  //   if (to.matched.length === 0) {
+  //     next('/404')
+  //   } else {
+  //     next()
+  //   }
+  // } else {
+  //    next()
+  // }
+  next()
 })
 
 router.afterEach(() => {

+ 0 - 3
src/router/index.js

@@ -6,9 +6,6 @@ Vue.use(Router)
 export default new Router({
   routes: [{
     path: '/',
-    redirect: '/maintain'
-  }, {
-    path: '/index',
     name: 'Index',
     component: () => import('@/views/Index'),
     meta: {

+ 7 - 7
src/utils/request.js

@@ -1,5 +1,5 @@
 import axios from 'axios'
-import {getToken} from '@/utils/auth'
+// import {getToken} from '@/utils/auth'
 import {Spin, Notice} from 'view-design'
 import Router from '../router'
 
@@ -22,13 +22,13 @@ request.interceptors.request.use(config => {
   //  显示加载
   Spin.show()
   //  获取accessToken
-  let accessToken = getToken()
+  // let accessToken = getToken()
   //  添加请求头信息,处理安全性问题
-  if (accessToken != undefined) {
-    config.headers.Authorization = 'Bearer ' + accessToken
-  } else {
-    config.headers.Authorization = 'Basic dnVlOnZ1ZQ=='
-  }
+  // if (accessToken != undefined) {
+  //   config.headers.Authorization = 'Bearer ' + accessToken
+  // } else {
+  //   config.headers.Authorization = 'Basic dnVlOnZ1ZQ=='
+  // }
   //  添加时间戳防止IE不刷新页面
   if (config.type != 'FORM') {
     if (config.method == 'post') {

+ 4 - 1
src/views/Index.vue

@@ -1,7 +1,10 @@
 <template>
   <div class="index">
+    1
     <Layout style="height: 100%;background-color: transparent">
+      2
       <Content class="content">
+        3
         <router-view></router-view>
       </Content>
     </Layout>
@@ -45,7 +48,7 @@ export default {
     height: 100%;
     position: relative;
     overflow: hidden;
-    background-image: url('~@/assets/images/index_bg.png');
+    // background-image: url('~@/assets/images/index_bg.png');
     background-size: 100% 100%;
     background-position: center;
     .content{

+ 1 - 31
src/views/Login.vue

@@ -1,23 +1,6 @@
 <template>
   <div class="login" @keydown.enter="handleSubmit">
-    <div class="login-con">
-      <h1  class="login-title">金鹰数据可视化</h1>
-      <div class="login-form">
-        <Form ref="loginForm" :model="loginForm" :rules="loginRules">
-          <FormItem prop="userAccount" >
-            <Input placeholder="账号/手机号码" v-model="loginForm.userAccount" size="large" class="login-input">
-              <img src="../assets/images/account.png" slot="prefix" style="margin-top: 8px"/>
-            </Input>
-          </FormItem>
-          <FormItem prop="password">
-            <Input type="password" placeholder="密码" v-model="loginForm.password" size="large" class="login-input">
-              <img src="../assets/images/password.png" slot="prefix" style="margin-top: 8px"/>
-            </Input>
-          </FormItem>
-        </Form>
-        <Button class="login-submit" :loading="loginLoading" @click="handleSubmit" type="primary" shape="circle"  size="large">登录</Button>
-      </div>
-    </div>
+    
   </div>
 </template>
 
@@ -30,19 +13,6 @@ export default {
   name: 'Login',
   data () {
     return {
-      loginLoading: false,
-      loginForm: {
-        userAccount: '11',
-        password: '11',
-        isSecurity: 0
-      },
-      loginRules: {
-        userAccount: [
-          {required: true, message: '账号不能为空', trigger: 'blur'}
-        ],
-        password: [
-          {required: true, message: '密码不能为空', trigger: 'blur'}
-        ]}
     }
   },
   computed: {

+ 1 - 0
src/views/maintain/index.vue

@@ -1,5 +1,6 @@
 <template>
   <div class="container">
+    4
     <div class="container-title" :style="{fontSize: resizeWidth * 0.01875 + 'px'}">{{common.pageTitle}}</div>
     <div class="index-logo" :style="{width: resizeWidth * 0.305 + 'px', height: resizeWidth * 0.283 + 'px'}"></div>
     <div class="index-icon sqp-icon" :style="{width: resizeWidth * 0.138 + 'px', height: resizeWidth * 0.096 + 'px',

+ 36 - 30
src/views/synthetic/index.vue

@@ -232,10 +232,10 @@ export default {
                 ])
             }
         },
-        { title: '班次', key: 'shift', align: 'center' },
-        { title: '负责人', key: 'principalName', align: 'center' },
-        { title: '状态', slot: 'status', align: 'center' },
-        { title: '备注', key: 'remark', align: 'center' },
+        { title: '班次', key: 'shift', align: 'center'},
+        { title: '负责人', key: 'principalName', align: 'center'},
+        { title: '状态', slot: 'status', align: 'center'},
+        { title: '备注', key: 'remark', align: 'center'},
         // ...this.tableOtherColumns.filter(site => site.show).map(site => {
         ...this.tableOtherColumns.map(site => {
           if(!this.columnIndex){
@@ -256,25 +256,25 @@ export default {
                     style: {
                       float: 'left',
                       fontSize: '24px',
-                      display: this.hasLastWeek ? '' : 'none'
+                      // display: this.hasLastWeek ? '' : 'none'
                     },
                     on: {
                       click: () => {
-                        this.changeColumns(params.column.title-1)
+                        this.changeColumns(params.column.title[1]-1)
                       }
                     }
                   }),
-                  h('span', params.column.title)
+                  h('span', params.column.title[0]+'-'+params.column.title[1]+'(week)'),
                 ])
               },
               children: [
-                { title: 'Mon', slot: 'monOne', align: 'center' },
-                { title: 'Tue', slot: 'tueOne', align: 'center' },
-                { title: 'Wen', slot: 'wenOne', align: 'center' },
-                { title: 'Thu', slot: 'thuOne', align: 'center' },
-                { title: 'Fri', slot: 'friOne', align: 'center' },
-                { title: 'Sat', slot: 'satOne', align: 'center' },
-                { title: 'Sun', slot: 'sunOne', align: 'center' }
+                { title: '周一', slot: 'monOne', align: 'center' },
+                { title: '周二', slot: 'tueOne', align: 'center' },
+                { title: '周三', slot: 'wenOne', align: 'center' },
+                { title: '周四', slot: 'thuOne', align: 'center' },
+                { title: '周五', slot: 'friOne', align: 'center' },
+                { title: '周六', slot: 'satOne', align: 'center' },
+                { title: '周日', slot: 'sunOne', align: 'center' }
               ]
             }
           } else {
@@ -286,7 +286,8 @@ export default {
               renderHeader: (h, params) => {
                 // console.log(params)
                 return h('div', [
-                  h('span', params.column.title),
+                  h('span', params.column.title[0]+'-'+params.column.title[1]+'(week)'),
+                  // title':year+'-'+data.week+'(week)
                   h('Icon', {
                     props: {
                       type: 'md-arrow-dropright'
@@ -294,24 +295,24 @@ export default {
                     style: {
                       float: 'right',
                       fontSize: '24px',
-                      display: this.hasNextWeek ? '' : 'none'
+                      // display: this.hasNextWeek ? '' : 'none'
                     },
                     on: {
                       click: () => {
-                        this.changeColumns(params.column.title)
+                        this.changeColumns(params.column.title[1])
                       }
                     }
                   })
                 ])
               },
               children: [
-                { title: 'Mon', slot: 'monTwo', align: 'center' },
-                { title: 'Tue', slot: 'tueTwo', align: 'center' },
-                { title: 'Wen', slot: 'wenTwo', align: 'center' },
-                { title: 'Thu', slot: 'thuTwo', align: 'center' },
-                { title: 'Fri', slot: 'friTwo', align: 'center' },
-                { title: 'Sat', slot: 'satTwo', align: 'center' },
-                { title: 'Sun', slot: 'sunTwo', align: 'center' }
+                { title: '周一', slot: 'monTwo', align: 'center' },
+                { title: '周二', slot: 'tueTwo', align: 'center' },
+                { title: '周三', slot: 'wenTwo', align: 'center' },
+                { title: '周四', slot: 'thuTwo', align: 'center' },
+                { title: '周五', slot: 'friTwo', align: 'center' },
+                { title: '周六', slot: 'satTwo', align: 'center' },
+                { title: '周日', slot: 'sunTwo', align: 'center' }
               ]
             }
           }
@@ -326,10 +327,12 @@ export default {
       resizeWidth: 100,
       resizeHeight: 100,
       data: {
-        "date": "",
+        "date": '',
         "shift": '',
-        "weekOfYear": 0
+        "weekOfYear": 0,
+        "year": ''
       },
+      year: '',
       remarkId: 0,
       remarkDate: '',
       tableOtherColumns: [],
@@ -364,8 +367,10 @@ export default {
         }
         let data = res.data
         this.tableOtherColumns = []
-        this.tableOtherColumns.push({'title':data.week})
-        this.tableOtherColumns.push({'title':data.lastWeek})
+        // this.tableOtherColumns.push({'title':year+'-'+data.week+'(week)'})
+        this.tableOtherColumns.push({'title':[data.year,data.week]})
+        this.tableOtherColumns.push({'title':[data.year,data.lastWeek]})
+        this.year = data.year
         this.hasLastWeek = data.hasLastWeek
         this.hasNextWeek = data.hasNextWeek
         for(let item of data.projectModle) {
@@ -457,6 +462,7 @@ export default {
     changeColumns (index) {
       this.data.weekOfYear = index
       this.data.date = ''
+      this.data.year = this.year
       this.upkeep_week_tv_look(this.data)
     },
     //  跳转详情
@@ -644,8 +650,8 @@ export default {
     border-radius: 0;
   }
   .nobody{
-    width: 15px;
-    height: 15px;
+    width: 30px;
+    height: 30px;
     border-radius: 8px;
     background-color: transparent;
   }